diff options
Diffstat (limited to 'arm')
-rw-r--r-- | arm/SelectOp.vp | 3 | ||||
-rw-r--r-- | arm/SelectOpproof.v | 10 |
2 files changed, 13 insertions, 0 deletions
diff --git a/arm/SelectOp.vp b/arm/SelectOp.vp index 3d4e8661..4ea1e1a1 100644 --- a/arm/SelectOp.vp +++ b/arm/SelectOp.vp @@ -194,6 +194,9 @@ Nondetfunction mul (e1: expr) (e2: expr) := | _, _ => Eop Omul (e1:::e2:::Enil) end. +Definition mulhs (e1: expr) (e2: expr) := Eop Omulhs (e1 ::: e2 ::: Enil). +Definition mulhu (e1: expr) (e2: expr) := Eop Omulhu (e1 ::: e2 ::: Enil). + (** ** Bitwise and, or, xor *) Nondetfunction andimm (n1: int) (e2: expr) := diff --git a/arm/SelectOpproof.v b/arm/SelectOpproof.v index dd194498..f025e345 100644 --- a/arm/SelectOpproof.v +++ b/arm/SelectOpproof.v @@ -337,6 +337,16 @@ Proof. TrivialExists. Qed. +Theorem eval_mulhs: binary_constructor_sound mulhs Val.mulhs. +Proof. + unfold mulhs; red; intros; TrivialExists. +Qed. + +Theorem eval_mulhu: binary_constructor_sound mulhu Val.mulhu. +Proof. + unfold mulhu; red; intros; TrivialExists. +Qed. + Theorem eval_andimm: forall n, unary_constructor_sound (andimm n) (fun x => Val.and x (Vint n)). Proof. |