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

Unified Diff: tests/compiler/dart2js/cps_ir/expected/argument_refinement_21.js

Issue 1585923010: dart2js cps: Eliminate duplicate branches. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Add missing type annotations Created 4 years, 11 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 | « pkg/compiler/lib/src/js_backend/codegen/task.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/cps_ir/expected/argument_refinement_21.js
diff --git a/tests/compiler/dart2js/cps_ir/expected/argument_refinement_21.js b/tests/compiler/dart2js/cps_ir/expected/argument_refinement_21.js
index 589d358576badac9d89b5c97a50464b673a0a2e3..2c4e7c7b2b692def5985d911d89dba18d3c61e55 100644
--- a/tests/compiler/dart2js/cps_ir/expected/argument_refinement_21.js
+++ b/tests/compiler/dart2js/cps_ir/expected/argument_refinement_21.js
@@ -16,15 +16,6 @@ function() {
P.print(v0);
if (!v0)
throw H.wrapException(H.argumentErrorValue(y));
- if (x < y)
- v0 = -1;
- else if (x > y)
- v0 = 1;
- else if (x === y) {
- v0 = x === 0;
- v0 = v0 ? (y === 0 ? 1 / y < 0 : y < 0) === (v0 ? 1 / x < 0 : x < 0) ? 0 : (v0 ? 1 / x < 0 : x < 0) ? -1 : 1 : 0;
- } else
- v0 = isNaN(x) ? isNaN(y) ? 0 : 1 : -1;
- P.print(v0);
+ P.print(x < y ? -1 : x > y ? 1 : x === y ? x === 0 ? 1 / x < 0 === (y === 0 ? 1 / y < 0 : y < 0) ? 0 : 1 / x < 0 ? -1 : 1 : 0 : isNaN(x) ? isNaN(y) ? 0 : 1 : -1);
P.print(true);
}
« no previous file with comments | « pkg/compiler/lib/src/js_backend/codegen/task.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698