Skip to content

libuv-wasix: use WASIX posix_spawn/proc_join for child processes#1

Closed
artemyarulin wants to merge 1 commit into
ubifrom
fix/spawn
Closed

libuv-wasix: use WASIX posix_spawn/proc_join for child processes#1
artemyarulin wants to merge 1 commit into
ubifrom
fix/spawn

Conversation

@artemyarulin

@artemyarulin artemyarulin commented Mar 17, 2026

Copy link
Copy Markdown

UPD: Not to be merged, but edgejs will look to this PR branch as a quick way to resolve stalling wasmerio/edgejs#34


Replace the broken WASIX fork fallback with a real spawn backend.

  • add a WASIX-specific posix_spawn path in process.c
  • map stdio/cwd/path handling onto WASIX spawn file actions
  • reap child exit via proc_join instead of waitpid
  • poll process handles from the event loop on WASIX
  • fix WASIX pipe setup for stdin/stdout/stderr semantics

This makes child_process spawning work through the WASIX process model instead of reporting fake fork success and hanging.

@Arshia001

Copy link
Copy Markdown

Closing as duplicate of #7.

#7 is a clean redo from the ea792e2 disable-fork baseline with POSIX-boundary-only spawn/reap (posix_spawnp + libc waitpid(WNOHANG), no direct __wasi_* in libuv). EdgeJS verification for the PR libuv#34 stall repros passes against d8ebea9 on fix/spawn-posix-v2.

@Arshia001 Arshia001 closed this Jun 23, 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.

2 participants