v8/test/mjsunit/regress/regress-abort-preparsing-params.js
verwaest 4fa2ebcbe0 Turn Scope::locals_ into a ThreadedList
This turns the ZoneList with minimum 6 words overhead into a linked list through variables, using 2 words for the empty list. Additionally the average number of pointers per entry goes down to the optimal 1 per variable that's in a list.

This does introduce 1 pointer unnecessary overhead for dynamic variables. If that becomes a problem we could distinguish between variables in lists and variables not in lists. We can distinguish them at construction-time.

BUG=v8:5209

Review-Url: https://codereview.chromium.org/2475433002
Cr-Commit-Position: refs/heads/master@{#40714}
2016-11-03 10:07:12 +00:00

947 lines
8.5 KiB
JavaScript

// Copyright 2016 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.
var outer_a;
function f(a, b, a) {
outer_a = a;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
x = 1;
}
f(1, 2, 1);
assertEquals(1, outer_a);