Changeset 244506 in webkit
- Timestamp:
- Apr 22, 2019 11:35:04 AM (5 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r244505 r244506 1 2019-04-22 Yusuke Suzuki <ysuzuki@apple.com> 2 3 [JSC] Use volatile load to populate backing page in MarkedBlock::Footer instead of using holdLock 4 https://bugs.webkit.org/show_bug.cgi?id=197152 5 6 Reviewed by Saam Barati. 7 8 Emit volatile load instead of using holdLock to populate backing page in MarkedBlock::Footer. 9 10 * heap/BlockDirectory.cpp: 11 (JSC::BlockDirectory::isPagedOut): 12 * heap/MarkedBlock.h: 13 (JSC::MarkedBlock::populatePage const): 14 1 15 2019-04-22 Yusuke Suzuki <ysuzuki@apple.com> 2 16 -
trunk/Source/JavaScriptCore/heap/BlockDirectory.cpp
r244352 r244506 62 62 unsigned itersSinceLastTimeCheck = 0; 63 63 for (auto* block : m_blocks) { 64 if (block) { 65 // We take and drop the lock as a way of touching that page of memory. 66 // FIXME: should we instead do a cheaper thing like a volatile load in the page? 67 (void) holdLock(block->block().lock()); 68 } 64 if (block) 65 block->block().populatePage(); 69 66 ++itersSinceLastTimeCheck; 70 67 if (itersSinceLastTimeCheck >= Heap::s_timeCheckResolution) { -
trunk/Source/JavaScriptCore/heap/MarkedBlock.h
r243667 r244506 375 375 376 376 Subspace* subspace() const { return footer().m_subspace; } 377 378 void populatePage() const 379 { 380 *bitwise_cast<volatile uint8_t*>(&footer()); 381 } 377 382 378 383 static constexpr size_t offsetOfFooter = endAtom * atomSize;
Note: See TracChangeset
for help on using the changeset viewer.