[Mono-bugs] [Bug 662741] New: Random SIGSEGV in signal handlers (mono_install_handler_block_guard)

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Thu Jan 6 08:30:10 EST 2011


https://bugzilla.novell.com/show_bug.cgi?id=662741

https://bugzilla.novell.com/show_bug.cgi?id=662741#c0


           Summary: Random SIGSEGV in signal handlers
                    (mono_install_handler_block_guard)
    Classification: Mono
           Product: Mono: Runtime
           Version: SVN
          Platform: x86-64
        OS/Version: All
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: JIT
        AssignedTo: lupus at novell.com
        ReportedBy: jeremie.laval at gmail.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---
           Blocker: ---


Created an attachment (id=407203)
 --> (http://bugzilla.novell.com/attachment.cgi?id=407203)
Testcase

User-Agent:       Mozilla/5.0 (X11; U; Linux x86_64; en-US) AppleWebKit/534.10
(KHTML, like Gecko) Chrome/8.0.552.224 Safari/534.10

Mono randomly segfaults when executing the test case repeatedly. 

Reproducible: Always

Steps to Reproduce:
Run provided testcase in a while loop and hope it triggers fast enough.
Actual Results:  
Following stacktrace (relevant part is in Thread 2):

Stacktrace:


Native stacktrace:

    /home/jeremie/mono/mono/mono/mini/mono() [0x48f726]
    /home/jeremie/mono/mono/mono/mini/mono() [0x4df25f]
    /home/jeremie/mono/mono/mono/mini/mono() [0x41a899]
    /lib/libpthread.so.0(+0xf070) [0x7f1eb4960070]
    /home/jeremie/mono/mono/mono/mini/mono() [0x48c48e]
    /home/jeremie/mono/mono/mono/mini/mono() [0x48e5bd]
    /home/jeremie/mono/mono/mono/mini/mono() [0x4908bc]
    /home/jeremie/mono/mono/mono/mini/mono() [0x4e3f67]
    /lib/libpthread.so.0(+0xf070) [0x7f1eb4960070]
    [0x40b91390]

Debug info from gdb:

[Thread debugging using libthread_db enabled]
[New Thread 0x7f1eabfff700 (LWP 7511)]
[New Thread 0x7f1eb06fb700 (LWP 7508)]
[New Thread 0x7f1eb13fb700 (LWP 7507)]
[New Thread 0x7f1eb1bfc700 (LWP 7506)]
[New Thread 0x7f1eb23fd700 (LWP 7505)]
[New Thread 0x7f1eb2bfe700 (LWP 7504)]
[New Thread 0x7f1eb33ff700 (LWP 7503)]
[New Thread 0x7f1eb3c00700 (LWP 7502)]
[New Thread 0x7f1eb4401700 (LWP 7501)]
0x00007f1eb495c324 in pthread_cond_wait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
  10 Thread 0x7f1eb4401700 (LWP 7501)  0x00007f1eb495c324 in
pthread_cond_wait@@GLIBC_2.3.2 () from /lib/libpthread.so.0
  9 Thread 0x7f1eb3c00700 (LWP 7502)  0x00007f1eb495c324 in
pthread_cond_wait@@GLIBC_2.3.2 () from /lib/libpthread.so.0
  8 Thread 0x7f1eb33ff700 (LWP 7503)  0x00007f1eb495c324 in
pthread_cond_wait@@GLIBC_2.3.2 () from /lib/libpthread.so.0
  7 Thread 0x7f1eb2bfe700 (LWP 7504)  0x00007f1eb495c324 in
pthread_cond_wait@@GLIBC_2.3.2 () from /lib/libpthread.so.0
  6 Thread 0x7f1eb23fd700 (LWP 7505)  0x00007f1eb495c324 in
pthread_cond_wait@@GLIBC_2.3.2 () from /lib/libpthread.so.0
  5 Thread 0x7f1eb1bfc700 (LWP 7506)  0x00007f1eb495c324 in
pthread_cond_wait@@GLIBC_2.3.2 () from /lib/libpthread.so.0
  4 Thread 0x7f1eb13fb700 (LWP 7507)  0x00007f1eb495c324 in
pthread_cond_wait@@GLIBC_2.3.2 () from /lib/libpthread.so.0
  3 Thread 0x7f1eb06fb700 (LWP 7508)  0x00007f1eb495e460 in sem_wait () from
/lib/libpthread.so.0
  2 Thread 0x7f1eabfff700 (LWP 7511)  0x00007f1eb495f1cd in read () from
/lib/libpthread.so.0
* 1 Thread 0x7f1eb53f1740 (LWP 7492)  0x00007f1eb495c324 in
pthread_cond_wait@@GLIBC_2.3.2 () from /lib/libpthread.so.0

Thread 10 (Thread 0x7f1eb4401700 (LWP 7501)):
#0  0x00007f1eb495c324 in pthread_cond_wait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#1  0x00000000005e229d in GC_wait_marker () at pthread_support.c:1863
#2  0x00000000005db9c0 in GC_help_marker (my_mark_no=11) at mark.c:1116
#3  0x00000000005e0f64 in GC_mark_thread (id=0x0) at pthread_support.c:552
#4  0x00007f1eb4957c60 in start_thread () from /lib/libpthread.so.0
#5  0x00007f1eb46c37ed in clone () from /lib/libc.so.6
#6  0x0000000000000000 in ?? ()

Thread 9 (Thread 0x7f1eb3c00700 (LWP 7502)):
#0  0x00007f1eb495c324 in pthread_cond_wait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#1  0x00000000005e229d in GC_wait_marker () at pthread_support.c:1863
#2  0x00000000005db9c0 in GC_help_marker (my_mark_no=11) at mark.c:1116
#3  0x00000000005e0f64 in GC_mark_thread (id=0x1) at pthread_support.c:552
#4  0x00007f1eb4957c60 in start_thread () from /lib/libpthread.so.0
#5  0x00007f1eb46c37ed in clone () from /lib/libc.so.6
#6  0x0000000000000000 in ?? ()

Thread 8 (Thread 0x7f1eb33ff700 (LWP 7503)):
#0  0x00007f1eb495c324 in pthread_cond_wait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#1  0x00000000005e229d in GC_wait_marker () at pthread_support.c:1863
#2  0x00000000005db9c0 in GC_help_marker (my_mark_no=11) at mark.c:1116
#3  0x00000000005e0f64 in GC_mark_thread (id=0x2) at pthread_support.c:552
#4  0x00007f1eb4957c60 in start_thread () from /lib/libpthread.so.0
#5  0x00007f1eb46c37ed in clone () from /lib/libc.so.6
#6  0x0000000000000000 in ?? ()

Thread 7 (Thread 0x7f1eb2bfe700 (LWP 7504)):
#0  0x00007f1eb495c324 in pthread_cond_wait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#1  0x00000000005e229d in GC_wait_marker () at pthread_support.c:1863
#2  0x00000000005db9c0 in GC_help_marker (my_mark_no=11) at mark.c:1116
#3  0x00000000005e0f64 in GC_mark_thread (id=0x3) at pthread_support.c:552
#4  0x00007f1eb4957c60 in start_thread () from /lib/libpthread.so.0
#5  0x00007f1eb46c37ed in clone () from /lib/libc.so.6
#6  0x0000000000000000 in ?? ()

Thread 6 (Thread 0x7f1eb23fd700 (LWP 7505)):
#0  0x00007f1eb495c324 in pthread_cond_wait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#1  0x00000000005e229d in GC_wait_marker () at pthread_support.c:1863
#2  0x00000000005db9c0 in GC_help_marker (my_mark_no=11) at mark.c:1116
#3  0x00000000005e0f64 in GC_mark_thread (id=0x4) at pthread_support.c:552
#4  0x00007f1eb4957c60 in start_thread () from /lib/libpthread.so.0
#5  0x00007f1eb46c37ed in clone () from /lib/libc.so.6
#6  0x0000000000000000 in ?? ()

Thread 5 (Thread 0x7f1eb1bfc700 (LWP 7506)):
#0  0x00007f1eb495c324 in pthread_cond_wait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#1  0x00000000005e229d in GC_wait_marker () at pthread_support.c:1863
#2  0x00000000005db9c0 in GC_help_marker (my_mark_no=11) at mark.c:1116
#3  0x00000000005e0f64 in GC_mark_thread (id=0x5) at pthread_support.c:552
#4  0x00007f1eb4957c60 in start_thread () from /lib/libpthread.so.0
#5  0x00007f1eb46c37ed in clone () from /lib/libc.so.6
#6  0x0000000000000000 in ?? ()

Thread 4 (Thread 0x7f1eb13fb700 (LWP 7507)):
#0  0x00007f1eb495c324 in pthread_cond_wait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#1  0x00000000005e229d in GC_wait_marker () at pthread_support.c:1863
#2  0x00000000005db9c0 in GC_help_marker (my_mark_no=11) at mark.c:1116
#3  0x00000000005e0f64 in GC_mark_thread (id=0x6) at pthread_support.c:552
#4  0x00007f1eb4957c60 in start_thread () from /lib/libpthread.so.0
#5  0x00007f1eb46c37ed in clone () from /lib/libc.so.6
#6  0x0000000000000000 in ?? ()

Thread 3 (Thread 0x7f1eb06fb700 (LWP 7508)):
#0  0x00007f1eb495e460 in sem_wait () from /lib/libpthread.so.0
#1  0x00000000005c16b8 in mono_sem_wait (sem=0x8ef780, alertable=0) at
mono-semaphore.c:113
#2  0x000000000050d902 in finalizer_thread (unused=<value optimized out>) at
gc.c:1050
#3  0x0000000000591847 in start_wrapper_internal (data=0x1ce1a50) at
threads.c:774
#4  start_wrapper (data=0x1ce1a50) at threads.c:822
#5  0x00000000005bbff4 in thread_start_routine (args=0x1cc06c0) at
wthreads.c:285
#6  0x00000000005e1f00 in GC_start_routine (arg=0x7f1eb5260fc0) at
pthread_support.c:1468
#7  0x00007f1eb4957c60 in start_thread () from /lib/libpthread.so.0
#8  0x00007f1eb46c37ed in clone () from /lib/libc.so.6
#9  0x0000000000000000 in ?? ()

Thread 2 (Thread 0x7f1eabfff700 (LWP 7511)):
#0  0x00007f1eb495f1cd in read () from /lib/libpthread.so.0
#1  0x000000000048f8ae in mono_handle_native_sigsegv (signal=<value optimized
out>, ctx=<value optimized out>) at mini-exceptions.c:2119
#2  0x00000000004df25f in mono_arch_handle_altstack_exception
(sigctx=0x7f1eb5227e40, fault_addr=<value optimized out>, stack_ovf=0) at
exceptions-amd64.c:944
#3  0x000000000041a899 in mono_sigsegv_signal_handler (_dummy=11,
info=0x7f1eb5227f70, context=0x7f1eb5227e40) at mini.c:5819
#4  <signal handler called>
#5  get_generic_info_from_stack_frame (ji=0x1d5fe40, ctx=0x7f1eabffe390) at
mini-exceptions.c:433
#6  0x000000000048e5bd in mono_walk_stack (func=0x48c290
<find_last_handler_block>, domain=0x7f1eb53e5d48, start_ctx=<value optimized
out>, do_il_offset=0, thread=<value optimized out>, lmf=0x1d6bcf0,
user_data=0x7f1eabffe4b0) at mini-exceptions.c:737
#7  0x00000000004908bc in mono_install_handler_block_guard (thread=<value
optimized out>, ctx=0x7f1eabffe560) at mini-exceptions.c:2335
#8  0x00000000004e3f67 in sigusr1_signal_handler (_dummy=<value optimized out>,
info=<value optimized out>, context=0x7f1eabffe600) at mini-posix.c:248
#9  <signal handler called>
#10 0x0000000040b91390 in ?? ()
#11 0x0000000040b90352 in ?? ()
#12 0x00007f1eb5233f50 in ?? ()
#13 0x00007f1eb525acc0 in ?? ()
#14 0x000000000000000f in ?? ()
#15 0x0000000000000010 in ?? ()
#16 0x0000000000000000 in ?? ()

Thread 1 (Thread 0x7f1eb53f1740 (LWP 7492)):
#0  0x00007f1eb495c324 in pthread_cond_wait@@GLIBC_2.3.2 () from
/lib/libpthread.so.0
#1  0x00000000005a8923 in _wapi_handle_timedwait_signal_handle (handle=0x400,
timeout=0x0, alertable=1, poll=<value optimized out>) at handles.c:1636
#2  0x00000000005b9fd1 in WaitForMultipleObjectsEx (numobjects=8,
handles=0x7fffaf615060, waitall=1, timeout=4294967295, alertable=1) at
wait.c:722
#3  0x000000000058f088 in wait_for_tids (wait=0x7fffaf615060, timeout=<value
optimized out>) at threads.c:2722
#4  0x000000000058fadd in mono_thread_manage () at threads.c:3022
#5  0x000000000046c63c in mono_main (argc=<value optimized out>, argv=<value
optimized out>) at driver.c:1847
#6  0x00007f1eb4613c3d in __libc_start_main () from /lib/libc.so.6
#7  0x0000000000414549 in _start ()

=================================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries 
used by your application.
=================================================================

Expected Results:

-- 
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list