[PATCH] D29939: [AArch64] AArch64AsmParser clean up of isImmediate functions. NFC

Oliver Stannard via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 14 06:56:58 PST 2017


olista01 added inline comments.


================
Comment at: lib/Target/AArch64/AsmParser/AArch64AsmParser.cpp:540
 
-  bool isImm0_1() const {
+  bool isImmInRange(int N, int M) const {
     if (!isImm())
----------------
I think it might be better to write this as a templated function, like we currently do for isUImm12Offset. That way, we don't have to write all of the trivial variations in this file at all.


https://reviews.llvm.org/D29939





More information about the llvm-commits mailing list