Reviewers: Jakob,

Message:
PTAL

Description:
Speed up mjsunit/compiler/regress-arguments.

BUG=

Please review this at https://codereview.chromium.org/138503008/

SVN Base: https://v8.googlecode.com/svn/branches/bleeding_edge

Affected files (+15, -5 lines):
  M test/mjsunit/compiler/regress-arguments.js
  M test/mjsunit/mjsunit.status


Index: test/mjsunit/compiler/regress-arguments.js
diff --git a/test/mjsunit/compiler/regress-arguments.js b/test/mjsunit/compiler/regress-arguments.js index ebae5a03998b2cb5dd63d7d0b519b93635d359cd..d32b435ff39a452e54f8b776c4df35cc8783a40f 100644
--- a/test/mjsunit/compiler/regress-arguments.js
+++ b/test/mjsunit/compiler/regress-arguments.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
+
 // Test of arguments.

 // Test passing null or undefined as receiver.
@@ -35,8 +37,15 @@ function h() { return f.apply(void 0, arguments); }

 var foo = 42;

-for (var i=0; i<1000000; i++) assertEquals(42, g());
-for (var i=0; i<1000000; i++) assertEquals(42, h());
+for (var i = 0; i < 3; i++) assertEquals(42, g());
+%OptimizeFunctionOnNextCall(g);
+%OptimizeFunctionOnNextCall(f);
+assertEquals(42, g());
+
+for (var i = 0; i < 3; i++) assertEquals(42, h());
+%OptimizeFunctionOnNextCall(h);
+%OptimizeFunctionOnNextCall(f);
+assertEquals(42, h());

 var G1 = 21;
 var G2 = 22;
@@ -49,4 +58,7 @@ function u() {
 Number.prototype.foo = 42;
 delete Number.prototype.foo;

-for (var i=0; i<100000; i++) assertEquals(void 0, u());
+for (var i = 0; i < 3; i++) assertEquals(void 0, u());
+%OptimizeFunctionOnNextCall(u);
+%OptimizeFunctionOnNextCall(f);
+assertEquals(void 0, u());
Index: test/mjsunit/mjsunit.status
diff --git a/test/mjsunit/mjsunit.status b/test/mjsunit/mjsunit.status
index 4997753a9dc5cf49aab8a3af14dc3a3cc805a1fe..aa0beaa82c2a1bc8a6e1818ca6d49528d54964f9 100644
--- a/test/mjsunit/mjsunit.status
+++ b/test/mjsunit/mjsunit.status
@@ -142,7 +142,6 @@
   'compiler/regress-4': [SKIP],
   'compiler/regress-funcaller': [SKIP],
   'compiler/regress-rep-change': [SKIP],
-  'compiler/regress-arguments': [SKIP],
   'compiler/regress-funarguments': [SKIP],
   'compiler/regress-3249650': [SKIP],
   'compiler/simple-deopt': [SKIP],
@@ -211,7 +210,6 @@
   'compiler/regress-4': [SKIP],
   'compiler/regress-funcaller': [SKIP],
   'compiler/regress-rep-change': [SKIP],
-  'compiler/regress-arguments': [SKIP],
   'compiler/regress-funarguments': [SKIP],
   'compiler/regress-3249650': [SKIP],
   'compiler/simple-deopt': [SKIP],


--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to