x86 LEA instruction for multiplication by constants.
* bug fix: in some situations compiler did not report usage of
generic arithmetic in (SPEED 3) policy.
+ * fixed some bugs revealed by Paul Dietz' test suite:
+ ** the RETURN clause in LOOP is now equivalent to DO (RETURN ...).
+ ** ROUND and FROUND now give the right answer when given very
+ small float arguments.
planned incompatible changes in 0.8.x:
* (not done yet, but planned:) When the profiling interface settles
;; GC :FULL T isn't nearly as effective as PURIFY here?
;; (GC :FULL T gets us down to about 38 Mbytes, but PURIFY
;; gets us down to about 19 Mbytes.)
- (let ((*gc-notify-stream* *standard-output*))
- (sb-int:/show "done with warm.lisp, about to GC :FULL T")
- (gc :full t))
+ (sb-int:/show "done with warm.lisp, about to GC :FULL T")
+ (gc :full t)
;; resetting compilation policy to neutral values in
;; preparation for SAVE-LISP-AND-DIE as final SBCL core (not
(if (eql divisor 1)
(round number)
(multiple-value-bind (tru rem) (truncate number divisor)
- (let ((thresh (/ (abs divisor) 2)))
- (cond ((or (> rem thresh)
- (and (= rem thresh) (oddp tru)))
- (if (minusp divisor)
- (values (- tru 1) (+ rem divisor))
- (values (+ tru 1) (- rem divisor))))
- ((let ((-thresh (- thresh)))
- (or (< rem -thresh)
- (and (= rem -thresh) (oddp tru))))
- (if (minusp divisor)
- (values (+ tru 1) (- rem divisor))
- (values (- tru 1) (+ rem divisor))))
- (t (values tru rem)))))))
+ (if (zerop rem)
+ (values tru rem)
+ (let ((thresh (/ (abs divisor) 2)))
+ (cond ((or (> rem thresh)
+ (and (= rem thresh) (oddp tru)))
+ (if (minusp divisor)
+ (values (- tru 1) (+ rem divisor))
+ (values (+ tru 1) (- rem divisor))))
+ ((let ((-thresh (- thresh)))
+ (or (< rem -thresh)
+ (and (= rem -thresh) (oddp tru))))
+ (if (minusp divisor)
+ (values (+ tru 1) (- rem divisor))
+ (values (- tru 1) (+ rem divisor))))
+ (t (values tru rem))))))))
(defun rem (number divisor)
#!+sb-doc
:cl))
(value (symbol-value name)))
(assert (zerop (/ value 2))))))
+
+;;; bug found by Paul Dietz: bad rounding on small floats
+(assert (= (fround least-positive-short-float least-positive-short-float) 1.0))
;;; checkins which aren't released. (And occasionally for internal
;;; versions, especially for internal versions off the main CVS
;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)
-"0.8.3.18"
+"0.8.3.19"