diff options
author | Chandler Carruth <chandlerc@gmail.com> | 2015-02-01 14:31:23 +0000 |
---|---|---|
committer | Chandler Carruth <chandlerc@gmail.com> | 2015-02-01 14:31:23 +0000 |
commit | ab5cb36c401cd31c7e3cb57d7affc0efff3c61fb (patch) | |
tree | 3d08d8b8d921c4a58f39196c5b537900ea1aa194 /llvm/lib | |
parent | c956ab66037e3b0e6b3a039728348de1db1c4ad6 (diff) | |
download | llvm-ab5cb36c401cd31c7e3cb57d7affc0efff3c61fb.zip llvm-ab5cb36c401cd31c7e3cb57d7affc0efff3c61fb.tar.gz llvm-ab5cb36c401cd31c7e3cb57d7affc0efff3c61fb.tar.bz2 |
[multiversion] Remove the function parameter from the unrolling
preferences interface on TTI now that all of TTI is per-function.
llvm-svn: 227741
Diffstat (limited to 'llvm/lib')
7 files changed, 9 insertions, 12 deletions
diff --git a/llvm/lib/Analysis/TargetTransformInfo.cpp b/llvm/lib/Analysis/TargetTransformInfo.cpp index d51cfb3..5a50d36 100644 --- a/llvm/lib/Analysis/TargetTransformInfo.cpp +++ b/llvm/lib/Analysis/TargetTransformInfo.cpp @@ -81,8 +81,8 @@ bool TargetTransformInfo::isLoweredToCall(const Function *F) const { } void TargetTransformInfo::getUnrollingPreferences( - const Function *F, Loop *L, UnrollingPreferences &UP) const { - return TTIImpl->getUnrollingPreferences(F, L, UP); + Loop *L, UnrollingPreferences &UP) const { + return TTIImpl->getUnrollingPreferences(L, UP); } bool TargetTransformInfo::isLegalAddImmediate(int64_t Imm) const { diff --git a/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp b/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp index eab080b..0646d85 100644 --- a/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp +++ b/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp @@ -424,7 +424,7 @@ unsigned AArch64TTIImpl::getMaxInterleaveFactor() { return 2; } -void AArch64TTIImpl::getUnrollingPreferences(const Function *F, Loop *L, +void AArch64TTIImpl::getUnrollingPreferences(Loop *L, TTI::UnrollingPreferences &UP) { // Disable partial & runtime unrolling on -Os. UP.PartialOptSizeThreshold = 0; diff --git a/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.h b/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.h index fffeb98..dd3fd1f 100644 --- a/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.h +++ b/llvm/lib/Target/AArch64/AArch64TargetTransformInfo.h @@ -132,8 +132,7 @@ public: unsigned getCostOfKeepingLiveOverCall(ArrayRef<Type *> Tys); - void getUnrollingPreferences(const Function *F, Loop *L, - TTI::UnrollingPreferences &UP); + void getUnrollingPreferences(Loop *L, TTI::UnrollingPreferences &UP); Value *getOrCreateResultFromMemIntrinsic(IntrinsicInst *Inst, Type *ExpectedType); diff --git a/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp b/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp index 98fe5cd..4003b1b 100644 --- a/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp +++ b/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.cpp @@ -181,7 +181,7 @@ unsigned PPCTTIImpl::getIntImmCost(unsigned Opcode, unsigned Idx, return PPCTTIImpl::getIntImmCost(Imm, Ty); } -void PPCTTIImpl::getUnrollingPreferences(const Function *F, Loop *L, +void PPCTTIImpl::getUnrollingPreferences(Loop *L, TTI::UnrollingPreferences &UP) { if (ST->getDarwinDirective() == PPC::DIR_A2) { // The A2 is in-order with a deep pipeline, and concatenation unrolling @@ -189,7 +189,7 @@ void PPCTTIImpl::getUnrollingPreferences(const Function *F, Loop *L, UP.Partial = UP.Runtime = true; } - BaseT::getUnrollingPreferences(F, L, UP); + BaseT::getUnrollingPreferences(L, UP); } unsigned PPCTTIImpl::getNumberOfRegisters(bool Vector) { diff --git a/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.h b/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.h index 0429a26..cef7079 100644 --- a/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.h +++ b/llvm/lib/Target/PowerPC/PPCTargetTransformInfo.h @@ -71,8 +71,7 @@ public: Type *Ty); TTI::PopcntSupportKind getPopcntSupport(unsigned TyWidth); - void getUnrollingPreferences(const Function *F, Loop *L, - TTI::UnrollingPreferences &UP); + void getUnrollingPreferences(Loop *L, TTI::UnrollingPreferences &UP); /// @} diff --git a/llvm/lib/Target/R600/AMDGPUTargetTransformInfo.cpp b/llvm/lib/Target/R600/AMDGPUTargetTransformInfo.cpp index be7b2f4..4647ddf 100644 --- a/llvm/lib/Target/R600/AMDGPUTargetTransformInfo.cpp +++ b/llvm/lib/Target/R600/AMDGPUTargetTransformInfo.cpp @@ -27,7 +27,7 @@ using namespace llvm; #define DEBUG_TYPE "AMDGPUtti" -void AMDGPUTTIImpl::getUnrollingPreferences(const Function *, Loop *L, +void AMDGPUTTIImpl::getUnrollingPreferences(Loop *L, TTI::UnrollingPreferences &UP) { UP.Threshold = 300; // Twice the default. UP.Count = UINT_MAX; diff --git a/llvm/lib/Target/R600/AMDGPUTargetTransformInfo.h b/llvm/lib/Target/R600/AMDGPUTargetTransformInfo.h index 4c41033..4abbdf2 100644 --- a/llvm/lib/Target/R600/AMDGPUTargetTransformInfo.h +++ b/llvm/lib/Target/R600/AMDGPUTargetTransformInfo.h @@ -61,8 +61,7 @@ public: bool hasBranchDivergence() { return true; } - void getUnrollingPreferences(const Function *F, Loop *L, - TTI::UnrollingPreferences &UP); + void getUnrollingPreferences(Loop *L, TTI::UnrollingPreferences &UP); TTI::PopcntSupportKind getPopcntSupport(unsigned TyWidth) { assert(isPowerOf2_32(TyWidth) && "Ty width must be power of 2"); |