commit | 63c7ad499be49ef959b3b1c5ea3f48491aa033d3 | [log] [tgz] |
---|---|---|
author | Andrew Top <aabtop@google.com> | Mon Nov 25 16:10:13 2019 -0800 |
committer | Andrew Top <aabtop@google.com> | Tue Nov 26 17:03:47 2019 -0800 |
tree | d79834891b0a2cceff2017e52c5664437df3a603 | |
parent | cab7770533804d582eaa66c713a1582f361182d3 [diff] [blame] |
Import Cobalt 20.master.0.234144 Includes the following patches: https://cobalt-review.googlesource.com/c/cobalt/+/5590 by n1214.hwang@samsung.com https://cobalt-review.googlesource.com/c/cobalt/+/5530 by errong.leng@samsung.com https://cobalt-review.googlesource.com/c/cobalt/+/5570 by devin.cai@mediatek.com
diff --git a/src/v8/test/mjsunit/regress/regress-crbug-937649.js b/src/v8/test/mjsunit/regress/regress-crbug-937649.js new file mode 100644 index 0000000..5dd794d --- /dev/null +++ b/src/v8/test/mjsunit/regress/regress-crbug-937649.js
@@ -0,0 +1,18 @@ +// Copyright 2019 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 + +(function() { +function foo(x) { + const i = x > 0; + const dv = new DataView(ab); + return dv.getUint16(i); +}; +%PrepareFunctionForOptimization(foo); +const ab = new ArrayBuffer(2); +foo(0); +foo(0); +%OptimizeFunctionOnNextCall(foo); +foo(0); +})();