20#define DEBUG_TYPE "transform-warning"
30 "FailedRequestedUnrolling",
31 L->getStartLoc(), L->getHeader())
32 <<
"loop not unrolled: the optimizer was unable to perform the "
33 "requested transformation; the transformation might be disabled or "
34 "specified as part of an unsupported transformation ordering");
41 "FailedRequestedUnrollAndJamming",
42 L->getStartLoc(), L->getHeader())
43 <<
"loop not unroll-and-jammed: the optimizer was unable to perform "
44 "the requested transformation; the transformation might be disabled "
45 "or specified as part of an unsupported transformation ordering");
50 std::optional<ElementCount> VectorizeWidth =
52 std::optional<int> InterleaveCount =
55 if (!VectorizeWidth || VectorizeWidth->isVector())
58 "FailedRequestedVectorization",
59 L->getStartLoc(), L->getHeader())
60 <<
"loop not vectorized: the optimizer was unable to perform the "
61 "requested transformation; the transformation might be disabled "
62 "or specified as part of an unsupported transformation ordering");
63 else if (InterleaveCount.value_or(0) != 1)
66 "FailedRequestedInterleaving",
67 L->getStartLoc(), L->getHeader())
68 <<
"loop not interleaved: the optimizer was unable to perform the "
69 "requested transformation; the transformation might be disabled "
70 "or specified as part of an unsupported transformation ordering");
77 "FailedRequestedDistribution",
78 L->getStartLoc(), L->getHeader())
79 <<
"loop not distributed: the optimizer was unable to perform the "
80 "requested transformation; the transformation might be disabled or "
81 "specified as part of an unsupported transformation ordering");
A container for analyses that lazily runs them and caches their results.
PassT::Result & getResult(IRUnitT &IR, ExtraArgTs... ExtraArgs)
Get the result of an analysis pass for a given IR unit.
Diagnostic information for optimization failures.
Analysis pass that exposes the LoopInfo for a function.
SmallVector< LoopT *, 4 > getLoopsInPreorder() const
Return all of the loops in the function in preorder across the loop nests, with siblings in forward p...
Represents a single loop in the control flow graph.
A set of analyses that are preserved following a run of a transformation pass.
static PreservedAnalyses all()
Construct a special preserved set that preserves all passes.
This is an optimization pass for GlobalISel generic memory operations.
std::optional< ElementCount > getOptionalElementCountLoopAttribute(const Loop *TheLoop)
Find a combination of metadata ("llvm.loop.vectorize.width" and "llvm.loop.vectorize....
TransformationMode hasVectorizeTransformation(const Loop *L)
TransformationMode hasUnrollAndJamTransformation(const Loop *L)
raw_ostream & dbgs()
dbgs() - This returns a reference to a raw_ostream for debugging messages.
TransformationMode hasUnrollTransformation(const Loop *L)
TransformationMode hasDistributeTransformation(const Loop *L)
std::optional< int > getOptionalIntLoopAttribute(const Loop *TheLoop, StringRef Name)
Find named metadata for a loop with an integer value.
@ TM_ForcedByUser
The transformation was directed by the user, e.g.