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

Reid Kleckner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed May 30 11:20:40 PDT 2018


rnk added a comment.

This breaks the invariant that an MCSymbol is always a relocatable symbol. I wonder if the better way to do this would be to pretend what we actually saw was a macro definition when the RHS of an assignment doesn't parse as an MCExpr, which is basically a language for relocatable expressions.

I'm not familiar enough with gas syntax to know what the equivalent directives would be. I see the `#define` suggestion in the bug, but is there a gas-only way to express that? We seem to support macros with arguments, but is there a way to express argument-less macros?


Repository:
  rL LLVM

https://reviews.llvm.org/D47545





More information about the llvm-commits mailing list