This is the mail archive of the
sid@sources.redhat.com
mailing list for the SID project.
Re: Profiling
- From: Scott Dattalo <scott at dattalo dot com>
- Cc: sid at sources dot redhat dot com
- Date: Tue, 25 Jun 2002 19:01:39 -0700 (PDT)
- Subject: Re: Profiling
On Tue, 25 Jun 2002, Frank Ch. Eigler wrote:
> Hi -
>
>
> On Tue, Jun 25, 2002 at 05:03:05PM -0700, Scott Dattalo wrote:
> > I'm trying to collect profile info on my ARM-based application. [...]
> > connect-pin main perform-activity -> gprof sample
> > connect-pin main stopping -> gprof store
>
> The "perform-activity" pin may signal infrequently compared to
> CPU instruction rates, so you will get a relatively low sample rate.
> You could connect that gprof sample pin from another source, such as
> the scheduler's CPU-bound NNN-output signal.
>
> > [...]
> > Now when I run gprof:
> > $ gprof --flat-profile gmon.out
> > I get the error:
> > gprof: gmon.out: not in a.out format
>
> This is a simple gprof usage error. gprof implicitly looks for the
> file named gmon.out, but it doesn't know what *target executable* to
> relate it to. gprof needs to process the executable in order to
> extract its symbol table, so that the PC sample addresses in gmon.out
> can become sensible. So, all you need to do is build the cross-gprof,
> and run
>
> arm-elf-gprof file.exe
Yes, I surmised as much when I saw the SID screen shot with this command.
But the question I have is how do you build arm-elf-gprof (I posed this
question to the eCos list as well, BTW)? When I follow the arm-elf tool
chain build instructions, I get a whole lot of arm-elf-* files, but no
gprof. I tried --enable-gprof as part of the binutil ./configure, but that
didn't do it. Of course, I'm just guessing at this point...
BTW, this is where I got the arm-elf build instructions:
http://sources.redhat.com/ecos/tools/linux-arm-elf.html
Scott