[PATCH] D35115: Clang's assembler crashes if Scale in lea is negative (pr33661)

Simon Pilgrim via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 14 03:43:22 PDT 2017


RKSimon added inline comments.


================
Comment at: lib/Target/X86/AsmParser/X86AsmParser.cpp:129
+      if (!(Op.first == IC_IMM || Op.first == IC_REGISTER))
+        return -1; // Return invalid value of Scale
       return Op.second;
----------------
Improve the comment to explain that the invalid value will be caught later by checkScale


https://reviews.llvm.org/D35115





More information about the llvm-commits mailing list