[PATCH] D49912: [X86] MCA tests for XCHG* and CMPXCHG* instructions

Andrew V. Tischenko via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 2 02:18:01 PDT 2018


avt77 added inline comments.


================
Comment at: test/tools/llvm-mca/X86/Atom/resources-x86_64.s:230
+cmpxchgq %rax, %rbx
+cmpxchgq %rax, (%rbx)
+
----------------
RKSimon wrote:
> Don't use AL/AX/EAX/RAX as explicit ops - they are implicitly referenced by in the instruction 
It seems it deos not work:

<stdin>:225:1: error: too few operands for instruction
cmpxchgb %bl
^
<stdin>:226:10: error: invalid operand for instruction
cmpxchgb (%rbx)
         ^~~~~~
<stdin>:228:1: error: too few operands for instruction
cmpxchgw %bx
^
<stdin>:229:10: error: invalid operand for instruction
cmpxchgw (%rbx)
         ^~~~~~
<stdin>:231:1: error: too few operands for instruction
cmpxchgl %ebx
^
<stdin>:232:10: error: invalid operand for instruction
cmpxchgl (%ebx)
         ^~~~~~
<stdin>:234:1: error: too few operands for instruction
cmpxchgq %rbx
^
<stdin>:235:10: error: invalid operand for instruction
cmpxchgq (%rbx)
         ^~~~~~


https://reviews.llvm.org/D49912





More information about the llvm-commits mailing list