Skip to main content

seeded_max_timeslice

Function seeded_max_timeslice 

Source
pub fn seeded_max_timeslice(sched_seed: u64, minimum_ns: u64) -> NonZeroU64
Expand description

The maximum timeslice, in virtual nanoseconds, drawn for sched_seed: one uniform number u from the seed’s own generator, mapped through the quantile function of SEEDED_MAX_TIMESLICE_PIECES (the piece whose cumulative share passes u, log-uniformly within it), rounded to a whole nanosecond, then raised to minimum_ns (one RCB at the run’s clock multiplier and slowdown, detcore::Config::minimum_max_timeslice_nanos) if it falls below it. The mapping is monotone in u.