X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fcode%2Farray.lisp;h=286d197b9a097999a0e57b00c98d24e7ed4dbe3e;hb=9b634117911815fbf4154546431b4dcf13e38b47;hp=873a9b7678f3a2bd2175886d58e81221f0b616d1;hpb=8cd045dfd24638b1958f1507f944f249d2d2ccde;p=sbcl.git diff --git a/src/code/array.lisp b/src/code/array.lisp index 873a9b7..286d197 100644 --- a/src/code/array.lisp +++ b/src/code/array.lisp @@ -56,7 +56,8 @@ (values vector index)) (values array index))) -(defun safe-simple-vector-compare-and-swap (vector index old new) +(declaim (inline simple-vector-compare-and-swap)) +(defun simple-vector-compare-and-swap (vector index old new) #!+(or x86 x86-64) (%simple-vector-compare-and-swap vector (%check-bound vector (length vector) index) @@ -349,11 +350,7 @@ of specialized arrays is supported." (:little-endian (- sb!vm:other-pointer-lowtag)) (:big-endian - ;; I'm not completely sure of what this - ;; 3 represents symbolically. It's - ;; just what all the LOAD-TYPE vops - ;; are doing. - (- 3 sb!vm:other-pointer-lowtag))))) + (- (1- sb!vm:n-word-bytes) sb!vm:other-pointer-lowtag))))) ;; WIDETAG-OF needs extra code to handle ;; LIST and FUNCTION lowtags. We're only ;; dispatching on other pointers, so let's @@ -485,6 +482,9 @@ of specialized arrays is supported." (defun data-vector-ref (array index) (hairy-data-vector-ref array index)) +(defun data-vector-ref-with-offset (array index offset) + (hairy-data-vector-ref array (+ index offset))) + ;;; SUBSCRIPTS has a dynamic-extent list structure and is destroyed (defun %array-row-major-index (array subscripts &optional (invalid-index-error-p t))