diff options
author | Xavier Leroy <xavier.leroy@inria.fr> | 2017-06-16 11:53:28 +0200 |
---|---|---|
committer | Bernhard Schommer <bschommer@users.noreply.github.com> | 2017-07-06 15:41:51 +0200 |
commit | 2ff53c2361773f28027ccc8332e1830686d5bbc6 (patch) | |
tree | 2c0b1dc7201bd3618859cc5dc2257dbf07e996de /riscV/SelectOpproof.v | |
parent | dff22ef6d855973e0e0f05c7203a6bfa9a4cf01a (diff) | |
download | compcert-2ff53c2361773f28027ccc8332e1830686d5bbc6.tar.gz compcert-2ff53c2361773f28027ccc8332e1830686d5bbc6.zip |
Extend builtin arguments with a pointer addition operator, continued
- Add support for PowerPC, with all addressing modes.
- Add support for ARM, with "reg + ofs" addressing mode.
- Add support for RISC-V, with the one addressing mode.
- Constprop.v: forgot to recurse in BA_addptr
- volatile4 test: more tests
Diffstat (limited to 'riscV/SelectOpproof.v')
-rw-r--r-- | riscV/SelectOpproof.v | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/riscV/SelectOpproof.v b/riscV/SelectOpproof.v index b9652b34..90f077db 100644 --- a/riscV/SelectOpproof.v +++ b/riscV/SelectOpproof.v @@ -902,13 +902,23 @@ Theorem eval_builtin_arg: eval_expr ge sp e m nil a v -> CminorSel.eval_builtin_arg ge sp e m (builtin_arg a) v. Proof. - intros until v. unfold builtin_arg; case (builtin_arg_match a); intros; InvEval. -- constructor. -- constructor. -- constructor. -- simpl in H5. inv H5. constructor. -- subst v. constructor; auto. + intros until v. unfold builtin_arg; case (builtin_arg_match a); intros. +- InvEval. constructor. +- InvEval. constructor. +- InvEval. constructor. +- InvEval. simpl in H5. inv H5. constructor. +- InvEval. subst v. constructor; auto. - inv H. InvEval. simpl in H6; inv H6. constructor; auto. +- destruct Archi.ptr64 eqn:SF. ++ constructor; auto. ++ InvEval. replace v with (if Archi.ptr64 then Val.addl v1 (Vint n) else Val.add v1 (Vint n)). + repeat constructor; auto. + rewrite SF; auto. +- destruct Archi.ptr64 eqn:SF. ++ InvEval. replace v with (if Archi.ptr64 then Val.addl v1 (Vlong n) else Val.add v1 (Vlong n)). + repeat constructor; auto. + rewrite SF; auto. ++ constructor; auto. - constructor; auto. Qed. |