[PATCH] D63865: [ARM] Fix bogus assertions in copyPhysReg v8.1-M cases.
Simon Tatham via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 27 02:50:50 PDT 2019
simon_tatham created this revision.
simon_tatham added reviewers: miyuki, ostannard.
Herald added subscribers: llvm-commits, hiraditya, kristof.beyls, javed.absar.
Herald added a project: LLVM.
The code to generate register move instructions in and out of VPR and
FPSCR_NZCV had assertions checking that the other register involved
was a GPR _pair_, instead of a single GPR as it should have been.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D63865
Files:
llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp
Index: llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp
===================================================================
--- llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp
+++ llvm/lib/Target/ARM/ARMBaseInstrInfo.cpp
@@ -927,25 +927,25 @@
copyToCPSR(MBB, I, SrcReg, KillSrc, Subtarget);
return;
} else if (DestReg == ARM::VPR) {
- assert(ARM::GPRPairRegClass.contains(SrcReg));
+ assert(ARM::GPRRegClass.contains(SrcReg));
BuildMI(MBB, I, I->getDebugLoc(), get(ARM::VMSR_P0), DestReg)
.addReg(SrcReg, getKillRegState(KillSrc))
.add(predOps(ARMCC::AL));
return;
} else if (SrcReg == ARM::VPR) {
- assert(ARM::GPRPairRegClass.contains(DestReg));
+ assert(ARM::GPRRegClass.contains(DestReg));
BuildMI(MBB, I, I->getDebugLoc(), get(ARM::VMRS_P0), DestReg)
.addReg(SrcReg, getKillRegState(KillSrc))
.add(predOps(ARMCC::AL));
return;
} else if (DestReg == ARM::FPSCR_NZCV) {
- assert(ARM::GPRPairRegClass.contains(SrcReg));
+ assert(ARM::GPRRegClass.contains(SrcReg));
BuildMI(MBB, I, I->getDebugLoc(), get(ARM::VMSR_FPSCR_NZCVQC), DestReg)
.addReg(SrcReg, getKillRegState(KillSrc))
.add(predOps(ARMCC::AL));
return;
} else if (SrcReg == ARM::FPSCR_NZCV) {
- assert(ARM::GPRPairRegClass.contains(DestReg));
+ assert(ARM::GPRRegClass.contains(DestReg));
BuildMI(MBB, I, I->getDebugLoc(), get(ARM::VMRS_FPSCR_NZCVQC), DestReg)
.addReg(SrcReg, getKillRegState(KillSrc))
.add(predOps(ARMCC::AL));
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D63865.206807.patch
Type: text/x-patch
Size: 1529 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190627/e1ad1c3d/attachment.bin>
More information about the llvm-commits
mailing list