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

Side by Side Diff: test/mjsunit/compiler/osr-block-scope-id.js

Issue 921083004: [turbofan] Rename context stack as part of the environment for OSR. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 10 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 | « test/mjsunit/compiler/osr-block-scope-func.js ('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: --allow-natives-syntax --use-osr --turbo-osr
6
7 "use strict";
8
9 function foo() {
10 var result = new Array();
11 var out;
12 {
13 let sum = 0;
14 for (var i = 0; i < 10; i++) {
15 {
16 let x = i;
17 if (i == 5) %OptimizeOsr();
18 sum += i;
19 result.push(function() { return x; });
20 }
21 }
22 out = sum;
23 }
24 result.push(out);
25 return result;
26 }
27
28
29 function check() {
30 var r = foo();
31 assertEquals(45, r.pop());
32 for (var i = 9; i >= 0; i--) {
33 assertEquals(i, r.pop()());
34 }
35 assertEquals(0, r.length);
36 }
37
38 check();
39 check();
40 check();
OLDNEW
« no previous file with comments | « test/mjsunit/compiler/osr-block-scope-func.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698