LLVM
8.0.1
|
#include "Target/SystemZ/SystemZTargetTransformInfo.h"
Additional Inherited Members | |
Protected Types inherited from llvm::TargetTransformInfoImplBase | |
typedef TargetTransformInfo | TTI |
Protected Member Functions inherited from llvm::BasicTTIImplBase< SystemZTTIImpl > | |
BasicTTIImplBase (const TargetMachine *TM, const DataLayout &DL) | |
Protected Member Functions inherited from llvm::TargetTransformInfoImplCRTPBase< SystemZTTIImpl > | |
TargetTransformInfoImplCRTPBase (const DataLayout &DL) | |
Protected Member Functions inherited from llvm::TargetTransformInfoImplBase | |
TargetTransformInfoImplBase (const DataLayout &DL) | |
unsigned | minRequiredElementSize (const Value *Val, bool &isSigned) |
bool | isStridedAccess (const SCEV *Ptr) |
const SCEVConstant * | getConstantStrideStep (ScalarEvolution *SE, const SCEV *Ptr) |
bool | isConstantStridedAccessLessThan (ScalarEvolution *SE, const SCEV *Ptr, int64_t MergeDistance) |
Protected Attributes inherited from llvm::TargetTransformInfoImplBase | |
const DataLayout & | DL |
Definition at line 19 of file SystemZTargetTransformInfo.h.
|
inlineexplicit |
Definition at line 33 of file SystemZTargetTransformInfo.h.
|
inline |
Definition at line 71 of file SystemZTargetTransformInfo.h.
References llvm::AMDGPU::HSAMD::Kernel::Key::Args, getArithmeticInstrCost(), getBoolVecToIntConversionCost(), getCastInstrCost(), getCmpSelInstrCost(), getInterleavedMemoryOpCost(), getIntrinsicInstrCost(), getMemoryOpCost(), getShuffleCost(), getVectorBitmaskConversionCost(), getVectorInstrCost(), getVectorTruncCost(), I, isFoldableLoad(), Kind, llvm::TargetTransformInfo::OK_AnyValue, and llvm::TargetTransformInfo::OP_None.
int SystemZTTIImpl::getArithmeticInstrCost | ( | unsigned | Opcode, |
Type * | Ty, | ||
TTI::OperandValueKind | Opd1Info = TTI::OK_AnyValue , |
||
TTI::OperandValueKind | Opd2Info = TTI::OK_AnyValue , |
||
TTI::OperandValueProperties | Opd1PropInfo = TTI::OP_None , |
||
TTI::OperandValueProperties | Opd2PropInfo = TTI::OP_None , |
||
ArrayRef< const Value *> | Args = ArrayRef<const Value *>() |
||
) |
Definition at line 350 of file SystemZTargetTransformInfo.cpp.
References assert(), C, llvm::BasicTTIImplBase< SystemZTTIImpl >::getArithmeticInstrCost(), getNumVectorRegs(), llvm::BasicTTIImplBase< SystemZTTIImpl >::getScalarizationOverhead(), llvm::Type::getScalarSizeInBits(), llvm::Type::getScalarType(), llvm::Value::getType(), llvm::ConstantInt::getValue(), llvm::Type::getVectorNumElements(), llvm::SystemZSubtarget::hasLoadStoreOnCond2(), llvm::SystemZSubtarget::hasVector(), llvm::SystemZSubtarget::hasVectorEnhancements1(), llvm::APInt::isPowerOf2(), llvm::Type::isVectorTy(), and llvm::ArrayRef< T >::size().
Referenced by enableInterleavedAccessVectorization().
unsigned SystemZTTIImpl::getBoolVecToIntConversionCost | ( | unsigned | Opcode, |
Type * | Dst, | ||
const Instruction * | I | ||
) |
Definition at line 634 of file SystemZTargetTransformInfo.cpp.
References assert(), getCmpOpsType(), getNumVectorRegs(), getVectorBitmaskConversionCost(), llvm::Type::getVectorNumElements(), and llvm::Type::isVectorTy().
Referenced by enableInterleavedAccessVectorization(), getCastInstrCost(), and getCmpOpsType().
|
inline |
Definition at line 63 of file SystemZTargetTransformInfo.h.
int SystemZTTIImpl::getCastInstrCost | ( | unsigned | Opcode, |
Type * | Dst, | ||
Type * | Src, | ||
const Instruction * | I = nullptr |
||
) |
Definition at line 650 of file SystemZTargetTransformInfo.cpp.
References assert(), getBoolVecToIntConversionCost(), llvm::BasicTTIImplBase< SystemZTTIImpl >::getCastInstrCost(), getCmpOpsType(), getElSizeLog2Diff(), getNumVectorRegs(), llvm::User::getOperand(), llvm::BasicTTIImplBase< SystemZTTIImpl >::getScalarizationOverhead(), llvm::Type::getScalarSizeInBits(), llvm::Type::getScalarType(), llvm::Type::getVectorNumElements(), getVectorTruncCost(), llvm::SystemZSubtarget::hasLoadStoreOnCond2(), llvm::SystemZSubtarget::hasVector(), llvm::Type::isFloatingPointTy(), llvm::Type::isIntegerTy(), llvm::Type::isVectorTy(), and llvm::max().
Referenced by enableInterleavedAccessVectorization().
int SystemZTTIImpl::getCmpSelInstrCost | ( | unsigned | Opcode, |
Type * | ValTy, | ||
Type * | CondTy, | ||
const Instruction * | I = nullptr |
||
) |
Definition at line 787 of file SystemZTargetTransformInfo.cpp.
References assert(), C, getCmpOpsType(), llvm::BasicTTIImplBase< SystemZTTIImpl >::getCmpSelInstrCost(), getNumVectorRegs(), llvm::User::getOperand(), getOperandsExtensionCost(), llvm::Instruction::getParent(), llvm::PPC::getPredicate(), llvm::Type::getScalarSizeInBits(), llvm::Type::getScalarType(), getVectorBitmaskConversionCost(), getVectorInstrCost(), llvm::Type::getVectorNumElements(), llvm::SystemZSubtarget::hasVector(), llvm::Type::isFloatingPointTy(), llvm::Type::isFloatTy(), llvm::Type::isIntegerTy(), llvm::Type::isVectorTy(), and llvm::MCID::Select.
Referenced by enableInterleavedAccessVectorization().
|
inline |
Definition at line 40 of file SystemZTargetTransformInfo.h.
References getIntImmCost(), getNumberOfRegisters(), getPopcntSupport(), getRegisterBitWidth(), getUnrollingPreferences(), and isLSRCostLess().
int SystemZTTIImpl::getInterleavedMemoryOpCost | ( | unsigned | Opcode, |
Type * | VecTy, | ||
unsigned | Factor, | ||
ArrayRef< unsigned > | Indices, | ||
unsigned | Alignment, | ||
unsigned | AddressSpace, | ||
bool | UseMaskForCond = false , |
||
bool | UseMaskForGaps = false |
||
) |
Definition at line 1040 of file SystemZTargetTransformInfo.cpp.
References assert(), B, llvm::Intrinsic::ceil, llvm::BitVector::count(), llvm::BasicTTIImplBase< SystemZTTIImpl >::getInterleavedMemoryOpCost(), getNumVectorRegs(), getScalarSizeInBits(), llvm::Type::getVectorNumElements(), llvm::SPII::Load, llvm::max(), and llvm::BitVector::set().
Referenced by enableInterleavedAccessVectorization().
Definition at line 34 of file SystemZTargetTransformInfo.cpp.
References assert(), llvm::APInt::getBitWidth(), llvm::Type::getPrimitiveSizeInBits(), llvm::APInt::getSExtValue(), llvm::APInt::getZExtValue(), llvm::isInt< 32 >(), llvm::Type::isIntegerTy(), llvm::isUInt< 32 >(), llvm::TargetTransformInfo::TCC_Basic, and llvm::TargetTransformInfo::TCC_Free.
Referenced by getInliningThresholdMultiplier(), and getIntImmCost().
Definition at line 66 of file SystemZTargetTransformInfo.cpp.
References llvm::MCID::Add, assert(), llvm::APInt::getBitWidth(), llvm::SystemZSubtarget::getInstrInfo(), llvm::Type::getPrimitiveSizeInBits(), llvm::APInt::getSExtValue(), llvm::APInt::getZExtValue(), llvm::isInt< 16 >(), llvm::isInt< 32 >(), llvm::Type::isIntegerTy(), llvm::isUInt< 32 >(), llvm::SPII::Store, llvm::TargetTransformInfo::TCC_Basic, llvm::TargetTransformInfo::TCC_Free, and TII.
int SystemZTTIImpl::getIntImmCost | ( | Intrinsic::ID | IID, |
unsigned | Idx, | ||
const APInt & | Imm, | ||
Type * | Ty | ||
) |
Definition at line 184 of file SystemZTargetTransformInfo.cpp.
References assert(), llvm::Intrinsic::experimental_patchpoint_i64, llvm::Intrinsic::experimental_patchpoint_void, llvm::Intrinsic::experimental_stackmap, llvm::APInt::getBitWidth(), getIntImmCost(), llvm::Type::getPrimitiveSizeInBits(), llvm::APInt::getSExtValue(), llvm::APInt::getZExtValue(), llvm::isInt< 32 >(), llvm::Type::isIntegerTy(), llvm::isUInt< 32 >(), llvm::Intrinsic::sadd_with_overflow, llvm::Intrinsic::smul_with_overflow, llvm::Intrinsic::ssub_with_overflow, llvm::TargetTransformInfo::TCC_Free, llvm::Intrinsic::uadd_with_overflow, llvm::Intrinsic::umul_with_overflow, and llvm::Intrinsic::usub_with_overflow.
int SystemZTTIImpl::getIntrinsicInstrCost | ( | Intrinsic::ID | ID, |
Type * | RetTy, | ||
ArrayRef< Value *> | Args, | ||
FastMathFlags | FMF, | ||
unsigned | VF = 1 |
||
) |
Definition at line 1107 of file SystemZTargetTransformInfo.cpp.
References llvm::BasicTTIImplBase< SystemZTTIImpl >::getIntrinsicInstrCost(), and getVectorIntrinsicInstrCost().
Referenced by enableInterleavedAccessVectorization().
int SystemZTTIImpl::getIntrinsicInstrCost | ( | Intrinsic::ID | ID, |
Type * | RetTy, | ||
ArrayRef< Type *> | Tys, | ||
FastMathFlags | FMF, | ||
unsigned | ScalarizationCostPassed = UINT_MAX |
||
) |
Definition at line 1116 of file SystemZTargetTransformInfo.cpp.
References llvm::BasicTTIImplBase< SystemZTTIImpl >::getIntrinsicInstrCost(), and getVectorIntrinsicInstrCost().
int SystemZTTIImpl::getMemoryOpCost | ( | unsigned | Opcode, |
Type * | Src, | ||
unsigned | Alignment, | ||
unsigned | AddressSpace, | ||
const Instruction * | I = nullptr |
||
) |
Definition at line 976 of file SystemZTargetTransformInfo.cpp.
References assert(), llvm::dyn_cast(), llvm::BasicTTIImplBase< SystemZTTIImpl >::getNumberOfParts(), llvm::User::getNumOperands(), getNumVectorRegs(), llvm::User::getOperand(), llvm::Type::getScalarSizeInBits(), llvm::Value::hasOneUse(), isBswapIntrinsicCall(), isFoldableLoad(), llvm::Type::isVectorTy(), llvm::Type::isVoidTy(), llvm::SPII::Load, SI, and llvm::Value::user_begin().
Referenced by enableInterleavedAccessVectorization(), and getUnrollingPreferences().
|
inline |
Definition at line 65 of file SystemZTargetTransformInfo.h.
References hasDivRemOp().
Definition at line 308 of file SystemZTargetTransformInfo.cpp.
References llvm::SystemZSubtarget::hasVector().
Referenced by getInliningThresholdMultiplier().
TargetTransformInfo::PopcntSupportKind SystemZTTIImpl::getPopcntSupport | ( | unsigned | TyWidth | ) |
Definition at line 234 of file SystemZTargetTransformInfo.cpp.
References assert(), llvm::SystemZSubtarget::hasPopulationCount(), llvm::isPowerOf2_32(), llvm::TargetTransformInfo::PSK_FastHardware, and llvm::TargetTransformInfo::PSK_Software.
Referenced by getInliningThresholdMultiplier().
|
inline |
Definition at line 64 of file SystemZTargetTransformInfo.h.
Definition at line 318 of file SystemZTargetTransformInfo.cpp.
References llvm::SystemZSubtarget::hasVector().
Referenced by getInliningThresholdMultiplier().
int SystemZTTIImpl::getShuffleCost | ( | TTI::ShuffleKind | Kind, |
Type * | Tp, | ||
int | Index, | ||
Type * | SubTp | ||
) |
Definition at line 493 of file SystemZTargetTransformInfo.cpp.
References assert(), getNumVectorRegs(), llvm::Type::getScalarType(), llvm::BasicTTIImplBase< SystemZTTIImpl >::getShuffleCost(), llvm::SystemZSubtarget::hasVector(), llvm::Type::isFP128Ty(), llvm::Type::isVectorTy(), llvm::TargetTransformInfo::SK_Broadcast, and llvm::TargetTransformInfo::SK_ExtractSubvector.
Referenced by enableInterleavedAccessVectorization().
void SystemZTTIImpl::getUnrollingPreferences | ( | Loop * | L, |
ScalarEvolution & | SE, | ||
TTI::UnrollingPreferences & | UP | ||
) |
Definition at line 241 of file SystemZTargetTransformInfo.cpp.
References llvm::TargetTransformInfo::UnrollingPreferences::AllowExpensiveTripCount, llvm::LoopBase< BlockT, LoopT >::blocks(), llvm::TargetTransformInfo::UnrollingPreferences::DefaultUnrollRuntimeCount, F(), llvm::TargetTransformInfo::UnrollingPreferences::Force, llvm::TargetTransformInfo::UnrollingPreferences::FullUnrollMaxCount, llvm::CallSiteBase< FunTy, BBTy, ValTy, UserTy, UseTy, InstrTy, CallTy, InvokeTy, IterTy >::getCalledFunction(), getMemoryOpCost(), I, llvm::TargetTransformInfoImplBase::isLoweredToCall(), llvm::TargetTransformInfo::UnrollingPreferences::MaxCount, llvm::Intrinsic::memcpy, llvm::Intrinsic::memset, llvm::TargetTransformInfo::UnrollingPreferences::Partial, llvm::TargetTransformInfo::UnrollingPreferences::PartialThreshold, llvm::TargetTransformInfo::UnrollingPreferences::Runtime, and llvm::SPII::Store.
Referenced by getInliningThresholdMultiplier().
Definition at line 583 of file SystemZTargetTransformInfo.cpp.
References assert(), getElSizeLog2Diff(), getNumVectorRegs(), llvm::Type::getScalarSizeInBits(), getVectorTruncCost(), and llvm::Type::isVectorTy().
Referenced by enableInterleavedAccessVectorization(), getBoolVecToIntConversionCost(), getCmpSelInstrCost(), and getVectorTruncCost().
Definition at line 868 of file SystemZTargetTransformInfo.cpp.
References getScalarSizeInBits(), llvm::BasicTTIImplBase< SystemZTTIImpl >::getVectorInstrCost(), isFoldableLoad(), and llvm::Type::isIntOrIntVectorTy().
Referenced by enableInterleavedAccessVectorization(), and getCmpSelInstrCost().
Definition at line 543 of file SystemZTargetTransformInfo.cpp.
References assert(), getElSizeLog2Diff(), getNumVectorRegs(), llvm::Type::getPrimitiveSizeInBits(), llvm::Type::getScalarSizeInBits(), getVectorBitmaskConversionCost(), llvm::Type::getVectorNumElements(), llvm::Type::isVectorTy(), and P.
Referenced by enableInterleavedAccessVectorization(), getCastInstrCost(), getElSizeLog2Diff(), and getVectorBitmaskConversionCost().
Definition at line 326 of file SystemZTargetTransformInfo.cpp.
References llvm::TargetTransformInfoImplBase::DL, llvm::TargetLoweringBase::getValueType(), llvm::EVT::isScalarInteger(), and llvm::TargetLoweringBase::isTypeLegal().
Referenced by getMinPrefetchStride().
bool SystemZTTIImpl::isFoldableLoad | ( | const LoadInst * | Ld, |
const Instruction *& | FoldedValue | ||
) |
Definition at line 889 of file SystemZTargetTransformInfo.cpp.
References llvm::MCID::Add, llvm::Instruction::getOpcode(), llvm::User::getOperand(), llvm::Type::getScalarSizeInBits(), getScalarSizeInBits(), llvm::Value::getType(), llvm::SystemZSubtarget::hasMiscellaneousExtensions2(), llvm::Value::hasOneUse(), llvm::isUInt< 16 >(), LLVM_FALLTHROUGH, and llvm::Value::user_begin().
Referenced by enableInterleavedAccessVectorization(), getMemoryOpCost(), and getVectorInstrCost().
bool SystemZTTIImpl::isLSRCostLess | ( | TargetTransformInfo::LSRCost & | C1, |
TargetTransformInfo::LSRCost & | C2 | ||
) |
Definition at line 296 of file SystemZTargetTransformInfo.cpp.
References llvm::TargetTransformInfo::LSRCost::AddRecCost, llvm::TargetTransformInfo::LSRCost::Insns, llvm::TargetTransformInfo::LSRCost::NumBaseAdds, llvm::TargetTransformInfo::LSRCost::NumIVMuls, llvm::TargetTransformInfo::LSRCost::NumRegs, llvm::TargetTransformInfo::LSRCost::ScaleCost, and llvm::TargetTransformInfo::LSRCost::SetupCost.
Referenced by getInliningThresholdMultiplier().
|
inline |
Definition at line 69 of file SystemZTargetTransformInfo.h.
|
inline |
Definition at line 68 of file SystemZTargetTransformInfo.h.
|
inline |
Definition at line 70 of file SystemZTargetTransformInfo.h.