Section CONSTRUCTORS.
Variable ge: genv.
Variable fn: function.
(** Decomposition of an integer constant *)
Remark decompose_int_arm_nil:
forall N n p, decompose_int_arm N n p = nil -> n = Int.zero.
Remark decompose_int_thumb_nil:
forall N n p, decompose_int_thumb N n p = nil -> n = Int.zero.

Lemma iterate_op_correct:
forall op1 op2 (f: val -> int -> val) (rs: regset) (r: ireg) m v0 n k,
(forall (rs:regset) n,
exec_instr ge fn (op2 (SOimm n)) rs m =
Next (nextinstr_nf (rs#r <- (f (rs#r) n))) m) ->
(forall n,
exec_instr ge fn (op1 (SOimm n)) rs m =
Next (nextinstr_nf (rs#r <- (f v0 n))) m) ->
exists rs',
exec_straight ge fn (iterate_op op1 op2 (decompose_int n) k) rs m  k rs' m
/\ rs'#r = List.fold_left f (decompose_int n) v0
/\ forall r': preg, r' <> r -> if_preg r' = true -> rs'#r' = rs#r'.