mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-26 12:50:30 +00:00
Fix the operand encoding in the test instruction.
Fixes pr22995. llvm-svn: 233686
This commit is contained in:
parent
7befde482c
commit
9790d5e711
@ -1216,10 +1216,10 @@ def X86testpat : PatFrag<(ops node:$lhs, node:$rhs),
|
||||
let isCompare = 1 in {
|
||||
let Defs = [EFLAGS] in {
|
||||
let isCommutable = 1 in {
|
||||
def TEST8rr : BinOpRR_F<0x84, "test", Xi8 , X86testpat, MRMSrcReg>;
|
||||
def TEST16rr : BinOpRR_F<0x84, "test", Xi16, X86testpat, MRMSrcReg>;
|
||||
def TEST32rr : BinOpRR_F<0x84, "test", Xi32, X86testpat, MRMSrcReg>;
|
||||
def TEST64rr : BinOpRR_F<0x84, "test", Xi64, X86testpat, MRMSrcReg>;
|
||||
def TEST8rr : BinOpRR_F<0x84, "test", Xi8 , X86testpat>;
|
||||
def TEST16rr : BinOpRR_F<0x84, "test", Xi16, X86testpat>;
|
||||
def TEST32rr : BinOpRR_F<0x84, "test", Xi32, X86testpat>;
|
||||
def TEST64rr : BinOpRR_F<0x84, "test", Xi64, X86testpat>;
|
||||
} // isCommutable
|
||||
|
||||
def TEST8rm : BinOpRM_F<0x84, "test", Xi8 , X86testpat>;
|
||||
|
@ -30,7 +30,7 @@
|
||||
# CHECK: movl %eax, -16(%ebp)
|
||||
0x67 0x66 0x89 0x45 0xf0
|
||||
|
||||
# CHECK: testb %bl, %cl
|
||||
# CHECK: testb %cl, %bl
|
||||
0x84 0xcb
|
||||
|
||||
# CHECK: cmpl %eax, %ebx
|
||||
|
@ -30,7 +30,7 @@
|
||||
// CHECK: movl %eax, -16(%ebp) # encoding: [0x67,0x66,0x89,0x45,0xf0]
|
||||
movl %eax, -16(%ebp)
|
||||
|
||||
// CHECK: testb %bl, %cl # encoding: [0x84,0xcb]
|
||||
// CHECK: testb %bl, %cl # encoding: [0x84,0xd9]
|
||||
testb %bl, %cl
|
||||
|
||||
// CHECK: cmpl %eax, %ebx # encoding: [0x66,0x39,0xc3]
|
||||
|
@ -79,7 +79,7 @@
|
||||
// CHECK: movl %eax, -16(%ebp) # encoding: [0x89,0x45,0xf0]
|
||||
movl %eax, -16(%ebp)
|
||||
|
||||
// CHECK: testb %bl, %cl # encoding: [0x84,0xcb]
|
||||
// CHECK: testb %bl, %cl # encoding: [0x84,0xd9]
|
||||
testb %bl, %cl
|
||||
|
||||
// CHECK: cmpl %eax, %ebx # encoding: [0x39,0xc3]
|
||||
|
@ -613,7 +613,7 @@ movq _foo@GOTPCREL(%rip), %r14
|
||||
movq 0x00(%r13,%rax,8),%r13
|
||||
|
||||
// CHECK: testq %rax, %rbx
|
||||
// CHECK: encoding: [0x48,0x85,0xd8]
|
||||
// CHECK: encoding: [0x48,0x85,0xc3]
|
||||
testq %rax, %rbx
|
||||
|
||||
// CHECK: cmpq %rbx, %r14
|
||||
|
Loading…
Reference in New Issue
Block a user