deadlock in lttng_ust_init

Bug #1618201 reported by Daniel d'Andrada
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
lttng-ust (Ubuntu)
New
Undecided
Unassigned
qtmir (Ubuntu)
Fix Released
Medium
Unassigned
ust (Ubuntu)
New
Undecided
Unassigned

Bug Description

Happens when running tests for https://code.launchpad.net/~dandrader/qtmir/content-hub-clipboard/+merge/303863 by CI.

This is the backtrace of where it gets stuck:
#0 0xffffffff in __pthread_mutex_unlock_usercnt (mutex=0xb6fff514 <_rtld_global+1220>, decr=1) at pthread_mutex_unlock.c:51
#1 0xffffffff in tls_get_addr_tail (ti=0xb637021c, dtv=0xb3757008, the_map=<optimized out>) at dl-tls.c:778
#2 0xffffffff in lttng_ust_init () at /usr/include/urcu/static/urcu-bp.h:158
#3 0xffffffff in lttng_ust_init () at lttng-ust-comm.c:369
#4 0xffffffff in lttng_ust_init () at lttng-ust-comm.c:1481
#5 0xffffffff in call_init (l=<optimized out>, argc=argc@entry=1, argv=argv@entry=0xbefff3d4, env=env@entry=0xbefff3dc) at dl-init.c:72
#6 0xffffffff in _dl_init (env=<optimized out>, argv=<optimized out>, argc=<optimized out>, l=<optimized out>) at dl-init.c:30
#7 0xffffffff in _dl_init (main_map=0xb6fff958, argc=1, argv=0xbefff3d4, env=0xbefff3dc) at dl-init.c:120
#8 0xffffffff in _dl_start_user () at /lib/ld-linux-armhf.so.3

It gets stuck during initialization, more specifically, inside lttng_fixup_urcu_bp_tls()

Related branches

Revision history for this message
Gerry Boland (gerboland) wrote :

This issue was worked around, but with a far-from-ideal solution

Changed in qtmir (Ubuntu):
status: New → Triaged
importance: Undecided → Medium
Changed in qtmir:
status: New → Triaged
importance: Undecided → Medium
Revision history for this message
Simon Marchi (simon-marchi) wrote :

Which version of liblttng-ust is that?

Revision history for this message
Mathieu Desnoyers (mathieu-desnoyers) wrote :

It seems odd that touching a shared object TLS (which triggers a TLS fixup) from a constructor would deadlock. Which version of glibc are you using ?

Revision history for this message
Daniel d'Andrada (dandrader) wrote :

It might have something to do with arm or chroot envs (likely what CI does) as tests run fine on my amd64 desktop but deadlock in a chroot on an arm device (like mako or flo).

Revision history for this message
Daniel d'Andrada (dandrader) wrote :

But on CI it also deadlocks in amd64.

Revision history for this message
Daniel d'Andrada (dandrader) wrote :

liblttng-ust 2.7.1-1~vividoverlay1
libglib2.0 2.44.1-1ubuntu1

About comments #4 and #5: what seems more relevant is actually ubuntu release/pkg versions since my desktop runs xenial+stable-phone-overlay whereas my arm devices run vivid+stable-phone-overlay.

Revision history for this message
Mathieu Desnoyers (mathieu-desnoyers) wrote :

What is your glibc version ? You provided your libglib version which is unrelated to lttng-ust.

Or are you using Android bionic libc... ?

Revision history for this message
Daniel d'Andrada (dandrader) wrote :

libc6 2.21-0ubuntu4.0.1

Revision history for this message
Michael Jeanson (mjeanson) wrote :
Changed in qtmir (Ubuntu):
status: Triaged → Fix Released
Changed in qtmir:
status: Triaged → Fix Released
Michał Sawicz (saviq)
no longer affects: qtmir
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.