v8/test/mjsunit/regress/regress-590074.js
jarin 9867a8a26e [turbofan] Fix register constraint for memory barrier.
After fixing the memory barrier for maps (https://codereview.chromium.org/1714513003), we are using a temp register for the map case. The temp register should not be aliased with the stored value (otherwise we perform the mem barrier check with a wrong value). This CL makes sure it is not aliased.

BUG=chromium:590074
LOG=n

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

Cr-Commit-Position: refs/heads/master@{#34607}
2016-03-09 09:39:51 +00:00

30 lines
544 B
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.
// Flags: --allow-natives-syntax --expose-gc
var __v_5 = {};
function __f_10() {
var __v_2 = [0, 0, 0];
__v_2[0] = 0;
gc();
return __v_2;
}
function __f_2(array) {
array[1] = undefined;
}
function __f_9() {
var __v_4 = __f_10();
__f_2(__f_10());
__v_5 = __f_10();
__v_4 = __f_10();
__f_2(__v_5);
}
__f_9();
%OptimizeFunctionOnNextCall(__f_9);
__f_9();