From: Alexey Dejneka Date: Tue, 19 Aug 2003 09:24:36 +0000 (+0000) Subject: 0.8.2.43: X-Git-Url: http://repo.macrolet.net/gitweb/?a=commitdiff_plain;h=d8edba3a4e96a718d9eab64d2cbb0b70d0946546;p=sbcl.git 0.8.2.43: * New optimization policy: RECOGNIZE-SELF-CALLS; * on x86 DATA-VECTOR-REF/SIMPLE-BASE-STRING does not use AL temporary. --- diff --git a/BUGS b/BUGS index 4582384..c09e590 100644 --- a/BUGS +++ b/BUGS @@ -170,12 +170,6 @@ WORKAROUND: 45: a slew of floating-point-related errors reported by Peter Van Eynde on July 25, 2000: - b: SBCL's value for LEAST-POSITIVE-SHORT-FLOAT on the x86 is - bogus, and should probably be 1.4012985e-45. In SBCL, - (/ LEAST-POSITIVE-SHORT-FLOAT 2) returns a number smaller - than LEAST-POSITIVE-SHORT-FLOAT. Similar problems - exist for LEAST-NEGATIVE-SHORT-FLOAT, LEAST-POSITIVE-LONG-FLOAT, - and LEAST-NEGATIVE-LONG-FLOAT. c: Many expressions generate floating infinity on x86/Linux: (/ 1 0.0) (/ 1 0.0d0) diff --git a/NEWS b/NEWS index 73e06ed..3c50624 100644 --- a/NEWS +++ b/NEWS @@ -1968,6 +1968,13 @@ changes in sbcl-0.8.3 relative to sbcl-0.8.2: * x86 bug fix in control stack exhaustion checking: now shows backtrace * bug fix in WITH-TIMEOUT: now the body can have more than one form. (thanks to Stig Sandoe) + * new optimization: inside a named function any reference to a + function with the same name is considered to be a self-reference; + this behaviour is controlled with SB-C::RECOGNIZE-SELF-CALLS + optimization quality. + * new optimization on x86: logical functions and + now have + optimized (UNSIGNED-BYTE 32) versions, which are automatically + used when the result is truncated to 32 bits. * fixed some bugs revealed by Paul Dietz' test suite: ** The system now obeys the constraint imposed by UPGRADED-ARRAY-ELEMENT-TYPE that the upgraded array element diff --git a/src/compiler/ir1tran-lambda.lisp b/src/compiler/ir1tran-lambda.lisp index b7d218e..ecb2a64 100644 --- a/src/compiler/ir1tran-lambda.lisp +++ b/src/compiler/ir1tran-lambda.lisp @@ -919,7 +919,10 @@ (setf (defined-fun-functional defined-fun-res) res) (unless (eq (defined-fun-inlinep defined-fun-res) :notinline) - (substitute-leaf res defined-fun-res)) + (substitute-leaf-if + (lambda (ref) + (policy ref (> recognize-self-calls 0))) + res defined-fun-res)) res) (apply #'ir1-convert-lambda `(lambda ,@(cddr thing)) :debug-name name args)))) diff --git a/src/compiler/policies.lisp b/src/compiler/policies.lisp index c55e3a6..be12bf6 100644 --- a/src/compiler/policies.lisp +++ b/src/compiler/policies.lisp @@ -43,3 +43,9 @@ 3 0) ("no" "maybe" "yes" "yes")) + +(define-optimization-quality recognize-self-calls + (if (> (max speed space) debug) + 3 + 0) + ("no" "maybe" "yes" "yes")) diff --git a/src/compiler/x86/array.lisp b/src/compiler/x86/array.lisp index 6d9d9a6..f8c3c70 100644 --- a/src/compiler/x86/array.lisp +++ b/src/compiler/x86/array.lisp @@ -1253,20 +1253,13 @@ (:args (object :scs (descriptor-reg)) (index :scs (unsigned-reg))) (:arg-types simple-base-string positive-fixnum) - (:temporary (:sc unsigned-reg ; byte-reg - :offset eax-offset ; al-offset - :target value - :from (:eval 0) :to (:result 0)) - eax) - (:ignore eax) (:results (value :scs (base-char-reg))) (:result-types base-char) (:generator 5 - (inst mov al-tn + (inst mov value (make-ea :byte :base object :index index :scale 1 :disp (- (* vector-data-offset n-word-bytes) - other-pointer-lowtag))) - (move value al-tn))) + other-pointer-lowtag))))) (define-vop (data-vector-ref-c/simple-base-string) (:translate data-vector-ref) @@ -1274,25 +1267,20 @@ (:args (object :scs (descriptor-reg))) (:info index) (:arg-types simple-base-string (:constant (signed-byte 30))) - (:temporary (:sc unsigned-reg :offset eax-offset :target value - :from (:eval 0) :to (:result 0)) - eax) - (:ignore eax) (:results (value :scs (base-char-reg))) (:result-types base-char) (:generator 4 - (inst mov al-tn + (inst mov value (make-ea :byte :base object :disp (- (+ (* vector-data-offset n-word-bytes) index) - other-pointer-lowtag))) - (move value al-tn))) + other-pointer-lowtag))))) (define-vop (data-vector-set/simple-base-string) (:translate data-vector-set) (:policy :fast-safe) (:args (object :scs (descriptor-reg) :to (:eval 0)) (index :scs (unsigned-reg) :to (:eval 0)) - (value :scs (base-char-reg))) + (value :scs (base-char-reg) :target result)) (:arg-types simple-base-string positive-fixnum base-char) (:results (result :scs (base-char-reg))) (:result-types base-char) diff --git a/version.lisp-expr b/version.lisp-expr index 77ca046..460a317 100644 --- a/version.lisp-expr +++ b/version.lisp-expr @@ -17,4 +17,4 @@ ;;; 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.2.42" +"0.8.2.43"