diff --git a/rio/frontend/ast.ml b/rio/frontend/ast.ml index f10afd4..df378cb 100644 --- a/rio/frontend/ast.ml +++ b/rio/frontend/ast.ml @@ -2,23 +2,29 @@ type clss = string type var = string (* Changes to this type must also be reflected in `Policy.t` in policy.ml *) -type policy = +type set = | Class of clss - | Union of policy list - | Fifo of policy list - | RoundRobin of policy list - | Strict of policy list - | WeightedFair of (policy * float) list - | EarliestDeadline of policy list - | ShortestJobNext of policy list - | ShortestRemaining of policy list - | RateControlled of policy list - | LeakyBucket of policy list * int * int - | TokenBucket of policy list * int * int - | StopAndGo of policy list * int + | Union of set list + +type stream = + (* Set-to-Stream *) + | Fifo of set list + | EarliestDeadline of set list + | ShortestJobNext of set list + | ShortestRemaining of set list + (* Stream-To-Stream *) + | RoundRobin of stream list + | Strict of stream list + | WeightedFair of (stream * float) list + (* Non-Work Conserving *) + | RateControlled of stream list + | LeakyBucket of stream list * int * int + | TokenBucket of stream list * int * int + | StopAndGo of stream list * int + (* Variables *) | Var of var type declare = clss list -type assignment = var * policy -type return = policy +type assignment = var * stream +type return = stream type program = declare * assignment list * return