Skip to main content

Module process

Module process 

Source
Expand description

Process-wide translator state for the single guest-process model.

Consolidates guest FD table, bottle root, soft signal state, and syscall limits behind one active slot (same pattern as crate::mem::AddressSpace). Trap handlers and BSD syscalls access this via with_mut / with_ref.

Structs§

ProcessState
Owned process state for one guest (or unit-test isolation via reset).

Functions§

bottle_root
Clone of the configured bottle root, if any.
fd_get
Resolve guest FD → host FD without taking the process lock (I/O hot path).
reset_run
Resets FD/signals/counters for a new guest run (keeps bottle root).
set_bottle_root
Configures the bottle root used by path-taking syscalls.
tick_syscall
Bumps the process-wide syscall counter without taking the process lock.
with_bottle_root
Borrow the bottle root without cloning (hot path for path translation).
with_mut
Exclusive access to the active process state.
with_ref
Shared access to the active process state (concurrent FD lookups, etc.).