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

Unified Diff: test/mjsunit/regress/regress-1237.js

Issue 6821009: Introduce runtime function %OptimizeFunctionOnNextCall to manually trigger optimization. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 8 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
Index: test/mjsunit/regress/regress-1237.js
diff --git a/test/mjsunit/regress/regress-1237.js b/test/mjsunit/regress/regress-1237.js
index f97f97861fc12319af6dfee5df4d6753cb8ec803..5c7c5f93ee5eafab84f300f54be8054188389521 100644
--- a/test/mjsunit/regress/regress-1237.js
+++ b/test/mjsunit/regress/regress-1237.js
@@ -25,6 +25,8 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+// Flags: --allow-natives-syntax
+
// Deoptimization after a conditional expression in an effect context should
// not see the value of the expression.
function observe(x, y) { return x; }
@@ -32,5 +34,9 @@ function test(x) {
return observe(1, ((x? observe(observe.prototype.x): 'c'), x + 1));
}
-for (var i = 0; i < 10000000; ++i) test(0);
+for (var i = 0; i < 5; ++i) test(0);
+%OptimizeFunctionOnNextCall(test);
+%OptimizeFunctionOnNextCall(observe);
Mads Ager (chromium) 2011/04/11 11:06:38 Ditto.
Jakob Kummerow 2011/04/11 12:55:51 Done.
+test(0);
+
test("a");

Powered by Google App Engine
This is Rietveld 408576698