MCPcopy Create free account
hub / github.com/nodejs/node / Test8Op

Function Test8Op

deps/v8/test/mjsunit/wasm/atomics.js:176–186  ·  view source on GitHub ↗
(operation, func)

Source from the content-addressed store, hash-verified

174}
175
176function Test8Op(operation, func) {
177 let i8 = new Uint8Array(memory.buffer);
178 for (let i = 0; i < i8.length; i = inc(i)) {
179 let expected = 0xbe;
180 let value = 0x12;
181 i8[i] = expected;
182 assertEquals(expected, func(i * kMemtypeSize8, value));
183 assertEquals(operation(expected, value), i8[i]);
184 }
185 VerifyBoundsCheck(func, kMemtypeSize8, 10);
186}
187
188function Test64Op(operation, func) {
189 let i64 = new BigUint64Array(memory.buffer);

Callers 1

atomics.jsFile · 0.85

Calls 4

VerifyBoundsCheckFunction · 0.85
incFunction · 0.70
funcFunction · 0.70
assertEqualsFunction · 0.50

Tested by

no test coverage detected