Skip to content

Port MicroQuickJS to WASI 0.2 Component Model#5

Open
yumin-chen wants to merge 1 commit into
mainfrom
microquickjs-wasi-component-8421867053650295251
Open

Port MicroQuickJS to WASI 0.2 Component Model#5
yumin-chen wants to merge 1 commit into
mainfrom
microquickjs-wasi-component-8421867053650295251

Conversation

@yumin-chen

Copy link
Copy Markdown

This change ports MicroQuickJS to a WASI 0.2 WebAssembly Component.

Key changes:

  1. WIT Definition: Added microquickjs.wit defining the component interface.
  2. Glue Code: Added glue.c and wasi_glue.c/h to bridge the MicroQuickJS engine to the Component Model ABI and satisfy WASI dependencies.
  3. WASM Exception Handling: Enabled -fwasm-exceptions and modern SJLJ emulation to support MicroQuickJS's parser error handling without WebAssembly traps.
  4. Build System: Created a robust and portable build.sh that automates standard library header generation, C compilation using WASI SDK, and component assembly using wit-bindgen and wasm-tools.
  5. Documentation: Added README.WASI.md with instructions on how to build and run the component in compliant runtimes like Wasmtime.
  6. Tooling Compatibility: Verified the component with Wasmtime 29+ and addressed previous review feedback regarding path portability and error handling robustness.
  7. WasmEdge: Added the WasmEdge repository as a submodule to facilitate compatibility testing.

PR created automatically by Jules for task 8421867053650295251 started by @yumin-chen

- Implemented WASI 0.2 component exporting `eval(code: string) -> string`.
- Integrated modern WebAssembly Exception Handling and SJLJ support.
- Added a portable `build.sh` script with environment verification.
- Added `README.WASI.md` documenting runtime requirements.
- Included WasmEdge as a git submodule for compatibility testing.
- Optimized MicroQuickJS build-time header generation for WASM.

Co-authored-by: yumin-chen <10954839+yumin-chen@users.noreply.github.com>
@Chen-Software Chen-Software deleted a comment from google-labs-jules Bot Apr 12, 2026
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.

1 participant