Implements PMULHRSW unit test

This commit is contained in:
Ryan Houdek 2020-09-26 15:32:58 -07:00
parent da16b40e12
commit 7b5892b0d5
2 changed files with 53 additions and 0 deletions

View File

@ -0,0 +1,25 @@
%ifdef CONFIG
{
"RegData": {
"XMM0": ["0x31A6343B36E09E7A", "0x48134B294E4F5186"]
}
}
%endif
mov rdx, 0xe0000000
mov rax, 0x4142434445468748
mov [rdx + 8 * 0], rax
mov rax, 0x5152535455565758
mov [rdx + 8 * 1], rax
mov rax, 0x6162636465666768
mov [rdx + 8 * 2], rax
mov rax, 0x7172737475767778
mov [rdx + 8 * 3], rax
movaps xmm0, [rdx + 8 * 0]
pmulhrsw xmm0, [rdx + 8 * 2]
hlt

View File

@ -0,0 +1,28 @@
%ifdef CONFIG
{
"RegData": {
"MM0": "0x00830087008B008F",
"MM1": "0x0100FF0000FF0100"
}
}
%endif
mov rdx, 0xe0000000
mov rax, 0x4142434445464748
mov [rdx + 8 * 0], rax
mov rax, 0x8001800280038004
mov [rdx + 8 * 1], rax
mov rax, 0x0101010101010101
mov [rdx + 8 * 2], rax
mov rax, 0xFF000100FF01FF00
mov [rdx + 8 * 3], rax
movq mm0, [rdx + 8 * 0]
movq mm1, [rdx + 8 * 1]
pmulhrsw mm0, [rdx + 8 * 2]
pmulhrsw mm1, [rdx + 8 * 3]
hlt