[lttng-dev] Can tracepoint be listed before app registered?

zlynus 302590304 at qq.com
Tue Mar 11 21:56:00 EDT 2014


Here is the mail I send to Jérémie a few days ago, and I forgot cc to mail list (maybe the mail was rejected):


-------------------------------------------------
So far, I'm not familiar with the detailed implementation of lttng-ust, thus my idea is simple and naive: we can make use of the
tracepoint probe library which generated by lttng-gen-tp or manually by user. Whether the probe library is dynamic or static ,it must contain the tracepoint information.
The use case is as such a scenario:
The target app has defined many events and  the user don't want to go over the source code to recall them. Instead, after creating a new session, user issue a hypothetical subcommand 'load_probe' which gather the information from the probe library.And since then, user is able to list all available events yet before any app is launched.

-----------------------------------------------


 mathieu 's idea  implementing a ELF parser to provide early event-listing feature is a  good proposal. However, do you think the quantity of work is plenty enough to be a GSoC proposal?  I asked that because I saw some idea was turned down due to 'not complex enough' in some IRC channel.  


Lingyu
------------------ Original ------------------
From:  "Jérémie Galarne";<jeremie.galarneau at efficios.com>;
Date:  Wed, Mar 12, 2014 03:23 AM
To:  "Mathieu Desnoyers"<mathieu.desnoyers at efficios.com>; 
Cc:  "zlynus"<302590304 at qq.com>; "lttng-dev"<lttng-dev at lists.lttng.org>; 
Subject:  Re: [lttng-dev] Can tracepoint be listed before app registered?



On Tue, Mar 11, 2014 at 3:16 PM, Mathieu Desnoyers
<mathieu.desnoyers at efficios.com> wrote:
>
>
> ----- Original Message -----
>> From: "Jérémie Galarneau" <jeremie.galarneau at efficios.com>
>> To: "zlynus" <302590304 at qq.com>
>> Cc: "lttng-dev" <lttng-dev at lists.lttng.org>
>> Sent: Friday, March 7, 2014 1:23:01 PM
>> Subject: Re: [lttng-dev] Can tracepoint be listed before app registered?
>>
>> On Fri, Mar 7, 2014 at 12:26 PM, zlynus <302590304 at qq.com> wrote:
>> > Hi,
>> > Sorry to bother you guys. The lttng-tool man page dosen't make it clear
>> > that
>> > when the tracepoints of user-space application can be listed. So I did a
>> > little test. As far as I can tell ,the tracepoint information is only
>> > available during the application is running.
>> >
>>
>> Correct.
>>
>> > So is it possible that the tracepoint can be available *before* app get
>> > running, specifically, before enable-event subcommand? I think it can be
>> > quite convenient to output the list when specify which events to trace. If
>> > it is not for now,
>> > maybe it's a feature worth working on. My idea is lttng-tool could read
>> > tracer provider library and get the info,and  add a option after 'list'
>> > subcommand which let user specify the provider library to read. Just a
>> > personal opion from a new comer :-)
>> >
>>
>> You can enable an event before the app is started. However, as you
>> pointed out, the session daemon has no knowledge of application events
>> before they are launched.
>>
>> My understanding of your suggestion is that we should define a public
>> provider API on which the lttng client could hook itself to list
>> events. It would be of limited use in the case of statically linked
>> providers, but It's an interesting problem... Do you have a specific
>> use-case in mind?
>
> Another option that would take care of statically linked providers
> would be to let a lttng library look at all the executables on the system
> (or from a certain path in the system), as well as .so, and list a specific
> "tracepoint provider" section that we could specify. We'd need to parse
> ELF for this.
>
> Thoughts ?
>

I like the idea. Lingyu, would that be something you'd like to propose
as a GSoC project?

Regards,
Jérémie

> Thanks,
>
> Mathieu
>
>>
>> Regards,
>> Jérémie
>>
>> > Best regards,
>> > Lingyu Zhu
>> >
>> >
>> > _______________________________________________
>> > lttng-dev mailing list
>> > lttng-dev at lists.lttng.org
>> > http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
>> >
>>
>>
>>
>> --
>> Jérémie Galarneau
>> EfficiOS Inc.
>> http://www.efficios.com
>>
>> _______________________________________________
>> lttng-dev mailing list
>> lttng-dev at lists.lttng.org
>> http://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
>>
>
> --
> Mathieu Desnoyers
> EfficiOS Inc.
> http://www.efficios.com



-- 
Jérémie Galarneau
EfficiOS Inc.
http://www.efficio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lttng.org/pipermail/lttng-dev/attachments/20140312/8973a1f9/attachment.html>


More information about the lttng-dev mailing list