Changeset 92092 in webkit


Ignore:
Timestamp:
Jul 31, 2011 4:48:27 PM (13 years ago)
Author:
fpizlo@apple.com
Message:

JSC GC lays out size classes under wrong assumptions about expected
object size.
https://bugs.webkit.org/show_bug.cgi?id=65437

Reviewed by Oliver Hunt.

Changed the atom size - which is both the smallest allocation size and
the smallest possible stepping unit for size class spacing - from
8 bytes to 4 pointer-size words. This is a 1% win on SunSpider.

  • heap/MarkedBlock.h:
Location:
trunk/Source/JavaScriptCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ChangeLog

    r92085 r92092  
     12011-07-31  Filip Pizlo  <fpizlo@apple.com>
     2
     3        JSC GC lays out size classes under wrong assumptions about expected
     4        object size.
     5        https://bugs.webkit.org/show_bug.cgi?id=65437
     6
     7        Reviewed by Oliver Hunt.
     8       
     9        Changed the atom size - which is both the smallest allocation size and
     10        the smallest possible stepping unit for size class spacing - from
     11        8 bytes to 4 pointer-size words.  This is a 1% win on SunSpider.
     12
     13        * heap/MarkedBlock.h:
     14
    1152011-07-31  Filip Pizlo  <fpizlo@apple.com>
    216
  • trunk/Source/JavaScriptCore/heap/MarkedBlock.h

    r92084 r92092  
    4343        friend class WTF::DoublyLinkedListNode<MarkedBlock>;
    4444    public:
    45         static const size_t atomSize = sizeof(double); // Ensures natural alignment for all built-in types.
     45        // Ensure natural alignment for native types whilst recognizing that the smallest
     46        // object the heap will commonly allocate is four words.
     47        static const size_t atomSize = 4 * sizeof(void*);
    4648        static const size_t blockSize = 16 * KB;
    4749
Note: See TracChangeset for help on using the changeset viewer.