summaryrefslogtreecommitdiff
path: root/checklink
diff options
context:
space:
mode:
authorGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2013-07-29 12:49:47 +0000
committerGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2013-07-29 12:49:47 +0000
commit2bf34f3c5e65508a793c3b2c6981b0ecad5ac0e7 (patch)
treeb1bb926e4e5b3e654dee0ea14d184d5c48448ab5 /checklink
parent41b7ecb127b93b1aecc29a298ec21dc94603e6fa (diff)
Update cchecklink w/ new Asm instructions Pmulh*
git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@2301 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'checklink')
-rw-r--r--checklink/Asm_printers.ml2
-rw-r--r--checklink/Check.ml22
2 files changed, 24 insertions, 0 deletions
diff --git a/checklink/Asm_printers.ml b/checklink/Asm_printers.ml
index 8bc8caf..794d47a 100644
--- a/checklink/Asm_printers.ml
+++ b/checklink/Asm_printers.ml
@@ -185,6 +185,8 @@ let string_of_instruction = function
| Pmtlr (i0) -> "Pmtlr(" ^ string_of_ireg i0 ^ ")"
| Pmulli (i0, i1, c2) -> "Pmulli(" ^ string_of_ireg i0 ^ ", " ^ string_of_ireg i1 ^ ", " ^ string_of_constant c2 ^ ")"
| Pmullw (i0, i1, i2) -> "Pmullw(" ^ string_of_ireg i0 ^ ", " ^ string_of_ireg i1 ^ ", " ^ string_of_ireg i2 ^ ")"
+| Pmulhw (i0, i1, i2) -> "Pmulhw(" ^ string_of_ireg i0 ^ ", " ^ string_of_ireg i1 ^ ", " ^ string_of_ireg i2 ^ ")"
+| Pmulhwu (i0, i1, i2) -> "Pmulhwu(" ^ string_of_ireg i0 ^ ", " ^ string_of_ireg i1 ^ ", " ^ string_of_ireg i2 ^ ")"
| Pnand (i0, i1, i2) -> "Pnand(" ^ string_of_ireg i0 ^ ", " ^ string_of_ireg i1 ^ ", " ^ string_of_ireg i2 ^ ")"
| Pnor (i0, i1, i2) -> "Pnor(" ^ string_of_ireg i0 ^ ", " ^ string_of_ireg i1 ^ ", " ^ string_of_ireg i2 ^ ")"
| Por (i0, i1, i2) -> "Por(" ^ string_of_ireg i0 ^ ", " ^ string_of_ireg i1 ^ ", " ^ string_of_ireg i2 ^ ")"
diff --git a/checklink/Check.ml b/checklink/Check.ml
index 4097267..be1360d 100644
--- a/checklink/Check.ml
+++ b/checklink/Check.ml
@@ -2104,6 +2104,28 @@ let rec compare_code ccode ecode pc: checker = fun fw ->
>>= recur_simpl
| _ -> error
end
+ | Pmulhw(rd, r1, r2) ->
+ begin match ecode with
+ | MULHWx(rD, rA, rB, rc) :: es ->
+ OK(fw)
+ >>= match_iregs rd rD
+ >>= match_iregs r1 rA
+ >>= match_iregs r2 rB
+ >>= match_bools false rc
+ >>= recur_simpl
+ | _ -> error
+ end
+ | Pmulhwu(rd, r1, r2) ->
+ begin match ecode with
+ | MULHWUx(rD, rA, rB, rc) :: es ->
+ OK(fw)
+ >>= match_iregs rd rD
+ >>= match_iregs r1 rA
+ >>= match_iregs r2 rB
+ >>= match_bools false rc
+ >>= recur_simpl
+ | _ -> error
+ end
| Pnand(rd, r1, r2) ->
begin match ecode with
| NANDx(rS, rA, rB, rc) :: es ->