small recursive function stack overflow crashes sbcl. Windows 8/ 64bit sbcl
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
SBCL |
Fix Released
|
Undecided
|
Luís Oliveira |
Bug Description
The following piece of code:
(defun req-sqrt(v)
(sqrt (req-sqrt v)))
(req-sqrt 1.0)
(req-sqrt 1.0)
reliable crashes both sbcl 1.1.8 and 1.1.12 on my setup: windows 8 64 bit with 64 bit sbcl.
actually replacing sqrt with sin or + 1 has same behaviour, possibly any function will do.
On 1.1.12 one might have to try twice.
*features*
(:SWANK :QUICKLISP :ASDF3 :ASDF2 :ASDF :OS-WINDOWS :NON-BASE-
:ASDF-UNICODE :ALIEN-CALLBACKS :ANSI-CL :ASH-RIGHT-VOPS
:C-STACK-
:COMPLEX-
:IEEE-
:MEMORY-
:OS-PROVIDES-PUTWC :PACKAGE-
:SB-DYNAMIC-CORE :SB-EVAL :SB-FUTEX :SB-LDB :SB-PACKAGE-LOCKS :SB-QSHOW
:SB-SAFEPOINT :SB-SAFEPOINT-
:SB-TEST :SB-THREAD :SB-THRUPTION :SB-UNICODE :SB-WTIMER :SBCL
:STACK-
:STACK-
:STACK-
Changed in sbcl: | |
status: | Fix Committed → Fix Released |
> reliable crashes [...]
Can you describe the failure mode in more detail?
> On 1.1.12 one might have to try twice.
What happens in the first try? The expected "Binding stack exhausted. PROCEED WITH CAUTION."?
Running SBCL 1.1.12 under wine (on x86) produces the following:
$ wine sbcl setup_exception _record stack overflow 1792 bytes in thread 0009 eip 7ef633e8 esp 00540c30 stack 0x540000- 0x541000- 0x740000
This is SBCL 1.1.12, an implementation of ANSI Common Lisp.
[...]
* (defun req-sqrt(v)
(sqrt (req-sqrt v)))
REQ-SQRT
* (req-sqrt 1.0)
err:seh:
Is this equivalent to what you experience?