From 86f42b92d87020875e2a7ef4ba40de12d261685f Mon Sep 17 00:00:00 2001 From: Yann Herklotz Date: Fri, 12 Jun 2020 14:40:15 +0100 Subject: Add declaration of loads --- src/translation/HTLgen.v | 1 + src/translation/HTLgenspec.v | 9 +++++---- 2 files changed, 6 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/translation/HTLgen.v b/src/translation/HTLgen.v index bbce47c..a891d6c 100644 --- a/src/translation/HTLgen.v +++ b/src/translation/HTLgen.v @@ -363,6 +363,7 @@ Definition transf_instr (fin rtrn stack: reg) (ni: node * instruction) : mon uni add_instr n n' (nonblock dst instr) | Iload mem addr args dst n' => do src <- translate_arr_access mem addr args stack; + do _ <- declare_reg None dst 32; add_instr n n' (block dst src) | Istore mem addr args src n' => do dst <- translate_arr_access mem addr args stack; diff --git a/src/translation/HTLgenspec.v b/src/translation/HTLgenspec.v index 770b372..7909688 100644 --- a/src/translation/HTLgenspec.v +++ b/src/translation/HTLgenspec.v @@ -387,10 +387,11 @@ Proof. constructor. eapply translate_instr_tr_op. apply EQ1. eapply in_map with (f := fst) in H14. contradiction. - + destruct o with pc1; destruct H11; simpl in *; rewrite AssocMap.gss in H9; eauto; congruence. - + destruct o0 with pc1; destruct H11; simpl in *; rewrite AssocMap.gss in H9; eauto; congruence. - + inversion H2. inversion H9. rewrite <- e2. rewrite H. econstructor. apply EQ1. - eapply in_map with (f := fst) in H9. contradiction. + + destruct o with pc1; destruct H16; simpl in *; rewrite AssocMap.gss in H14; eauto; congruence. + + destruct o0 with pc1; destruct H16; simpl in *; rewrite AssocMap.gss in H14; eauto; congruence. + + inversion H2. inversion H14. rewrite <- e2. assert (HST: st_st s2 = st_st s0) by congruence. + rewrite HST. econstructor. apply EQ1. + eapply in_map with (f := fst) in H14. contradiction. + destruct o with pc1; destruct H11; simpl in *; rewrite AssocMap.gss in H9; eauto; congruence. + destruct o0 with pc1; destruct H11; simpl in *; rewrite AssocMap.gss in H9; eauto; congruence. -- cgit