* i am getting same profile(for gcc) for all testcases
@ 2004-03-04 3:03 perugupa
2004-03-04 21:10 ` Jim Wilson
0 siblings, 1 reply; 5+ messages in thread
From: perugupa @ 2004-03-04 3:03 UTC (permalink / raw)
To: gcc
Hi,
i have compiled gcc3.2.3 with profiling enabled. i am using the
regression test suite to generate profiles for gcc (not for the test
case it self ie. i want to see whats heppening in gcc).i compiled gcc
like...
../gcc/configure --prefix=/src/inst --enable-languages=c,c++ \
--disable-checking
$ make -j8 all CFLAGS="-g -profile -O2"
$ make install
this is what i am using to generate profile file.
gcc test.c
gprof -a /root/install/bin/gcc gmon.out > output
I also tried this one
gprof -a /root/install/lib/gcc/TARGET/VERSION/cc1 gmon.out > output
but i am getting the same profiles for any program i compile.i have been
struggling to get this done for a long time.can somebody please help
me.thanx in advance.
regards
nath.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: i am getting same profile(for gcc) for all testcases
2004-03-04 3:03 i am getting same profile(for gcc) for all testcases perugupa
@ 2004-03-04 21:10 ` Jim Wilson
2004-03-04 21:46 ` Daniel Jacobowitz
2004-03-05 10:15 ` Segher Boessenkool
0 siblings, 2 replies; 5+ messages in thread
From: Jim Wilson @ 2004-03-04 21:10 UTC (permalink / raw)
To: perugupa; +Cc: gcc
perugupa@csee.wvu.edu wrote:
> $ make -j8 all CFLAGS="-g -profile -O2"
-profile isn't a gcc option. This might be the problem. Try -p or -pg.
-pg will give more info.
> this is what i am using to generate profile file.
> gcc test.c
> gprof -a /root/install/bin/gcc gmon.out > output
>
> I also tried this one
> gprof -a /root/install/lib/gcc/TARGET/VERSION/cc1 gmon.out > output
>
> but i am getting the same profiles for any program i compile.i have been
> struggling to get this done for a long time.can somebody please help
> me.thanx in advance.
It isn't clear what your problem is. What profiles are you getting?
Why do you think they are wrong?
Gcc contains multiple programs. If you compiled all of them with
profile info, then the profile output files may be overwriting each
other. Use gcc -v to see what all the gcc driver does, and try running
individual programs instead of running the gcc driver.
--
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: i am getting same profile(for gcc) for all testcases
2004-03-04 21:10 ` Jim Wilson
@ 2004-03-04 21:46 ` Daniel Jacobowitz
2004-03-05 10:15 ` Segher Boessenkool
1 sibling, 0 replies; 5+ messages in thread
From: Daniel Jacobowitz @ 2004-03-04 21:46 UTC (permalink / raw)
To: Jim Wilson; +Cc: perugupa, gcc
On Thu, Mar 04, 2004 at 01:10:04PM -0800, Jim Wilson wrote:
> perugupa@csee.wvu.edu wrote:
> > $ make -j8 all CFLAGS="-g -profile -O2"
>
> -profile isn't a gcc option. This might be the problem. Try -p or -pg.
> -pg will give more info.
Actually, for many targets, it is. It's handled completely in specs;
it implies -pg for compilation and on some targets -pg -lc_p when
linking.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: i am getting same profile(for gcc) for all testcases
2004-03-04 21:10 ` Jim Wilson
2004-03-04 21:46 ` Daniel Jacobowitz
@ 2004-03-05 10:15 ` Segher Boessenkool
2004-03-05 10:42 ` perugupa
1 sibling, 1 reply; 5+ messages in thread
From: Segher Boessenkool @ 2004-03-05 10:15 UTC (permalink / raw)
To: Jim Wilson; +Cc: gcc, perugupa
On 4-mrt-04, at 22:10, Jim Wilson wrote:
> Gcc contains multiple programs. If you compiled all of them with
> profile info, then the profile output files may be overwriting each
> other. Use gcc -v to see what all the gcc driver does, and try
> running individual programs instead of running the gcc driver.
Or set the environment variable GMON_OUT_PREFIX, i.e.,
export GMON_OUT_PREFIX=gmon
Segher
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: i am getting same profile(for gcc) for all testcases
2004-03-05 10:15 ` Segher Boessenkool
@ 2004-03-05 10:42 ` perugupa
0 siblings, 0 replies; 5+ messages in thread
From: perugupa @ 2004-03-05 10:42 UTC (permalink / raw)
To: segher; +Cc: wilson, gcc, perugupa
segher....,thanx and i will try this and let you know if it works.and is
it ok if i compile everything with profiling on or shall i compile only
cc1.how will i know which part of source code comes under 'C proper'.
Jim...,i sent a sample profile in last mail i will send it again later
today as i done have it with me at home right now.but its same every time
and i am using the regression test suite given with gcc release 3.2.3 (on
gcc3.2.3).
thanx for ur help guys..
regards,
nath
>
> On 4-mrt-04, at 22:10, Jim Wilson wrote:
>> Gcc contains multiple programs. If you compiled all of them with
>> profile info, then the profile output files may be overwriting each
>> other. Use gcc -v to see what all the gcc driver does, and try
>> running individual programs instead of running the gcc driver.
>
> Or set the environment variable GMON_OUT_PREFIX, i.e.,
>
> export GMON_OUT_PREFIX=gmon
>
>
> Segher
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2004-03-05 10:42 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-03-04 3:03 i am getting same profile(for gcc) for all testcases perugupa
2004-03-04 21:10 ` Jim Wilson
2004-03-04 21:46 ` Daniel Jacobowitz
2004-03-05 10:15 ` Segher Boessenkool
2004-03-05 10:42 ` perugupa
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).