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

Side by Side Diff: test/mjsunit/compiler/osr-forin-nested.js

Issue 988423003: [turbofan] Fix --turbo-osr for OSRing into inner loop inside for-in. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 9 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 unified diff | Download patch
« no previous file with comments | « src/compiler/ast-graph-builder.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2015 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // Flags: --turbo-osr --allow-natives-syntax
6
7 function test(e, f, v) {
8 assertEquals(e, f(v));
9 assertEquals(e, f(v));
10 assertEquals(e, f(v));
11 }
12
13 function foo(t) {
14 for (var x in t) {
15 for (var i = 0; i < 2; i++) {
16 %OptimizeOsr();
17 }
18 }
19 return 5;
20 }
21
22 test(5, foo, {x:20});
23
24 function bar(t) {
25 var sum = 0;
26 for (var x in t) {
27 for (var i = 0; i < 2; i++) {
28 %OptimizeOsr();
29 sum += t[x];
30 }
31 }
32 return sum;
33 }
34
35 test(62, bar, {x:20,y:11});
OLDNEW
« no previous file with comments | « src/compiler/ast-graph-builder.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698