Commit e1a9c1e8 authored by Deepti Gandluri's avatar Deepti Gandluri Committed by Commit Bot

[wasm] Enable atomic operations on all memory by default

Currently, atomics operations are only allowed on shared memory and are
enabled on regular memory behind the --wasm-atomics-on-non-shared-memory
flag. Set the default value of this flag to true. This enables the
following behaviors:

 - No validation failures when atomic opcodes are used on wasm memory
 backed by ArrayBuffers
 - memory.atomics.wait{32/64} operations will trap when wasm memory is
 not shared
 - memory.atomics.notify will always return 0 if wasm memory is not
 not shared.

Bug: v8:9921
Change-Id: I1feb8c3db428187ee192ea72277957bfde9ac4b2
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2258099Reviewed-by: 's avatarAndreas Haas <ahaas@chromium.org>
Commit-Queue: Deepti Gandluri <gdeepti@chromium.org>
Cr-Commit-Position: refs/heads/master@{#68486}
parent 906db63f
......@@ -807,7 +807,7 @@ DEFINE_BOOL(wasm_lazy_validation, false,
// Flags for wasm prototyping that are not strictly features i.e., part of
// an existing proposal that may be conditionally enabled.
DEFINE_BOOL(wasm_atomics_on_non_shared_memory, false,
DEFINE_BOOL(wasm_atomics_on_non_shared_memory, true,
"allow atomic operations on non-shared WebAssembly memory")
DEFINE_BOOL(wasm_grow_shared_memory, true,
"allow growing shared WebAssembly memory objects")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment