OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2015 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 | |
6 | |
7 function loader(dst, src, i) { | |
8 dst[i] = src[i]; | |
9 } | |
10 | |
11 var ab = new ArrayBuffer(8); | |
12 var i_view = new Int32Array(ab); | |
13 i_view[0] = 0xFFFFFFFF; | |
Jakob Kummerow
2015/01/20 13:25:38
You want to change this to the new hole-NaN now.
| |
14 i_view[1] = 0x7FFFFFFF; | |
15 var f_view = new Float64Array(ab); | |
16 | |
17 var fixed_double_elements = new Float64Array(1); | |
18 fixed_double_elements[0] = f_view[0]; | |
19 | |
20 var doubles = [0.5]; | |
21 loader(doubles, fixed_double_elements, 0); | |
22 loader(doubles, fixed_double_elements, 0); | |
23 %OptimizeFunctionOnNextCall(loader); | |
24 loader(doubles, fixed_double_elements, 0); | |
25 assertTrue(doubles[0] !== undefined); | |
OLD | NEW |