]> granicus.if.org Git - llvm/commit
[ARM] Fix assembly and disassembly for VMRS/VMSR
authorAndre Vieira <andre.simoesdiasvieira@arm.com>
Mon, 7 Aug 2017 08:41:05 +0000 (08:41 +0000)
committerAndre Vieira <andre.simoesdiasvieira@arm.com>
Mon, 7 Aug 2017 08:41:05 +0000 (08:41 +0000)
commit1103886c3ddb28e4660d21f4ddaeb6f0a690ae7d
treeb47aab028c580f5bd0490eea4de12d7fe7ac1855
parent1b06abdb2cd64e0db124b3df9fe126581e6f4641
[ARM] Fix assembly and disassembly for VMRS/VMSR

This patch addresses two issues with assembly and disassembly for VMRS/VMSR:

1.currently VMRS/VMSR instructions accessing fpsid, mvfr{0-2} and fpexc, are
  accepted for non ARMv8-A targets.

2. all VMRS/VMSR instructions accept writing/reading to PC and SP, when only
   ARMv7-A and ARMv8-A should be allowed to write/read to SP and none to PC.

This patch addresses those issues and adds tests for these cases.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@310243 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/ARM/ARMInstrVFP.td
lib/Target/ARM/AsmParser/ARMAsmParser.cpp
lib/Target/ARM/Disassembler/ARMDisassembler.cpp
test/MC/ARM/directive-arch_extension-fp.s
test/MC/ARM/simple-fp-encoding.s
test/MC/ARM/vmrs_vmsr.s [new file with mode: 0644]
test/MC/Disassembler/ARM/arm-vmrs_vmsr.txt [new file with mode: 0644]
test/MC/Disassembler/ARM/fp-encoding.txt
test/MC/Disassembler/ARM/thumb-vmrs_vmsr.txt [new file with mode: 0644]