Changeset 7889


Ignore:
Timestamp:
Dec 12, 2007, 10:11:27 AM (13 years ago)
Author:
gb
Message:

Try to avoide a GF call in %SHARED-INITIALIZE.

Look at %CLASS.CPL (which is inlined) first before calling %INITED-CLASS-CPL
in optimized reader dcode functions that need the CPL.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/working-0711/ccl/level-1/l1-clos.lisp

    r7864 r7889  
    16931693  ;; obsolete instances.  This'll eventually call
    16941694  ;; UPDATE-INSTANCE-FOR-REDEFINED-CLASS if it needs to.
    1695   (let* ((wrapper (instance-class-wrapper instance))
     1695  (let* ((wrapper (if (eq (typecode instance) target::subtag-instance)
     1696                    (instance.class-wrapper instance)
     1697                    (instance-class-wrapper instance)))
    16961698         (class (%wrapper-class wrapper)))
    16971699    (when (eql 0 (%wrapper-hash-index wrapper)) ; obsolete
     
    17961798         (class (if (eq (typecode instance) target::subtag-instance)
    17971799                  (%class-of-instance instance))))
    1798     (if (and class (memq defining-class (%inited-class-cpl class)))
     1800    (if (and class (memq defining-class (or (%class.cpl class)
     1801                                            (%inited-class-cpl class))))
    17991802      (%slot-ref (instance.slots instance) location)
    18001803      (no-applicable-method (%gf-dispatch-table-gf dt) instance))))
     
    18101813         (class (if (eq (typecode instance) target::subtag-instance)
    18111814                  (%class-of-instance instance)))
    1812          (cpl (if class (%inited-class-cpl class))))
     1815         (cpl (if class (or (%class.cpl class) (%inited-class-cpl class)))))
    18131816    (if (dolist (defining-class (%svref dt %gf-dispatch-table-first-data))
    18141817          (when (memq defining-class cpl) (return t)))
Note: See TracChangeset for help on using the changeset viewer.