-
Notifications
You must be signed in to change notification settings - Fork 202
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This adds support for a new experimental "Reactor" executable model. The "Commands" and "Reactors" concepts are introduced here: WebAssembly/WASI#13 A companion Clang patch, which just consists of using the new reactor-crt1.o and Reactor-specific entry point name, is here: https://reviews.llvm.org/D62922 Instead of an entrypoint named "_start", which calls "main", which then scopes the lifetime of the program, Reactors have a "__wasi_unstable_reactor_start" function, which calls "reactor_setup". When "reactor_setup" exits, the intention is that the program should persist and be available for calling. At present, the main anticipated use for this is in environments like Node, where WASI-using modules can be imported and don't necessarily want the semantics of a "main" function. The "unstable" in "__wasi_unstable_reactor_start" reflects that this Reactor concept is not yet stable, and likely to evolve.
- Loading branch information
1 parent
92eaf25
commit d146934
Showing
5 changed files
with
38 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -68,3 +68,4 @@ __wasi_sock_send | |
__wasi_sock_shutdown | ||
__wasm_call_ctors | ||
main | ||
reactor_setup |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters