aboutsummaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorDavid Monniaux <david.monniaux@univ-grenoble-alpes.fr>2019-09-03 23:02:06 +0200
committerDavid Monniaux <david.monniaux@univ-grenoble-alpes.fr>2019-09-03 23:02:06 +0200
commit1d90fa730df7d1cb2ee726d3b41b9915ae4e4e2e (patch)
treec6f814f178b11a93f2a4113ddaad536dcdf4d657 /common
parent2fe044ba1dbaa3fce00a221d988e06c6907cfaf2 (diff)
downloadcompcert-kvx-1d90fa730df7d1cb2ee726d3b41b9915ae4e4e2e.tar.gz
compcert-kvx-1d90fa730df7d1cb2ee726d3b41b9915ae4e4e2e.zip
moved trapping_mode to a more appropriate place
Diffstat (limited to 'common')
-rw-r--r--common/AST.v9
1 files changed, 9 insertions, 0 deletions
diff --git a/common/AST.v b/common/AST.v
index a91138c9..d98f954a 100644
--- a/common/AST.v
+++ b/common/AST.v
@@ -193,6 +193,15 @@ Definition chunk_of_type (ty: typ) :=
Lemma chunk_of_Tptr: chunk_of_type Tptr = Mptr.
Proof. unfold Mptr, Tptr; destruct Archi.ptr64; auto. Qed.
+(** Trapping mode: does undefined behavior result in a trap or an undefined value (e.g. for loads) *)
+Inductive trapping_mode : Type := TRAP | NOTRAP.
+
+Definition trapping_mode_eq : forall x y : trapping_mode,
+ { x=y } + { x <> y}.
+Proof.
+ decide equality.
+Defined.
+
(** Initialization data for global variables. *)
Inductive init_data: Type :=