wasi-threads icon indicating copy to clipboard operation
wasi-threads copied to clipboard

Quesitons about `wasi_thread_spawn` semantics

Open yamt opened this issue 1 year ago • 5 comments

the description of wasi_thread_spawn says:

instantiate the module again — this child instance will be used for the new thread

it isn't obvious to me which module "the module" here is when multiple modules are involved. for example, if module A calls a function imported from module B and the function calls wasi_thread_spawn, which module is it?

also, does instantiate the module again imply that an engine needs to keep an equivalent of wasm-c-api wasm_extern_vec_t or "import object" (i mean importObject argument of WebAssembly.instantiate) for possible wasi_thread_spawn operations?

yamt avatar Dec 06 '22 12:12 yamt