pub fn refuse_hold_without_preemption(
program: &HappensBeforeProgram,
path: &Path,
reason: &str,
) -> Result<()>Expand description
Refuse a version-2 program on a run without a preemption timer, saying
why (reason). A version-2 spec bounds every hold by max_hold_ns,
charged in committed virtual time; without the timer a thread that spins
without syscalls never ends its turn, committed time stops, and a hold
could never be charged, so the run would hang instead of ending in
HERMIT_HB_HOLD_BUDGET_EXCEEDED. Called before launch twice: for an
explicit --max-timeslice disabled, and after argument validation, when
the timer can also be lost because the host cannot arm it. A version-1
program has no budget and is never refused here.