Require compcert.cfrontend.Clight.
Module CC := Clight.
Require VST.veric.Clight_core.
Module CC' := Clight_core.
Section GE.
Variable ge : genv.
Definition CCstep s1 s2 :=
Clight_core.at_external s1 = None /\
Clight.step ge (Clight.function_entry2 ge) s1 Events.E0 s2.
Fixpoint strip_skip' (k: CC.cont) : CC.cont :=
match k with
| CC.Kseq Sskip k' => strip_skip' k'
| _ => k
end.
Inductive match_cont:  cont -> CC.cont -> Prop :=
| match_cont_nil: match_cont nil CC.Kstop
| match_cont_seq: forall s k k',
match_cont (strip_skip k) (strip_skip' k') ->
match_cont (Kseq s :: k) (CC.Kseq s k')
| match_cont_loop1: forall e3 s k k',
match_cont (strip_skip k) (strip_skip' k') ->
match_cont (Kseq Scontinue :: Kloop1 s e3 :: k) (CC.Kloop1 s e3 k')
| match_cont_loop2: forall e3 s k k',
match_cont (strip_skip k) (strip_skip' k') ->
match_cont (Kloop2 s e3 :: k) (CC.Kloop2 s e3 k')
| match_cont_switch: forall k k',
match_cont (strip_skip k) (strip_skip' k') ->
match_cont (Kswitch :: k) (CC.Kswitch k')
| match_cont_call: forall lid fd f ve te k k'
(CUR: match current_function k with Some f' => f'=f | _ => True end),
match_cont (strip_skip k) (strip_skip' k') ->
match_cont (Kseq (Sreturn None) :: Kcall lid fd ve te :: k) (CC.Kcall lid f ve te k').
Inductive star: state -> state -> Prop :=
| star_refl: forall s,
star s s
| star_step: forall s1 s2 s3,
CCstep s1 s2 -> star s2 s3 -> star s1 s3.

Lemma star_two:
forall s1 s2 s3,
CCstep s1 s2 -> CCstep s2 s3 ->
star s1 s3.