[PATCH] D35621: X86 Asm can't work properly with symbolic Scale

coby via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Aug 18 01:37:21 PDT 2017


coby added a comment.

In https://reviews.llvm.org/D35621#845117, @avt77 wrote:

> Coby, Reid, is eveything OK? Could you get LGTM?


added one minor.
+ I'm currently having a patch on review (https://reviews.llvm.org/D36793) which contains most of the intended goals of this one (everything but the new error, afaik), can you verify it answers your needs?



================
Comment at: lib/Target/X86/AsmParser/X86AsmParser.cpp:1434
           return Error(Tok.getLoc(), "Unexpected identifier!");
-        SM.onIdentifierExpr(Val, Identifier);
+        if (Val->getKind() == MCExpr::Constant) {
+          if (const auto *CE = dyn_cast<MCConstantExpr>(Val)) {
----------------
this line is redundant, its semantics contained in the check performed on the next one.


https://reviews.llvm.org/D35621





More information about the llvm-commits mailing list