X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Fpcl%2Fcache.lisp;h=7536f2a76dadbd5b38b76fb13ff77f03fd97fcbf;hb=c01ff86b012283af04641a02e45f066aa7cdb10c;hp=ed83efde42e7e6e04dddb23de9776e395eee3c93;hpb=e13730f246bc1f6b4fab39479f4e50534283dac1;p=sbcl.git diff --git a/src/pcl/cache.lisp b/src/pcl/cache.lisp index ed83efd..7536f2a 100644 --- a/src/pcl/cache.lisp +++ b/src/pcl/cache.lisp @@ -204,6 +204,7 @@ (defmacro wrapper-no-of-instance-slots (wrapper) `(layout-length ,wrapper)) +;;; FIXME: Why are these macros? (defmacro wrapper-instance-slots-layout (wrapper) `(%wrapper-instance-slots-layout ,wrapper)) (defmacro wrapper-class-slots (wrapper) @@ -367,9 +368,8 @@ ;; INSTANCE's class. See also the comment above ;; FORCE-CACHE-FLUSHES. Paul Dietz has test cases for this. ((member t) - (let ((class (class-of instance))) - (force-cache-flushes class) - (class-wrapper class))) + (force-cache-flushes (class-of instance)) + (check-wrapper-validity instance)) (cons (ecase (car state) (:flush @@ -651,13 +651,13 @@ (defun dfun-arg-symbol (arg-number) (or (nth arg-number (the list *dfun-arg-symbols*)) - (intern (format nil ".ARG~A." arg-number) *pcl-package*))) + (format-symbol *pcl-package* ".ARG~A." arg-number))) (defvar *slot-vector-symbols* '(.SLOTS0. .SLOTS1. .SLOTS2. .SLOTS3.)) (defun slot-vector-symbol (arg-number) (or (nth arg-number (the list *slot-vector-symbols*)) - (intern (format nil ".SLOTS~A." arg-number) *pcl-package*))) + (format-symbol *pcl-package* ".SLOTS~A." arg-number))) ;; FIXME: There ought to be a good way to factor out the idiom: ;; @@ -941,7 +941,7 @@ (assert wrappers) (or (fill-cache-p nil cache wrappers value) - (and (< (ceiling (* (cache-count cache) 1.25)) + (and (< (ceiling (* (cache-count cache) *cache-expand-threshold*)) (if (= (cache-nkeys cache) 1) (1- (cache-nlines cache)) (cache-nlines cache)))