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

Unified Diff: test/mjsunit/compiler/turbo-number-feedback.js

Issue 2184513003: [turbofan] Adds handling of number or oddball type feedback to SpeculativeNumberShiftLeft. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Update. Created 4 years, 5 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/compiler/simplified-lowering.cc ('k') | test/unittests/compiler/js-typed-lowering-unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/compiler/turbo-number-feedback.js
diff --git a/test/mjsunit/compiler/turbo-number-feedback.js b/test/mjsunit/compiler/turbo-number-feedback.js
index 896d1542424bf9cb727306070fc2fffd3a08983a..1462c385e8547a67c8c46fc9e64b2415cd1fc294 100644
--- a/test/mjsunit/compiler/turbo-number-feedback.js
+++ b/test/mjsunit/compiler/turbo-number-feedback.js
@@ -67,3 +67,14 @@
%OptimizeFunctionOnNextCall(f4);
assertEquals(64, f4(4, 4));
})();
+
+(function ShiftLeftNumbers() {
+ function f5(a, b) {
+ return a << b;
+ }
+
+ assertEquals(24, f5(3.3, 3.4));
+ assertEquals(40, f5(5.1, 3.9));
+ %OptimizeFunctionOnNextCall(f5);
+ assertEquals(64, f5(4.9, 4.1));
+})();
« no previous file with comments | « src/compiler/simplified-lowering.cc ('k') | test/unittests/compiler/js-typed-lowering-unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698