[parisc-linux] gcc instrument-function on parisc?
John David Anglin
dave at hiauly1.hia.nrc.ca
Tue Apr 18 10:20:21 MDT 2006
> OTOH I find this comment in gcc-4.0 info:
> `-finstrument-functions'
> Generate instrumentation calls for entry and exit to functions.
> Just after function entry and just before function exit, the
> following profiling functions will be called with the address of
> the current function and its call site. (On some platforms,
> `__builtin_return_address' does not work beyond the current
> function, so the call site information may not be available to the
> profiling functions otherwise.)
>
> Is 'some platform' include parisc?
Yes, `__builtin_return_address' only provides the return address
for the current function on PA-RISC (on some targets, it can unwind
multiple levels). There's some question in my mind as to whether it
handles all stubs correctly. If it detects a stub, it tries to
provide the return address for the stub. It's guaranteed not to
work in a signal handler.
The above hasn't really been tested as far as I know on parisc.
Dave
--
J. David Anglin dave.anglin at nrc-cnrc.gc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6602)
More information about the parisc-linux
mailing list