llvm-6502/test/Analysis
Jingyue Wu 9f141640b5 [TTI/CostModel] improve TTI::getGEPCost and use it in CostModel::getInstructionCost
Summary:
This patch updates TargetTransformInfoImplCRTPBase::getGEPCost to consider
addressing modes. It now returns TCC_Free when the GEP can be completely folded
to an addresing mode.

I started this patch as I refactored SLSR. Function isGEPFoldable looks common
and is indeed used by some WIP of mine. So I extracted that logic to getGEPCost.

Furthermore, I noticed getGEPCost wasn't directly tested anywhere. The best
testing bed seems CostModel, but its getInstructionCost method invokes
getAddressComputationCost for GEPs which provides very coarse estimation. So
this patch also makes getInstructionCost call the updated getGEPCost for GEPs.
This change inevitably breaks some tests because the cost model changes, but
nothing looks seriously wrong -- if we believe the new cost model is the right
way to go, these tests should be updated.

This patch is not perfect yet -- the comments in some tests need to be updated.
I want to know whether this is a right approach before fixing those details.

Reviewers: chandlerc, hfinkel

Subscribers: aschwaighofer, llvm-commits, aemerson

Differential Revision: http://reviews.llvm.org/D9819

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@243250 91177308-0d34-0410-b5e6-96231b3b80d8
2015-07-26 17:28:13 +00:00
..
AssumptionCache
BasicAA NFC. Explicitly specify attributes in BasicAA/cs-cs.ll test. 2015-07-23 14:31:18 +00:00
BlockFrequencyInfo Add documentation for new backedge mass propagation in irregular loops. 2015-06-17 16:28:22 +00:00
BranchProbabilityInfo
CallGraph [CallGraph] Given -print-callgraph a stable printing order. 2015-06-19 23:20:31 +00:00
CFLAliasAnalysis
CostModel [TTI/CostModel] improve TTI::getGEPCost and use it in CostModel::getInstructionCost 2015-07-26 17:28:13 +00:00
Delinearization
DependenceAnalysis [DependenceAnalysis] Extend unifySubscriptType for handling coupled subscript groups. 2015-05-29 16:58:08 +00:00
DivergenceAnalysis/NVPTX
Dominators Move the personality function from LandingPadInst to Function 2015-06-17 20:52:32 +00:00
GlobalsModRef [PM/AA] Disable the core unsafe aspect of GlobalsModRef in the face of 2015-07-17 06:58:24 +00:00
LazyCallGraph [LazyCallGraph] Port test case from r240039 to LCG. 2015-07-02 02:03:58 +00:00
Lint Move the personality function from LandingPadInst to Function 2015-06-17 20:52:32 +00:00
LoopAccessAnalysis Fix memcheck interval ends for pointers with negative strides 2015-07-16 14:02:58 +00:00
LoopInfo
MemoryDependenceAnalysis [MDA] change BlockScanLimit into a command line option. 2015-07-21 21:50:39 +00:00
PostDominators
RegionInfo
ScalarEvolution
ScopedNoAliasAA [Testsuite] Renumber metadata in ScopedNoAliasAA test to match CHECK lines 2015-05-11 09:10:14 +00:00
TypeBasedAliasAnalysis
ValueTracking [ValueTracking] do not overwrite analysis results already computed 2015-06-15 05:46:29 +00:00