summaryrefslogtreecommitdiff
path: root/test/wasm2js/atomics_32.2asm.js.opt
diff options
context:
space:
mode:
authorSam Clegg <sbc@chromium.org>2021-11-23 16:04:50 -0800
committerGitHub <noreply@github.com>2021-11-24 00:04:50 +0000
commit0bf6ff7922473c37265f6dd601f889a4476ad600 (patch)
tree40ebfb38d4e845c2d6f28599e8ce5dd3e452395b /test/wasm2js/atomics_32.2asm.js.opt
parenta8dd9e83be8db755294f9e78b8f3466d1d03c1de (diff)
downloadbinaryen-0bf6ff7922473c37265f6dd601f889a4476ad600.tar.gz
binaryen-0bf6ff7922473c37265f6dd601f889a4476ad600.tar.bz2
binaryen-0bf6ff7922473c37265f6dd601f889a4476ad600.zip
wasm2js: Don't assume the existence of js assert function (#4357)
Its seems that with this emscripten change DCE is able to remove the `assert` JS runtime function making this call to assert fail with `ReferenceError: assert is not defined`.
Diffstat (limited to 'test/wasm2js/atomics_32.2asm.js.opt')
-rw-r--r--test/wasm2js/atomics_32.2asm.js.opt2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/wasm2js/atomics_32.2asm.js.opt b/test/wasm2js/atomics_32.2asm.js.opt
index 1b62f99b3..94f25dc2c 100644
--- a/test/wasm2js/atomics_32.2asm.js.opt
+++ b/test/wasm2js/atomics_32.2asm.js.opt
@@ -40,7 +40,7 @@ memorySegments[1] = base64DecodeToExistingUint8Array(new Uint8Array(6), 0, "d29y
}
function wasm2js_atomic_rmw_i64(op, bytes, offset, ptr, valueLow, valueHigh) {
- assert(bytes == 8); // TODO: support 1, 2, 4 as well
+ // TODO: support bytes=1, 2, 4 as well as 8.
var view = new BigInt64Array(bufferView.buffer); // TODO cache
ptr = (ptr + offset) >> 3;
var value = BigInt(valueLow >>> 0) | (BigInt(valueHigh >>> 0) << BigInt(32));