skan added inline comments.
================ Comment at: llvm/test/MC/X86/x86-64-movdir64b-intel.s:1 +// RUN: llvm-mc -triple x86_64-unknown-unknown -x86-asm-syntax=intel -output-asm-variant=1 --show-encoding %s | FileCheck %s +// CHECK: movdir64b rax, zmmword ptr [rax - 4096] ---------------- akshaykhadse wrote: > skan wrote: > > The test can pass w/o this patch. I think we should replace it with IR test > > (llc) here, the input should be the diff in ms-inline-asm-64.c. > It is better to remove this as it does not add any value. > > We cannot write a llc test for this because: > - If input IR is `call ... "movdir64b eax, ZMMWORD PTR arr ..."`, the > generated assembly will be `movdir64b arr, %rax" > - If input IR is `call ... "movdir64b eax, ZMMWORD PTR $0 ..."`, the > generated assembly will be `movdir64b -4016(%rbp), %rax" > > In other words, it's responsibility of front-end to generate the correct IR. > If the IR is not correct, the back-end will not fix it and incorrect assembly > will be generated. > The backend will parse the inline asm in IR too. As I mentioned, you split the end-to-end test to C->IR and IR->AS. So you need to check the inline asm in IR can be parsed correctly. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151863/new/ https://reviews.llvm.org/D151863 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits