[lttng-dev] Check if userland tracing enabled

Philippe Proulx eeppeliteloop at gmail.com
Fri Sep 22 14:59:56 UTC 2017


On Fri, Sep 22, 2017 at 10:06 AM, Simon Crowe <smncrowe at gmail.com> wrote:
> All,
>
> I am looking a userland C program, but i want the application to do a little
> extra work when there is a tracing session active, is there fast call I
> could use which would tell me if a tracing session is in progress on my app
> or particular trace name

You can use tracepoint_enabled() and do_tracepoint() at least, which
is somewhat equivalent.

See <http://lttng.org/man/3/lttng-ust/v2.10/#doc-tracepoint>.

Phil
>
> Regards
>
> Si
>
> _______________________________________________
> lttng-dev mailing list
> lttng-dev at lists.lttng.org
> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
>


More information about the lttng-dev mailing list