Remove pragma optimize
from v8.
This instance of `pragma optimize` was from long ago when we built with frame pointers disabled. We always build with frame pointers on these days. (Also, clang-cl ignores this pragma and will warn about it.) Bug: chromium:505314 Change-Id: Ia125c9c54e6ec486247241102de1cb62c72d268b Reviewed-on: https://chromium-review.googlesource.com/993423 Commit-Queue: Jakob Kummerow <jkummerow@chromium.org> Reviewed-by: Jakob Kummerow <jkummerow@chromium.org> Cr-Commit-Position: refs/heads/master@{#52336}
This commit is contained in:
parent
2e197ba64e
commit
d8840043fb
@ -163,24 +163,11 @@ void DisableSignalStackDump() {
|
||||
g_dump_stack_in_signal_handler = false;
|
||||
}
|
||||
|
||||
// Disable optimizations for the StackTrace::StackTrace function. It is
|
||||
// important to disable at least frame pointer optimization ("y"), since
|
||||
// that breaks CaptureStackBackTrace() and prevents StackTrace from working
|
||||
// in Release builds (it may still be janky if other frames are using FPO,
|
||||
// but at least it will make it further).
|
||||
#if defined(V8_CC_MSVC)
|
||||
#pragma optimize("", off)
|
||||
#endif
|
||||
|
||||
StackTrace::StackTrace() {
|
||||
// When walking our own stack, use CaptureStackBackTrace().
|
||||
count_ = CaptureStackBackTrace(0, arraysize(trace_), trace_, nullptr);
|
||||
}
|
||||
|
||||
#if defined(V8_CC_MSVC)
|
||||
#pragma optimize("", on)
|
||||
#endif
|
||||
|
||||
StackTrace::StackTrace(EXCEPTION_POINTERS* exception_pointers) {
|
||||
InitTrace(exception_pointers->ContextRecord);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user