mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-23 01:24:30 +00:00
fix some warnings in release-asserts mode.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67738 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -182,8 +182,7 @@ copyRegToReg(MachineBasicBlock &MBB, MachineBasicBlock::iterator I,
|
|||||||
void MipsInstrInfo::
|
void MipsInstrInfo::
|
||||||
storeRegToStackSlot(MachineBasicBlock &MBB, MachineBasicBlock::iterator I,
|
storeRegToStackSlot(MachineBasicBlock &MBB, MachineBasicBlock::iterator I,
|
||||||
unsigned SrcReg, bool isKill, int FI,
|
unsigned SrcReg, bool isKill, int FI,
|
||||||
const TargetRegisterClass *RC) const
|
const TargetRegisterClass *RC) const {
|
||||||
{
|
|
||||||
unsigned Opc;
|
unsigned Opc;
|
||||||
|
|
||||||
DebugLoc DL = DebugLoc::getUnknownLoc();
|
DebugLoc DL = DebugLoc::getUnknownLoc();
|
||||||
@ -193,10 +192,10 @@ storeRegToStackSlot(MachineBasicBlock &MBB, MachineBasicBlock::iterator I,
|
|||||||
Opc = Mips::SW;
|
Opc = Mips::SW;
|
||||||
else if (RC == Mips::FGR32RegisterClass)
|
else if (RC == Mips::FGR32RegisterClass)
|
||||||
Opc = Mips::SWC1;
|
Opc = Mips::SWC1;
|
||||||
else if (RC == Mips::AFGR64RegisterClass)
|
else {
|
||||||
|
assert(RC == Mips::AFGR64RegisterClass);
|
||||||
Opc = Mips::SDC1;
|
Opc = Mips::SDC1;
|
||||||
else
|
}
|
||||||
assert(0 && "Can't store this register to stack slot");
|
|
||||||
|
|
||||||
BuildMI(MBB, I, DL, get(Opc)).addReg(SrcReg, false, false, isKill)
|
BuildMI(MBB, I, DL, get(Opc)).addReg(SrcReg, false, false, isKill)
|
||||||
.addImm(0).addFrameIndex(FI);
|
.addImm(0).addFrameIndex(FI);
|
||||||
@ -211,10 +210,10 @@ void MipsInstrInfo::storeRegToAddr(MachineFunction &MF, unsigned SrcReg,
|
|||||||
Opc = Mips::SW;
|
Opc = Mips::SW;
|
||||||
else if (RC == Mips::FGR32RegisterClass)
|
else if (RC == Mips::FGR32RegisterClass)
|
||||||
Opc = Mips::SWC1;
|
Opc = Mips::SWC1;
|
||||||
else if (RC == Mips::AFGR64RegisterClass)
|
else {
|
||||||
|
assert(RC == Mips::AFGR64RegisterClass);
|
||||||
Opc = Mips::SDC1;
|
Opc = Mips::SDC1;
|
||||||
else
|
}
|
||||||
assert(0 && "Can't store this register");
|
|
||||||
|
|
||||||
DebugLoc DL = DebugLoc::getUnknownLoc();
|
DebugLoc DL = DebugLoc::getUnknownLoc();
|
||||||
MachineInstrBuilder MIB = BuildMI(MF, DL, get(Opc))
|
MachineInstrBuilder MIB = BuildMI(MF, DL, get(Opc))
|
||||||
@ -235,10 +234,10 @@ loadRegFromStackSlot(MachineBasicBlock &MBB, MachineBasicBlock::iterator I,
|
|||||||
Opc = Mips::LW;
|
Opc = Mips::LW;
|
||||||
else if (RC == Mips::FGR32RegisterClass)
|
else if (RC == Mips::FGR32RegisterClass)
|
||||||
Opc = Mips::LWC1;
|
Opc = Mips::LWC1;
|
||||||
else if (RC == Mips::AFGR64RegisterClass)
|
else {
|
||||||
|
assert(RC == Mips::AFGR64RegisterClass);
|
||||||
Opc = Mips::LDC1;
|
Opc = Mips::LDC1;
|
||||||
else
|
}
|
||||||
assert(0 && "Can't load this register from stack slot");
|
|
||||||
|
|
||||||
DebugLoc DL = DebugLoc::getUnknownLoc();
|
DebugLoc DL = DebugLoc::getUnknownLoc();
|
||||||
if (I != MBB.end()) DL = I->getDebugLoc();
|
if (I != MBB.end()) DL = I->getDebugLoc();
|
||||||
@ -254,10 +253,10 @@ void MipsInstrInfo::loadRegFromAddr(MachineFunction &MF, unsigned DestReg,
|
|||||||
Opc = Mips::LW;
|
Opc = Mips::LW;
|
||||||
else if (RC == Mips::FGR32RegisterClass)
|
else if (RC == Mips::FGR32RegisterClass)
|
||||||
Opc = Mips::LWC1;
|
Opc = Mips::LWC1;
|
||||||
else if (RC == Mips::AFGR64RegisterClass)
|
else {
|
||||||
|
assert(RC == Mips::AFGR64RegisterClass);
|
||||||
Opc = Mips::LDC1;
|
Opc = Mips::LDC1;
|
||||||
else
|
}
|
||||||
assert(0 && "Can't load this register");
|
|
||||||
|
|
||||||
DebugLoc DL = DebugLoc::getUnknownLoc();
|
DebugLoc DL = DebugLoc::getUnknownLoc();
|
||||||
MachineInstrBuilder MIB = BuildMI(MF, DL, get(Opc), DestReg);
|
MachineInstrBuilder MIB = BuildMI(MF, DL, get(Opc), DestReg);
|
||||||
@ -307,10 +306,10 @@ foldMemoryOperandImpl(MachineFunction &MF,
|
|||||||
|
|
||||||
if (RC == Mips::FGR32RegisterClass) {
|
if (RC == Mips::FGR32RegisterClass) {
|
||||||
LoadOpc = Mips::LWC1; StoreOpc = Mips::SWC1;
|
LoadOpc = Mips::LWC1; StoreOpc = Mips::SWC1;
|
||||||
} else if (RC == Mips::AFGR64RegisterClass) {
|
} else {
|
||||||
|
assert(RC == Mips::AFGR64RegisterClass);
|
||||||
LoadOpc = Mips::LDC1; StoreOpc = Mips::SDC1;
|
LoadOpc = Mips::LDC1; StoreOpc = Mips::SDC1;
|
||||||
} else
|
}
|
||||||
assert(0 && "foldMemoryOperandImpl register unknown");
|
|
||||||
|
|
||||||
if (Ops[0] == 0) { // COPY -> STORE
|
if (Ops[0] == 0) { // COPY -> STORE
|
||||||
unsigned SrcReg = MI->getOperand(1).getReg();
|
unsigned SrcReg = MI->getOperand(1).getReg();
|
||||||
|
Reference in New Issue
Block a user