diff options
| author | Tony Jiang <jtony@ca.ibm.com> | 2017-09-19 15:22:36 +0000 |
|---|---|---|
| committer | Tony Jiang <jtony@ca.ibm.com> | 2017-09-19 15:22:36 +0000 |
| commit | 425071eff33f258880a2d278b965793a78d5a517 (patch) | |
| tree | c94273f3f8a0e48ba5de937d82574fceedbd610a /llvm/test | |
| parent | 485e01be26b27107b65fecc2464aec703ceaf3b7 (diff) | |
| download | bcm5719-llvm-425071eff33f258880a2d278b965793a78d5a517.tar.gz bcm5719-llvm-425071eff33f258880a2d278b965793a78d5a517.zip | |
[Power9] Add missing Power9 instructions.
The following 8 instructions are implemented in this patch.
addpcis(subpcis, lnia), darn, maddhd, maddhdu, maddld, setb
llvm-svn: 313636
Diffstat (limited to 'llvm/test')
| -rw-r--r-- | llvm/test/MC/Disassembler/PowerPC/ppc64-encoding.txt | 21 | ||||
| -rw-r--r-- | llvm/test/MC/PowerPC/ppc64-encoding.s | 32 |
2 files changed, 53 insertions, 0 deletions
diff --git a/llvm/test/MC/Disassembler/PowerPC/ppc64-encoding.txt b/llvm/test/MC/Disassembler/PowerPC/ppc64-encoding.txt index 0877e8d4033..6b052474310 100644 --- a/llvm/test/MC/Disassembler/PowerPC/ppc64-encoding.txt +++ b/llvm/test/MC/Disassembler/PowerPC/ppc64-encoding.txt @@ -328,6 +328,27 @@ # CHECK: mulhwu. 2, 3, 4 0x7c 0x43 0x20 0x17 +# CHECK: maddhd 2, 3, 4, 5 +0x10 0x43 0x21 0x70 + +# CHECK: maddhdu 2, 3, 4, 5 +0x10 0x43 0x21 0x71 + +# CHECK: maddld 2, 3, 4, 5 +0x10 0x43 0x21 0x73 + +# CHECK: setb 2, 3 +0x7c 0x4c 0x01 0x00 + +# CHECK: darn 2, 3 +0x7c 0x43 0x05 0xe6 + +# CHECK: addpcis 3, 22627 +0x4c,0x71,0x58,0x45 + +# CHECK: lnia 3 +0x4c,0x60,0x00,0x04 + # CHECK: divw 2, 3, 4 0x7c 0x43 0x23 0xd6 diff --git a/llvm/test/MC/PowerPC/ppc64-encoding.s b/llvm/test/MC/PowerPC/ppc64-encoding.s index 4a2c6ab9ae9..18d405d27e6 100644 --- a/llvm/test/MC/PowerPC/ppc64-encoding.s +++ b/llvm/test/MC/PowerPC/ppc64-encoding.s @@ -460,6 +460,38 @@ # CHECK-LE: mulhwu. 2, 3, 4 # encoding: [0x17,0x20,0x43,0x7c] mulhwu. 2, 3, 4 +# CHECK-BE: maddhd 2, 3, 4, 5 # encoding: [0x10,0x43,0x21,0x70] +# CHECK-LE: maddhd 2, 3, 4, 5 # encoding: [0x70,0x21,0x43,0x10] + maddhd 2, 3, 4, 5 + +# CHECK-BE: maddhdu 2, 3, 4, 5 # encoding: [0x10,0x43,0x21,0x71] +# CHECK-LE: maddhdu 2, 3, 4, 5 # encoding: [0x71,0x21,0x43,0x10] + maddhdu 2, 3, 4, 5 + +# CHECK-BE: maddld 2, 3, 4, 5 # encoding: [0x10,0x43,0x21,0x73] +# CHECK-LE: maddld 2, 3, 4, 5 # encoding: [0x73,0x21,0x43,0x10] + maddld 2, 3, 4, 5 + +# CHECK-BE: setb 2, 3 # encoding: [0x7c,0x4c,0x01,0x00] +# CHECK-LE: setb 2, 3 # encoding: [0x00,0x01,0x4c,0x7c] + setb 2, 3 + +# CHECK-BE: darn 2, 3 # encoding: [0x7c,0x43,0x05,0xe6] +# CHECK-LE: darn 2, 3 # encoding: [0xe6,0x05,0x43,0x7c] + darn 2, 3 + +# CHECK-BE: addpcis 3, 22627 # encoding: [0x4c,0x71,0x58,0x45] +# CHECK-LE: addpcis 3, 22627 # encoding: [0x45,0x58,0x71,0x4c] + addpcis 3, 22627 + +# CHECK-BE: addpcis 3, 22627 # encoding: [0x4c,0x71,0x58,0x45] +# CHECK-LE: addpcis 3, 22627 # encoding: [0x45,0x58,0x71,0x4c] + subpcis 3, -22627 + +# CHECK-BE: lnia 3 # encoding: [0x4c,0x60,0x00,0x04] +# CHECK-LE: lnia 3 # encoding: [0x04,0x00,0x60,0x4c] + lnia 3 + # CHECK-BE: divw 2, 3, 4 # encoding: [0x7c,0x43,0x23,0xd6] # CHECK-LE: divw 2, 3, 4 # encoding: [0xd6,0x23,0x43,0x7c] divw 2, 3, 4 |

