Changeset 182878 in webkit
- Timestamp:
- Apr 15, 2015, 8:40:14 PM (11 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 5 edited
-
ChangeLog (modified) (1 diff)
-
heap/MarkedBlock.h (modified) (1 diff)
-
heap/WeakBlock.h (modified) (1 diff)
-
llint/LLIntData.cpp (modified) (1 diff)
-
llint/LowLevelInterpreter.asm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r182872 r182878 1 2015-04-15 Andreas Kling <akling@apple.com> 2 3 Make MarkedBlock and WeakBlock 4x smaller. 4 <https://webkit.org/b/143802> 5 6 Reviewed by Mark Hahnenberg. 7 8 To reduce GC heap fragmentation and generally use less memory, reduce the size of MarkedBlock 9 and its buddy WeakBlock by 4x, bringing them from 64kB+4kB to 16kB+1kB. 10 11 In a sampling of cool web sites, I'm seeing ~8% average reduction in overall GC heap size. 12 Some examples: 13 14 apple.com: 6.3MB -> 5.5MB (14.5% smaller) 15 reddit.com: 4.5MB -> 4.1MB ( 9.7% smaller) 16 twitter.com: 23.2MB -> 21.4MB ( 8.4% smaller) 17 cuteoverload.com: 24.5MB -> 23.6MB ( 3.8% smaller) 18 19 Benchmarks look mostly neutral. 20 Some small slowdowns on Octane, some slightly bigger speedups on Kraken and SunSpider. 21 22 * heap/MarkedBlock.h: 23 * heap/WeakBlock.h: 24 * llint/LLIntData.cpp: 25 (JSC::LLInt::Data::performAssertions): 26 * llint/LowLevelInterpreter.asm: 27 1 28 2015-04-15 Jordan Harband <ljharb@gmail.com> 2 29 -
trunk/Source/JavaScriptCore/heap/MarkedBlock.h
r182747 r182878 75 75 static const size_t atomSize = 16; // bytes 76 76 static const size_t atomShiftAmount = 4; // log_2(atomSize) FIXME: Change atomSize to 16. 77 static const size_t blockSize = 64* KB;77 static const size_t blockSize = 16 * KB; 78 78 static const size_t blockMask = ~(blockSize - 1); // blockSize must be a power of two. 79 79 -
trunk/Source/JavaScriptCore/heap/WeakBlock.h
r182347 r182878 42 42 public: 43 43 friend class WTF::DoublyLinkedListNode<WeakBlock>; 44 static const size_t blockSize = 4 * KB; // 5%of MarkedBlock size44 static const size_t blockSize = 1 * KB; // 1/16 of MarkedBlock size 45 45 46 46 struct FreeCell { -
trunk/Source/JavaScriptCore/llint/LLIntData.cpp
r182205 r182878 154 154 ASSERT(ResolveModeAndType::mask == 0xffff); 155 155 156 ASSERT(MarkedBlock::blockMask == ~static_cast<decltype(MarkedBlock::blockMask)>(0x ffff));156 ASSERT(MarkedBlock::blockMask == ~static_cast<decltype(MarkedBlock::blockMask)>(0x3fff)); 157 157 158 158 // FIXME: make these assertions less horrible. -
trunk/Source/JavaScriptCore/llint/LowLevelInterpreter.asm
r182759 r182878 197 197 const ResolveModeMask = 0xffff 198 198 199 const MarkedBlockSize = 64* 1024199 const MarkedBlockSize = 16 * 1024 200 200 const MarkedBlockMask = ~(MarkedBlockSize - 1) 201 201 # Constants for checking mark bits.
Note:
See TracChangeset
for help on using the changeset viewer.