gprof output question

MR ZenWiz mrzenwiz@gmail.com
Fri Feb 21 18:23:00 GMT 2014


On Fri, Feb 21, 2014 at 9:51 AM, Tim Prince <n8tm@aol.com> wrote:
>
> On 2/20/2014 6:42 PM, MR ZenWiz wrote:
>>
>> In using gprof on a large C++ app, there are a number of functions in
>> the output that do not have any class name or parameters associated
>> with them.
>>
>> In a thorough search of the app source, I cannot find any functions
>> defined with a particular name that shows up like this in the gprof
>> output.
>>
>> How can I track down where these functions live?
>>
>> In the call trace section, they show up as "spontaneous," so I can't
>> even tell from where they are called.
>>
>> Any guidance would be most appreciated.
>>
>> Thanks.
>>
>> MR
>
> A function called from a source file not built with -pg or via a function
> pointer (so that the actual function isn't known at compile time) would
> likely produce a <spontaneous>.  It's also helpful to use -static linking.
>
The external libraries involved here are all statically linked.

That does help, though.  I've created a test version that uses a
different library and we'll see what happens.  Hopefully it will
confirm my diagnosis and we can move forward.

Thanks.

MR



More information about the Gcc-help mailing list