Changeset 190350 in webkit
- Timestamp:
- Sep 30, 2015 10:17:27 AM (9 years ago)
- Location:
- trunk/Source
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r190329 r190350 1 2015-09-30 Commit Queue <commit-queue@webkit.org> 2 3 Unreviewed, rolling out r190324. 4 https://bugs.webkit.org/show_bug.cgi?id=149671 5 6 Caused flaky crashes, rdar://problem/22916304 (Requested by ap 7 on #webkit). 8 9 Reverted changeset: 10 11 "ParallelHelperPool::runFunctionInParallel() shouldn't 12 allocate, and ParallelHelperPool.h shouldn't be included 13 everywhere" 14 https://bugs.webkit.org/show_bug.cgi?id=149635 15 http://trac.webkit.org/changeset/190324 16 1 17 2015-09-29 Commit Queue <commit-queue@webkit.org> 2 18 -
trunk/Source/JavaScriptCore/heap/Heap.cpp
r190324 r190350 54 54 #include <wtf/RAMSize.h> 55 55 #include <wtf/CurrentTime.h> 56 #include <wtf/ParallelHelperPool.h>57 56 #include <wtf/ParallelVectorIterator.h> 58 57 #include <wtf/ProcessID.h> … … 359 358 , m_delayedReleaseRecursionCount(0) 360 359 #endif 361 , m_helperClient( std::make_unique<ParallelHelperClient>(&heapHelperPool()))360 , m_helperClient(&heapHelperPool()) 362 361 { 363 362 m_storageSpace.init(); … … 549 548 m_parallelMarkersShouldExit = false; 550 549 551 m_helperClient ->setFunction(550 m_helperClient.setFunction( 552 551 [this] () { 553 552 SlotVisitor* slotVisitor; … … 606 605 m_markingConditionVariable.notifyAll(); 607 606 } 608 m_helperClient ->finish();607 m_helperClient.finish(); 609 608 updateObjectCounts(gcStartTime); 610 609 resetVisitors(); … … 639 638 // we have created is not going to be running anymore. Hence, everything on the stack here 640 639 // outlives the task. 641 m_helperClient ->runFunctionInParallel(640 m_helperClient.runFunctionInParallel( 642 641 [&] () { 643 642 CopyVisitor copyVisitor(*this); -
trunk/Source/JavaScriptCore/heap/Heap.h
r190324 r190350 46 46 #include <wtf/HashCountedSet.h> 47 47 #include <wtf/HashSet.h> 48 49 namespace WTF { 50 class ParallelHelperClient; 51 } 52 using WTF::ParallelHelperClient; 48 #include <wtf/ParallelHelperPool.h> 53 49 54 50 namespace JSC { … … 446 442 ListableHandler<UnconditionalFinalizer>::List m_unconditionalFinalizers; 447 443 448 std::unique_ptr<ParallelHelperClient>m_helperClient;444 ParallelHelperClient m_helperClient; 449 445 }; 450 446 -
trunk/Source/WTF/ChangeLog
r190324 r190350 1 2015-09-30 Commit Queue <commit-queue@webkit.org> 2 3 Unreviewed, rolling out r190324. 4 https://bugs.webkit.org/show_bug.cgi?id=149671 5 6 Caused flaky crashes, rdar://problem/22916304 (Requested by ap 7 on #webkit). 8 9 Reverted changeset: 10 11 "ParallelHelperPool::runFunctionInParallel() shouldn't 12 allocate, and ParallelHelperPool.h shouldn't be included 13 everywhere" 14 https://bugs.webkit.org/show_bug.cgi?id=149635 15 http://trac.webkit.org/changeset/190324 16 1 17 2015-09-29 Filip Pizlo <fpizlo@apple.com> 2 18 -
trunk/Source/WTF/wtf/ParallelHelperPool.h
r190324 r190350 149 149 WTF_EXPORT_PRIVATE void runTaskInParallel(RefPtr<SharedTask>); 150 150 151 // Semantically equivalent to:151 // Equivalent to: 152 152 // client->setFunction(functor); 153 153 // client->doSomeHelping(); 154 154 // client->finish(); 155 //156 // Except, unlike the above sequence, this won't allocate the task in the heap. This allocates157 // the task on the stack because it knows that the task is not reachable after this method is158 // done.159 155 template<typename Functor> 160 156 void runFunctionInParallel(const Functor& functor) 161 157 { 162 SharedTaskFunctor<Functor> sharedTask(functor); 163 runTaskInParallel(&sharedTask); 158 runTaskInParallel(createSharedTask(functor)); 164 159 } 165 160
Note: See TracChangeset
for help on using the changeset viewer.