summaryrefslogtreecommitdiff
path: root/language/l2.ml
diff options
context:
space:
mode:
authorKathy Gray2014-07-18 12:04:22 +0100
committerKathy Gray2014-07-18 12:04:22 +0100
commitcf267a6d0f0b65c74c78fc3cf13e2175e49aea68 (patch)
treed6457f227c3392d35fd85770dae7635afb7837f9 /language/l2.ml
parentf784ecdc6eb2b34c1f471098eb007e21378eaf66 (diff)
Writing to concatenated aliases
Diffstat (limited to 'language/l2.ml')
-rw-r--r--language/l2.ml62
1 files changed, 36 insertions, 26 deletions
diff --git a/language/l2.ml b/language/l2.ml
index 60343397..a00e2f84 100644
--- a/language/l2.ml
+++ b/language/l2.ml
@@ -81,6 +81,12 @@ id_aux = (* Identifier *)
type
+effect_aux = (* effect set, of kind Effects *)
+ Effect_var of kid
+ | Effect_set of (base_effect) list (* effect set *)
+
+
+type
order_aux = (* vector order specifications, of kind Order *)
Ord_var of kid (* variable *)
| Ord_inc (* increasing (little-endian) *)
@@ -88,24 +94,18 @@ order_aux = (* vector order specifications, of kind Order *)
type
-effect_aux = (* effect set, of kind Effects *)
- Effect_var of kid
- | Effect_set of (base_effect) list (* effect set *)
-
-
-type
id =
Id_aux of id_aux * l
type
-order =
- Ord_aux of order_aux * l
+effect =
+ Effect_aux of effect_aux * l
type
-effect =
- Effect_aux of effect_aux * l
+order =
+ Ord_aux of order_aux * l
type
@@ -231,6 +231,11 @@ typschm =
type
+'a reg_id_aux =
+ RI_id of id
+
+
+type
'a exp_aux = (* Expression *)
E_block of ('a exp) list (* block *)
| E_nondet of ('a exp) list (* nondeterminisitic block, expressions evaluate in an unspecified order, or concurrently *)
@@ -309,11 +314,8 @@ and 'a letbind =
type
-'a alias_spec_aux = (* Register alias expression forms. Other than where noted, each id must refer to an unaliased register of type vector *)
- AL_subreg of id * id (* id must refer to a register, id' to a declared subregister of id *)
- | AL_bit of id * 'a exp
- | AL_slice of id * 'a exp * 'a exp
- | AL_concat of id * id (* both id and id' must refer to a register *)
+'a reg_id =
+ RI_aux of 'a reg_id_aux * 'a annot
type
@@ -351,8 +353,11 @@ rec_opt_aux = (* Optional recursive annotation for functions *)
type
-'a alias_spec =
- AL_aux of 'a alias_spec_aux * 'a annot
+'a alias_spec_aux = (* Register alias expression forms. Other than where noted, each id must refer to an unaliased register of type vector *)
+ AL_subreg of 'a reg_id * id
+ | AL_bit of 'a reg_id * 'a exp
+ | AL_slice of 'a reg_id * 'a exp * 'a exp
+ | AL_concat of 'a reg_id * 'a reg_id
type
@@ -396,10 +401,8 @@ and index_range =
type
-'a dec_spec_aux = (* Register declarations *)
- DEC_reg of typ * id
- | DEC_alias of id * 'a alias_spec
- | DEC_typ_alias of typ * id * 'a alias_spec
+'a alias_spec =
+ AL_aux of 'a alias_spec_aux * 'a annot
type
@@ -433,6 +436,13 @@ type
type
+'a dec_spec_aux = (* Register declarations *)
+ DEC_reg of typ * id
+ | DEC_alias of id * 'a alias_spec
+ | DEC_typ_alias of typ * id * 'a alias_spec
+
+
+type
'a val_spec_aux = (* Value type specification *)
VS_val_spec of typschm * id
| VS_extern_no_rename of typschm * id
@@ -440,11 +450,6 @@ type
type
-'a dec_spec =
- DEC_aux of 'a dec_spec_aux * 'a annot
-
-
-type
'a scattered_def =
SD_aux of 'a scattered_def_aux * 'a annot
@@ -465,6 +470,11 @@ type
type
+'a dec_spec =
+ DEC_aux of 'a dec_spec_aux * 'a annot
+
+
+type
'a val_spec =
VS_aux of 'a val_spec_aux * 'a annot