[llvm] [X86] Quote symbol names that collide with registers/keywords in Intel syntax (PR #186570)

Fangrui Song via llvm-commits llvm-commits at lists.llvm.org
Sat Mar 14 16:52:34 PDT 2026


MaskRay wrote:

 PR #180464 adds MCTargetOptions access to MCAsmInfo. Once it lands:

* In isValidX86UnquotedName, query the output variant through MCTargetOptions:
* Simplifications in llvm-mc.cpp and CodeGenTargetMachineImpl.cpp — the AsmVariant computation for createMCInstPrinter can also consult the same path, potentially eliminating the manual value_or/getNumOccurrences logic
* Use this patch to get the output syntax and potentially quote the symbols for the Intel syntax.

https://github.com/llvm/llvm-project/pull/186570


More information about the llvm-commits mailing list