diff options
author | Chandler Carruth <chandlerc@gmail.com> | 2012-12-20 22:31:43 +0000 |
---|---|---|
committer | Chandler Carruth <chandlerc@gmail.com> | 2012-12-20 22:31:43 +0000 |
commit | 41d2daa9344a4c4e8bb88dba51cd087c0648b695 (patch) | |
tree | 7e22b30849a5a15a044a3423d0e8df884992ceea /lib/Transforms/Vectorize/LoopVectorize.h | |
parent | 571f3e0cc9e767d1e3dcfd3e7e0b3d11ec4f7884 (diff) | |
parent | 6c583141bf6b7a6b5f8125c1037ecbc089813288 (diff) |
Updating branches/google/testing to 170392
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/google/testing@170779 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Vectorize/LoopVectorize.h')
-rw-r--r-- | lib/Transforms/Vectorize/LoopVectorize.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/lib/Transforms/Vectorize/LoopVectorize.h b/lib/Transforms/Vectorize/LoopVectorize.h index 9d6d80e22b..e5ef29052e 100644 --- a/lib/Transforms/Vectorize/LoopVectorize.h +++ b/lib/Transforms/Vectorize/LoopVectorize.h @@ -320,6 +320,9 @@ public: /// Returns the induction variables found in the loop. InductionList *getInductionVars() { return &Inductions; } + /// Returns True if V is an induction variable in this loop. + bool isInductionVariable(const Value *V); + /// Return true if the block BB needs to be predicated in order for the loop /// to be vectorized. bool blockNeedsPredication(BasicBlock *BB); @@ -420,10 +423,11 @@ public: const VectorTargetTransformInfo *Vtti): TheLoop(Lp), SE(Se), Legal(Leg), VTTI(Vtti) { } - /// Returns the most profitable vectorization factor for the loop that is - /// smaller or equal to the VF argument. This method checks every power - /// of two up to VF. - unsigned findBestVectorizationFactor(unsigned VF = MaxVectorSize); + /// Returns the most profitable vectorization factor in powers of two. + /// This method checks every power of two up to VF. If UserVF is not ZERO + /// then this vectorization factor will be selected if vectorization is + /// possible. + unsigned selectVectorizationFactor(bool OptForSize, unsigned UserVF); private: /// Returns the expected execution cost. The unit of the cost does |