Skip to content

[WasmFS] Partial support for standalone mode with WasmFS - #16059

Merged
kripken merged 8 commits into
mainfrom
wfstand
Jan 18, 2022
Merged

kripken merged 8 commits into
mainfrom
wfstand

Conversation

@kripken

@kripken kripken commented Jan 18, 2022

Copy link
Copy Markdown
Member

Implement stubs for standalone things we do not expect to handle like
preloaded files. Handle stdout/stderr using interposition as suggested by
@sbc100 , importing the VM's fd_write under a different name.

This is not complete (and so #16008 will not be closed) because
to actually run in a wasm VM we need to implement more syscalls in WasmFS.
Right now those end up as imports that the VM cannot handle. However, in
an optimized build some tests already pass (as those imports are removed),
so this PR is able to add some testing.

Also switch wasmfs to use -O2, which is consistent with other modes
(see the ones nearby in the diff), and which is necessary as just mentioned
for the testing added.

@kripken
kripken requested review from sbc100 and tlively January 18, 2022 19:12

@sbc100 sbc100 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

(Make me think once again it might be time to split standalone.c into multiple files)

@tlively tlively left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

neat!

@kripken
kripken enabled auto-merge (squash) January 18, 2022 20:26
@kripken
kripken merged commit 334fd5e into main Jan 18, 2022
@kripken
kripken deleted the wfstand branch January 18, 2022 20:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants