Verify-backtrace fails on BACKTRACE-INTERRUPTED-CONDITION-WAIT
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
SBCL |
New
|
Undecided
|
Unassigned |
Bug Description
Hi.
I compiled today Sbcl 1.1.9 on a Macbook (Mac OS/X 10.6.8). I selected the integration of the SB-Thread and SB-Core-Compression features beyond those selected by default. The local-target-
((lambda (features) (set-difference features (list)))
(union (list :sb-thread :sb-core-
Running the regression tests failed only on 2 test cases, one being the BACKTRACE-
$ (cd tests && sh ./run-tests.sh --break-on-failure debug.impure.lisp)
[...]
; caught 1 STYLE-WARNING condition
::: Running :BACKTRACE-
//SB-THREAD:
(((FLET #:LAMBDA1 :IN VERIFY-BACKTRACE) #<SIMPLE-ERROR "foo" {1004FFDCC3}>)
(SIGNAL #<SIMPLE-ERROR "foo" {1004FFDCC3}>) (ERROR "foo")
[...]
due to #<SIMPLE-ERROR "~@<The assertion ~S failed~:[.~:; ~
"The assertion
(LAMBDA ()
failed with
(LAMBDA ()
= #<CLOSURE # {1004FFD86B}>,
[...]
Looking up on Launchpad for a condition similar to that referred to in debug.impure.lisp I found Bug #549673. I am however not sure whether this test case is a regression test for the fix to that bug.
In addition to the trace reported above I observed the following when I run this command:
$ (cd tmp && sbcl --eval '(with-
This is SBCL 1.1.9, an implementation of ANSI Common Lisp.
More information about SBCL is available at <http://
SBCL is free software, provided as is, with absolutely no warranty.
It is mostly in the public domain; some portions are provided under
BSD-style licenses. See the CREDITS and COPYING files in the
distribution for more information.
; file: /Users/
; in: LET ((M (SB-THREAD:
; (HANDLER-BIND ((TIMEOUT (LAMBDA (C) (ERROR "foo"))))
; (WITH-TIMEOUT 0.1
; (SB-THREAD:
; --> SB-IMPL:
; ==>
; (FLET ((#:LAMBDA0 (C)
; (ERROR "foo")))
; (DECLARE (SB-INT:
; (LET ((SB-KERNEL:
; (DECLARE (SB-INT:
; (PROGN
; (PROGN
; (WITH-TIMEOUT 0.1
; #)))))
;
; caught STYLE-WARNING:
; The variable C is defined but never used.
debugger invoked on a SIMPLE-ERROR in thread
#<THREAD "main thread" RUNNING {1002B1B6C3}>:
foo
Type HELP for debugger help, or (SB-EXT:EXIT) to exit from SBCL.
restarts (invokable by number or by possibly-
0: [RETRY ] Retry EVAL of current toplevel form.
1: [CONTINUE] Ignore error and continue loading file "/Users/
2: [ABORT ] Abort loading file "/Users/
3: Ignore runtime option --eval "(with-
4: Skip rest of --eval and --load options.
5: Skip to toplevel READ/EVAL/PRINT loop.
6: [EXIT ] Exit SBCL (calling #'EXIT, killing the process).
("bogus stack frame")
0]
WARNING: Starting a select(2) without a timeout while interrupts are disabled.
(list-backtrace)
; No debug variables for current frame: using EVAL instead of EVAL-IN-FRAME.
(("bogus stack frame")
(SB-UNIX:NANOSLEEP #<unavailable argument> #<unavailable argument>)
(SB-IMPL:
#<dynamic-extent: #<CLOSURE (FLET SB-THREAD::WAKEUP :IN SB-THREAD:
NIL NIL)
((FLET #:WITHOUT-
(SB-THREAD:
((FLET SB-THREAD:
((FLET #:WITHOUT-
(SB-THREAD:
#<dynamic-extent: #<CLOSURE (FLET SB-THREAD:
#<SB-THREAD:MUTEX (free) {1002C04F63}> NIL T NIL)
((LAMBDA ()
:IN
"/Users/
(SB-INT:
(LET ((M (SB-THREAD:
(SB-
(HANDLER-BIND (#)
#))))
#<NULL-LEXENV>)
(EVAL-TLF
(LET ((M (SB-THREAD:
(SB-
(HANDLER-BIND (#)
#))))
0 #<NULL-LEXENV>)
((FLET SB-FASL::EVAL-FORM :IN SB-INT:
(LET ((M (SB-THREAD:
(SB-
(HANDLER-BIND (#)
#))))
0)
...)
0]
WARNING: Starting a select(2) without a timeout while interrupts are disabled.
That is, I have to call (list-backtrace) to get the full trace which, incidentally, does contain a reference to the wait-condition. I'm not sure how this fits in with the comment left in debug.impure.lisp's verify-backtrace and the failing test case.
FYI, the code in cond-wait.lisp reads:
(let ((m (sb-thread:
(q (sb-thread:
(sb-thread:
(handler-bind ((timeout (lambda (c)
(with-timeout 0.1
* Additional information *
uname -a:
Darwin christian-
*features*:
(:ALIEN-CALLBACKS :ANSI-CL :ASH-RIGHT-VOPS :BSD :C-STACK-
:COMMON-LISP :COMPARE-
:DARWIN9-OR-BETTER :FLOAT-EQL-VOPS :GENCGC :IEEE-FLOATING-
:INLINE-CONSTANTS :INODE64 :LINKAGE-TABLE :LITTLE-ENDIAN
:MACH-
:OS-PROVIDES-
:OS-PROVIDES-PUTWC :OS-PROVIDES-
:RAW-INSTANCE-
:SB-PACKAGE-LOCKS :SB-SIMD-PACK :SB-SOURCE-
:SB-UNICODE :SBCL :STACK-
:STACK-
:STACK-
:UNWIND-