[cmucl-ticket] [cmucl] #72: SIGFPE with no exceptions currently enabled?
cmucl
cmucl-devel at common-lisp.net
Wed Jan 30 02:25:58 UTC 2013
#72: SIGFPE with no exceptions currently enabled?
--------------------+-------------------------------------------------------
Reporter: rtoy | Owner: somebody
Type: defect | Status: new
Priority: major | Milestone:
Component: Core | Version: 2013-01
Keywords: |
--------------------+-------------------------------------------------------
While I've seen this SIGFPE issue before, I never tracked it down. Here
is a repeatable case (from Carl):
{{{
(defun test (x y)
(declare (optimize (speed 3) (safety 0))
(type (signed-byte 32) x y))
(the (signed-byte 32) (truncate x y)))
}}}
Although the code lies to the compiler (the asserted return type of
{{{truncate}}} is incorrect), the point is that {{{(test #x-80000000
-1)}}} causes the SIGFPE exception.
I believe {{{sigfpe-handler}}} was only expecting to handle FP exceptions.
In this example, the division causes an overflow which generates the
SIGFPE.
--
Ticket URL: <http://trac.common-lisp.net/cmucl/ticket/72>
cmucl <http://common-lisp.net/project/cmucl>
Cmucl is a high-performance, free Common Lisp implementation.
More information about the cmucl-ticket
mailing list