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

Side by Side Diff: src/heap/page-parallel-job.h

Issue 1961893002: Instrument callers of Semaphore::Signal to help with investigation of (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 7 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
« no previous file with comments | « src/heap/mark-compact.cc ('k') | src/heap/spaces.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 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_PAGE_PARALLEL_JOB_ 5 #ifndef V8_HEAP_PAGE_PARALLEL_JOB_
6 #define V8_HEAP_PAGE_PARALLEL_JOB_ 6 #define V8_HEAP_PAGE_PARALLEL_JOB_
7 7
8 #include "src/allocation.h" 8 #include "src/allocation.h"
9 #include "src/cancelable-task.h" 9 #include "src/cancelable-task.h"
10 #include "src/utils.h" 10 #include "src/utils.h"
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 bool success = JobTraits::ProcessPageInParallel( 154 bool success = JobTraits::ProcessPageInParallel(
155 heap_, data_, current->chunk, current->data); 155 heap_, data_, current->chunk, current->data);
156 current->state.SetValue(success ? kFinished : kFailed); 156 current->state.SetValue(success ? kFinished : kFailed);
157 } 157 }
158 current = current->next; 158 current = current->next;
159 // Wrap around if needed. 159 // Wrap around if needed.
160 if (current == nullptr) { 160 if (current == nullptr) {
161 current = items_; 161 current = items_;
162 } 162 }
163 } 163 }
164 on_finish_->Signal(); 164 on_finish_->Signal("PageParallelJob::Task::RunInternal");
165 } 165 }
166 166
167 Heap* heap_; 167 Heap* heap_;
168 Item* items_; 168 Item* items_;
169 int num_items_; 169 int num_items_;
170 int start_index_; 170 int start_index_;
171 base::Semaphore* on_finish_; 171 base::Semaphore* on_finish_;
172 typename JobTraits::PerTaskData data_; 172 typename JobTraits::PerTaskData data_;
173 DISALLOW_COPY_AND_ASSIGN(Task); 173 DISALLOW_COPY_AND_ASSIGN(Task);
174 }; 174 };
175 175
176 Heap* heap_; 176 Heap* heap_;
177 CancelableTaskManager* cancelable_task_manager_; 177 CancelableTaskManager* cancelable_task_manager_;
178 Item* items_; 178 Item* items_;
179 int num_items_; 179 int num_items_;
180 int num_tasks_; 180 int num_tasks_;
181 base::Semaphore* pending_tasks_; 181 base::Semaphore* pending_tasks_;
182 DISALLOW_COPY_AND_ASSIGN(PageParallelJob); 182 DISALLOW_COPY_AND_ASSIGN(PageParallelJob);
183 }; 183 };
184 184
185 } // namespace internal 185 } // namespace internal
186 } // namespace v8 186 } // namespace v8
187 187
188 #endif // V8_HEAP_PAGE_PARALLEL_JOB_ 188 #endif // V8_HEAP_PAGE_PARALLEL_JOB_
OLDNEW
« no previous file with comments | « src/heap/mark-compact.cc ('k') | src/heap/spaces.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698