v8/test/mjsunit/regress/regress-351261.js
mvstanton@chromium.org 11df4b8815 Fix for issue 351261.
This relands the following fix: "HAllocate should never generate
allocation code if the requested size does not fit into page. Regression
test included. (bug 347543)" along with additional fixes to KeyedStoreIC.

BUG=351261
LOG=N
R=verwaest@chromium.org

Review URL: https://codereview.chromium.org/200113002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19926 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-03-14 10:22:55 +00:00

20 lines
419 B
JavaScript

// Copyright 2014 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Flags: --allow-natives-syntax --fold-constants
function store(a) {
a[5000000] = 1;
}
function foo() {
var __v_8 = new Object;
var __v_7 = new Array(4999990);
store(__v_8);
store(__v_7);
}
foo();
%OptimizeFunctionOnNextCall(foo);
foo();