llvm/lib/Transforms/Scalar
Chandler Carruth 32bf0088fb [LICM] Teach LICM how to handle cases where the alias set tracker was
merged into a loop that was subsequently unrolled (or otherwise nuked).

In this case it can't merge in the ASTs for any remaining nested loops,
it needs to re-add their instructions dircetly.

The fix is very isolated, but I've pulled the code for merging blocks
into the AST into a single place in the process. The only behavior
change is in the case which would have crashed before.

This fixes a crash reported by Mikael Holmen on the list after r261316
restored much of the loop pass pipelining and allowed us to actually do
this kind of nested transformation sequenc. I've taken that test case
and further reduced it into the somewhat twisty maze of loops in the
included test case. This does in fact trigger the bug even in this
reduced form.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@262108 91177308-0d34-0410-b5e6-96231b3b80d8
2016-02-27 04:34:07 +00:00
..
ADCE.cpp Avoid overly large SmallPtrSet/SmallSet 2016-01-30 01:24:31 +00:00
AlignmentFromAssumptions.cpp [SCEV] Add and use SCEVConstant::getAPInt; NFCI 2015-12-17 20:28:46 +00:00
BDCE.cpp Add GlobalsAA as preserved to a bunch of transforms 2015-09-10 10:22:12 +00:00
CMakeLists.txt [PPCLoopDataPrefetch] Move pass to Transforms/Scalar/LoopDataPrefetch. NFC 2016-02-18 21:38:19 +00:00
ConstantHoisting.cpp Scalar: Remove some implicit ilist iterator conversions, NFC 2015-10-13 18:26:00 +00:00
ConstantProp.cpp Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
CorrelatedValuePropagation.cpp Follow up to 260439, Speculative fix to clang builders 2016-02-10 22:22:41 +00:00
DCE.cpp Scalar: Remove some implicit ilist iterator conversions, NFC 2015-10-13 18:26:00 +00:00
DeadStoreElimination.cpp Revert r255247, r255265, and r255286 due to serious compile-time regressions. 2015-12-11 18:39:41 +00:00
EarlyCSE.cpp Minor code cleanup. NFC. 2016-02-18 10:09:20 +00:00
FlattenCFGPass.cpp Scalar: Remove some implicit ilist iterator conversions, NFC 2015-10-13 18:26:00 +00:00
Float2Int.cpp [Float2Int] Don't operate on vector instructions 2015-12-09 21:08:18 +00:00
GVN.cpp Remove unused variable 2016-02-12 20:33:51 +00:00
InductiveRangeCheckElimination.cpp [LPM] Factor all of the loop analysis usage updates into a common helper 2016-02-19 10:45:18 +00:00
IndVarSimplify.cpp [LPM] Factor all of the loop analysis usage updates into a common helper 2016-02-19 10:45:18 +00:00
JumpThreading.cpp [JumpThreading] Simplify Instructions first in ComputeValueKnownInPredecessors() 2016-02-26 06:06:04 +00:00
LICM.cpp [LICM] Teach LICM how to handle cases where the alias set tracker was 2016-02-27 04:34:07 +00:00
LLVMBuild.txt Update libdeps in LLVMipo and LLVMScalarOpts, corresponding to r245940. 2015-08-25 17:11:17 +00:00
LoadCombine.cpp [PM/AA] Rebuild LLVM's alias analysis infrastructure in a way compatible 2015-09-09 17:55:00 +00:00
LoopDataPrefetch.cpp [PPCLoopDataPrefetch] Move pass to Transforms/Scalar/LoopDataPrefetch. NFC 2016-02-18 21:38:19 +00:00
LoopDeletion.cpp [LoopDeletion] Add an assert that verifies LCSSA 2016-02-21 17:11:59 +00:00
LoopDistribute.cpp LPM: Stop threading Pass * through all of the loop utility APIs. NFC 2015-12-15 19:40:57 +00:00
LoopIdiomRecognize.cpp [LPM] Factor all of the loop analysis usage updates into a common helper 2016-02-19 10:45:18 +00:00
LoopInstSimplify.cpp [LPM] Factor all of the loop analysis usage updates into a common helper 2016-02-19 10:45:18 +00:00
LoopInterchange.cpp LPM: Stop threading Pass * through all of the loop utility APIs. NFC 2015-12-15 19:40:57 +00:00
LoopLoadElimination.cpp [LoopLoadElim] Don't allow versioning when optForSize 2016-02-05 01:14:05 +00:00
LoopRerollPass.cpp Allow setting MaxRerollIterations above 16 2016-02-22 09:38:28 +00:00
LoopRotation.cpp [LPM] Factor all of the loop analysis usage updates into a common helper 2016-02-19 10:45:18 +00:00
LoopSimplifyCFG.cpp [LPM] Factor all of the loop analysis usage updates into a common helper 2016-02-19 10:45:18 +00:00
LoopStrengthReduce.cpp [LoopStrengthReduce] Don't rewrite PHIs with incoming values from CatchSwitches 2016-02-03 21:30:34 +00:00
LoopUnrollPass.cpp [LoopUnrollAnalyzer] Check that we're using SCEV for the same loop we're simulating. 2016-02-26 02:57:05 +00:00
LoopUnswitch.cpp [LPM] Factor all of the loop analysis usage updates into a common helper 2016-02-19 10:45:18 +00:00
LoopVersioningLICM.cpp Fix MSVC 2013 build after rL260504 2016-02-11 11:27:51 +00:00
LowerAtomic.cpp Scalar: Remove remaining ilist iterator implicit conversions 2015-10-13 19:26:58 +00:00
LowerExpectIntrinsic.cpp fix typo; NFC 2015-08-24 20:11:14 +00:00
MemCpyOptimizer.cpp Fix PR26051: Memcpy optimization should introduce a call to memcpy before the store destination position 2016-01-06 23:50:22 +00:00
MergedLoadStoreMotion.cpp Fix some Clang-tidy modernize warnings, other minor fixes. 2015-11-04 22:32:32 +00:00
NaryReassociate.cpp [opaque pointer types] [NFC] GEP: replace get(Pointer)ElementType uses with get{Source,Result}ElementType. 2016-01-19 17:28:00 +00:00
PartiallyInlineLibCalls.cpp Scalar: Remove remaining ilist iterator implicit conversions 2015-10-13 19:26:58 +00:00
PlaceSafepoints.cpp [PlaceSafepoints] Use DEBUG() instead of TraceLSP 2016-01-28 23:49:27 +00:00
Reassociate.cpp ADT: Remove == and != comparisons between ilist iterators and pointers 2016-02-21 20:39:50 +00:00
Reg2Mem.cpp Scalar: Remove remaining ilist iterator implicit conversions 2015-10-13 19:26:58 +00:00
RewriteStatepointsForGC.cpp [RS4GC] "Constant fold" the rs4gc-split-vector-values flag 2016-02-22 21:01:28 +00:00
Scalar.cpp [LoopDataPrefetch] Make it testable with opt 2016-02-22 21:41:22 +00:00
Scalarizer.cpp Scalar: Remove remaining ilist iterator implicit conversions 2015-10-13 19:26:58 +00:00
ScalarReplAggregates.cpp [opaque pointer types] [NFC] DataLayout::getIndexedOffset: take source element type instead of pointer type and rename to getIndexedOffsetInType. 2016-01-22 03:08:27 +00:00
SCCP.cpp Fix build bot breakage 2016-01-24 16:46:53 +00:00
SeparateConstOffsetFromGEP.cpp Bug fix: use dyn_cast_or_null instead of dyn_cast 2016-02-19 02:17:07 +00:00
SimplifyCFGPass.cpp PM: Fix an inverted condition in simplifyFunctionCFG 2016-01-15 21:21:39 +00:00
Sink.cpp Remove uses of builtin comma operator. 2016-02-18 22:09:30 +00:00
SpeculativeExecution.cpp Scalar: Remove remaining ilist iterator implicit conversions 2015-10-13 19:26:58 +00:00
SROA.cpp Fix buildbot failure introduced by 258010. Remove local variables became unused. 2016-01-17 12:59:40 +00:00
StraightLineStrengthReduce.cpp [opaque pointer types] [NFC] GEP: replace get(Pointer)ElementType uses with get{Source,Result}ElementType. 2016-01-19 17:28:00 +00:00
StructurizeCFG.cpp StructurizeCFG: Initialize SkipUniformRegions in the default constructor 2016-02-10 01:10:09 +00:00
TailRecursionElimination.cpp Change isSafeToLoadUnconditionally arguments order. Separated from http://reviews.llvm.org/D10920. 2016-01-15 15:27:46 +00:00