From ef0513807d2bb3aa96d81ed18796da2c4a298a95 Mon Sep 17 00:00:00 2001 From: Clemens Hammacher Date: Thu, 14 Jun 2018 14:50:45 +0200 Subject: [PATCH] [cleanup] Properly undef TRACE_ISOLATE R=mstarzinger@chromium.org Bug: v8:7754 Change-Id: I1da5aea2a67047ea8ed48e2b3080d2b8cbf97100 Reviewed-on: https://chromium-review.googlesource.com/1100878 Reviewed-by: Michael Starzinger Commit-Queue: Clemens Hammacher Cr-Commit-Position: refs/heads/master@{#53732} --- src/isolate.cc | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/src/isolate.cc b/src/isolate.cc index 24bbca50e4..d7ab8a746e 100644 --- a/src/isolate.cc +++ b/src/isolate.cc @@ -66,6 +66,18 @@ namespace v8 { namespace internal { +#ifdef DEBUG +#define TRACE_ISOLATE(tag) \ + do { \ + if (FLAG_trace_isolates) { \ + PrintF("Isolate %p (id %d)" #tag "\n", reinterpret_cast(this), \ + id()); \ + } \ + } while (false) +#else +#define TRACE_ISOLATE(tag) +#endif + base::Atomic32 ThreadId::highest_thread_id_ = 0; #ifdef V8_EMBEDDED_BUILTINS @@ -2366,19 +2378,6 @@ void Isolate::ThreadDataTable::RemoveAllThreads() { table_.clear(); } - -#ifdef DEBUG -#define TRACE_ISOLATE(tag) \ - do { \ - if (FLAG_trace_isolates) { \ - PrintF("Isolate %p (id %d)" #tag "\n", \ - reinterpret_cast(this), id()); \ - } \ - } while (false) -#else -#define TRACE_ISOLATE(tag) -#endif - class VerboseAccountingAllocator : public AccountingAllocator { public: VerboseAccountingAllocator(Heap* heap, size_t allocation_sample_bytes, @@ -4198,5 +4197,8 @@ bool InterruptsScope::Intercept(StackGuard::InterruptFlag flag) { last_postpone_scope->intercepted_flags_ |= flag; return true; } + +#undef TRACE_ISOLATE + } // namespace internal } // namespace v8