X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=contrib%2Fsb-rotate-byte%2Fcompiler.lisp;h=2e7d5e1d7f1bc179613d2cab5aab069bc57458c5;hb=939275c1bc2f18ef93cd1dd4ab35a18f6008cfd9;hp=a2282278426f445db19cc1bf8ca713eaaab22394;hpb=4f4a1695fa74e2becf1fb87110132ad4943fac61;p=sbcl.git diff --git a/contrib/sb-rotate-byte/compiler.lisp b/contrib/sb-rotate-byte/compiler.lisp index a228227..2e7d5e1 100644 --- a/contrib/sb-rotate-byte/compiler.lisp +++ b/contrib/sb-rotate-byte/compiler.lisp @@ -29,29 +29,29 @@ (defoptimizer (%rotate-byte derive-type) ((count size posn num)) ;; FIXME: this looks fairly unwieldy. I'm sure it can be made ;; simpler, and also be made to deal with negative integers too. - (let ((size (sb-c::continuation-type size))) + (let ((size (sb-c::lvar-type size))) (if (numeric-type-p size) - (let ((size-high (numeric-type-high size)) - (num-type (sb-c::continuation-type num))) - (if (and size-high - num-type - (<= size-high sb-vm:n-word-bits) - (csubtypep num-type - (specifier-type `(unsigned-byte ,size-high)))) + (let ((size-high (numeric-type-high size)) + (num-type (sb-c::lvar-type num))) + (if (and size-high + num-type + (<= size-high sb-vm:n-word-bits) + (csubtypep num-type + (specifier-type `(unsigned-byte ,size-high)))) (specifier-type `(unsigned-byte ,size-high)) - *universal-type*)) + *universal-type*)) *universal-type*))) (deftransform %rotate-byte ((count size pos integer) - ((constant-arg (member 0)) * * *) *) + ((constant-arg (member 0)) * * *) *) "fold identity operation" 'integer) (deftransform %rotate-byte ((count size pos integer) - ((integer -31 31) - (constant-arg (member 32)) - (constant-arg (member 0)) - (unsigned-byte 32)) *) + ((integer -31 31) + (constant-arg (member 32)) + (constant-arg (member 0)) + (unsigned-byte 32)) *) "inline 32-bit rotation" ;; FIXME: What happens when, as here, the two type specifiers for ;; COUNT overlap? Which gets to run first?