diff options
author | David Monniaux <david.monniaux@univ-grenoble-alpes.fr> | 2019-12-02 19:49:30 +0100 |
---|---|---|
committer | David Monniaux <david.monniaux@univ-grenoble-alpes.fr> | 2019-12-02 19:49:30 +0100 |
commit | f0c1cc8327ecf2b1e3021bce66f2d6bb0265f6c0 (patch) | |
tree | 6d5c6988ad68cfe7052dc6dac267c4de53f0202b /common | |
parent | be3d241a0c2247f48dab2988f49e9c651417328b (diff) | |
parent | eaea751c200213e0f86cf51c1fe93b7ba09c4227 (diff) | |
download | compcert-kvx-f0c1cc8327ecf2b1e3021bce66f2d6bb0265f6c0.tar.gz compcert-kvx-f0c1cc8327ecf2b1e3021bce66f2d6bb0265f6c0.zip |
Merge remote-tracking branch 'origin/mppa-work' into mppa-non-trapping-load
Diffstat (limited to 'common')
-rw-r--r-- | common/AST.v | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/common/AST.v b/common/AST.v index bb8508b7..86cab287 100644 --- a/common/AST.v +++ b/common/AST.v @@ -17,7 +17,7 @@ the abstract syntax trees of many of the intermediate languages. *) Require Import String. -Require Import Coqlib Maps Errors Integers Floats. +Require Import Coqlib Maps Errors Integers Floats BinPos. Require Archi. Set Implicit Arguments. @@ -640,11 +640,28 @@ Inductive builtin_arg (A: Type) : Type := | BA_splitlong (hi lo: builtin_arg A) | BA_addptr (a1 a2: builtin_arg A). +Definition builtin_arg_eq {A: Type}: + (forall x y : A, {x = y} + {x <> y}) -> + forall (ba1 ba2: (builtin_arg A)), {ba1=ba2} + {ba1<>ba2}. +Proof. + intro. generalize Integers.int_eq int64_eq float_eq float32_eq chunk_eq ptrofs_eq ident_eq. + decide equality. +Defined. +Global Opaque builtin_arg_eq. + Inductive builtin_res (A: Type) : Type := | BR (x: A) | BR_none | BR_splitlong (hi lo: builtin_res A). +Definition builtin_res_eq {A: Type}: + (forall x y : A, {x = y} + {x <> y}) -> + forall (a b: builtin_res A), {a=b} + {a<>b}. +Proof. + intro. decide equality. +Defined. +Global Opaque builtin_res_eq. + Fixpoint globals_of_builtin_arg (A: Type) (a: builtin_arg A) : list ident := match a with | BA_loadglobal chunk id ofs => id :: nil |