X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcompiler%2Ftn.lisp;h=a94c585b126706f02849ccc25f0625820ce85e58;hb=a8419eb994f3b59b70cfa12e1004711a830a43fa;hp=cd2525a394940e76328d79925c09c3c763fa6d1e;hpb=741d910ca6f69a115905872ea84258baba5392c7;p=sbcl.git diff --git a/src/compiler/tn.lisp b/src/compiler/tn.lisp index cd2525a..a94c585 100644 --- a/src/compiler/tn.lisp +++ b/src/compiler/tn.lisp @@ -204,15 +204,17 @@ (let* ((immed (immediate-constant-sc (constant-value constant))) (use-immed-p (and immed (or (not boxedp) - (eql immed (sc-number-or-lose 'sb!vm::immediate)))))) + (boxed-immediate-sc-p immed))))) (cond ;; CONSTANT-TN uses two caches, one for boxed and one for unboxed uses. ;; ;; However, in the case of USE-IMMED-P we can have the same TN for both ;; uses. The first two legs here take care of that by cross-pollinating the ;; cached values. - ((and use-immed-p boxedp (leaf-info constant))) - ((and use-immed-p (not boxedp) (constant-boxed-tn constant))) + ;; + ;; Similarly, when there is no immediate SC. + ((and (or use-immed-p (not immed)) boxedp (leaf-info constant))) + ((and (or use-immed-p (not immed)) (not boxedp) (constant-boxed-tn constant))) (t (let* ((component (component-info *component-being-compiled*)) (sc (svref *backend-sc-numbers*