fact: Fixpoint regalloc (c: com) (L: IdentSet.t) : com := match c with | SKIP => SKIP | ASSIGN x a => if IdentSet.mem x L then match expr_is_var a with | None => ASSIGN (f x) (rename_aexp a) | Some y => if string_dec (f x) (f y) then SKIP else ASSIGN (f x) (rename_aexp a) end else SKIP | SEQ c1 c2 => SEQ (regalloc c1 (live c2 L)) (regalloc c2 L) | IFTHENELSE b c1 c2 => IFTHENELSE (rename_bexp b) (regalloc c1 L) (regalloc c2 L) | WHILE b c => WHILE (rename_bexp b) (regalloc c (live (WHILE b c) L)) end.
imports: Coq(ZArith Psatz Bool String Program.Equality FSets Wellfounded) CDF(Sequences IMP Simulation)