llvm-project/llvm/test/Transforms/LICM
David Stenberg 05b6a53340 [MustExecute] Fix a debug invariant issue in isGuaranteedToExecute()
Summary:
Look past debug intrinsics when querying whether an instruction is the
first instruction in the header block. The commit includes a reproducer
for a case where LICM would not hoist an instruction, due to the presence
of the intrinsic.

A caveat with this commit is that the check will not work properly if
the instruction at hand is a debug intrinsic. I assume that no one
depends on isGuaranteedToExecute() to return true for debug intrinsics
for these cases (and that this might be an indication of another debug
invariant issue), so I thought that it was not worth adding that extra
bit of complexity.

Reviewers: reames, anna

Reviewed By: anna

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D47197

llvm-svn: 333274
2018-05-25 13:02:59 +00:00
..
2003-02-26-LoopExitNotDominated.ll
2003-02-27-NestedLoopExitBlocks.ll
2003-02-27-PreheaderExitNodeUpdate.ll
2003-02-27-PreheaderProblem.ll
2003-02-27-StoreSinkPHIs.ll
2003-02-28-PromoteDifferentType.ll
2003-05-02-LoadHoist.ll
2003-12-11-SinkingToPHI.ll
2004-09-14-AliasAnalysisInvalidate.ll
2004-11-17-UndefIndexCrash.ll
2006-09-12-DeadUserOfSunkInstr.ll
2007-05-22-VolatileSink.ll
2007-07-30-AliasSet.ll
2007-09-17-PromoteValue.ll
2007-09-24-PromoteNullValue.ll
2007-10-01-PromoteSafeValue.ll
2008-05-20-AliasSetVAArg.ll
2008-07-22-LoadGlobalConstant.ll
2009-12-10-LICM-Indbr-Crash.ll
2011-04-06-HoistMissedASTUpdate.ll
2011-04-06-PromoteResultOfPromotion.ll
2011-04-09-RAUW-AST.ll
2011-07-06-Alignment.ll
2014-09-10-doFinalizationAssert.ll
AliasSetMemSet.ll
PR19798.ll
PR21582.ll
PR24013.ll
Preserve-LCSSA.ll
alias-set-tracker-loss.ll
argmemonly-call.ll
assume.ll
atomics.ll [LICM] Make store promotion work in the face of unordered atomics 2017-02-14 01:38:31 +00:00
basictest.ll
bisect-state.ll
constexpr.ll
crash.ll
debug-value.ll Remove the obsolete offset parameter from @llvm.dbg.value 2017-07-28 20:21:02 +00:00
dropped-tbaa.ll [AliasSetTracker] Don't drop AA MD so eagerly 2017-06-29 19:13:11 +00:00
extra-copies.ll
funclet.ll
hoist-bitcast-load.ll
hoist-debuginvariant.ll [MustExecute] Fix a debug invariant issue in isGuaranteedToExecute() 2018-05-25 13:02:59 +00:00
hoist-deref-load.ll
hoist-fast-fdiv.ll [LICM] Hoist fp division from the loops and replace by a reciprocal 2017-04-11 02:22:54 +00:00
hoist-invariant-load.ll
hoist-mustexec.ll [LICM] Extend the MustExecute scope 2018-05-18 04:56:28 +00:00
hoist-nounwind.ll
hoist-round.ll Mark @llvm.powi.* as safe to speculatively execute. 2017-01-25 09:32:30 +00:00
hoisting.ll [LICM] Hoist loads that are dominated by invariant.start intrinsic, and are invariant in the loop. 2017-02-02 13:22:03 +00:00
int_sideeffect.ll Add an @llvm.sideeffect intrinsic 2017-11-08 21:59:51 +00:00
lcssa-ssa-promoter.ll
loopsink.ll Xfail the test added in r324445 until the underlying issue in LoopSink is fixed. 2018-02-07 06:11:50 +00:00
no-preheader-test.ll
opt-remarks-conditional-load.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
opt-remarks-intervening-store.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
opt-remarks.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
pr23608.ll
pr26843.ll Remove alignment argument from memcpy/memmove/memset in favour of alignment attributes (Step 1) 2018-01-19 17:13:12 +00:00
pr27262.ll Remove alignment argument from memcpy/memmove/memset in favour of alignment attributes (Step 1) 2018-01-19 17:13:12 +00:00
pr32129.ll Use a WeakVH for UnknownInstructions in AliasSetTracker 2017-03-11 01:15:48 +00:00
pr35342.ll [LICM] Fix PR35342 2017-11-17 20:38:25 +00:00
pr37323.ll [LICM] Preserve DT and LoopInfo specifically 2018-05-24 15:58:34 +00:00
preheader-safe.ll [LICM] Compute a must execute property for the prefix of the header as we go 2018-05-04 21:35:00 +00:00
promote-order.ll
promote-tls.ll
scalar-promote-memmodel.ll
scalar-promote-unwind.ll
scalar-promote.ll [LICM] Ignore exits provably not taken on first iteration when computing must execute 2018-03-15 21:04:28 +00:00
sink-foldable.ll Re-commit : [LICM] Allow sinking when foldable in loop 2017-12-15 20:33:24 +00:00
sink.ll
sinking.ll [LICM] Salvage DI from dying Instructions 2018-03-18 15:59:19 +00:00
speculate.ll
strlen.ll Add argmononly attribute to strlen and wcslen, i.e. they only read memory (string) passed to them. 2017-06-18 03:10:26 +00:00
unrolled-deeply-nested.ll Remove alignment argument from memcpy/memmove/memset in favour of alignment attributes (Step 1) 2018-01-19 17:13:12 +00:00
update-scev.ll
volatile-alias.ll