Skip to content

Support Linux fork on Windows userland - #1492

Open
Weidong Cui (wdcui) wants to merge 2 commits into
uliteboxfrom
wdcui/ulitebox/windows-fork
Open

Weidong Cui (wdcui) wants to merge 2 commits into
uliteboxfrom
wdcui/ulitebox/windows-fork

Conversation

@wdcui

Copy link
Copy Markdown
Member

This PR adds Linux-shim fork and vfork+exec support on Windows userland. The broker writes a forked child's memory image into a page-file-backed section that reserves the policy's maximum child image size and commits pages as they are written, and passes the child runner a read-only handle to it during setup. The runner maps short-lived views of the section to restore each region. To support this, ProcessLauncher::create_image now takes the image capacity, and --allow-process-duplication is now available on Windows. The Linux-on-Windows runner now decodes child startup data, either restoring a forked process from its image or starting an exec'd program in a new runner, so its program argument is now optional. New Windows loader tests run prebuilt static fork_parent and vfork_exec_parent/vfork_exec_child guests, and unit tests cover the image transport, including that the runner cannot write the image.

Weidong Cui (wdcui) and others added 2 commits October 3, 2026 17:16
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 4c14910e-872b-44e8-a57e-eb7c6a1d43a2
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 4c14910e-872b-44e8-a57e-eb7c6a1d43a2
@github-actions

github-actions Bot commented Oct 4, 2026

Copy link
Copy Markdown

🤖 SemverChecks 🤖 ⚠️ Potential breaking API changes detected ⚠️

Click for details
--- failure trait_method_parameter_count_changed: pub trait method parameter count changed ---

Description:
A trait method now takes a different number of parameters.
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#trait-item-signature
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.51.0/src/lints/trait_method_parameter_count_changed.ron

Failed in:
  ProcessLauncher::create_image now takes 1 instead of 0 parameters, in file /home/runner/work/litebox/litebox/litebox_broker_host/src/lib.rs:905

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