X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=include%2Fllvm%2FTransforms%2FScalar.h;h=e89759a0976195acfc669790a04c624bea632be7;hb=fef8b70f9d40e57fdd2e0c2bdf013cb7d0ea6df2;hp=fa848459a766b1d8dcfaff67d222bc67b77a3e8f;hpb=d82e9e7d939bb4b4f4773e9853c061e14188f705;p=oota-llvm.git diff --git a/include/llvm/Transforms/Scalar.h b/include/llvm/Transforms/Scalar.h index fa848459a76..e89759a0976 100644 --- a/include/llvm/Transforms/Scalar.h +++ b/include/llvm/Transforms/Scalar.h @@ -68,12 +68,22 @@ FunctionPass *createDeadStoreEliminationPass(); // FunctionPass *createAggressiveDCEPass(); +//===----------------------------------------------------------------------===// +// +// SROA - Replace aggregates or pieces of aggregates with scalar SSA values. +// +FunctionPass *createSROAPass(bool RequiresDomTree = true); + //===----------------------------------------------------------------------===// // // ScalarReplAggregates - Break up alloca's of aggregates into multiple allocas // if possible. // -FunctionPass *createScalarReplAggregatesPass(signed Threshold = -1); +FunctionPass *createScalarReplAggregatesPass(signed Threshold = -1, + bool UseDomTree = true, + signed StructMemberThreshold = -1, + signed ArrayElementThreshold = -1, + signed ScalarLoadThreshold = -1); //===----------------------------------------------------------------------===// // @@ -105,11 +115,11 @@ Pass *createLICMPass(); //===----------------------------------------------------------------------===// // // LoopStrengthReduce - This pass is strength reduces GEP instructions that use -// a loop's canonical induction variable as one of their indices. It takes an -// optional parameter used to consult the target machine whether certain -// transformations are profitable. +// a loop's canonical induction variable as one of their indices. // -Pass *createLoopStrengthReducePass(const TargetLowering *TLI = 0); +Pass *createLoopStrengthReducePass(); + +Pass *createGlobalMergePass(const TargetLowering *TLI = 0); //===----------------------------------------------------------------------===// // @@ -117,11 +127,17 @@ Pass *createLoopStrengthReducePass(const TargetLowering *TLI = 0); // Pass *createLoopUnswitchPass(bool OptimizeForSize = false); +//===----------------------------------------------------------------------===// +// +// LoopInstSimplify - This pass simplifies instructions in a loop's body. +// +Pass *createLoopInstSimplifyPass(); + //===----------------------------------------------------------------------===// // // LoopUnroll - This pass is a simple loop unrolling pass. // -Pass *createLoopUnrollPass(); +Pass *createLoopUnrollPass(int Threshold = -1, int Count = -1, int AllowPartial = -1); //===----------------------------------------------------------------------===// // @@ -129,6 +145,12 @@ Pass *createLoopUnrollPass(); // Pass *createLoopRotatePass(); +//===----------------------------------------------------------------------===// +// +// LoopIdiom - This pass recognizes and replaces idioms in loops. +// +Pass *createLoopIdiomPass(); + //===----------------------------------------------------------------------===// // // PromoteMemoryToRegister - This pass is used to promote memory references to @@ -161,13 +183,6 @@ extern char &DemoteRegisterToMemoryID; // FunctionPass *createReassociatePass(); -//===----------------------------------------------------------------------===// -// -// TailDuplication - Eliminate unconditional branches through controlled code -// duplication, creating simpler CFG structures. -// -FunctionPass *createTailDuplicationPass(); - //===----------------------------------------------------------------------===// // // JumpThreading - Thread control through mult-pred/multi-succ blocks where some @@ -252,6 +267,13 @@ FunctionPass *createBlockPlacementPass(); Pass *createLCSSAPass(); extern char &LCSSAID; +//===----------------------------------------------------------------------===// +// +// EarlyCSE - This pass performs a simple and fast CSE pass over the dominator +// tree. +// +FunctionPass *createEarlyCSEPass(); + //===----------------------------------------------------------------------===// // // GVN - This pass performs global value numbering and redundant load @@ -279,12 +301,6 @@ Pass *createLoopDeletionPass(); /// specific well-known (library) functions. FunctionPass *createSimplifyLibCallsPass(); -//===----------------------------------------------------------------------===// -// -/// createSimplifyHalfPowrLibCallsPass - This is an experimental pass that -/// optimizes specific half_pow functions. -FunctionPass *createSimplifyHalfPowrLibCallsPass(); - //===----------------------------------------------------------------------===// // // CodeGenPrepare - This pass prepares a function for instruction selection. @@ -298,12 +314,6 @@ FunctionPass *createCodeGenPreparePass(const TargetLowering *TLI = 0); FunctionPass *createInstructionNamerPass(); extern char &InstructionNamerID; -//===----------------------------------------------------------------------===// -// -// GEPSplitter - Split complex GEPs into simple ones -// -FunctionPass *createGEPSplitterPass(); - //===----------------------------------------------------------------------===// // // Sink - Code Sinking @@ -322,6 +332,21 @@ Pass *createLowerAtomicPass(); // Pass *createCorrelatedValuePropagationPass(); +//===----------------------------------------------------------------------===// +// +// InstructionSimplifier - Remove redundant instructions. +// +FunctionPass *createInstructionSimplifierPass(); +extern char &InstructionSimplifierID; + + +//===----------------------------------------------------------------------===// +// +// LowerExpectIntriniscs - Removes llvm.expect intrinsics and creates +// "block_weights" metadata. +FunctionPass *createLowerExpectIntrinsicPass(); + + } // End llvm namespace #endif