[lttng-dev] Log semaphore, mutex in CTF

Jonathan Rajotte-Julien jonathan.rajotte-julien at efficios.com
Tue Jul 2 10:15:17 EDT 2019


HI Zvika,

It all depends on what exactly you traced. Did you trace some userspace
application? Did you trace the kernel?

A trace is as good as its tracepoints. You can use lttng list to get the
available tracepoints for each tracing domain:

>From "lttng-list" man page:

  With one or more of the --kernel, --userspace, --jul, --log4j, and --python
  domain options, the command lists the available event sources of the selected
  domain on the system. The JUL, log4j, and Python domains list the names of their
  available loggers. The --syscall option can be used alongside the --kernel
  option to get a list of traceable Linux system calls. The --fields option can be
  used to show the fields of the listed event sources.

AFAIK, lttng-modules does not instrument locking primitive.

lttng-ust does provides overwrite library for pthread_mutex_lock,
pthread_mutex_trylock and pthread_mutex_unlock. You will need to LD_PRELOAD (application start) it.

https://github.com/lttng/lttng-ust/tree/9d4d2a639afc19a1bd705ea560782917ac892596/liblttng-ust-libc-wrapper

Cheers.

On Mon, Jul 01, 2019 at 07:49:16AM +0300, Zvi Vered wrote:
> Hello,
> 
> I converted CTF files created by ltt-ng to text file using babeltrace.
> 
> Can you please tell how semaphore, mutex are logged in this text file ?
> 
> I did not find the terms "sema" or "mutex".
> 
> Thank you,
> Zvika

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


-- 
Jonathan Rajotte-Julien
EfficiOS


More information about the lttng-dev mailing list