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

Unified Diff: runtime/vm/cpu_arm.h

Issue 189833006: Changes that somehow got lost from my last commit. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/cpu_arm.h
===================================================================
--- runtime/vm/cpu_arm.h (revision 33442)
+++ runtime/vm/cpu_arm.h (working copy)
@@ -18,6 +18,12 @@
// additionally mock the options needed for the target architecture so that
// they may be altered for testing.
+enum ARMVersion {
+ ARMv6,
+ ARMv7,
+ ARMvUnknown,
+};
+
class HostCPUFeatures: public AllStatic {
public:
static void InitOnce();
@@ -34,6 +40,10 @@
DEBUG_ASSERT(initialized_);
return neon_supported_;
}
+ static ARMVersion arm_version() {
+ DEBUG_ASSERT(initialized_);
+ return arm_version_;
+ }
#if !defined(HOST_ARCH_ARM)
static void set_integer_division_supported(bool supported) {
@@ -44,12 +54,17 @@
DEBUG_ASSERT(initialized_);
neon_supported_ = supported;
}
+ static void set_arm_version(ARMVersion version) {
+ DEBUG_ASSERT(initialized_);
+ arm_version_ = version;
+ }
#endif // !defined(HOST_ARCH_ARM)
private:
static const char* hardware_;
static bool integer_division_supported_;
static bool neon_supported_;
+ static ARMVersion arm_version_;
#if defined(DEBUG)
static bool initialized_;
#endif
@@ -75,6 +90,9 @@
static const char* hardware() {
return HostCPUFeatures::hardware();
}
+ static ARMVersion arm_version() {
+ return HostCPUFeatures::arm_version();
+ }
};
} // namespace dart
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698