X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Fmips%2Ftype-vops.lisp;h=eb0c5f61aafc487de6dda82b345e46ad4d1e35a2;hb=557df1e8a17c2f4d9f97752cb8476805e79f0073;hp=2f727234a9096b37614c6362e176c504722d8d2a;hpb=52cfe54802db8736f1f4e2b67764c43bba9b78b3;p=sbcl.git diff --git a/src/compiler/mips/type-vops.lisp b/src/compiler/mips/type-vops.lisp index 2f72723..eb0c5f6 100644 --- a/src/compiler/mips/type-vops.lisp +++ b/src/compiler/mips/type-vops.lisp @@ -14,7 +14,7 @@ ;;; Test generation utilities. (defun %test-fixnum (value target not-p &key temp) (assemble () - (inst and temp value 3) + (inst and temp value fixnum-tag-mask) (if not-p (inst bne temp zero-tn target) (inst beq temp zero-tn target)) @@ -23,29 +23,28 @@ (defun %test-fixnum-and-headers (value target not-p headers &key temp) (let ((drop-through (gen-label))) (assemble () - (inst and temp value 3) + (inst and temp value fixnum-tag-mask) (inst beq temp zero-tn (if not-p drop-through target))) (%test-headers value target not-p nil headers :drop-through drop-through :temp temp))) (defun %test-immediate (value target not-p immediate &key temp) (assemble () - (inst and temp value 255) + (inst and temp value widetag-mask) (inst xor temp immediate) (if not-p (inst bne temp zero-tn target) (inst beq temp zero-tn target)) (inst nop))) -(defun %test-lowtag (value target not-p lowtag &key skip-nop temp) +(defun %test-lowtag (value target not-p lowtag &key temp) (assemble () (inst and temp value lowtag-mask) (inst xor temp lowtag) (if not-p (inst bne temp zero-tn target) (inst beq temp zero-tn target)) - (unless skip-nop - (inst nop)))) + (inst nop))) (defun %test-headers (value target not-p function-p headers &key (drop-through (gen-label)) temp) @@ -151,7 +150,7 @@ (values not-target target) (values target not-target)) (assemble () - (inst and temp value 3) + (inst and temp value fixnum-tag-mask) (inst beq temp zero-tn yep) (inst and temp value lowtag-mask) (inst xor temp other-pointer-lowtag) @@ -189,7 +188,7 @@ (values target not-target)) (assemble () ;; Is it a fixnum? - (inst and temp value 3) + (inst and temp value fixnum-tag-mask) (inst beq temp zero-tn fixnum) (move temp value t)