llvm-6502/lib/Transforms/Scalar
Jingyue Wu 439d17ca9f [SLSR] handle candidate form &B[i * S]
Summary:
This patch enhances SLSR to handle another candidate form &B[i * S]. If
we found two candidates

S1: X = &B[i * S]
S2: Y = &B[i' * S]

and S1 dominates S2, we can replace S2 with

Y = &X[(i' - i) * S]

Test Plan:
slsr-gep.ll
X86/no-slsr.ll: verify that we do not run SLSR on GEPs that already fit into
an addressing mode

Reviewers: eliben, atrick, meheff, hfinkel

Reviewed By: hfinkel

Subscribers: sanjoy, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@233286 91177308-0d34-0410-b5e6-96231b3b80d8
2015-03-26 16:49:24 +00:00
..
ADCE.cpp [ADCE] Don't indent inside an anonymous namespace 2015-02-16 18:08:00 +00:00
AlignmentFromAssumptions.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
BDCE.cpp DataLayout is mandatory, update the API to reflect it with references. 2015-03-10 02:37:25 +00:00
CMakeLists.txt Reapply r233062: "float2int": Add a new pass to demote from float to int where possible. 2015-03-25 10:03:42 +00:00
ConstantHoisting.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
ConstantProp.cpp DataLayout is mandatory, update the API to reflect it with references. 2015-03-10 02:37:25 +00:00
CorrelatedValuePropagation.cpp DataLayout is mandatory, update the API to reflect it with references. 2015-03-10 02:37:25 +00:00
DCE.cpp [PM] Separate the TargetLibraryInfo object from the immutable pass. 2015-01-15 10:41:28 +00:00
DeadStoreElimination.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
EarlyCSE.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
FlattenCFGPass.cpp [Modules] Fix potential ODR violations by sinking the DEBUG_TYPE 2014-04-22 02:55:47 +00:00
Float2Int.cpp [optnone] Skip pass Float2Int on optnone functions. 2015-03-25 12:22:37 +00:00
GVN.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
InductiveRangeCheckElimination.cpp [IRCE] Fix how IRCE checks for no-sign-overflow. 2015-03-24 19:29:22 +00:00
IndVarSimplify.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
JumpThreading.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
LICM.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
LLVMBuild.txt Update libdeps since TLI was moved from Target to Analysis in r226078. 2015-01-15 05:21:00 +00:00
LoadCombine.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
LoopDeletion.cpp [PM] Split the LoopInfo object apart from the legacy pass, creating 2015-01-17 14:16:18 +00:00
LoopIdiomRecognize.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
LoopInstSimplify.cpp DataLayout is mandatory, update the API to reflect it with references. 2015-03-10 02:37:25 +00:00
LoopInterchange.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
LoopRerollPass.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
LoopRotation.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
LoopStrengthReduce.cpp DataLayout is mandatory, update the API to reflect it with references. 2015-03-10 02:37:25 +00:00
LoopUnrollPass.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
LoopUnswitch.cpp DataLayout is mandatory, update the API to reflect it with references. 2015-03-10 02:37:25 +00:00
LowerAtomic.cpp IR: add "cmpxchg weak" variant to support permitted failure. 2014-06-13 14:24:07 +00:00
LowerExpectIntrinsic.cpp [PM] Port LowerExpectIntrinsic to the new pass manager. 2015-01-24 11:13:02 +00:00
Makefile
MemCpyOptimizer.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
MergedLoadStoreMotion.cpp Another set of missing raw_ostream.h. Still no functional change. 2015-03-23 18:45:56 +00:00
PartiallyInlineLibCalls.cpp [multiversion] Thread a function argument through all the callers of the 2015-02-01 12:01:35 +00:00
PlaceSafepoints.cpp PlaceSafepoints: use IRBuilder helpers 2015-02-26 00:35:56 +00:00
Reassociate.cpp Reapply "[Reassociate] Add initial support for vector instructions." 2015-03-13 20:53:01 +00:00
Reg2Mem.cpp Standardize {pred,succ,use,user}_empty() 2015-01-13 03:46:47 +00:00
RewriteStatepointsForGC.cpp Make helper functions static. 2015-03-09 16:23:46 +00:00
SampleProfile.cpp SampleProfile: Check for missing debug locations 2015-03-20 00:56:55 +00:00
Scalar.cpp Reapply r233062: "float2int": Add a new pass to demote from float to int where possible. 2015-03-25 10:03:42 +00:00
Scalarizer.cpp Opaque Pointer Types: GEP API migrations to specify the gep type explicitly 2015-03-24 22:38:16 +00:00
ScalarReplAggregates.cpp DataLayout is mandatory, update the API to reflect it with references. 2015-03-10 02:37:25 +00:00
SCCP.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
SeparateConstOffsetFromGEP.cpp [opaque pointer type] Start migrating GEP creation to explicitly specify the pointee type 2015-03-14 01:53:18 +00:00
SimplifyCFGPass.cpp DataLayout is mandatory, update the API to reflect it with references. 2015-03-10 02:37:25 +00:00
Sink.cpp DataLayout is mandatory, update the API to reflect it with references. 2015-03-10 02:37:25 +00:00
SROA.cpp DataLayout is mandatory, update the API to reflect it with references. 2015-03-10 02:37:25 +00:00
StraightLineStrengthReduce.cpp [SLSR] handle candidate form &B[i * S] 2015-03-26 16:49:24 +00:00
StructurizeCFG.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00
TailRecursionElimination.cpp Re-sort includes with sort-includes.py and insert raw_ostream.h where it's used. 2015-03-23 19:32:43 +00:00