llvm-6502/lib/Analysis
Dan Gohman eed9e5b833 Fix another place that calls Loop::contains a lot to construct a sorted
container of the blocks and do efficient lookups. This makes
isLoopSimplifyForm much faster on large loops, fixing a significant
compile-time issue in builds with assertions enabled.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84673 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 20:41:13 +00:00
..
IPA Remove MallocInst from LLVM Instructions. 2009-10-17 01:18:07 +00:00
AliasAnalysis.cpp
AliasAnalysisCounter.cpp
AliasAnalysisEvaluator.cpp
AliasDebugger.cpp
AliasSetTracker.cpp
Analysis.cpp
BasicAliasAnalysis.cpp inline isGEP away. 2009-10-17 23:48:54 +00:00
CaptureTracking.cpp
CFGPrinter.cpp make DOTGraphTraits public, patch by Tobias Grosser! 2009-10-18 04:09:11 +00:00
CMakeLists.txt add function passes for printing various dominator datastructures 2009-10-18 04:10:40 +00:00
ConstantFolding.cpp
DbgInfoPrinter.cpp
DebugInfo.cpp
DomPrinter.cpp fix the other issue with ID's, hopefully really fixing the linux build. 2009-10-18 04:58:34 +00:00
InlineCost.cpp Remove MallocInst from LLVM Instructions. 2009-10-17 01:18:07 +00:00
InstCount.cpp Remove MallocInst from LLVM Instructions. 2009-10-17 01:18:07 +00:00
Interval.cpp
IntervalPartition.cpp
IVUsers.cpp
LibCallAliasAnalysis.cpp
LibCallSemantics.cpp
LiveValues.cpp
LoopDependenceAnalysis.cpp
LoopInfo.cpp Fix another place that calls Loop::contains a lot to construct a sorted 2009-10-20 20:41:13 +00:00
LoopPass.cpp
Makefile
MallocHelper.cpp Invert isSafeToGetMallocArraySize check because we return NULL when we don't know the size. 2009-10-16 18:08:17 +00:00
MemoryDependenceAnalysis.cpp
PointerTracking.cpp
PostDominators.cpp
ProfileEstimatorPass.cpp
ProfileInfo.cpp
ProfileInfoLoader.cpp
ProfileInfoLoaderPass.cpp
ProfileVerifierPass.cpp
README.txt
ScalarEvolution.cpp
ScalarEvolutionAliasAnalysis.cpp
ScalarEvolutionExpander.cpp
SparsePropagation.cpp
Trace.cpp
ValueTracking.cpp Remove MallocInst from LLVM Instructions. 2009-10-17 01:18:07 +00:00

Analysis Opportunities:

//===---------------------------------------------------------------------===//

In test/Transforms/LoopStrengthReduce/quadradic-exit-value.ll, the
ScalarEvolution expression for %r is this:

  {1,+,3,+,2}<loop>

Outside the loop, this could be evaluated simply as (%n * %n), however
ScalarEvolution currently evaluates it as

  (-2 + (2 * (trunc i65 (((zext i64 (-2 + %n) to i65) * (zext i64 (-1 + %n) to i65)) /u 2) to i64)) + (3 * %n))

In addition to being much more complicated, it involves i65 arithmetic,
which is very inefficient when expanded into code.

//===---------------------------------------------------------------------===//