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

Unified Diff: runtime/vm/os_thread.cc

Issue 1678203002: Remove more feature in product mode (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 10 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/object.cc ('k') | runtime/vm/parser.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/os_thread.cc
diff --git a/runtime/vm/os_thread.cc b/runtime/vm/os_thread.cc
index 0dcd50602a67d93bdba284f8b3da1e2aa305ce48..03031617cdb8eb8a700edba44bb764538ce4884b 100644
--- a/runtime/vm/os_thread.cc
+++ b/runtime/vm/os_thread.cc
@@ -51,8 +51,10 @@ OSThread::~OSThread() {
RemoveThreadFromList(this);
delete log_;
log_ = NULL;
- if (Timeline::recorder() != NULL) {
- Timeline::recorder()->FinishBlock(timeline_block_);
+ if (FLAG_support_timeline) {
+ if (Timeline::recorder() != NULL) {
+ Timeline::recorder()->FinishBlock(timeline_block_);
+ }
}
timeline_block_ = NULL;
delete timeline_block_lock_;
@@ -70,7 +72,7 @@ void OSThread::EnableThreadInterrupts() {
ASSERT(OSThread::Current() == this);
uintptr_t old =
AtomicOperations::FetchAndDecrement(&thread_interrupt_disabled_);
- if (old == 1) {
+ if (FLAG_profiler && (old == 1)) {
// We just decremented from 1 to 0.
// Make sure the thread interrupter is awake.
ThreadInterrupter::WakeUp();
« no previous file with comments | « runtime/vm/object.cc ('k') | runtime/vm/parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698