private:
static const unsigned MaxNumRegsForArgsRet = 16;
- bool shouldReturnTypeInRegister(QualType Ty,
- ASTContext &Context) const;
unsigned numRegsForType(QualType Ty) const;
bool isHomogeneousAggregateBaseType(QualType Ty) const override;
return Members * NumRegs <= MaxNumRegsForArgsRet;
}
-/// Check whether the type is small enough to consider passing directly in
-/// registers.
-bool AMDGPUABIInfo::shouldReturnTypeInRegister(QualType Ty,
- ASTContext &Ctx) const {
- return ((Ctx.getTypeSize(Ty) + 31) / 32) <= MaxNumRegsForArgsRet;
-}
-
/// Estimate number of registers the type will use when passed in registers.
unsigned AMDGPUABIInfo::numRegsForType(QualType Ty) const {
unsigned NumRegs = 0;