forked from OSchip/llvm-project
Fix build failures from r337347, found by clang
* Delete a no-longer-used override, and mark the other getRegisterTypeForCallingConv() as override. * SPE only supports i32, not i64, as the internal type, so simply remove the type check, so that DestReg and Opc are provably always set. GCC 6.4 did not warn about either of the above. llvm-svn: 337350
This commit is contained in:
parent
95063a45b8
commit
22e939a15b
|
@ -1223,13 +1223,11 @@ bool PPCFastISel::SelectFPToI(const Instruction *I, bool IsSigned) {
|
||||||
unsigned Opc;
|
unsigned Opc;
|
||||||
|
|
||||||
if (PPCSubTarget->hasSPE()) {
|
if (PPCSubTarget->hasSPE()) {
|
||||||
if (DstVT == MVT::i32) {
|
DestReg = createResultReg(&PPC::GPRCRegClass);
|
||||||
DestReg = createResultReg(&PPC::GPRCRegClass);
|
if (IsSigned)
|
||||||
if (IsSigned)
|
Opc = InRC == &PPC::SPE4RCRegClass ? PPC::EFSCTSIZ : PPC::EFDCTSIZ;
|
||||||
Opc = InRC == &PPC::SPE4RCRegClass ? PPC::EFSCTSIZ : PPC::EFDCTSIZ;
|
else
|
||||||
else
|
Opc = InRC == &PPC::SPE4RCRegClass ? PPC::EFSCTUIZ : PPC::EFDCTUIZ;
|
||||||
Opc = InRC == &PPC::SPE4RCRegClass ? PPC::EFSCTUIZ : PPC::EFDCTUIZ;
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
DestReg = createResultReg(&PPC::F8RCRegClass);
|
DestReg = createResultReg(&PPC::F8RCRegClass);
|
||||||
if (DstVT == MVT::i32)
|
if (DstVT == MVT::i32)
|
||||||
|
|
|
@ -1237,12 +1237,6 @@ MVT PPCTargetLowering::getRegisterTypeForCallingConv(LLVMContext &Context,
|
||||||
return PPCTargetLowering::getRegisterType(Context, VT);
|
return PPCTargetLowering::getRegisterType(Context, VT);
|
||||||
}
|
}
|
||||||
|
|
||||||
MVT PPCTargetLowering::getRegisterTypeForCallingConv(MVT VT) const {
|
|
||||||
if (Subtarget.hasSPE() && VT == MVT::f64)
|
|
||||||
return MVT::i32;
|
|
||||||
return PPCTargetLowering::getRegisterType(VT);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool PPCTargetLowering::useSoftFloat() const {
|
bool PPCTargetLowering::useSoftFloat() const {
|
||||||
return Subtarget.useSoftFloat();
|
return Subtarget.useSoftFloat();
|
||||||
}
|
}
|
||||||
|
|
|
@ -874,9 +874,8 @@ namespace llvm {
|
||||||
unsigned getNumRegistersForCallingConv(LLVMContext &Context,
|
unsigned getNumRegistersForCallingConv(LLVMContext &Context,
|
||||||
EVT VT) const override;
|
EVT VT) const override;
|
||||||
|
|
||||||
MVT getRegisterTypeForCallingConv(MVT VT) const;
|
|
||||||
MVT getRegisterTypeForCallingConv(LLVMContext &Context,
|
MVT getRegisterTypeForCallingConv(LLVMContext &Context,
|
||||||
EVT VT) const;
|
EVT VT) const override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
struct ReuseLoadInfo {
|
struct ReuseLoadInfo {
|
||||||
|
|
Loading…
Reference in New Issue