diff options
Diffstat (limited to 'x86')
-rw-r--r-- | x86/SelectOp.vp | 3 | ||||
-rw-r--r-- | x86/SelectOpproof.v | 10 |
2 files changed, 13 insertions, 0 deletions
diff --git a/x86/SelectOp.vp b/x86/SelectOp.vp index f8010f0a..2037760f 100644 --- a/x86/SelectOp.vp +++ b/x86/SelectOp.vp @@ -226,6 +226,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/x86/SelectOpproof.v b/x86/SelectOpproof.v index cdb79c6f..1728c39d 100644 --- a/x86/SelectOpproof.v +++ b/x86/SelectOpproof.v @@ -363,6 +363,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. |