Index: test/mjsunit/compiler/lazy-deopt-in-literal.js |
diff --git a/test/mjsunit/compiler/regress-ntl-effect.js b/test/mjsunit/compiler/lazy-deopt-in-literal.js |
similarity index 50% |
copy from test/mjsunit/compiler/regress-ntl-effect.js |
copy to test/mjsunit/compiler/lazy-deopt-in-literal.js |
index 708fe32828c9197dfa3d8c371ab01cbc1ad3317a..0a1481c571a0a8ec20e9ed3ff65bbd7a4f44aece 100644 |
--- a/test/mjsunit/compiler/regress-ntl-effect.js |
+++ b/test/mjsunit/compiler/lazy-deopt-in-literal.js |
@@ -4,13 +4,17 @@ |
// Flags: --allow-natives-syntax |
-function g() { |
- throw 0; |
+function deopt() { |
+ %DeoptimizeFunction(fun3); |
} |
-function f() { |
- g(); |
- while (1) {} |
+function fun3() { |
+ var r = { 113: deopt(), 113: 7 }; |
+ return r[113]; |
} |
-assertThrows(function () { f(); }); |
+fun3(); |
+fun3(); |
+%OptimizeFunctionOnNextCall(fun3); |
+var y = fun3(); |
+assertEquals(7, y); |