Inconsistent results from compiled code

Bug #1856325 reported by Paul F. Dietz
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SBCL
Fix Released
Undecided
Unassigned

Bug Description

A function is producing inconsistent results from one compile to the next.

(defparameter *f394*
  '(logand
    (let ((v4 (lcm c (boole boole-set c 0)))
          (v8 (count a '(124279146003 8 -21554437971210 13) :test-not '<=)))
      (if (= v8 v4)
          (if (> v4 v8)
              b
              0)
          c))
    505173))

(defun f394 ()
  (let ((lam1
         `(lambda (a b c)
            (declare (type (integer 56599 16934241778) b))
            (declare (type (integer 1096801 7569586005534388022) c))
            ,*f394*))
        (lam2 `(lambda (a b c) ,*f394*))
        (params '(0 16818888021 6213045866750398436)))
    (values
     (apply (compile nil lam1) params)
     (apply (compile nil lam2) params))))

(f394) ==> 143685, 361796

(reevaluate those forms, including the defun, and run again)

(f394) ==> 173141, 361796

Stas Boukarev (stassats)
Changed in sbcl:
status: New → Fix Committed
Stas Boukarev (stassats)
Changed in sbcl:
status: Fix Committed → Fix Released
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.