[jumbo] #undef TRACE at the end of source files

This macro is defined all over the place, and often causes macro
redefinition errors in jumbo builds.  Let's make sure all such
instances created in source files are #undef'ed.

Candidate files found with:
  grep -wL '#undef TRACE' $(git grep -wl '#define TRACE' -- '*.cc')

While we're at it, let's undef all macros defined in these files.

Bug: chromium:746958
Change-Id: I639ca2b141f908457d1b2601cd6d5827dee0ead0
Reviewed-on: https://chromium-review.googlesource.com/652476
Reviewed-by: Mircea Trofin <mtrofin@chromium.org>
Reviewed-by: Clemens Hammacher <clemensh@chromium.org>
Commit-Queue: Mostyn Bramley-Moore <mostynb@opera.com>
Cr-Commit-Position: refs/heads/master@{#47859}
This commit is contained in:
Mostyn Bramley-Moore 2017-09-06 19:44:54 +02:00 committed by Commit Bot
parent 40c98daa17
commit b91b8def42
5 changed files with 35 additions and 0 deletions

View File

@ -394,6 +394,8 @@ SimplifiedOperatorBuilder* JSInliningHeuristic::simplified() const {
return jsgraph()->simplified();
}
#undef TRACE
} // namespace compiler
} // namespace internal
} // namespace v8

View File

@ -2369,6 +2369,14 @@ InstructionSelector::AlignmentRequirements() {
}
}
#undef SIMD_BINOP_LIST
#undef SIMD_SHIFT_OP_LIST
#undef SIMD_UNOP_LIST
#undef SIMD_TYPE_LIST
#undef SIMD_FORMAT_LIST
#undef TRACE_UNIMPL
#undef TRACE
} // namespace compiler
} // namespace internal
} // namespace v8

View File

@ -2756,6 +2756,7 @@ void InstructionSelector::VisitInt64AbsWithOverflow(Node* node) {
V(I16x8) \
V(I8x16)
// TODO(mostynb@opera.com): this is never used, remove it?
#define SIMD_FORMAT_LIST(V) \
V(32x4) \
V(16x8) \
@ -3064,6 +3065,14 @@ InstructionSelector::AlignmentRequirements() {
}
}
#undef SIMD_BINOP_LIST
#undef SIMD_SHIFT_OP_LIST
#undef SIMD_UNOP_LIST
#undef SIMD_FORMAT_LIST
#undef SIMD_TYPE_LIST
#undef TRACE_UNIMPL
#undef TRACE
} // namespace compiler
} // namespace internal
} // namespace v8

View File

@ -1151,6 +1151,10 @@ const char* ExternalKindName(WasmExternalKind kind) {
return "unknown";
}
#undef TRACE
#undef TRACE_CHAIN
#undef TRACE_COMPILE
} // namespace wasm
} // namespace internal
} // namespace v8

View File

@ -22,6 +22,7 @@
if (FLAG_trace_wasm_instances) PrintF(__VA_ARGS__); \
} while (false)
// TODO(mostynb@opera.com): this is never used, remove it?
#define TRACE_CHAIN(instance) \
do { \
instance->PrintInstancesChain(); \
@ -1147,7 +1148,15 @@ bool WasmCompiledModule::IsWasmCompiledModule(Object* obj) {
#define WCM_CHECK_LARGE_NUMBER(TYPE, NAME) \
WCM_CHECK_TYPE(NAME, obj->IsUndefined(isolate) || obj->IsMutableHeapNumber())
WCM_PROPERTY_TABLE(WCM_CHECK)
#undef WCM_CHECK_TYPE
#undef WCM_CHECK_OBJECT
#undef WCM_CHECK_CONST_OBJECT
#undef WCM_CHECK_WASM_OBJECT
#undef WCM_CHECK_WEAK_LINK
#undef WCM_CHECK_SMALL_NUMBER
#undef WCM_CHECK
#undef WCM_CHECK_SMALL_CONST_NUMBER
#undef WCM_CHECK_LARGE_NUMBER
// All checks passed.
return true;
@ -1569,5 +1578,8 @@ Handle<Code> WasmCompiledModule::CompileLazy(
patch_caller);
}
#undef TRACE
#undef TRACE_CHAIN
} // namespace internal
} // namespace v8