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

Unified Diff: src/heap.cc

Issue 10807024: Optimize functions on a second thread. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: src/heap.cc
diff --git a/src/heap.cc b/src/heap.cc
index 15ac5c31ae944a12a209db2e5206b91a70c01503..3bb89bda91fedee9656f55f50e6e385a807ad9bb 100644
--- a/src/heap.cc
+++ b/src/heap.cc
@@ -1199,6 +1199,7 @@ class ScavengeWeakObjectRetainer : public WeakObjectRetainer {
void Heap::Scavenge() {
+ RelocationLock relocation_lock(this);
#ifdef DEBUG
if (FLAG_verify_heap) VerifyNonPointerSpacePointers();
#endif
@@ -6161,6 +6162,8 @@ bool Heap::SetUp(bool create_heap_objects) {
store_buffer()->SetUp();
+ if (FLAG_parallel_recompilation) relocation_mutex_ = OS::CreateMutex();
+
return true;
}
@@ -6246,6 +6249,8 @@ void Heap::TearDown() {
isolate_->memory_allocator()->TearDown();
+ if (FLAG_parallel_recompilation) delete relocation_mutex_;
Yang 2012/07/19 12:47:30 I think you can omit checking for the flag since d
sanjoy 2012/07/19 15:06:09 Done.
+
#ifdef DEBUG
delete debug_utils_;
debug_utils_ = NULL;

Powered by Google App Engine
This is Rietveld 408576698