public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Dan Kegel <dank@kegel.com>
To: law@redhat.com
Cc: GCC Mailing List <gcc@gcc.gnu.org>,  bastian@kde.org
Subject: Re: profile-driven optimization and the linker?
Date: Fri, 26 Nov 2004 06:19:00 -0000	[thread overview]
Message-ID: <41A6AC41.7000305@kegel.com> (raw)
In-Reply-To: <1101419643.13475.69.camel@localhost.localdomain>

I went looking for instances of people using gprof's --function-ordering
option, but came up fairly empty handed.  Anyone
have good references?  Here's the little bit I dug up:

Ben's post just now was pretty good, even though that was for data and not code:
http://gcc.gnu.org/ml/gcc/2004-11/msg01002.html
Did reordering the global variables end up helping performance on any
interesting tasks?

http://gcc.gnu.org/ml/gcc-patches/2001-11/msg00935.html says
"Steve Christiansen tried using gprof output to create a linker
script that orders functions based on run-time call graphs
and call counts, but couldn't show that it made a difference, based on SPEC CPU2000 results."
(Since the --function-ordering option was added to gprof at
the end of 1995, I imagine Steve Christiansen used it.
On the other hand, since glibc aborted with more
than 64K symbols when run with -pg until late 2002,
maybe he ran into trouble there.)

http://vr3.uid0.sk/cd/Mailinglist_Archives/agenda-mail/agenda-user/200107/995378424.txt says
Jay Carlson gave it a try, but doesn't have any results.

http://sources.redhat.com/binutils/docs-2.15/ld/Input-Section.html#Input%20Section
describes (just barely) how one writes a linker script
to map a given list of input sections to an output section.
That plus gcc's -ffunction-sections option are probably needed
to use this.
- Dan

-- 
Trying to get a job as a c++ developer?  See http://kegel.com/academy/getting-hired.html

  parent reply	other threads:[~2004-11-26  5:08 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-11-25 19:49 Dan Kegel
2004-11-25 20:38 ` Jeffrey A Law
2004-11-25 21:07   ` Dan Kegel
2004-11-25 22:52     ` Joseph S. Myers
2004-11-26  5:32       ` Dan Kegel
2004-11-29 18:05       ` Joe Buck
2004-11-25 23:13     ` Jeffrey A Law
2004-11-26  5:08       ` Dan Kegel
2004-11-26  6:19       ` Dan Kegel [this message]
2004-11-26  8:55         ` Dan Kegel
2004-11-29 16:30         ` Will Cohen
2004-11-26  0:01   ` Ben Elliston
2004-11-29 16:20   ` Will Cohen
2004-11-30  3:24     ` Dan Kegel

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=41A6AC41.7000305@kegel.com \
    --to=dank@kegel.com \
    --cc=bastian@kde.org \
    --cc=gcc@gcc.gnu.org \
    --cc=law@redhat.com \
    /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).