[Bug 211947] bconsole won't die sitting on do_rw_wrlock
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Wed Aug 24 09:02:27 UTC 2016
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=211947
Konstantin Belousov <kib at FreeBSD.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |kib at FreeBSD.org
--- Comment #3 from Konstantin Belousov <kib at FreeBSD.org> ---
I can reproduce a hang with your test program with stable/10 libs on 11 kernel.
On the other hand, I run your program in a loop for a hour on HEAD machine and
was not able to observe the hang.
When the program hangs, I see that the only live thread waits for the
rtld_bind_lock, which is declared as write locked. So it looks as if the
cancelled thread leaked the rtld bind lock. It might be only appearance of the
leak, though.
[Switching to LWP 101215 of process 54629]
_umtx_op_err () at /usr/src/lib/libthr/arch/i386/i386/_umtx_op_err.S:36
36 SYSCALL_ERR(_umtx_op)
(gdb) bt
#0 _umtx_op_err () at /usr/src/lib/libthr/arch/i386/i386/_umtx_op_err.S:36
#1 0x2807fe01 in __thr_rwlock_wrlock (rwlock=0x0, tsp=<optimized out>)
at /usr/src/lib/libthr/thread/thr_umtx.c:297
#2 0x280884c0 in _thr_rwlock_wrlock (rwlock=<optimized out>,
tsp=<optimized out>) at /usr/src/lib/libthr/thread/thr_umtx.h:204
#3 _thr_rtld_wlock_acquire (lock=0x28097d00)
at /usr/src/lib/libthr/thread/thr_rtld.c:141
#4 0x280539ff in wlock_acquire (lock=0x28063f58 <rtld_locks>,
lockstate=0xffffd598) at /usr/src/libexec/rtld-elf/rtld_lock.c:217
#5 0x2804da23 in objlist_call_fini (list=<optimized out>,
root=<optimized out>, lockstate=<optimized out>)
at /usr/src/libexec/rtld-elf/rtld.c:2421
#6 0x2804cb7a in rtld_exit () at /usr/src/libexec/rtld-elf/rtld.c:2801
#7 0x281a68ab in __cxa_finalize (dso=<optimized out>)
at /usr/src/lib/libc/stdlib/atexit.c:200
#8 0x28146f7f in exit (status=-10552) at /usr/src/lib/libc/stdlib/exit.c:73
#9 0x080488f6 in main () at pr-211947.c:70
(gdb) frame 4
#4 0x280539ff in wlock_acquire (lock=0x28063f58 <rtld_locks>,
lockstate=0xffffd598) at /usr/src/libexec/rtld-elf/rtld_lock.c:217
217 lockinfo.wlock_acquire(lock->handle);
(gdb) p/x *(struct urwlock *)(lock->handle)
$3 = {rw_state = 0xa0000000, rw_flags = 0x2, rw_blocked_readers = 0x0,
rw_blocked_writers = 0x0, rw_spare = {0x0, 0x0, 0x0, 0x0}}
0xa0000000 == URWLOCK_WRITE_OWNER | URWLOCK_READ_WAITERS
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-threads
mailing list