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

Unified Diff: test/mjsunit/compiler/minus-zero.js

Issue 1680783002: [intrinsics] Kill the %_IsMinusZero intrinsic. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 10 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 | « test/cctest/compiler/test-run-intrinsics.cc ('k') | test/mjsunit/constant-fold-control-instructions.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/compiler/minus-zero.js
diff --git a/test/mjsunit/compiler/minus-zero.js b/test/mjsunit/compiler/minus-zero.js
index c161257d77a838b1d81b3454ae5d30b0a33b6425..ac66350051cbc2217325002f4b676bc38f383907 100644
--- a/test/mjsunit/compiler/minus-zero.js
+++ b/test/mjsunit/compiler/minus-zero.js
@@ -37,31 +37,8 @@ assertEquals(0, add(0, 0));
assertEquals(-0, add(-0, -0));
-function test(x, y) {
- assertTrue(%_IsMinusZero(-0));
- assertTrue(%_IsMinusZero(1/(-Infinity)));
- assertTrue(%_IsMinusZero(x));
-
- assertFalse(%_IsMinusZero(0));
- assertFalse(%_IsMinusZero(1/Infinity));
- assertFalse(%_IsMinusZero(0.1));
- assertFalse(%_IsMinusZero(-0.2));
- assertFalse(%_IsMinusZero({}));
- assertFalse(%_IsMinusZero(""));
- assertFalse(%_IsMinusZero("-0"));
- assertFalse(%_IsMinusZero(function() {}));
- assertFalse(%_IsMinusZero(y));
-}
-
-test(-0, 1.2);
-test(-0, 1.2);
-%OptimizeFunctionOnNextCall(test);
-test(-0, 1.2);
-assertOptimized(test);
-
-
function testsin() {
- assertTrue(%_IsMinusZero(Math.sin(-0)));
+ assertEquals(-0, Math.sin(-0));
}
testsin();
@@ -71,8 +48,7 @@ testsin();
function testfloor() {
- assertTrue(%_IsMinusZero(Math.floor(-0)));
- assertFalse(%_IsMinusZero(Math.floor(2)));
+ assertEquals(-0, Math.floor(-0));
}
testfloor();
« no previous file with comments | « test/cctest/compiler/test-run-intrinsics.cc ('k') | test/mjsunit/constant-fold-control-instructions.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698