Commit 2b29b630 authored by shenhan's avatar shenhan Committed by Commit bot

OS::ArmUsingHardFloat returns bogus value for clang-built chrome.

This caused a runtime crash for Chrome built with clang on all
ChromeOs
arm32 platforms - ChromeOs chrome is using hardfp while this routine
returns false.

The fix is straightforward.

BUG=chromium:586219
TEST=built arm32 hardfp using clang and passed all tests.
LOG=N

Review URL: https://codereview.chromium.org/1733863002

Cr-Commit-Position: refs/heads/master@{#34367}
parent a40d5d54
...@@ -72,14 +72,14 @@ bool OS::ArmUsingHardFloat() { ...@@ -72,14 +72,14 @@ bool OS::ArmUsingHardFloat() {
#define GCC_VERSION (__GNUC__ * 10000 \ #define GCC_VERSION (__GNUC__ * 10000 \
+ __GNUC_MINOR__ * 100 \ + __GNUC_MINOR__ * 100 \
+ __GNUC_PATCHLEVEL__) + __GNUC_PATCHLEVEL__)
#if GCC_VERSION >= 40600 #if GCC_VERSION >= 40600 && !defined(__clang__)
#if defined(__ARM_PCS_VFP) #if defined(__ARM_PCS_VFP)
return true; return true;
#else #else
return false; return false;
#endif #endif
#elif GCC_VERSION < 40500 #elif GCC_VERSION < 40500 && !defined(__clang__)
return false; return false;
#else #else
...@@ -89,7 +89,7 @@ bool OS::ArmUsingHardFloat() { ...@@ -89,7 +89,7 @@ bool OS::ArmUsingHardFloat() {
!defined(__VFP_FP__) !defined(__VFP_FP__)
return false; return false;
#else #else
#error "Your version of GCC does not report the FP ABI compiled for." \ #error "Your version of compiler does not report the FP ABI compiled for." \
"Please report it on this issue" \ "Please report it on this issue" \
"http://code.google.com/p/v8/issues/detail?id=2140" "http://code.google.com/p/v8/issues/detail?id=2140"
......
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