aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOwen Anderson <resistor@mac.com>2011-11-01 22:18:13 +0000
committerOwen Anderson <resistor@mac.com>2011-11-01 22:18:13 +0000
commit60cb643f7561e5be7a3b5fe705535e96de72cbf5 (patch)
tree59674407c86b583c39a2d2a0a660cbc4a55ea06b
parent0173864d8a87d9243d304fbf91b556e20b5a32fc (diff)
downloadexternal_llvm-60cb643f7561e5be7a3b5fe705535e96de72cbf5.zip
external_llvm-60cb643f7561e5be7a3b5fe705535e96de72cbf5.tar.gz
external_llvm-60cb643f7561e5be7a3b5fe705535e96de72cbf5.tar.bz2
Fix disassembly of some VST1 instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143507 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/Target/ARM/Disassembler/ARMDisassembler.cpp24
-rw-r--r--test/MC/Disassembler/ARM/neon.txt3
2 files changed, 21 insertions, 6 deletions
diff --git a/lib/Target/ARM/Disassembler/ARMDisassembler.cpp b/lib/Target/ARM/Disassembler/ARMDisassembler.cpp
index e81cc76..6927d2d 100644
--- a/lib/Target/ARM/Disassembler/ARMDisassembler.cpp
+++ b/lib/Target/ARM/Disassembler/ARMDisassembler.cpp
@@ -2240,13 +2240,27 @@ static DecodeStatus DecodeVSTInstruction(llvm::MCInst &Inst, unsigned Insn,
return MCDisassembler::Fail;
// AddrMode6 Offset (register)
- if (Rm == 0xD)
- Inst.addOperand(MCOperand::CreateReg(0));
- else if (Rm != 0xF) {
- if (!Check(S, DecodeGPRRegisterClass(Inst, Rm, Address, Decoder)))
- return MCDisassembler::Fail;
+ switch (Inst.getOpcode()) {
+ default:
+ if (Rm == 0xD)
+ Inst.addOperand(MCOperand::CreateReg(0));
+ else if (Rm != 0xF) {
+ if (!Check(S, DecodeGPRRegisterClass(Inst, Rm, Address, Decoder)))
+ return MCDisassembler::Fail;
+ }
+ break;
+ case ARM::VST1d8wb_fixed:
+ case ARM::VST1d16wb_fixed:
+ case ARM::VST1d32wb_fixed:
+ case ARM::VST1d64wb_fixed:
+ case ARM::VST1q8wb_fixed:
+ case ARM::VST1q16wb_fixed:
+ case ARM::VST1q32wb_fixed:
+ case ARM::VST1q64wb_fixed:
+ break;
}
+
// First input register
if (!Check(S, DecodeDPRRegisterClass(Inst, Rd, Address, Decoder)))
return MCDisassembler::Fail;
diff --git a/test/MC/Disassembler/ARM/neon.txt b/test/MC/Disassembler/ARM/neon.txt
index fe315f8..1623a0c 100644
--- a/test/MC/Disassembler/ARM/neon.txt
+++ b/test/MC/Disassembler/ARM/neon.txt
@@ -1861,4 +1861,5 @@
# CHECK: vld1.8 {d23, d24, d25}, [r6, :64]!
0x9d 0x62 0x6f 0xf4
# CHECK: vld1.32 {d22, d23, d24, d25}, [pc, :64]!
-
+0x9d 0xaa 0x41 0xf4
+# CHECK: vst1.32 {d26, d27}, [r1, :64]!