X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Fppc%2Fsystem.lisp;h=b5ed227667b4b8409dd07ef5dae3b1c76a55168c;hb=d3705ad6676c19417b69cf38dd3667f6b3c3d2ef;hp=6a437e140eaccbca80faba0acd224bfcd474acda;hpb=52cfe54802db8736f1f4e2b67764c43bba9b78b3;p=sbcl.git diff --git a/src/compiler/ppc/system.lisp b/src/compiler/ppc/system.lisp index 6a437e1..b5ed227 100644 --- a/src/compiler/ppc/system.lisp +++ b/src/compiler/ppc/system.lisp @@ -121,15 +121,15 @@ (move res x))) -(define-vop (make-fixnum) +(define-vop (pointer-hash) + (:translate pointer-hash) (:args (ptr :scs (any-reg descriptor-reg))) (:results (res :scs (any-reg descriptor-reg))) + (:policy :fast-safe) (:generator 1 - ;; - ;; Some code (the hash table code) depends on this returning a - ;; positive number so make sure it does. - (inst slwi res ptr 3) - (inst srwi res res 1))) + ;; FIXME: It would be better if this would mask the lowtag, + ;; and shift the result into a positive fixnum like on x86. + (inst rlwinm res ptr n-fixnum-tag-bits 1 n-positive-fixnum-bits))) (define-vop (make-other-immediate-type) (:args (val :scs (any-reg descriptor-reg))