Changeset 54141 in webkit


Ignore:
Timestamp:
Feb 1, 2010 12:04:34 PM (14 years ago)
Author:
oliver@apple.com
Message:

2010-02-01 Oliver Hunt <oliver@apple.com>

Reviewed by Gavin Barraclough.

Structure not accounting for anonymous slots when computing property storage size
https://bugs.webkit.org/show_bug.cgi?id=34441

Previously any Structure with anonymous storage would have a property map, so we
were only including anonymous slot size if there was a property map. Given this
is no longer the case we should always include the anonymous slot count in the
property storage size.

  • runtime/Structure.h: (JSC::Structure::propertyStorageSize):
Location:
trunk/JavaScriptCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/ChangeLog

    r54131 r54141  
     12010-02-01  Oliver Hunt  <oliver@apple.com>
     2
     3        Reviewed by Gavin Barraclough.
     4
     5        Structure not accounting for anonymous slots when computing property storage size
     6        https://bugs.webkit.org/show_bug.cgi?id=34441
     7
     8        Previously any Structure with anonymous storage would have a property map, so we
     9        were only including anonymous slot size if there was a property map.  Given this
     10        is no longer the case we should always include the anonymous slot count in the
     11        property storage size.
     12
     13        * runtime/Structure.h:
     14        (JSC::Structure::propertyStorageSize):
     15
    1162010-02-01  Oliver Hunt  <oliver@apple.com>
    217
  • trunk/JavaScriptCore/runtime/Structure.h

    r54129 r54141  
    102102        void growPropertyStorageCapacity();
    103103        unsigned propertyStorageCapacity() const { return m_propertyStorageCapacity; }
    104         unsigned propertyStorageSize() const { return m_propertyTable ? m_propertyTable->keyCount + m_propertyTable->anonymousSlotCount + (m_propertyTable->deletedOffsets ? m_propertyTable->deletedOffsets->size() : 0) : m_offset + 1; }
     104        unsigned propertyStorageSize() const { return m_anonymousSlotCount + (m_propertyTable ? m_propertyTable->keyCount + (m_propertyTable->deletedOffsets ? m_propertyTable->deletedOffsets->size() : 0) : m_offset + 1); }
    105105        bool isUsingInlineStorage() const;
    106106
Note: See TracChangeset for help on using the changeset viewer.