| OLD | NEW |
| 1 // Copyright 2015 the V8 project authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Flags: --allow-natives-syntax --harmony-atomics --harmony-sharedarraybuffer | 5 // Flags: --allow-natives-syntax --harmony-sharedarraybuffer |
| 6 | 6 |
| 7 (function TestFailsWithNonSharedArray() { | 7 (function TestFailsWithNonSharedArray() { |
| 8 var ab = new ArrayBuffer(16); | 8 var ab = new ArrayBuffer(16); |
| 9 | 9 |
| 10 var i8a = new Int8Array(ab); | 10 var i8a = new Int8Array(ab); |
| 11 var i16a = new Int16Array(ab); | 11 var i16a = new Int16Array(ab); |
| 12 var i32a = new Int32Array(ab); | 12 var i32a = new Int32Array(ab); |
| 13 var ui8a = new Uint8Array(ab); | 13 var ui8a = new Uint8Array(ab); |
| 14 var ui8ca = new Uint8ClampedArray(ab); | 14 var ui8ca = new Uint8ClampedArray(ab); |
| 15 var ui16a = new Uint16Array(ab); | 15 var ui16a = new Uint16Array(ab); |
| (...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 265 assertEquals(0, %AtomicsFutexNumWaitersForTesting(i32a, index2)); | 265 assertEquals(0, %AtomicsFutexNumWaitersForTesting(i32a, index2)); |
| 266 | 266 |
| 267 for (id = 0; id < 4; ++id) { | 267 for (id = 0; id < 4; ++id) { |
| 268 assertEquals(Atomics.OK, workers[id].getMessage()); | 268 assertEquals(Atomics.OK, workers[id].getMessage()); |
| 269 workers[id].terminate(); | 269 workers[id].terminate(); |
| 270 } | 270 } |
| 271 | 271 |
| 272 })(); | 272 })(); |
| 273 | 273 |
| 274 } | 274 } |
| OLD | NEW |