(sin #.SB-EXT:SINGLE-FLOAT-POSITIVE-INFINITY) bombs SBCL

Bug #1919264 reported by Sean Luke
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SBCL
Invalid
Undecided
Unassigned

Bug Description

SBCL 1.1.6.0-3c5581a
Darwin geepers-8771.local 17.7.0 Darwin Kernel Version 17.7.0: Mon Aug 31 22:11:23 PDT 2020; root:xnu-4570.71.82.6~1/RELEASE_X86_64 x86_64

In most programming languages, sin(infinity) returns NaN. One would expect this behavior on SBCL if traps are turned off, or at least to raise a condition if traps were turned on. But neither happens: instead, SBCL bombs hard.

It's easily replicated:

----

This is SBCL 1.1.6.0-3c5581a, an implementation of ANSI Common Lisp.
More information about SBCL is available at <http://www.sbcl.org/>.

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.
* (sin #.SB-EXT:SINGLE-FLOAT-POSITIVE-INFINITY)
fatal error encountered in SBCL pid 80419:
set_pseudo_atomic_atomic: pseudo atomic bits is 44038880.

Welcome to LDB, a low-level debugger for the Lisp runtime environment.
ldb>

---

Alternatively you could do something like this:

----

This is SBCL 1.1.6.0-3c5581a, an implementation of ANSI Common Lisp.
More information about SBCL is available at <http://www.sbcl.org/>.

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.
* (sb-int:set-floating-point-modes :traps '(:invalid))

* (sin (exp 1000))
fatal error encountered in SBCL pid 80451:
set_pseudo_atomic_atomic: pseudo atomic bits is 18869216.

Welcome to LDB, a low-level debugger for the Lisp runtime environment.
ldb>

---

Revision history for this message
Douglas Katzman (dougk) wrote :

SBCL 1.1.6 is 8 years old. You need to upgrade.

Changed in sbcl:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.