diff options
Diffstat (limited to 'llvm/include')
-rw-r--r-- | llvm/include/llvm-c/Transforms/Scalar.h | 3 | ||||
-rw-r--r-- | llvm/include/llvm/Analysis/TargetTransformInfo.h | 7 | ||||
-rw-r--r-- | llvm/include/llvm/InitializePasses.h | 1 | ||||
-rw-r--r-- | llvm/include/llvm/LinkAllPasses.h | 1 | ||||
-rw-r--r-- | llvm/include/llvm/Transforms/Scalar.h | 6 | ||||
-rw-r--r-- | llvm/include/llvm/Transforms/Scalar/LoopUnrollAndJamPass.h | 35 | ||||
-rw-r--r-- | llvm/include/llvm/Transforms/Utils/UnrollLoop.h | 41 |
7 files changed, 0 insertions, 94 deletions
diff --git a/llvm/include/llvm-c/Transforms/Scalar.h b/llvm/include/llvm-c/Transforms/Scalar.h index f55cdce86be..88fff2a8ad4 100644 --- a/llvm/include/llvm-c/Transforms/Scalar.h +++ b/llvm/include/llvm-c/Transforms/Scalar.h @@ -89,9 +89,6 @@ void LLVMAddLoopRerollPass(LLVMPassManagerRef PM); /** See llvm::createLoopUnrollPass function. */ void LLVMAddLoopUnrollPass(LLVMPassManagerRef PM); -/** See llvm::createLoopUnrollAndJamPass function. */ -void LLVMAddLoopUnrollAndJamPass(LLVMPassManagerRef PM); - /** See llvm::createLoopUnswitchPass function. */ void LLVMAddLoopUnswitchPass(LLVMPassManagerRef PM); diff --git a/llvm/include/llvm/Analysis/TargetTransformInfo.h b/llvm/include/llvm/Analysis/TargetTransformInfo.h index 139264ac50e..913d1744ea8 100644 --- a/llvm/include/llvm/Analysis/TargetTransformInfo.h +++ b/llvm/include/llvm/Analysis/TargetTransformInfo.h @@ -422,13 +422,6 @@ public: bool AllowPeeling; /// Allow unrolling of all the iterations of the runtime loop remainder. bool UnrollRemainder; - /// Allow unroll and jam. Used to enable unroll and jam for the target. - bool UnrollAndJam; - /// Threshold for unroll and jam, for inner loop size. The 'Threshold' - /// value above is used during unroll and jam for the outer loop size. - /// This value is used in the same manner to limit the size of the inner - /// loop. - unsigned UnrollAndJamInnerLoopThreshold; }; /// Get target-customized preferences for the generic loop unrolling diff --git a/llvm/include/llvm/InitializePasses.h b/llvm/include/llvm/InitializePasses.h index f57a018660d..a4f2dae9540 100644 --- a/llvm/include/llvm/InitializePasses.h +++ b/llvm/include/llvm/InitializePasses.h @@ -226,7 +226,6 @@ void initializeLoopSimplifyCFGLegacyPassPass(PassRegistry&); void initializeLoopSimplifyPass(PassRegistry&); void initializeLoopStrengthReducePass(PassRegistry&); void initializeLoopUnrollPass(PassRegistry&); -void initializeLoopUnrollAndJamPass(PassRegistry&); void initializeLoopUnswitchPass(PassRegistry&); void initializeLoopVectorizePass(PassRegistry&); void initializeLoopVersioningLICMPass(PassRegistry&); diff --git a/llvm/include/llvm/LinkAllPasses.h b/llvm/include/llvm/LinkAllPasses.h index c5d95a1ebc4..a49c4aad865 100644 --- a/llvm/include/llvm/LinkAllPasses.h +++ b/llvm/include/llvm/LinkAllPasses.h @@ -130,7 +130,6 @@ namespace { (void) llvm::createLoopStrengthReducePass(); (void) llvm::createLoopRerollPass(); (void) llvm::createLoopUnrollPass(); - (void) llvm::createLoopUnrollAndJamPass(); (void) llvm::createLoopUnswitchPass(); (void) llvm::createLoopVersioningLICMPass(); (void) llvm::createLoopIdiomPass(); diff --git a/llvm/include/llvm/Transforms/Scalar.h b/llvm/include/llvm/Transforms/Scalar.h index 9491e1bbac9..317cc37d22f 100644 --- a/llvm/include/llvm/Transforms/Scalar.h +++ b/llvm/include/llvm/Transforms/Scalar.h @@ -192,12 +192,6 @@ Pass *createSimpleLoopUnrollPass(int OptLevel = 2); //===----------------------------------------------------------------------===// // -// LoopUnrollAndJam - This pass is a simple loop unroll and jam pass. -// -Pass *createLoopUnrollAndJamPass(int OptLevel = 2); - -//===----------------------------------------------------------------------===// -// // LoopReroll - This pass is a simple loop rerolling pass. // Pass *createLoopRerollPass(); diff --git a/llvm/include/llvm/Transforms/Scalar/LoopUnrollAndJamPass.h b/llvm/include/llvm/Transforms/Scalar/LoopUnrollAndJamPass.h deleted file mode 100644 index fc69aa36105..00000000000 --- a/llvm/include/llvm/Transforms/Scalar/LoopUnrollAndJamPass.h +++ /dev/null @@ -1,35 +0,0 @@ -//===- LoopUnrollAndJamPass.h -----------------------------------*- C++ -*-===// -// -// The LLVM Compiler Infrastructure -// -// This file is distributed under the University of Illinois Open Source -// License. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -#ifndef LLVM_TRANSFORMS_SCALAR_LOOPUNROLLANDJAMPASS_H -#define LLVM_TRANSFORMS_SCALAR_LOOPUNROLLANDJAMPASS_H - -#include "llvm/Analysis/LoopAnalysisManager.h" -#include "llvm/Analysis/LoopInfo.h" -#include "llvm/IR/PassManager.h" - -namespace llvm { - -class Loop; -struct LoopStandardAnalysisResults; -class LPMUpdater; - -/// A simple loop rotation transformation. -class LoopUnrollAndJamPass : public PassInfoMixin<LoopUnrollAndJamPass> { - const int OptLevel; - -public: - explicit LoopUnrollAndJamPass(int OptLevel = 2) : OptLevel(OptLevel) {} - PreservedAnalyses run(Loop &L, LoopAnalysisManager &AM, - LoopStandardAnalysisResults &AR, LPMUpdater &U); -}; - -} // end namespace llvm - -#endif // LLVM_TRANSFORMS_SCALAR_LOOPUNROLLANDJAMPASS_H diff --git a/llvm/include/llvm/Transforms/Utils/UnrollLoop.h b/llvm/include/llvm/Transforms/Utils/UnrollLoop.h index a6b84af068a..d96c65804d8 100644 --- a/llvm/include/llvm/Transforms/Utils/UnrollLoop.h +++ b/llvm/include/llvm/Transforms/Utils/UnrollLoop.h @@ -19,13 +19,11 @@ #include "llvm/ADT/DenseMap.h" #include "llvm/ADT/StringRef.h" #include "llvm/Analysis/TargetTransformInfo.h" -#include "llvm/Transforms/Utils/ValueMapper.h" namespace llvm { class AssumptionCache; class BasicBlock; -class DependenceInfo; class DominatorTree; class Loop; class LoopInfo; @@ -80,47 +78,8 @@ bool canPeel(Loop *L); bool peelLoop(Loop *L, unsigned PeelCount, LoopInfo *LI, ScalarEvolution *SE, DominatorTree *DT, AssumptionCache *AC, bool PreserveLCSSA); -LoopUnrollResult UnrollAndJamLoop(Loop *L, unsigned Count, unsigned TripCount, - unsigned TripMultiple, bool UnrollRemainder, - LoopInfo *LI, ScalarEvolution *SE, - DominatorTree *DT, AssumptionCache *AC, - OptimizationRemarkEmitter *ORE); - -bool isSafeToUnrollAndJam(Loop *L, ScalarEvolution &SE, DominatorTree &DT, - DependenceInfo &DI); - -bool computeUnrollCount(Loop *L, const TargetTransformInfo &TTI, - DominatorTree &DT, LoopInfo *LI, ScalarEvolution &SE, - const SmallPtrSetImpl<const Value *> &EphValues, - OptimizationRemarkEmitter *ORE, unsigned &TripCount, - unsigned MaxTripCount, unsigned &TripMultiple, - unsigned LoopSize, - TargetTransformInfo::UnrollingPreferences &UP, - bool &UseUpperBound); - -BasicBlock *foldBlockIntoPredecessor(BasicBlock *BB, LoopInfo *LI, - ScalarEvolution *SE, DominatorTree *DT); - -void remapInstruction(Instruction *I, ValueToValueMapTy &VMap); - -void simplifyLoopAfterUnroll(Loop *L, bool SimplifyIVs, LoopInfo *LI, - ScalarEvolution *SE, DominatorTree *DT, - AssumptionCache *AC); - MDNode *GetUnrollMetadata(MDNode *LoopID, StringRef Name); -TargetTransformInfo::UnrollingPreferences gatherUnrollingPreferences( - Loop *L, ScalarEvolution &SE, const TargetTransformInfo &TTI, int OptLevel, - Optional<unsigned> UserThreshold, Optional<unsigned> UserCount, - Optional<bool> UserAllowPartial, Optional<bool> UserRuntime, - Optional<bool> UserUpperBound, Optional<bool> UserAllowPeeling); - -unsigned ApproximateLoopSize(const Loop *L, unsigned &NumCalls, - bool &NotDuplicatable, bool &Convergent, - const TargetTransformInfo &TTI, - const SmallPtrSetImpl<const Value *> &EphValues, - unsigned BEInsns); - } // end namespace llvm #endif // LLVM_TRANSFORMS_UTILS_UNROLLLOOP_H |