[AArch64][SVE] Asm: error on unexpected SVE vector register type suffix
authorSander de Smalen <sander.desmalen@arm.com>
Wed, 27 Mar 2019 17:23:38 +0000 (17:23 +0000)
committerSander de Smalen <sander.desmalen@arm.com>
Wed, 27 Mar 2019 17:23:38 +0000 (17:23 +0000)
commite1eab42f65f2d5479bbefaaa967e66746b94a003
treed604153969e72ad4b49836bb1467cba19f27d02b
parent17e39100a201c52b54847d94290ca2c00d16923a
[AArch64][SVE] Asm: error on unexpected SVE vector register type suffix

This patch fixes an assembler bug that allowed SVE vector registers to contain a
type suffix when not expected. The SVE unpredicated movprfx instruction is the
only instruction affected.

The following are examples of what was previously valid:

    movprfx z0.b, z0.b
    movprfx z0.b, z0.s
    movprfx z0, z0.s

These instructions are now erroneous.

Patch by Cullen Rhodes (c-rhodes)

Reviewed By: sdesmalen

Differential Revision: https://reviews.llvm.org/D59636

llvm-svn: 357094
llvm/lib/Target/AArch64/AsmParser/AArch64AsmParser.cpp
llvm/test/MC/AArch64/SVE/ldr-diagnostics.s
llvm/test/MC/AArch64/SVE/movprfx-diagnostics.s
llvm/test/MC/AArch64/SVE/str-diagnostics.s