Commit 5cddc222 authored by Wez's avatar Wez Committed by Commit Bot

Update the enable_frame_pointers logic for ChromeOS.

Now that we have a patch for the ARM A12/A17 errata, it is safe to try
building ARM Thumb without frame-pointers again, since we don't need
them.

We leave frame-pointers enabled in ChromeOS for 64-bit.

The Windows case is tweaked to use current_cpu rather than target_cpu,
and the Android case is explicitly gated on is_android.

Bug: 740806, 711784
Change-Id: I2fff46d1a3a8d78d12c389f95a20acf54013318d
Reviewed-on: https://chromium-review.googlesource.com/567608
Commit-Queue: Wez <wez@chromium.org>
Reviewed-by: default avatarDirk Pranke <dpranke@chromium.org>
Cr-Commit-Position: refs/heads/master@{#486165}
parent 085ef091
...@@ -78,11 +78,11 @@ if (is_mac || is_ios) { ...@@ -78,11 +78,11 @@ if (is_mac || is_ios) {
enable_frame_pointers = true enable_frame_pointers = true
} }
} else if (is_chromeos) { } else if (is_chromeos) {
# ChromeOS requires frame pointers in x64 builds, to support CWP. # ChromeOS generally prefers frame pointers, to support CWP.
# TODO(711784): Building ARM Thumb without frame pointers can lead to code # However, Clang does not currently generate usable frame pointers in ARM
# in ChromeOS which triggers some ARM A12/A17 errata. They can be disabled # 32-bit builds (https://bugs.llvm.org/show_bug.cgi?id=18505) so disable them
# on non-x64 once that is resolved. # there to avoid the unnecessary overhead.
enable_frame_pointers = true enable_frame_pointers = current_cpu != "arm"
} else if (current_cpu == "arm64") { } else if (current_cpu == "arm64") {
# Ensure that stacks from arm64 crash dumps are usable (crbug.com/391706). # Ensure that stacks from arm64 crash dumps are usable (crbug.com/391706).
enable_frame_pointers = true enable_frame_pointers = true
...@@ -100,6 +100,7 @@ if (is_mac || is_ios) { ...@@ -100,6 +100,7 @@ if (is_mac || is_ios) {
can_unwind_with_frame_pointers = enable_frame_pointers can_unwind_with_frame_pointers = enable_frame_pointers
if (current_cpu == "arm" && arm_use_thumb) { if (current_cpu == "arm" && arm_use_thumb) {
# We cannot currently unwind ARM Thumb frame pointers correctly. # We cannot currently unwind ARM Thumb frame pointers correctly.
# See https://bugs.llvm.org/show_bug.cgi?id=18505
can_unwind_with_frame_pointers = false can_unwind_with_frame_pointers = false
} else if (is_win) { } else if (is_win) {
# Windows 32-bit does provide frame pointers, but the compiler does not # Windows 32-bit does provide frame pointers, but the compiler does not
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment