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

Unified Diff: src/js/v8natives.js

Issue 2115493002: [builtins] Migrate Math.abs() to TurboFan builtins. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Add comment back in Created 4 years, 6 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/js/math.js ('k') | test/mjsunit/mirror-script.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/js/v8natives.js
diff --git a/src/js/v8natives.js b/src/js/v8natives.js
index 5dfe877a175d15c32ffce08c4a27e58c5fcf199d..9f0ac087f43522cc35e5aead9d47c86e6688f511 100644
--- a/src/js/v8natives.js
+++ b/src/js/v8natives.js
@@ -9,23 +9,19 @@
// ----------------------------------------------------------------------------
// Imports
-var GlobalArray = global.Array;
var GlobalNumber = global.Number;
var GlobalObject = global.Object;
var iteratorSymbol = utils.ImportNow("iterator_symbol");
var MakeRangeError;
var MakeSyntaxError;
var MakeTypeError;
-var MathAbs;
var NaN = %GetRootNaN();
var ObjectToString = utils.ImportNow("object_to_string");
-var toStringTagSymbol = utils.ImportNow("to_string_tag_symbol");
utils.Import(function(from) {
MakeRangeError = from.MakeRangeError;
MakeSyntaxError = from.MakeSyntaxError;
MakeTypeError = from.MakeTypeError;
- MathAbs = from.MathAbs;
});
// ----------------------------------------------------------------------------
@@ -367,7 +363,7 @@ function NumberIsSafeInteger(number) {
if (NumberIsFinite(number)) {
var integral = TO_INTEGER(number);
if (integral == number) {
- return MathAbs(integral) <= kMaxSafeInteger;
+ return %math_abs(integral) <= kMaxSafeInteger;
}
}
return false;
« no previous file with comments | « src/js/math.js ('k') | test/mjsunit/mirror-script.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698