bytecodealliance / wasmtime

A fast and secure runtime for WebAssembly
https://wasmtime.dev/
Apache License 2.0
15.21k stars 1.28k forks source link

shared memory: enable shared memory in differential_v8 fuzz target #4268

Open abrown opened 2 years ago

abrown commented 2 years ago

In the differential_v8 fuzz target, the oracle retrieves the first exported memory and checks that the memory contents are the same between Wasmtime and V8. To properly enable shared memory in this fuzz target, we would need to check whether the first exported memory is shared and if so:

cfallin commented 2 years ago

As a high-level question: how are we planning to do differential checking in the presence of nondeterminism if/when our generated fuzz tests include actual spawning of multiple threads?

I can see a few possibilities:

alexcrichton commented 2 years ago

Personally I have no ideas beyond your first bullet. I don't know how to fuzz a multithreaded system for correctness really other than custom one-off programs which we can verify that "when compiled to wasm and run this should always work".