From 5de595a603432af99f912c86c2723905e154b75e Mon Sep 17 00:00:00 2001 From: jkummerow Date: Wed, 17 Jun 2015 07:24:29 -0700 Subject: [PATCH] [test] Fix gc-stress failures of regress-crbug-500497.js R=machenbach@chromium.org NOTRY=y Review URL: https://codereview.chromium.org/1175123003 Cr-Commit-Position: refs/heads/master@{#29091} --- test/mjsunit/regress/regress-crbug-500497.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/mjsunit/regress/regress-crbug-500497.js b/test/mjsunit/regress/regress-crbug-500497.js index 9117440..2d3d40f 100644 --- a/test/mjsunit/regress/regress-crbug-500497.js +++ b/test/mjsunit/regress/regress-crbug-500497.js @@ -13,6 +13,9 @@ function Ctor() { } for (var i = 0; i < 120; i++) { + // This print() is important! Without it, in --gc-stress mode, the function + // Ctor is optimized too early. No idea why. + print(i); // Make the "a" property long-lived, while everything else is short-lived. global.push(Ctor().a); (function FillNewSpace() { new Array(10000); })(); -- 2.7.4