Skip to content

perf(tfork): overlap socket purge with source capture - #9

Open
yiying-zhang wants to merge 66 commits into
mainfrom
perf/tfork-overlap-socket-purge
Open

perf(tfork): overlap socket purge with source capture#9
yiying-zhang wants to merge 66 commits into
mainfrom
perf/tfork-overlap-socket-purge

Conversation

@yiying-zhang

Copy link
Copy Markdown
Collaborator

Summary

  • emit a CRIU post-tfork-freeze action and expose a crun restore barrier;
  • scan the first clone root while CRIU performs Phase A;
  • record socket paths in a NUL-delimited manifest;
  • apply that manifest to every clone root instead of recursively scanning each
    clone;
  • keep restore blocked until purge completes;
  • gate the path with PODMAN_TFORK_OVERLAP_SOCKET_PURGE=1.

Performance

Ten interleaved real-Webtop pairs, with source syncfs enabled in both arms:

Mode Wall median Mean
serialized recursive scan 0.845 s 0.847 s
overlapped scan 0.650 s 0.655 s
saving 0.195 s 0.192 s

Validation

  • 20/20 real-Webtop forks passed inheritance and isolation checks;
  • the prepared Webtop correctly produced an empty socket manifest;
  • a synthetic owned Unix socket was found in the manifest and removed from
    every clone before restore;
  • scan/manifest failure keeps the barrier closed and enters transactional
    rollback.

yiying-zhang and others added 30 commits July 10, 2026 23:44
Stabilize live tfork source freezing
yiying-zhang and others added 30 commits July 18, 2026 10:08
…-main

Stabilize single-copy tfork clone path
Rewrite tclone setup for Gensee Crate
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