let rec delay exp_faust = match exp_faust with
|Const v -> 0
|Ident s ->
(
match s with
|Add -> 0
|Sup -> 0
|Mul -> 0
|Div -> 0
|Pass -> 0
|Stop -> 0
|Mem -> 1
|Delay -> 100000 (* danger! *)
|Floor -> 0
|Int -> 0
|Sin -> 0
|Cos -> 0
|Atan -> 0
|Atantwo -> 0
|Sqrt -> 0
|Rdtable -> 100000 (* danger! *)
|Mod -> 0
|Larger -> 0
|Smaller -> 0
|Vectorize -> 100 (* danger! *)
|Concat -> 0
|Nth -> 0
|Serialize -> 0
|Prefix -> 1
|Selecttwo -> 0
|Selectthree -> 0
)
|Par (e1, e2) -> max (delay e1) (delay e2)
|Seq (e1, e2) -> (delay e1) + (delay e2)
|Split (e1, e2) -> (delay e1) + (delay e2)
|Merge (e1, e2) -> (delay e1) + (delay e2)
|Rec (e1, e2) -> delay e1