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

Unified Diff: test/mjsunit/regress/call-function-in-effect-context-deopt.js

Issue 131343013: Test and fix for _CallFunction intrinsic deoptimization. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 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
« src/hydrogen.cc ('K') | « src/hydrogen.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/regress/call-function-in-effect-context-deopt.js
diff --git a/test/mjsunit/recursive-store-opt.js b/test/mjsunit/regress/call-function-in-effect-context-deopt.js
similarity index 84%
copy from test/mjsunit/recursive-store-opt.js
copy to test/mjsunit/regress/call-function-in-effect-context-deopt.js
index fb2649248dbabc642f864f671d0ce2273ad44bd7..9a36c141b7bc6c00ec8ed8b558588abac21beb0f 100644
--- a/test/mjsunit/recursive-store-opt.js
+++ b/test/mjsunit/regress/call-function-in-effect-context-deopt.js
@@ -27,15 +27,15 @@
// Flags: --allow-natives-syntax
-function g() {
- this.x = this;
+function f(deopt, osr) {
+ var result = "result";
+ %_CallFunction(0, 0, function() {});
+ var dummy = deopt + 0;
+ if (osr) while (%GetOptimizationStatus(f) == 2) {}
+ return result;
}
-function f() {
- return new g();
-}
-
-f();
-f();
+assertEquals("result", f(3, false));
+assertEquals("result", f(3, false));
%OptimizeFunctionOnNextCall(f);
-f();
+assertEquals("result", f("foo", true));
« src/hydrogen.cc ('K') | « src/hydrogen.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698