gcc + gprof : basic bloc counting

  • Thread starter =?iso-8859-1?q?Nicolas_Herv=E9?=
  • Start date
?

=?iso-8859-1?q?Nicolas_Herv=E9?=

I am using gprof, and as explain in
http://www.gnu.org/software/binutils/manual/gprof-2.9.1/html_node/gprof_18.html#SEC18
I could use the "-g -pg -a" options of gcc and then use the "-l -A"
options of gprof to obtain an anotated source listing at the basic
bloc level.

Unfortunately my version of gcc (4.0.0) does not recognize the "-a"
option.
cc1: error: unrecognized command line option "-a"

So does the option name have changed, or does this feature desapears ?
I have tried with the -fprofile-arcs option, but it does'nt seems to
be the good one.

Any Idee ?
Thanks
 
F

Flash Gordon

Nicolas Hervé wrote, On 25/07/07 22:08:
I am using gprof, and as explain in

<snip>

This is about gcc and gprof rather than about the C programming
language, so you need to ask somewhere specific to you tools or OS such
as gnu.gcc.help or one of the GNU mailing lists.
-
Flash Gordon
 
R

Richard

Nicolas Hervé said:
I am using gprof, and as explain in
http://www.gnu.org/software/binutils/manual/gprof-2.9.1/html_node/gprof_18.html#SEC18
I could use the "-g -pg -a" options of gcc and then use the "-l -A"
options of gprof to obtain an anotated source listing at the basic
bloc level.

Unfortunately my version of gcc (4.0.0) does not recognize the "-a"
option.
cc1: error: unrecognized command line option "-a"

So does the option name have changed, or does this feature desapears ?
I have tried with the -fprofile-arcs option, but it does'nt seems to
be the good one.

Any Idee ?
Thanks


it's wrong or misleading.

-pg to activate and link the profiling libraries
-g for line by line profiling

-a is an option for gprof.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top