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

Unified Diff: src/runtime/runtime-numbers.cc

Issue 648643003: Drop obsolete misc-intrinsics.h file. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 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
« no previous file with comments | « src/misc-intrinsics.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime/runtime-numbers.cc
diff --git a/src/runtime/runtime-numbers.cc b/src/runtime/runtime-numbers.cc
index 17c52e14f59111fcbcd48b69883bf717e2147d01..9090067b8fc4bc474291d10cb764a01c75cbd5b3 100644
--- a/src/runtime/runtime-numbers.cc
+++ b/src/runtime/runtime-numbers.cc
@@ -5,9 +5,9 @@
#include "src/v8.h"
#include "src/arguments.h"
+#include "src/base/bits.h"
#include "src/bootstrapper.h"
#include "src/codegen.h"
-#include "src/misc-intrinsics.h"
#include "src/runtime/runtime.h"
#include "src/runtime/runtime-utils.h"
@@ -526,11 +526,11 @@ RUNTIME_FUNCTION(Runtime_SmiLexicographicCompare) {
// integer comes first in the lexicographic order.
// From http://graphics.stanford.edu/~seander/bithacks.html#IntegerLog10
- int x_log2 = IntegerLog2(x_scaled);
+ int x_log2 = 31 - base::bits::CountLeadingZeros32(x_scaled);
int x_log10 = ((x_log2 + 1) * 1233) >> 12;
x_log10 -= x_scaled < kPowersOf10[x_log10];
- int y_log2 = IntegerLog2(y_scaled);
+ int y_log2 = 31 - base::bits::CountLeadingZeros32(y_scaled);
int y_log10 = ((y_log2 + 1) * 1233) >> 12;
y_log10 -= y_scaled < kPowersOf10[y_log10];
« no previous file with comments | « src/misc-intrinsics.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698