Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(363)

Unified Diff: src/platform-linux.cc

Issue 11037023: Use movw/movt instead of constant pool on ARMv7 (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Set flag properly Created 8 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/platform-linux.cc
diff --git a/src/platform-linux.cc b/src/platform-linux.cc
index fe366c942fbaa984905773628534b27c1a553481..d2859e4fcc9144b3767f5cef5cd96a0b0e093412 100644
--- a/src/platform-linux.cc
+++ b/src/platform-linux.cc
@@ -174,6 +174,24 @@ bool OS::ArmCpuHasFeature(CpuFeature feature) {
}
+CpuImplementer OS::GetCpuImplementer() {
+ static bool use_cached_value = false;
+ static CpuImplementer cached_value = UnknownImplementer;
+ if (use_cached_value) {
+ return cached_value;
+ }
+ if (CPUInfoContainsString("CPU implementer\t: 0x41")) {
+ cached_value = ARMImplementer;
+ } else if (CPUInfoContainsString("CPU implementer\t: 0x51")) {
+ cached_value = QualcommImplementer;
+ } else {
+ cached_value = UnknownImplementer;
+ }
+ use_cached_value = true;
+ return cached_value;
+}
+
+
bool OS::ArmUsingHardFloat() {
// GCC versions 4.6 and above define __ARM_PCS or __ARM_PCS_VFP to specify
// the Floating Point ABI used (PCS stands for Procedure Call Standard).

Powered by Google App Engine
This is Rietveld 408576698