Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[tracecompass-dev] LTTng-UST with custom trace points

Hi 

I would like to effectively use "-finstrument-functions" but only in selected scopes in my code. I cannot really afford to partition this code into separate files which my build system could feed the compiler directive.  Also it would still leave me instrumenting std::find etc ...

I tried this by inserting a simple lifetime object into some scopes via a macro. On construction this object calls __cyg_profile_func_enter and on destruction calls __cyg_profile_func_exit. These need an address so I passed the address of a static char* inserted by the same macro which was set to the "function name". At the end of my process I write all this addresses to a file to create my function name mapping file. 

All goes well when I bring up TraceCompass - I can see my call stack, with bogus addresses. However, I try import my mapping file TraceCompass only seems to want me to point to a binary. I am using LTTng 2.9 - is the file option disabled? I was hoping I wouldn't have to post-process the CTF output.

thanks

Dominic

Back to the top