public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jim Wilson <wilson@redhat.com>
To: "Kaveh R. Ghazi" <ghazi@caip.rutgers.edu>
Cc: gcc-bugs@gcc.gnu.org, gcc@gcc.gnu.org, tprince@computer.org,
	David.Billinghurst@riotinto.com, echristo@redhat.com
Subject: Re: Profiling on mips-irix6?  (Testcase gcc.dg/nest.c failure)
Date: Thu, 03 Oct 2002 12:15:00 -0000	[thread overview]
Message-ID: <xwu4rc3weuk.fsf@tonopah.toronto.redhat.com> (raw)
In-Reply-To: <200210030530.BAA26682@caip.rutgers.edu>

Historically, SGI mips based systems have never supported gprof based
profiling.  This is because they have pixie/pixstats which is a more flexible
tool, and thus they apparently felt that they didn't need gprof.  Later pixie
was replaced by tools with fancy names, e.g. speedshop, but I think it is
still basically pixie underneath the covers.

The gcrt1.o stuff is in there on the principle that eventually someone would
port gprof to mips-sgi-irix systems, and hence we would need it anyways even
though the OS doesn't support gprof.

libprof1.a is for prof not gprof.  I think prof and its libraries are supposed
to be there.  It is only gprof/gcrt1.o that is missing from the OS.

gprof requires both compiler and library support in order to work.  I
think it makes sense to supply the compiler part even if the library part
is missing, because that makes it easier for library people to supply their
missing part, and gives them some incentive to do so.

If someone has reported that gprof profiling doesn't work on an irix system,
then the correct answer is to tell them that the OS doesn't support gprof.
I suppose we could change the irix ports to give an error message or ignore
the option instead of complaining about missing files.  I don't really care
anymore how this specific issue is handled.

Testcases that use -pg aren't portable, since not every OS supports gprof.
gprof was a BSD invention, and lots of AT&T derived OSes never supported it.
Plus on anything that isn't unix, you can't expect -pg to work.  This can
work only if gcc silently ignores -pg on all systems where gprof doesn't
work, but it is rude for gcc to silently ignore an option when it doesn't
work.  Getting an error from the irix compiler for -pg is somewhat better
than just ignoring it, though one could argue it either way.

Jim

      reply	other threads:[~2002-10-03 18:35 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-10-02  8:05 Kaveh R. Ghazi
2002-10-02 21:54 ` Tim Prince
2002-10-03  1:46   ` Kaveh R. Ghazi
2002-10-03 12:15     ` Jim Wilson [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xwu4rc3weuk.fsf@tonopah.toronto.redhat.com \
    --to=wilson@redhat.com \
    --cc=David.Billinghurst@riotinto.com \
    --cc=echristo@redhat.com \
    --cc=gcc-bugs@gcc.gnu.org \
    --cc=gcc@gcc.gnu.org \
    --cc=ghazi@caip.rutgers.edu \
    --cc=tprince@computer.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).