hanchenye-llvm-project/llvm/test/Transforms/LoopUnroll
Shiva Chen 2c864551df [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label.
In order to set breakpoints on labels and list source code around
labels, we need collect debug information for labels, i.e., label
name, the function label belong, line number in the file, and the
address label located. In order to keep these information in LLVM
IR and to allow backend to generate debug information correctly.
We create a new kind of metadata for labels, DILabel. The format
of DILabel is

!DILabel(scope: !1, name: "foo", file: !2, line: 3)

We hope to keep debug information as much as possible even the
code is optimized. So, we create a new kind of intrinsic for label
metadata to avoid the metadata is eliminated with basic block.
The intrinsic will keep existing if we keep it from optimized out.
The format of the intrinsic is

llvm.dbg.label(metadata !1)

It has only one argument, that is the DILabel metadata. The
intrinsic will follow the label immediately. Backend could get the
label metadata through the intrinsic's parameter.

We also create DIBuilder API for labels to be used by Frontend.
Frontend could use createLabel() to allocate DILabel objects, and use
insertLabel() to insert llvm.dbg.label intrinsic in LLVM IR.

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

Patch by Hsiangkai Wang.

llvm-svn: 331841
2018-05-09 02:40:45 +00:00
..
AArch64
AMDGPU [AMDGPU] Switch to the new addr space mapping by default 2018-02-02 16:07:16 +00:00
ARM [ARM] Allow unrolling of multi-block loops. 2017-10-23 08:05:14 +00:00
Hexagon peel loops with runtime small trip counts 2018-04-03 03:39:43 +00:00
PowerPC The cost of splitting a large vector instruction is not being taken into account by the getUserCost function. This was leading to some loops being over unrolled. The cost of a vector instruction is now being multiplied by the cost of the type legalization. This will return a more accurate cost. 2017-10-19 18:16:31 +00:00
X86 Changed basic cost of store operation on X86 2017-08-20 12:34:29 +00:00
2004-05-13-DontUnrollTooMuch.ll
2005-03-06-BadLoopInfoUpdate.ll
2006-08-24-MultiBlockLoop.ll
2007-04-16-PhiUpdate.ll
2007-05-05-UnrollMiscomp.ll
2007-05-09-UnknownTripCount.ll
2007-11-05-Crash.ll
2011-08-08-PhiUpdate.ll
2011-08-09-IVSimplify.ll
2011-08-09-PhiUpdate.ll
2011-10-01-NoopTrunc.ll
2012-04-09-unroll-indirectbr.ll
basic.ll [PM] Split LoopUnrollPass and make partial unroller a function pass 2017-08-02 20:35:29 +00:00
complete_unroll_profitability_with_assume.ll [LoopUnroll] Peel off iterations if it makes conditions true/false. 2018-03-15 21:34:43 +00:00
convergent.ll LoopUnroll: respect pragma unroll when AllowRemainder is disabled 2018-03-02 16:22:32 +00:00
debug-info.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
ephemeral.ll
epilog_const_phi.ll
full-unroll-bad-cost.ll
full-unroll-crashers.ll
full-unroll-heuristics-2.ll
full-unroll-heuristics-cmp.ll
full-unroll-heuristics-dce.ll
full-unroll-heuristics-geps.ll
full-unroll-heuristics-phi-prop.ll
full-unroll-heuristics.ll [PM] Split LoopUnrollPass and make partial unroller a function pass 2017-08-02 20:35:29 +00:00
full-unroll-keep-first-exit.ll
high-cost-trip-count-computation.ll
ignore-annotation-intrinsic-cost.ll
invalidate_right_loop.ll [LoopUnroll] Fix dangling pointers in SCEV 2018-03-26 11:31:46 +00:00
loop-remarks-with-hotness.ll
loop-remarks.ll [LoopUnroll] Clean up remarks for unroll remainder 2017-10-31 10:47:46 +00:00
not-rotated.ll
partial-unroll-const-bounds.ll [PM] Split LoopUnrollPass and make partial unroller a function pass 2017-08-02 20:35:29 +00:00
peel-loop-conditions.ll [LoopUnroll] Only peel if a predicate becomes known in the loop body. 2018-04-18 12:29:24 +00:00
peel-loop-irreducible.ll
peel-loop-negative.ll
peel-loop-not-forced.ll [LoopUnroll] Make LoopPeeling respect the AllowPeeling preference. 2018-04-06 13:57:21 +00:00
peel-loop-pgo.ll Use profile summary to disable peeling for huge working sets 2017-08-03 23:42:58 +00:00
peel-loop.ll [SimplifyCFG] Re-apply Relax restriction for folding unconditional branches 2018-02-08 07:16:29 +00:00
peel-loop2.ll
pr10813.ll
pr11361.ll
pr14167.ll
pr18861.ll
pr27157.ll
pr28132.ll
pr31718.ll
pr33437.ll [LoopUnroll] Make the test for PR33437 actually useful. 2017-08-29 17:24:09 +00:00
rebuild_lcssa.ll
revisit.ll [PM] Split LoopUnrollPass and make partial unroller a function pass 2017-08-02 20:35:29 +00:00
runtime-epilog-debuginfo.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
runtime-li.ll
runtime-loop-multiexit-dom-verify.ll [RuntimeUnrolling] Update DomTree correctly when exit blocks have successors 2017-07-13 13:21:23 +00:00
runtime-loop-multiple-exits.ll [RuntimeUnrolling] Populate the VMap entry correctly when default generated through lookup 2017-09-15 13:29:33 +00:00
runtime-loop.ll [PM] Split LoopUnrollPass and make partial unroller a function pass 2017-08-02 20:35:29 +00:00
runtime-loop1.ll [DebugInfo] Add DILabel metadata and intrinsic llvm.dbg.label. 2018-05-09 02:40:45 +00:00
runtime-loop2.ll [PM] Split LoopUnrollPass and make partial unroller a function pass 2017-08-02 20:35:29 +00:00
runtime-loop3.ll [PM] Split LoopUnrollPass and make partial unroller a function pass 2017-08-02 20:35:29 +00:00
runtime-loop4.ll
runtime-loop5.ll [PM] Split LoopUnrollPass and make partial unroller a function pass 2017-08-02 20:35:29 +00:00
runtime-multiexit-heuristic.ll [RuntimeUnroll] Add heuristic for unrolling multi-exit loop 2017-09-15 15:56:05 +00:00
runtime-unroll-remainder.ll [ValueTracking] Enabling ValueTracking patch by default 2017-10-20 10:08:47 +00:00
scevunroll.ll
shifted-tripcount.ll
tripcount-overflow.ll
unloop.ll [PM] Split LoopUnrollPass and make partial unroller a function pass 2017-08-02 20:35:29 +00:00
unroll-cleanup.ll
unroll-cleanuppad.ll
unroll-count.ll
unroll-heuristics-pgo.ll
unroll-loop-invalidation.ll Use a BumpPtrAllocator for Loop objects 2017-09-28 02:45:42 +00:00
unroll-maxcount.ll
unroll-opt-attribute.ll
unroll-pragmas-disabled.ll
unroll-pragmas.ll LoopUnroll: respect pragma unroll when AllowRemainder is disabled 2018-03-02 16:22:32 +00:00
update-loop-info-in-subloops.ll [PM] Split LoopUnrollPass and make partial unroller a function pass 2017-08-02 20:35:29 +00:00