Commit 94b0e8d4 authored by Julian Kranz's avatar Julian Kranz
Browse files

X86 RREIL Translator

- Added semantics of: (V)PSUBSB, (V)PSUBSW
parent b31e81a3
......@@ -407,10 +407,15 @@ main:
#vpsrld %xmm1, %xmm2, %xmm3
#vpsrlq $33, %xmm1, %xmm2
psubb (%rax), %mm1
psubw (%rax), %xmm1
psubd %xmm1, %xmm2
vpsubd (%rax), %xmm1, %xmm2
#psubb (%rax), %mm1
#psubw (%rax), %xmm1
#psubd %xmm1, %xmm2
#vpsubd (%rax), %xmm1, %xmm2
psubsb (%rax), %mm1
psubsw (%rax), %xmm1
vpsubsb %xmm1, %xmm2, %xmm3
vpsubsw %xmm1, %xmm2, %xmm3
#vmovd %xmm5, %ebx
......
......@@ -1700,6 +1700,9 @@ val sem-vpsrl element-size x = sem-ps-vps-opnd '1' element-size shr x.opnd1 x.op
val sem-psub element-size x = sem-pbinop-opnd '0' element-size sub x.opnd1 x.opnd1 x.opnd2
val sem-vpsub element-size x = sem-pbinop-opnd '1' element-size sub x.opnd1 x.opnd2 x.opnd3
val sem-psubs element-size x = sem-pbinop-opnd '0' element-size sub-signed-saturating x.opnd1 x.opnd1 x.opnd2
val sem-vpsubs element-size x = sem-pbinop-opnd '1' element-size sub-signed-saturating x.opnd1 x.opnd2 x.opnd3
val ps-push opnd-sz opnd = do
mode64 <- mode64?;
stack-addr-sz <- runtime-stack-address-size;
......
......@@ -1435,8 +1435,8 @@ val semantics insn =
| PSUBB x: sem-psub 8 x
| PSUBD x: sem-psub 32 x
| PSUBQ x: sem-psub 64 x
| PSUBSB x: sem-undef-arity2 x
| PSUBSW x: sem-undef-arity2 x
| PSUBSB x: sem-psubs 8 x
| PSUBSW x: sem-psubs 16 x
| PSUBUSB x: sem-undef-arity2 x
| PSUBUSW x: sem-undef-arity2 x
| PSUBW x: sem-psub 16 x
......@@ -2117,8 +2117,14 @@ val semantics insn =
case v of
VA3 x: sem-vpsub 64 x
end
| VPSUBSB x: sem-undef-varity x
| VPSUBSW x: sem-undef-varity x
| VPSUBSB v:
case v of
VA3 x: sem-vpsubs 8 x
end
| VPSUBSW v:
case v of
VA3 x: sem-vpsubs 16 x
end
| VPSUBUSB x: sem-undef-varity x
| VPSUBUSW x: sem-undef-varity x
| VPSUBW v:
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment