Skip to contentSkip to conversation

lttng-ust missing tracepoints

DISCUSSION Gerlando Falauto 2 participants 4 messages May 16, 2014 – May 21, 2014 4 messages not in the archive

lore
Share & tools
lore
#1 lore raw
In reply to a message not in the archive

Hi,

following up on my own mail:

On 05/15/2014 07:39 PM, Gerlando Falauto wrote:
[...]

Quoted 3 lines

If I put an additional tracef() call exactly where my tracepoint is located, this gets traced without a problem. So the infrastructure should be all working in my opinion.

I repeated my test by compiling the same tracepoint provider directly on the target, and linking it to a no-brainer main(), whose body simply calls tracepoint() and tracef(). And I now get the opposite result!

Now tracepoint() requests are perfectly recorded, whereas tracef() is nowhere to be seen.

Any hints?
Thank you!
Gerlando

#3 lore raw

linking of tracepoint probes

In reply to a message not in the archive

Hi,

I played a bit more and came to the following conclusion:

- if I compile the application statically (so the tracepoint calls as well as their providers are linked with the main executable), tracepoints work but tracef() doesn't

- if I compile and link the tracepoints, as well as the tracepoint calls, within a shared library, tracef() works but the tracepoint doesn't

- if I change the above setting and recompile without cleaning first, I end up with the following message:

LTTng-UST: Error (-17) while registering tracepoint probe. Duplicate registration of tracepoint probes having the same name is not allowed. Aborted

So this means I'm doing something wrong with linking and/or libraries.
As if I had the same symbol defined in two different places and one would win over the other according to how I'm compiling. Since I really have no clue how this whole machinery works, could someone please shed some light on this topic?

Thank you!
Gerlando

Quoted 21 lines · Gerlando Falauto

Hi,

following up on my own mail:

On 05/15/2014 07:39 PM, Gerlando Falauto wrote:
[...]

Quoted 3 lines

If I put an additional tracef() call exactly where my tracepoint is located, this gets traced without a problem. So the infrastructure should be all working in my opinion.

I repeated my test by compiling the same tracepoint provider directly on the target, and linking it to a no-brainer main(), whose body simply calls tracepoint() and tracef(). And I now get the opposite result!

Now tracepoint() requests are perfectly recorded, whereas tracef() is nowhere to be seen.

Any hints?
Thank you!
Gerlando

#5 lore raw

Re: linking of tracepoint probes

In reply to a message not in the archive
Quoted 8 lines · Gerlando Falauto

Hi,

I played a bit more and came to the following conclusion:

- if I compile the application statically (so the tracepoint calls as well as their providers are linked with the main executable), tracepoints work but tracef() doesn't

You need to enable the DEBUG log level. See the USAGE WITH TRACEF section of the lttng-ust man page.

Jérémie

Quoted 50 lines

- if I compile and link the tracepoints, as well as the tracepoint calls, within a shared library, tracef() works but the tracepoint doesn't

- if I change the above setting and recompile without cleaning first, I end up with the following message:

LTTng-UST: Error (-17) while registering tracepoint probe. Duplicate registration of tracepoint probes having the same name is not allowed. Aborted

So this means I'm doing something wrong with linking and/or libraries. As if I had the same symbol defined in two different places and one would win over the other according to how I'm compiling.
Since I really have no clue how this whole machinery works, could someone please shed some light on this topic?

Thank you!
Gerlando

Quoted 17 lines · Gerlando Falauto

Hi,

following up on my own mail:

On 05/15/2014 07:39 PM, Gerlando Falauto wrote:
[...]

Quoted 3 lines

If I put an additional tracef() call exactly where my tracepoint is located, this gets traced without a problem. So the infrastructure should be all working in my opinion.

I repeated my test by compiling the same tracepoint provider directly on the target, and linking it to a no-brainer main(), whose body simply calls tracepoint() and tracef(). And I now get the opposite result!

Quoted 6 lines

Now tracepoint() requests are perfectly recorded, whereas tracef() is nowhere to be seen.

Any hints?
Thank you!
Gerlando

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

Signature · 8 lines
Jérémie Galarneau
EfficiOS Inc.
http://www.efficios.com

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
#7 lore raw

Re: linking of tracepoint probes

In reply to a message not in the archive

Hi Jérémie,

Quoted 6 lines · Jérémie Galarneau
Quoted 4 lines · Gerlando Falauto

Hi,

I played a bit more and came to the following conclusion:

Quoted 7 lines
Quoted 4 lines

- if I compile the application statically (so the tracepoint calls as well as their providers are linked with the main executable), tracepoints work but tracef() doesn't

You need to enable the DEBUG log level. See the USAGE WITH TRACEF section of the lttng-ust man page.

I do enable it. See from my first email:

lttng enable-event -u -a --loglevel=TRACE_DEBUG

Really, in both cases what I do at userspace level is exactly the same. The only difference is in how I compile and link the application.
And I can get either tracef() or tracepoints to work, but never both at the same time.

Thank you,
Gerlando

Quoted 56 lines

Jérémie

Quoted 50 lines

- if I compile and link the tracepoints, as well as the tracepoint calls, within a shared library, tracef() works but the tracepoint doesn't

- if I change the above setting and recompile without cleaning first, I end up with the following message:

LTTng-UST: Error (-17) while registering tracepoint probe. Duplicate registration of tracepoint probes having the same name is not allowed. Aborted

So this means I'm doing something wrong with linking and/or libraries. As if I had the same symbol defined in two different places and one would win over the other according to how I'm compiling.
Since I really have no clue how this whole machinery works, could someone please shed some light on this topic?

Thank you!
Gerlando

Quoted 17 lines · Gerlando Falauto

Hi,

following up on my own mail:

On 05/15/2014 07:39 PM, Gerlando Falauto wrote:
[...]

Quoted 3 lines

If I put an additional tracef() call exactly where my tracepoint is located, this gets traced without a problem. So the infrastructure should be all working in my opinion.

I repeated my test by compiling the same tracepoint provider directly on the target, and linking it to a no-brainer main(), whose body simply calls tracepoint() and tracef(). And I now get the opposite result!

Quoted 6 lines

Now tracepoint() requests are perfectly recorded, whereas tracef() is nowhere to be seen.

Any hints?
Thank you!
Gerlando

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

_______________________________________________
lttng-dev mailing list
[email protected]
http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev