Incorrect result from integer code with MAX, type decls

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

Bug Description

(defun bug234 ()
  (let* ((vals '(-14611266490586102582 94
                 5164423910675051733))
         (form '(max
                 5164423910675051733
                 (logeqv b d)
                 (+ d d -1 8388603 -7 a 29 d b)))
         (lam1
           `(lambda (a b d)
              (declare (type (integer 14 101) b))
              (declare (type (signed-byte 64) d))
              ,form))
         (lam2
           `(lambda (a b d)
              ,form)))
    (values (apply (compile nil lam1) vals)
            (apply (compile nil lam2) vals))))

(bug234) ==> 882005241447441335, 5164423910675051733

x86-64, "2.3.8.142-11db25613"

Revision history for this message
Stas Boukarev (stassats) wrote :

Can't reproduce for some reason.

Revision history for this message
Paul F. Dietz (paul-f-dietz) wrote :

Weird. It also doesn't reproduce in a fresh image. So something must have gone wrong behind the scenes, in something persistent? Is there caching of information, say related to types?

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.