Home | History | Annotate | Download | only in regress
      1 // Copyright 2014 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 --debug-code --use-gvn
      6 
      7 function f(a, base) {
      8   a[base] = 1;
      9   a[base + 4] = 2;
     10   a[base] = 3;
     11 }
     12 var a1 = new Array(1024);
     13 var a2 = new Array(128);
     14 f(a1, 1);
     15 f(a2, -2);
     16 %OptimizeFunctionOnNextCall(f);
     17 f(a1, -2);
     18