[PATCH] D41382: [AArch64] Asm: Fix parsing of register aliases that have a name starting with 'z'

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 19 04:50:39 PST 2017

fhahn added inline comments.

Comment at: lib/Target/AArch64/AsmParser/AArch64AsmParser.cpp:2010
+  // tryParse methods for SVE data and predicate vectors.
+  if (AArch64MCRegisterClasses[AArch64::ZPRRegClassID].contains(RegNum))
     return -1;
fhahn wrote:
> I don't think we need this early exit here. If it's a vector register, `matchRegisterNameAlias` should return 0 and we return -1 later. We do not bail out for NEON early either.
Ok, I was wrong about `matchRegisterNameAlias`. But it seems the early exit is not needed, the MC test pass for me without it and we do not have a similar case for NEON.


More information about the llvm-commits mailing list