Unbreak the stuff, this is ugly, but we cannot do better for now with 'plain' C calling conv.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78232 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Anton Korobeynikov 2009-08-05 19:40:16 +00:00
parent f49a23d7a7
commit 14d9495403

View File

@ -1460,13 +1460,12 @@ ARMTargetLowering::LowerFormalArguments(SDValue Chain,
} else {
TargetRegisterClass *RC;
bool IsHardFloatCC = (CallConv == CallingConv::ARM_AAPCS_VFP);
if (IsHardFloatCC && RegVT == MVT::f32)
if (FloatABIType == FloatABI::Hard && RegVT == MVT::f32)
RC = ARM::SPRRegisterClass;
else if (IsHardFloatCC && RegVT == MVT::f64)
else if (FloatABIType == FloatABI::Hard && RegVT == MVT::f64)
RC = ARM::DPRRegisterClass;
else if (IsHardFloatCC && RegVT == MVT::v2f64)
else if (FloatABIType == FloatABI::Hard && RegVT == MVT::v2f64)
RC = ARM::QPRRegisterClass;
else if (AFI->isThumb1OnlyFunction())
RC = ARM::tGPRRegisterClass;
@ -1474,7 +1473,7 @@ ARMTargetLowering::LowerFormalArguments(SDValue Chain,
RC = ARM::GPRRegisterClass;
assert((RegVT == MVT::i32 || RegVT == MVT::f32 ||
(IsHardFloatCC &&
(FloatABIType == FloatABI::Hard &&
((RegVT == MVT::f64) || (RegVT == MVT::v2f64)))) &&
"RegVT not supported by FORMAL_ARGUMENTS Lowering");