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

Roman Lebedev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 27 06:32:44 PDT 2018


lebedev.ri added inline comments.


================
Comment at: test/tools/llvm-mca/X86/Atom/resources-x86_64.s:676-677
+xchgb %bl, %cl
+xchgb %al, (%rbx)
+xchgb %bl, (%rbx)
+
----------------
avt77 wrote:
> lebedev.ri wrote:
> > http://felixcloutier.com/x86/XCHG.html suggests that memory operand can be on either side,
> > so this needs to be repeated with swapped order.
> In fact I checked it but decided not to include in the test because this test is not about syntax. But if you insist I'll extend the test. Is it enough to include the check in one test file only? I mean that I'd like to check this syntax construction for one cpu, OK? Or you'd like to see it inside all 10 files?
> In fact I checked it but decided not to include in the test because this test is not about syntax.
I agree. But the existing tests are doing exhaustive coverage - e.g. see `sub`, `add`.

> Or you'd like to see it inside all 10 files?
All these generic files should be identical other than the CPU specified in run line.
One can argue that it is a bad design, to have to duplicate the tests for every CPU.
But this is what it is...

So yes, all of them, please.


https://reviews.llvm.org/D49912





More information about the llvm-commits mailing list