diff options
author | Nate Begeman <natebegeman@mac.com> | 2004-10-18 21:08:22 +0000 |
---|---|---|
committer | Nate Begeman <natebegeman@mac.com> | 2004-10-18 21:08:22 +0000 |
commit | eaa13851a7fe604363577350c5cf65c257c4d41a (patch) | |
tree | 6a697cff36c099f32c520d2e6b67cb043cc71875 /include/llvm | |
parent | 103f2eede3f0586449be1601afc0ea26275c4c10 (diff) | |
download | external_llvm-eaa13851a7fe604363577350c5cf65c257c4d41a.zip external_llvm-eaa13851a7fe604363577350c5cf65c257c4d41a.tar.gz external_llvm-eaa13851a7fe604363577350c5cf65c257c4d41a.tar.bz2 |
Initial implementation of the strength reduction for GEP instructions in
loops. This optimization is not turned on by default yet, but may be run
with the opt tool's -loop-reduce flag. There are many FIXMEs listed in the
code that will make it far more applicable to a wide range of code, but you
have to start somewhere :)
This limited version currently triggers on the following tests in the
MultiSource directory:
pcompress2: 7 times
cfrac: 5 times
anagram: 2 times
ks: 6 times
yacr2: 2 times
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17134 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm')
-rw-r--r-- | include/llvm/Transforms/Scalar.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/include/llvm/Transforms/Scalar.h b/include/llvm/Transforms/Scalar.h index 34e87dc..5515c6a 100644 --- a/include/llvm/Transforms/Scalar.h +++ b/include/llvm/Transforms/Scalar.h @@ -141,6 +141,12 @@ FunctionPass *createInstructionCombiningPass(); // FunctionPass *createLICMPass(); +//===----------------------------------------------------------------------===// +// +// LoopStrengthReduce - This pass is strength reduces GEP instructions that use +// a loop's canonical induction variable as one of their indices. +// +FunctionPass *createLoopStrengthReducePass(); //===----------------------------------------------------------------------===// // @@ -155,7 +161,6 @@ FunctionPass *createLoopUnswitchPass(); // FunctionPass *createLoopUnrollPass(); - //===----------------------------------------------------------------------===// // // This pass is used to promote memory references to be register references. A |