aboutsummaryrefslogtreecommitdiffstats
path: root/mppa_k1c
diff options
context:
space:
mode:
authorDavid Monniaux <david.monniaux@univ-grenoble-alpes.fr>2019-04-12 11:46:13 +0200
committerDavid Monniaux <david.monniaux@univ-grenoble-alpes.fr>2019-04-12 11:46:13 +0200
commit6a267e0bce732e68ab5e5b6c971ba5e0fe226719 (patch)
treeae7ec59c521936cbfe375a81d9e0a2f1f87ec7d7 /mppa_k1c
parent4b78052471c339c1e7dbbabe9ac20835fe963b9c (diff)
downloadcompcert-kvx-6a267e0bce732e68ab5e5b6c971ba5e0fe226719.tar.gz
compcert-kvx-6a267e0bce732e68ab5e5b6c971ba5e0fe226719.zip
some more simplifications
Diffstat (limited to 'mppa_k1c')
-rw-r--r--mppa_k1c/SelectOp.vp6
-rw-r--r--mppa_k1c/SelectOpproof.v22
2 files changed, 25 insertions, 3 deletions
diff --git a/mppa_k1c/SelectOp.vp b/mppa_k1c/SelectOp.vp
index 72f5616c..d6dfdce1 100644
--- a/mppa_k1c/SelectOp.vp
+++ b/mppa_k1c/SelectOp.vp
@@ -358,6 +358,12 @@ Nondetfunction notint (e: expr) :=
| Eop (Oorimm n) (e1:::Enil) => Eop (Onorimm n) (e1:::Enil)
| Eop Oxor (e1:::e2:::Enil) => Eop Onxor (e1:::e2:::Enil)
| Eop (Oxorimm n) (e1:::Enil) => Eop (Onxorimm n) (e1:::Enil)
+ | Eop Onand (e1:::e2:::Enil) => Eop Oand (e1:::e2:::Enil)
+ | Eop (Onandimm n) (e1:::Enil) => Eop (Oandimm n) (e1:::Enil)
+ | Eop Onor (e1:::e2:::Enil) => Eop Oor (e1:::e2:::Enil)
+ | Eop (Onorimm n) (e1:::Enil) => Eop (Oorimm n) (e1:::Enil)
+ | Eop Onxor (e1:::e2:::Enil) => Eop Oxor (e1:::e2:::Enil)
+ | Eop (Onxorimm n) (e1:::Enil) => Eop (Oxorimm n) (e1:::Enil)
| Eop Onot (e1:::Enil) => e1
| Eop (Ointconst k) Enil => Eop (Ointconst (Int.not k)) Enil
| _ => Eop Onot (e:::Enil)
diff --git a/mppa_k1c/SelectOpproof.v b/mppa_k1c/SelectOpproof.v
index 023f2a3c..c836fb86 100644
--- a/mppa_k1c/SelectOpproof.v
+++ b/mppa_k1c/SelectOpproof.v
@@ -680,9 +680,25 @@ Proof.
- TrivialExists; simpl; congruence.
- TrivialExists; simpl; congruence.
- TrivialExists; simpl; congruence.
- - rewrite <- H0.
- exists v1.
- split; auto.
+ - subst x. exists (Val.and v1 v0); split; trivial.
+ econstructor. constructor. eassumption. constructor.
+ eassumption. constructor. simpl. reflexivity.
+ - subst x. exists (Val.and v1 (Vint n)); split; trivial.
+ econstructor. constructor. eassumption. constructor.
+ simpl. reflexivity.
+ - subst x. exists (Val.or v1 v0); split; trivial.
+ econstructor. constructor. eassumption. constructor.
+ eassumption. constructor. simpl. reflexivity.
+ - subst x. exists (Val.or v1 (Vint n)); split; trivial.
+ econstructor. constructor. eassumption. constructor.
+ simpl. reflexivity.
+ - subst x. exists (Val.xor v1 v0); split; trivial.
+ econstructor. constructor. eassumption. constructor.
+ eassumption. constructor. simpl. reflexivity.
+ - subst x. exists (Val.xor v1 (Vint n)); split; trivial.
+ econstructor. constructor. eassumption. constructor.
+ simpl. reflexivity.
+ - subst x. exists v1; split; trivial.
- TrivialExists.
- TrivialExists.
Qed.