[PATCH] D47545: [MC][X86] Allow assembler variable assignment to register name.

Nick Desaulniers via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 30 14:28:34 PDT 2018


nickdesaulniers added inline comments.


================
Comment at: llvm/lib/Target/X86/AsmParser/X86AsmParser.cpp:2197
+    SMLoc StartLoc = Parser.getTok().getLoc();
+    // Normal Expression parse fails, check if it could be a register.
+    unsigned RegNo;
----------------
rnk wrote:
> Does this generalize to more than just registers? Could it include things like `foo = $42`, or `foo = 0x40(%rcx)` as some kind of alias for an accessor? We might want to allow these things so that we don't have to do this fire drill again the next time a Linux developer writes some creative GNU as.
or tries to do this with another ISA, like arm64.  I guess I'm curious if this is needs to be implemented in the other parsers as well?  We only see the issue on x86 in the kernel currently, but I'd think this kind of functionality would be ISA independent?


Repository:
  rL LLVM

https://reviews.llvm.org/D47545





More information about the llvm-commits mailing list