1.0.15.19: use TEST X X when possible in SIGNED-BYTE-*-LEN VOPS
authorNikodemus Siivola <nikodemus@random-state.net>
Mon, 10 Mar 2008 19:26:15 +0000 (19:26 +0000)
committerNikodemus Siivola <nikodemus@random-state.net>
Mon, 10 Mar 2008 19:26:15 +0000 (19:26 +0000)
 * Both x86 and x86-64.

src/compiler/x86-64/arith.lisp
src/compiler/x86/arith.lisp
version.lisp-expr

index c02e9d7..0daa98d 100644 (file)
   (:result-types unsigned-num)
   (:generator 28
     (move res arg)
-    (inst cmp res 0)
+    (if (sc-is res unsigned-reg)
+        (inst test res res)
+        (inst cmp res 0))
     (inst jmp :ge POS)
     (inst not res)
     POS
index e7ec031..970b369 100644 (file)
   (:result-types unsigned-num)
   (:generator 28
     (move res arg)
-    (inst cmp res 0)
+    (if (sc-is res unsigned-reg)
+        (inst test res res)
+        (inst cmp res 0))
     (inst jmp :ge POS)
     (inst not res)
     POS
index d9723ca..9de3b23 100644 (file)
@@ -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".)
-"1.0.15.18"
+"1.0.15.19"