Index: test/mjsunit/regress/regress-2315.js |
diff --git a/test/mjsunit/fast-array-length.js b/test/mjsunit/regress/regress-2315.js |
similarity index 87% |
copy from test/mjsunit/fast-array-length.js |
copy to test/mjsunit/regress/regress-2315.js |
index 42f2c38f49b1dd3a3c0ffa867f7db368df78e760..ddc9618e1beff6cb0c076cc7f1d89b56474ae4bc 100644 |
--- a/test/mjsunit/fast-array-length.js |
+++ b/test/mjsunit/regress/regress-2315.js |
@@ -27,11 +27,12 @@ |
// Flags: --allow-natives-syntax |
-// This is a regression test for overlapping key and value registers. |
+var foo = (function() { |
+ return eval("(function bar() { return 1; })"); |
+})(); |
+for (var i = 0; i < 10; ++i) foo(); |
Michael Starzinger
2012/12/07 09:50:17
Is there a particular reason we need two separate
rossberg
2012/12/07 10:23:33
Now using %OptimizeFunctionOnNextCall instead.
|
+for (var i = 0; i < 10000; ++i) foo(); |
-var a = [0, 1, 2, 3, 4, 5]; |
-assertTrue(%HasFastSmiElements(a)); |
-a.length = (1 << 30); |
-assertFalse(%HasFastSmiElements(a)); |
- |
+// Function should be optimized now. |
+assertTrue(%GetOptimizationStatus(foo) != 2); |