v8/test/mjsunit/regress/regress-381313.js
jarin@chromium.org 457de26330 Fix arm64 deoptimization from double registers (reverts r20613).
This reverts "ARM64: Use pair memory access in deoptimizer entry", r20613. It does not really make sense to micro-optimize the deoptimizer as it is the ultra-slow path. Moreover, the original code was easier to read (in addition to being correct).

BUG=391313
LOG=N
R=ulan@chromium.org

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

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@22360 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-07-11 19:30:09 +00:00

43 lines
842 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
var g = 0;
function f(x, deopt) {
var a0 = x;
var a1 = 2 * x;
var a2 = 3 * x;
var a3 = 4 * x;
var a4 = 5 * x;
var a5 = 6 * x;
var a6 = 7 * x;
var a7 = 8 * x;
var a8 = 9 * x;
var a9 = 10 * x;
var a10 = 11 * x;
var a11 = 12 * x;
var a12 = 13 * x;
var a13 = 14 * x;
var a14 = 15 * x;
var a15 = 16 * x;
var a16 = 17 * x;
var a17 = 18 * x;
var a18 = 19 * x;
var a19 = 20 * x;
g = 1;
deopt + 0;
return a0 + a1 + a2 + a3 + a4 + a5 + a6 + a7 + a8 + a9 +
a10 + a11 + a12 + a13 + a14 + a15 + a16 + a17 + a18 + a19;
}
f(0.5, 0);
f(0.5, 0);
%OptimizeFunctionOnNextCall(f);
print(f(0.5, ""));