gcl-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gcl-devel] gcl floating point overflow


From: Dan Gildea
Subject: [Gcl-devel] gcl floating point overflow
Date: Mon, 7 Nov 2016 04:58:01 -0500

I am currently getting errors in the test suite with gcl and ecl
that are caused by a floating point overflow not getting trapped.

I tried enabling overflow trapping in gcl 2.6.12 by adding
this to float.lisp:

     (eval-when (load eval)
       (si::break-on-floating-point-exceptions :floating-point-overflow t))

When I start maxima, it seems that the overflow is not trapped,
but that the flag is set, and that examining the flag without
setting it changes the behavior:
        
        Maxima branch_5_38_base_343_ge354f84 http://maxima.sourceforge.net
        using Lisp GNU Common Lisp (GCL) GCL 2.6.12
        Distributed under the GNU Public License. See the file COPYING.
        Dedicated to the memory of William Schelter.
        The function bug_report() provides bug reporting information.
        (%i1) exp(1000),numer;
        (%o1)                               #<inf>
        (%i2) :lisp  (si::break-on-floating-point-exceptions )
        
        (FLOATING-POINT-OVERFLOW)
        (%i2) exp(1000),numer;
        
        Maxima encountered a Lisp error:
        
         Condition in MACSYMA-TOP-LEVEL [or a callee]: 
INTERNAL-SIMPLE-FLOATING-POINT-OVERFLOW: 
        Arithmetic error when performing (:INSN "fnop ;" :OP FNOP :FUN NIL
                                                :ADDR 46912502196056) on NIL: 
        
        Automatically continuing.
        To enable the Lisp debugger set *debugger-hook* to nil.
        
What could be going on?

Dan



reply via email to

[Prev in Thread] Current Thread [Next in Thread]