Index: test/mjsunit/compiler/regress-694088.js |
diff --git a/test/mjsunit/compiler/regress-694088.js b/test/mjsunit/compiler/regress-694088.js |
new file mode 100644 |
index 0000000000000000000000000000000000000000..42817092a0cf14e3710d23fac973093c02224d8e |
--- /dev/null |
+++ b/test/mjsunit/compiler/regress-694088.js |
@@ -0,0 +1,29 @@ |
+// Copyright 2017 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. |
+ |
+(function () { |
+ var buffer = new ArrayBuffer(8); |
+ var i32 = new Int32Array(buffer); |
+ var f64 = new Float64Array(buffer); |
+ |
+ function foo() { |
+ f64[0] = 1; |
+ var x = f64[0]; |
+ return i32[0]; |
+ } |
+ assertEquals(0, foo()); |
JaideepBajwa
2017/03/01 21:52:18
The testcase fails on Big Endian platforms, the be
|
+})(); |
+ |
+(function () { |
+ var buffer = new ArrayBuffer(8); |
+ var i16 = new Int16Array(buffer); |
+ var i32 = new Int32Array(buffer); |
+ |
+ function foo() { |
+ i32[0] = 0x10001; |
+ var x = i32[0]; |
+ return i16[0]; |
+ } |
+ assertEquals(1, foo()); |
+})(); |