Lines Matching refs:Atomics

50     assertThrows(function() { Atomics.compareExchange(o, 0, 0, 0); },
52 assertThrows(function() { Atomics.load(o, 0); }, TypeError);
53 assertThrows(function() { Atomics.store(o, 0, 0); }, TypeError);
54 assertThrows(function() { Atomics.add(o, 0, 0); }, TypeError);
55 assertThrows(function() { Atomics.sub(o, 0, 0); }, TypeError);
56 assertThrows(function() { Atomics.and(o, 0, 0); }, TypeError);
57 assertThrows(function() { Atomics.or(o, 0, 0); }, TypeError);
58 assertThrows(function() { Atomics.xor(o, 0, 0); }, TypeError);
59 assertThrows(function() { Atomics.exchange(o, 0, 0); }, TypeError);
87 testAtomicOp(Atomics.compareExchange, si32a, i, 0, name);
88 testAtomicOp(Atomics.load, si32a, i, 0, name);
89 testAtomicOp(Atomics.store, si32a, i, 0, name);
90 testAtomicOp(Atomics.add, si32a, i, 0, name);
91 testAtomicOp(Atomics.sub, si32a, i, 0, name);
92 testAtomicOp(Atomics.and, si32a, i, 0, name);
93 testAtomicOp(Atomics.or, si32a, i, 0, name);
94 testAtomicOp(Atomics.xor, si32a, i, 0, name);
95 testAtomicOp(Atomics.exchange, si32a, i, 0, name);
102 assertEquals(undefined, Atomics.compareExchange(si32a, i, 0, 0), name);
103 assertEquals(undefined, Atomics.load(si32a, i), name);
104 assertEquals(undefined, Atomics.store(si32a, i, 0), name);
105 assertEquals(undefined, Atomics.add(si32a, i, 0), name);
106 assertEquals(undefined, Atomics.sub(si32a, i, 0), name);
107 assertEquals(undefined, Atomics.and(si32a, i, 0), name);
108 assertEquals(undefined, Atomics.or(si32a, i, 0), name);
109 assertEquals(undefined, Atomics.xor(si32a, i, 0), name);
110 assertEquals(undefined, Atomics.exchange(si32a, i, 0), name);
116 assertEquals(undefined, Atomics.compareExchange(si32a2, i, 0, 0), name);
117 assertEquals(undefined, Atomics.load(si32a2, i), name);
118 assertEquals(undefined, Atomics.store(si32a2, i, 0), name);
119 assertEquals(undefined, Atomics.add(si32a2, i, 0), name);
120 assertEquals(undefined, Atomics.sub(si32a2, i, 0), name);
121 assertEquals(undefined, Atomics.and(si32a2, i, 0), name);
122 assertEquals(undefined, Atomics.or(si32a2, i, 0), name);
123 assertEquals(undefined, Atomics.xor(si32a2, i, 0), name);
124 assertEquals(undefined, Atomics.exchange(si32a2, i, 0), name);
131 assertEquals(undefined, Atomics.compareExchange(si32a, i, 0, 0), name);
132 assertEquals(undefined, Atomics.load(si32a, i), name);
133 assertEquals(undefined, Atomics.store(si32a, i, 0), name);
134 assertEquals(undefined, Atomics.add(si32a, i, 0), name);
135 assertEquals(undefined, Atomics.sub(si32a, i, 0), name);
136 assertEquals(undefined, Atomics.and(si32a, i, 0), name);
137 assertEquals(undefined, Atomics.or(si32a, i, 0), name);
138 assertEquals(undefined, Atomics.xor(si32a, i, 0), name);
139 assertEquals(undefined, Atomics.exchange(si32a, i, 0), name);
154 testAtomicOp(Atomics.compareExchange, array, i, 3, name);
155 testAtomicOp(Atomics.load, array, i, 3, name);
156 testAtomicOp(Atomics.store, array, i, 3, name);
157 testAtomicOp(Atomics.add, array, i, 3, name);
158 testAtomicOp(Atomics.sub, array, i, 3, name);
159 testAtomicOp(Atomics.and, array, i, 3, name);
160 testAtomicOp(Atomics.or, array, i, 3, name);
161 testAtomicOp(Atomics.xor, array, i, 3, name);
162 testAtomicOp(Atomics.exchange, array, i, 3, name);
185 assertEquals(0, Atomics.compareExchange(array, i, 0, 50), name);
189 assertEquals(50, Atomics.compareExchange(array, i, 0, 100), name);
207 assertEquals(0, Atomics.load(array, i), name);
209 assertEquals(50, Atomics.load(array, i), name);
225 assertEquals(50, Atomics.store(array, i, 50), name);
228 assertEquals(100, Atomics.store(array, i, 100), name);
245 assertEquals(0, Atomics.add(array, i, 50), name);
248 assertEquals(50, Atomics.add(array, i, 70), name);
266 assertEquals(120, Atomics.sub(array, i, 50), name);
269 assertEquals(70, Atomics.sub(array, i, 70), name);
287 assertEquals(0x3f, Atomics.and(array, i, 0x30), name);
290 assertEquals(0x30, Atomics.and(array, i, 0x20), name);
308 assertEquals(0x30, Atomics.or(array, i, 0x1c), name);
311 assertEquals(0x3c, Atomics.or(array, i, 0x09), name);
329 assertEquals(0x30, Atomics.xor(array, i, 0x1c), name);
332 assertEquals(0x2c, Atomics.xor(array, i, 0x09), name);
350 assertEquals(0x30, Atomics.exchange(array, i, 0x1c), name);
353 assertEquals(0x1c, Atomics.exchange(array, i, 0x09), name);
362 assertEquals(true, Atomics.isLockFree(1));
363 assertEquals(true, Atomics.isLockFree(2));
364 assertEquals(true, Atomics.isLockFree(4));
375 assertEquals(false, Atomics.isLockFree(i));
393 assertEquals(50, Atomics.compareExchange(sta, 0, v, v), name);
396 assertEquals(+v, Atomics.store(sta, 0, v), name);
401 assertEquals(120, Atomics.add(sta, 0, v), name);
406 assertEquals(70, Atomics.sub(sta, 0, v), name);
411 assertEquals(0x20, Atomics.and(sta, 0, v), name);
416 assertEquals(0x3d, Atomics.or(sta, 0, v), name);
421 assertEquals(0x25, Atomics.xor(sta, 0, v), name);
426 assertEquals(0x09, Atomics.exchange(sta, 0, v), name);
448 assertEquals(val, Atomics.compareExchange(sta, 0, val, newVal), name);
454 assertEquals(val, Atomics.compareExchange(sta, 0, val, newVal), name);
461 assertEquals(val, Atomics.store(sta, 0, val), name);
466 assertEquals(val, Atomics.store(sta, 0, val), name);
473 assertEquals(val, Atomics.add(sta, 0, operand), name);
479 assertEquals(val, Atomics.add(sta, 0, operand), name);
486 assertEquals(val, Atomics.sub(sta, 0, operand), name);
492 assertEquals(val, Atomics.sub(sta, 0, operand), name);
503 assertEquals(val, Atomics.and(sta, 0, operand), name);
510 assertEquals(val, Atomics.or(sta, 0, operand), name);
517 assertEquals(val, Atomics.xor(sta, 0, operand), name);
524 assertEquals(val, Atomics.exchange(sta, 0, operand), name);