Mirror of the lttng-dev mailing list
 help / color / mirror / Atom feed
From: mathieu.desnoyers@efficios.com (Mathieu Desnoyers)
Subject: [lttng-dev] SIG33 message
Date: Tue, 16 Apr 2019 14:11:53 -0400 (EDT)	[thread overview]
Message-ID: <56684942.2314.1555438313423.JavaMail.zimbra@efficios.com> (raw)
In-Reply-To: <03778ce1-f017-176a-3c5f-35fba359b5aa@gydle.com>


----- On Apr 16, 2019, at 1:58 PM, Sebastien Boisvert sboisvert at gydle.com wrote:

> Hi Mosleh,
> 
> (I just saw Mathieu's answer arrive in my inbox while I was writing this.)
> 
> First, I don't know the exact solution.
> 
> 
> In Linux, signals are sent with the kill() function.
> 
> In the LTTng-UST source code, there are 3 signals that relate to 'Suspended:
> Signal: SIG33:Real-time event 33' (RT):
> 
> libringbuffer/ring_buffer_frontend.c:82:#define LTTNG_UST_RB_SIG_FLUSH		SIGRTMIN
> libringbuffer/ring_buffer_frontend.c:83:#define LTTNG_UST_RB_SIG_READ		SIGRTMIN
> + 1
> libringbuffer/ring_buffer_frontend.c:84:#define LTTNG_UST_RB_SIG_TEARDOWN
> 	SIGRTMIN + 2
> 
> =>
> http://git.lttng.org/?p=lttng-ust.git;a=blob;f=libringbuffer/ring_buffer_frontend.c;h=9721df1634585f028316d13f96b184af7e99cc08;hb=HEAD#l82
> 
> 
> On my system (Ubuntu 18.04.2 LTS with Linux 4.15.0-47-generic), SIGRTMIN = 34.
> 
> Check with 'kill -l SIGRTMIN' on your system to see if it it the same value.
> 
> 
> 
> In the LTTng-UST source code, there 1 this call to kill():
> 
> libringbuffer/ring_buffer_frontend.c:767:	kill(getpid(),
> LTTNG_UST_RB_SIG_TEARDOWN);
> 
> =>
> http://git.lttng.org/?p=lttng-ust.git;a=blob;f=libringbuffer/ring_buffer_frontend.c;h=9721df1634585f028316d13f96b184af7e99cc08;hb=HEAD#l767
> 
> 
> 
> 
> These custom signals seem to be handled here:
> 
> libringbuffer/ring_buffer_frontend.c:660
> 
> =>
> http://git.lttng.org/?p=lttng-ust.git;a=blob;f=libringbuffer/ring_buffer_frontend.c;h=9721df1634585f028316d13f96b184af7e99cc08;hb=HEAD#l660

Hi Sebastien,

This part of the ring buffer should only be used by the consumer daemon through
liblttng-ust-ctl.so, never from the traced applications.

So I keep suspecting that it's NPTL's use of SIG33 which is causing an old
version of gdb to trap, ref: https://gdb.sourceware.narkive.com/SzqG56iA/program-received-signal-sig33-real-time-event-33

Thanks,

Mathieu

> 
> 
> 
> 
> On 2019-04-04 3:26 p.m., Mosleh Uddin wrote:
>> Hello,
>> 
>> I am building an application which I am compiling with the 'lttng-ust' flag.
>> When I try to debug the application using gdb, I get a 'Suspended: Signal:
>> SIG33:Real-time event 33' message. This only happens when I compile with the
>> 'lttng-ust' flag, if I remove it I no longer have this issue. Any insight?
>> 
>> Regards,
>> Mosleh
>> 
>> _______________________________________________
>> lttng-dev mailing list
>> lttng-dev at lists.lttng.org
>> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev
>> 
> _______________________________________________
> lttng-dev mailing list
> lttng-dev at lists.lttng.org
> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

-- 
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com


  reply	other threads:[~2019-04-16 18:11 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CAJyWpKFdOV6uiwWUicD5GNSSjWsD1TXjn=p45p_g6xu7F3HJbQ@mail.gmail.com>
2019-04-16 17:40 ` Mathieu Desnoyers
2019-04-16 17:58 ` Sebastien Boisvert
2019-04-16 18:11   ` Mathieu Desnoyers [this message]
2019-04-16 18:21     ` Sebastien Boisvert
2019-04-16 18:41       ` Mathieu Desnoyers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=56684942.2314.1555438313423.JavaMail.zimbra@efficios.com \
    --to=mathieu.desnoyers@efficios.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox