[lttng-dev] LTTng-UST and "ip" context

Woegerer, Paul Paul_Woegerer at mentor.com
Tue Mar 4 03:25:48 EST 2014


Hi David,

On 03/03/2014 11:24 PM, David OShea wrote:
> Hi all,
> 
>  
> 
> Apologies if this is a stupid question, but is the “ip” context meant to
> be used with LTTng-UST?  I tried it out, and the address in the field
> pointed to the TRACEPOINT_EVENT definition in my header file, i.e. not
> to the tracepoint() call site.  Could this be due to the fact that I use

That's most likely a side effect of having debug info with macro
expansion (e.g. caused by compiling with -g3).

See: GCC info pages:

     Level 3 includes extra information, such as all the macro
     definitions present in the program.  Some debuggers support macro
     expansion when you use `-g3'.

Use 'addr2line -i' if you want to see where the TRACEPOINT_EVENT macro
was expanded instead of the definition of the macro itself:

       -i
       --inlines
           If the address belongs to a function that was inlined, the
           source information for all enclosing scopes back to the
           first non-inlined function will also be printed. ....


For example:

addr2line -e $PREFIX/bin/test 400ee6
/home/pwoegere/test/test_tracepoint.h:18

With -i you get:

addr2line -i -e $PREFIX/bin/test 400ee6
/home/pwoegere/test/test_tracepoint.h:18
/home/pwoegere/test/test.c:15 <-- That's what you want !


HTH,
Paul


> dynamic trace providers, could it be due to my compile options, or is
> this only meant for kernel tracing?
> 
>  
> 
> This is with the following (with some minor patches, so admittedly it
> could be my fault) on CentOS 6:
> 
> babeltrace-1.1.2
> 
> lttng-tools-2.3.2
> 
> lttng-ust-2.3.2
> 
> userspace-rcu-0.8.3
> 
>  
> 
> Thanks in advance,
> David
> 
> ------------------------------------------------------------------------
> The information contained in this transmission may be confidential. Any
> disclosure, copying, or further distribution of confidential information
> is not permitted unless such privilege is explicitly granted in writing
> by Quantum. Quantum reserves the right to have electronic
> communications, including email and attachments, sent across its
> networks filtered through anti virus and spam software programs and
> retain such messages in order to comply with applicable data security
> and retention requirements. Quantum is not responsible for the proper
> and complete transmission of the substance of this communication or for
> any delay in its receipt.
> 
> 
> _______________________________________________
> lttng-dev mailing list
> lttng-dev at lists.lttng.org
> http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
> 


-- 
Paul Woegerer, SW Development Engineer
Sourcery Analyzer <http://go.mentor.com/sourceryanalyzer>
Mentor Graphics, Embedded Software Division



More information about the lttng-dev mailing list