Crash caused by SB-APROF

Bug #1947040 reported by Douglas Katzman
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SBCL
Undecided
Unassigned

Bug Description

Observed on Darwin from running gc.impure.lisp with sb-aprof enabled:

::: UNEXPECTED-FAILURE :GC-WITHOUT-INTERRUPTS due to TYPE-ERROR:
        "The value
Unhandled TYPE-ERROR in thread #<SB-THREAD:THREAD RUNNING {1002A5DDA3}>:
  The value
           NIL
         is not of type
    NIL
  is not of type
    SB-KERNEL:CODE-COMPONENT

           SB-KERNEL:CODE-COMPONENT"
Backtrace for: #<SB-THREAD:THREAD RUNNING {1002A5DDA3}>
0: (SB-DI::SUB-ACCESS-DEBUG-VAR-SLOT #.(SB-SYS:INT-SAP #X0FA87770) 99 #<SB-ALIEN-INTERNALS:ALIEN-VALUE :SAP #X0FA87268 :TYPE (* (SB-ALIEN:STRUCT SB-VM::OS-CONTEXT-T-STRUCT))>)
1: (SB-KERNEL:INTERNAL-ERROR #.(SB-SYS:INT-SAP #X0FA87268) #<unused argument>)
2: ("foreign function: call_into_lisp")
3: ("foreign function: funcall2")
4: ("foreign function: interrupt_internal_error")
5: ("foreign function: signal_emulation_wrapper")
6: ("bogus stack frame")
7: ("foreign function: _dispatch_semaphore_wait_slow")
8: ("foreign function: thread_wait_until_not")
9: ("foreign function: gc_stop_the_world")
10: (SB-KERNEL::GC-STOP-THE-WORLD)
11: ((FLET "WITHOUT-GCING-BODY-4" :IN SB-KERNEL:SUB-GC))
12: ((FLET "WITHOUT-INTERRUPTS-BODY-1" :IN SB-KERNEL:SUB-GC))
13: (SB-KERNEL:SUB-GC 0)
14: (GC :FULL NIL :GEN 0)
15: ((FLET SB-UNIX::BODY :IN SB-THREAD::RUN))
16: ((FLET "WITHOUT-INTERRUPTS-BODY-10" :IN SB-THREAD::RUN))
17: ((FLET SB-UNIX::BODY :IN SB-THREAD::RUN))
18: ((FLET "WITHOUT-INTERRUPTS-BODY-3" :IN SB-THREAD::RUN))
19: (SB-THREAD::RUN)
20: ("foreign function: call_into_lisp")
21: ("foreign function: funcall1")

unhandled condition in --disable-debugger mode, quitting

and then it hangs, despite saying that it's quitting.

Revision history for this message
Stas Boukarev (stassats) wrote :

This is involves fork, since it's under parallel-exec?

In the depths of _dispatch_semaphore_wait_slow I see

libdispatch.dylib`_dispatch_fork_becomes_unsafe_slow:
    0x7fff201c90e8 <+0>: leaq 0x60491ca1(%rip), %rcx ; _dispatch_unsafe_fork
    0x7fff201c90ef <+7>: movb (%rcx), %al
    0x7fff201c90f1 <+9>: movl %eax, %edx
    0x7fff201c90f3 <+11>: orb $0x1, %dl
    0x7fff201c90f6 <+14>: lock
    0x7fff201c90f7 <+15>: cmpxchgb %dl, (%rcx)
    0x7fff201c90fa <+18>: jne 0x7fff201c90f1 ; <+9>
    0x7fff201c90fc <+20>: testb $0x2, %al
    0x7fff201c90fe <+22>: jne 0x7fff201c9101 ; <+25>
    0x7fff201c9100 <+24>: retq
    0x7fff201c9101 <+25>: leaq 0x284c6(%rip), %rcx ; "BUG IN CLIENT OF LIBDISPATCH: Transition to multithreaded is prohibited"
    0x7fff201c9108 <+32>: movq %rcx, 0x604c4679(%rip) ; gCRAnnotations + 8
    0x7fff201c910f <+39>: ud2

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers