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

Unified Diff: runtime/vm/isolate.cc

Issue 2998663002: Reverts CLs related to the TLAB due to heap exhaustion. (Closed)
Patch Set: Created 3 years, 4 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
« no previous file with comments | « runtime/vm/heap.cc ('k') | runtime/vm/scavenger.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/isolate.cc
diff --git a/runtime/vm/isolate.cc b/runtime/vm/isolate.cc
index c32e7e63451358def58842205b5803762b5a8548..d97a4cfa1548eb9d7058dd4b76b3983f69f2e772 100644
--- a/runtime/vm/isolate.cc
+++ b/runtime/vm/isolate.cc
@@ -2563,6 +2563,10 @@ Thread* Isolate::ScheduleThread(bool is_mutator, bool bypass_safepoint) {
os_thread->set_thread(thread);
if (is_mutator) {
scheduled_mutator_thread_ = thread;
+ if (this != Dart::vm_isolate()) {
+ scheduled_mutator_thread_->set_top(heap()->new_space()->top());
+ scheduled_mutator_thread_->set_end(heap()->new_space()->end());
+ }
}
Thread::SetCurrent(thread);
os_thread->EnableThreadInterrupts();
@@ -2601,6 +2605,12 @@ void Isolate::UnscheduleThread(Thread* thread,
os_thread->set_thread(NULL);
OSThread::SetCurrent(os_thread);
if (is_mutator) {
+ if (this != Dart::vm_isolate()) {
+ heap()->new_space()->set_top(scheduled_mutator_thread_->top_);
+ heap()->new_space()->set_end(scheduled_mutator_thread_->end_);
+ }
+ scheduled_mutator_thread_->top_ = 0;
+ scheduled_mutator_thread_->end_ = 0;
scheduled_mutator_thread_ = NULL;
}
thread->isolate_ = NULL;
« no previous file with comments | « runtime/vm/heap.cc ('k') | runtime/vm/scavenger.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698