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

Side by Side Diff: test/mjsunit/compiler/regress-621147.js

Issue 2126623003: [turbofan] Set elements kind to holey if constructing array of possibly non-zero length. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 5 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
OLDNEW
(Empty)
1 // Copyright 2014 the V8 project authors. All rights reserved.
ahaas 2016/07/06 07:50:12 2016
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 --turbo-filter=test2
6
7 function test(n) {
8 return Array(n);
9 }
10
11 function test2() {
12 return test(2);
13 }
14
15 function test3(a) {
16 a[0] = 1;
17 }
18
19 test(0);
20
21 var smi_array = [1,2];
22 smi_array[2] = 3;
23 test3(smi_array);
24
25 %OptimizeFunctionOnNextCall(test2);
26
27 var broken_array = test2();
28 test3(broken_array);
29 1+broken_array[0];
OLDNEW
« src/compiler/js-create-lowering.cc ('K') | « src/compiler/js-create-lowering.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698