Section PROPERTIES.
Variable initial_move: moves.
Inductive wf_move: reg -> reg -> Prop :=
| wf_move_same: forall s d,
In (s, d) initial_move -> wf_move s d
| wf_move_temp_left: forall s d,
wf_move s d -> wf_move (temp s) d
| wf_move_temp_right: forall s d,
wf_move s d -> wf_move s (temp s).
Definition wf_moves (m: moves) : Prop :=
forall s d, In (s, d) m -> wf_move s d.
Hint Rewrite wf_moves_cons wf_moves_append: pmov.
Inductive wf_state: state -> Prop :=
| wf_state_intro: forall mu sigma tau,
wf_moves mu -> wf_moves sigma -> wf_moves tau ->
wf_state (State mu sigma tau).
End PROPERTIES.
(** As a corollary, we show that all sources of [parmove mu] are sources of [mu] or temporaries, and likewise all destinations of [parmove mu] are destinations of [mu] or temporaries. *)
Remark wf_move_initial_reg_or_temp:
forall mu s d,
wf_move mu s d ->
(In s (srcs mu) \/ is_temp s) /\ (In d (dests mu) \/ is_temp d).
Remark in_srcs:
forall mu s, In s (srcs mu) -> exists d, In (s, d) mu.
Remark in_dests:
forall mu d, In d (dests mu) -> exists s, In (s, d) mu.

Lemma parmove_dests_initial_reg_or_temp:
forall mu d,
In d (dests (parmove mu)) -> In d (dests mu) \/ is_temp d.