* Unbreak (LOG DOUBLE INTEGER).
* LAMBDAS-CONVERTED / LAMBDA-CONVERSIONS confusion in PRINT-TIME.
(patch by Erik Marsden)
((and (typep number '(integer (0) *))
(typep base '(integer (0) *)))
(coerce (/ (log2 number) (log2 base)) 'single-float))
- ((or (and (typep number 'integer) (typep base 'double-float))
- (and (typep number 'double-float) (typep base 'integer)))
+ ((and (typep number 'integer) (typep base 'double-float))
;; No single float intermediate result
(/ (log2 number) (log base 2.0d0)))
+ ((and (typep number 'double-float) (typep base 'integer))
+ (/ (log number 2.0d0) (log2 base)))
(t
(/ (log number) (log base))))
(number-dispatch ((number number))
(defun print-time (&key real-time-ms user-run-time-us system-run-time-us
gc-run-time-ms processor-cycles eval-calls
- lambda-conversions page-faults bytes-consed
+ lambdas-converted page-faults bytes-consed
aborted)
(let ((total-run-time-us (+ user-run-time-us system-run-time-us)))
(format *trace-output*
100.0
(float (* 100 (/ (round total-run-time-us 1000) real-time-ms))))
eval-calls
- lambda-conversions
+ lambdas-converted
processor-cycles
page-faults
bytes-consed
(assert (eql 2567.6046442221327d0
(log (loop for n from 1 to 1000 for f = 1 then (* f n)
finally (return f))
- 10d0))))
+ 10d0)))
+ ;; both ways
+ (assert (eql (log 123123123.0d0 10) (log 123123123 10.0d0))))
(with-test (:name :log-base-zero-return-type)
(assert (eql 0.0f0 (log 123 (eval 0))))
(when (>= time time1)
(return)))))))
3)
+
+(with-test (:name :time/lambdas-converted)
+ (time (compile nil '(lambda () 42))))
;;; 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".)
-"1.0.20.32"
+"1.0.20.33"