Changeset 5569


Ignore:
Timestamp:
Dec 3, 2006, 1:21:37 AM (18 years ago)
Author:
Gary Byers
Message:

CHECK-MISC-BOUNDS: shift the header word right (after clearing its low
byte) and compare the index to that. (Shifting the index left - d'oh -
obviously fails for indices of large magnitude.)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ccl/compiler/X86/X8664/x8664-vinsns.lisp

    r5535 r5569  
    680680                                       (v :lisp))
    681681                                      ((temp :u64)))
    682   (movq (:%q idx) (:%q temp))
    683   (shlq (:$ub (- x8664::num-subtag-bits x8664::fixnumshift)) (:%q temp))
    684   (decb (:%b temp))
    685   (rcmpq (:%q temp) (:@ x8664::misc-header-offset (:%q v)))
     682  (movq (:@ x8664::misc-header-offset (:%q v)) (:%q temp))
     683  (xorb (:%b temp) (:%b temp))
     684  (shrq (:$ub (- x8664::num-subtag-bits x8664::fixnumshift)) (:%q temp))
     685  (rcmpq (:%q idx) (:%q temp))
    686686  (jb.pt :ok)
    687687  (uuo-error-vector-bounds (:%q idx) (:%q v))
Note: See TracChangeset for help on using the changeset viewer.