Skip to main content

compute_schedule

Function compute_schedule 

Source
pub fn compute_schedule(domains: &[ClockDomain]) -> Vec<Vec<bool>>
Expand description

Compute the interleaved firing schedule for a set of clock domains.

Returns a Vec<Vec<bool>> where schedule[global_step][domain_index] indicates whether that domain fires at that global step.

The schedule covers one full LCM period. Ratios are interpreted as (numerator, denominator) meaning the domain fires numerator times per denominator-unit base period. Domains without a ratio default to (1, 1).

Within the LCM period, the fastest domain fires every step. Slower domains fire at evenly-spaced intervals proportional to their rates.