Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(28)

Side by Side Diff: src/heap/concurrent-marking.h

Issue 2735803005: [heap] Start concurrent marking simultaneously with incremental marking. (Closed)
Patch Set: tweak Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2017 the V8 project authors. All rights reserved. 1 // Copyright 2017 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_HEAP_CONCURRENT_MARKING_ 5 #ifndef V8_HEAP_CONCURRENT_MARKING_
6 #define V8_HEAP_CONCURRENT_MARKING_ 6 #define V8_HEAP_CONCURRENT_MARKING_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "src/allocation.h" 10 #include "src/allocation.h"
(...skipping 10 matching lines...) Expand all
21 class ConcurrentMarking { 21 class ConcurrentMarking {
22 public: 22 public:
23 explicit ConcurrentMarking(Heap* heap); 23 explicit ConcurrentMarking(Heap* heap);
24 ~ConcurrentMarking(); 24 ~ConcurrentMarking();
25 25
26 void AddRoot(HeapObject* object); 26 void AddRoot(HeapObject* object);
27 27
28 void StartMarkingTask(); 28 void StartMarkingTask();
29 void WaitForTaskToComplete(); 29 void WaitForTaskToComplete();
30 30
31 bool IsMarkingInProgress() { return is_task_pending_; }
Hannes Payer (out of office) 2017/03/08 12:58:50 IsInProgress
ulan 2017/03/10 16:45:26 I named it IsTaskPending().
32
31 private: 33 private:
32 class Task; 34 class Task;
33 Heap* heap_; 35 Heap* heap_;
34 base::Semaphore pending_task_; 36 base::Semaphore pending_task_semaphore_;
Michael Lippautz 2017/03/08 19:14:34 super nit (feel free to ignore): We could align na
ulan 2017/03/10 16:45:26 We will probably (re-)start the tasks multiple tim
35 std::vector<HeapObject*> root_set_; 37 std::vector<HeapObject*> root_set_;
38 bool is_task_pending_;
36 }; 39 };
37 40
38 } // namespace internal 41 } // namespace internal
39 } // namespace v8 42 } // namespace v8
40 43
41 #endif // V8_HEAP_PAGE_PARALLEL_JOB_ 44 #endif // V8_HEAP_PAGE_PARALLEL_JOB_
OLDNEW
« no previous file with comments | « src/globals.h ('k') | src/heap/concurrent-marking.cc » ('j') | src/heap/concurrent-marking.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698