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

Unified Diff: src/arm/assembler-arm.cc

Issue 385069: Fix some style issues in the ARM code.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 1 month 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/arm/assembler-arm.cc
===================================================================
--- src/arm/assembler-arm.cc (revision 3292)
+++ src/arm/assembler-arm.cc (working copy)
@@ -43,30 +43,30 @@
namespace internal {
// Safe default is no features.
-uint64_t CpuFeatures::supported_ = 0;
-uint64_t CpuFeatures::enabled_ = 0;
+unsigned CpuFeatures::supported_ = 0;
+unsigned CpuFeatures::enabled_ = 0;
void CpuFeatures::Probe() {
- // Perform runtime detection of VFP.
- static const char* descriptive_file_linux = "/proc/cpuinfo";
-
+ // If the compiler is allowed to use vfp then we can use vfp too in our
+ // code generation.
#if !defined(__arm__) || (defined(__VFP_FP__) && !defined(__SOFTFP__))
- // The supported & enabled flags for VFP are set to true for the following
+ // The supported flags for VFP are set to true for the following
// conditions, even without runtime detection of VFP:
// (1) For the simulator=arm build, always use VFP since
// the arm simulator has VFP support.
// (2) If V8 is being compiled with GCC with the vfp option turned on,
// always use VFP since the build system assumes that V8 will run on
// a platform that has VFP hardware.
- supported_ |= static_cast<uint64_t>(1) << VFP3;
- enabled_ |= static_cast<uint64_t>(1) << VFP3;
+ supported_ |= 1u << VFP3;
+ enabled_ |= 1u << VFP3;
#endif
- if (OS::fgrep_vfp(descriptive_file_linux, "vfp")) {
+ if (Serializer::enabled()) return; // No features if we might serialize.
+
+ if (OS::ArmCpuHasFeature(OS::VFP)) {
// This implementation also sets the VFP flags if
// runtime detection of VFP returns true.
- supported_ |= static_cast<uint64_t>(1) << VFP3;
- enabled_ |= static_cast<uint64_t>(1) << VFP3;
+ supported_ |= 1u << VFP3;
}
}

Powered by Google App Engine
This is Rietveld 408576698