LLVM 23.0.0git
VPlanVerifier.cpp
Go to the documentation of this file.
1//===-- VPlanVerifier.cpp -------------------------------------------------===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8///
9/// \file
10/// This file defines the class VPlanVerifier, which contains utility functions
11/// to check the consistency and invariants of a VPlan.
12///
13//===----------------------------------------------------------------------===//
14
15#include "VPlanVerifier.h"
16#include "VPlan.h"
17#include "VPlanCFG.h"
18#include "VPlanDominatorTree.h"
19#include "VPlanHelpers.h"
20#include "VPlanPatternMatch.h"
21#include "VPlanUtils.h"
23#include "llvm/ADT/TypeSwitch.h"
24
25#define DEBUG_TYPE "loop-vectorize"
26
27using namespace llvm;
28using namespace VPlanPatternMatch;
29
30namespace {
31class VPlanVerifier {
32 const VPDominatorTree &VPDT;
33 VPTypeAnalysis &TypeInfo;
34
36
37 // Verify that phi-like recipes are at the beginning of \p VPBB, with no
38 // other recipes in between. Also check that only header blocks contain
39 // VPHeaderPHIRecipes.
40 bool verifyPhiRecipes(const VPBasicBlock *VPBB);
41
42 /// Verify that \p LastActiveLane's operand is guaranteed to be a prefix-mask.
43 bool verifyLastActiveLaneRecipe(const VPInstruction &LastActiveLane) const;
44
45 bool verifyVPBasicBlock(const VPBasicBlock *VPBB);
46
47 bool verifyBlock(const VPBlockBase *VPB);
48
49 /// Helper function that verifies the CFG invariants of the VPBlockBases
50 /// within
51 /// \p Region. Checks in this function are generic for VPBlockBases. They are
52 /// not specific for VPBasicBlocks or VPRegionBlocks.
53 bool verifyBlocksInRegion(const VPRegionBlock *Region);
54
55 /// Verify the CFG invariants of VPRegionBlock \p Region and its nested
56 /// VPBlockBases. Do not recurse inside nested VPRegionBlocks.
57 bool verifyRegion(const VPRegionBlock *Region);
58
59 /// Verify the CFG invariants of VPRegionBlock \p Region and its nested
60 /// VPBlockBases. Recurse inside nested VPRegionBlocks.
61 bool verifyRegionRec(const VPRegionBlock *Region);
62
63public:
64 VPlanVerifier(VPDominatorTree &VPDT, VPTypeAnalysis &TypeInfo)
65 : VPDT(VPDT), TypeInfo(TypeInfo) {}
66
67 bool verify(const VPlan &Plan);
68};
69} // namespace
70
71bool VPlanVerifier::verifyPhiRecipes(const VPBasicBlock *VPBB) {
72 auto RecipeI = VPBB->begin();
73 auto End = VPBB->end();
74 unsigned NumActiveLaneMaskPhiRecipes = 0;
75 bool IsHeaderVPBB = VPBlockUtils::isHeader(VPBB, VPDT);
76 while (RecipeI != End && RecipeI->isPhi()) {
78 NumActiveLaneMaskPhiRecipes++;
79
80 if (IsHeaderVPBB &&
82 errs() << "Found non-header PHI recipe in header VPBB";
83#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
84 errs() << ": ";
85 RecipeI->dump();
86#endif
87 return false;
88 }
89
90 if (!IsHeaderVPBB && isa<VPHeaderPHIRecipe>(*RecipeI)) {
91 errs() << "Found header PHI recipe in non-header VPBB";
92#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
93 errs() << ": ";
94 RecipeI->dump();
95#endif
96 return false;
97 }
98
100 !isa_and_nonnull<VPCanonicalIVPHIRecipe>(std::prev(RecipeI))) {
101 errs() << "CurrentIteration PHI is not immediately after canonical IV\n";
102 return false;
103 }
104
105 // Check if the recipe operands match the number of predecessors.
106 // TODO Extend to other phi-like recipes.
107 if (auto *PhiIRI = dyn_cast<VPIRPhi>(&*RecipeI)) {
108 if (PhiIRI->getNumOperands() != VPBB->getNumPredecessors()) {
109 errs() << "Phi-like recipe with different number of operands and "
110 "predecessors.\n";
111 // TODO: Print broken recipe. At the moment printing an ill-formed
112 // phi-like recipe may crash.
113 return false;
114 }
115 }
116
117 RecipeI++;
118 }
119
120 if (!VPBB->getPlan()->isUnrolled() && NumActiveLaneMaskPhiRecipes > 1) {
121 errs() << "There should be no more than one VPActiveLaneMaskPHIRecipe";
122 return false;
123 }
124
125 while (RecipeI != End) {
126 if (RecipeI->isPhi() && !isa<VPBlendRecipe>(&*RecipeI)) {
127 errs() << "Found phi-like recipe after non-phi recipe";
128
129#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
130 errs() << ": ";
131 RecipeI->dump();
132 errs() << "after\n";
133 std::prev(RecipeI)->dump();
134#endif
135 return false;
136 }
137 RecipeI++;
138 }
139 return true;
140}
141
142static bool isKnownMonotonic(VPValue *V) {
143 VPValue *X, *Y;
144 if (match(V, m_Add(m_VPValue(X), m_VPValue(Y))))
145 return cast<VPRecipeWithIRFlags>(V)->hasNoUnsignedWrap() &&
147 if (match(V, m_StepVector()))
148 return true;
149 // Only handle a subset of IVs until we can guarantee there's no overflow.
150 if (auto *WidenIV = dyn_cast<VPWidenIntOrFpInductionRecipe>(V))
151 return WidenIV->isCanonical();
152 if (auto *Steps = dyn_cast<VPScalarIVStepsRecipe>(V))
153 return match(Steps->getOperand(0),
157 match(Steps->getStepValue(), m_One());
159 return true;
161}
162
163bool VPlanVerifier::verifyLastActiveLaneRecipe(
164 const VPInstruction &LastActiveLane) const {
165 assert(LastActiveLane.getOpcode() == VPInstruction::LastActiveLane &&
166 "must be called with VPInstruction::LastActiveLane");
167
168 if (LastActiveLane.getNumOperands() < 1) {
169 errs() << "LastActiveLane must have at least one operand\n";
170 return false;
171 }
172
173 const VPlan &Plan = *LastActiveLane.getParent()->getPlan();
174 // All operands must be prefix-mask. This means an icmp ult/ule LHS, RHS where
175 // the LHS is monotonically increasing and RHS is uniform across VFs and UF.
176 for (VPValue *Op : LastActiveLane.operands()) {
177 if (vputils::isHeaderMask(Op, Plan))
178 continue;
179
180 CmpPredicate Pred;
181 VPValue *LHS, *RHS;
182 if (match(Op, m_ICmp(Pred, m_VPValue(LHS), m_VPValue(RHS))) &&
183 (Pred == CmpInst::ICMP_ULE || Pred == CmpInst::ICMP_ULT) &&
186 match(RHS, m_EVL(m_VPValue()))))
187 continue;
188
189 errs() << "LastActiveLane operand ";
190#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
191 VPSlotTracker Tracker(&Plan);
192 Op->printAsOperand(errs(), Tracker);
193#endif
194 errs() << " must be prefix mask (a header mask or an "
195 "EVL-derived mask currently)\n";
196 return false;
197 }
198
199 return true;
200}
201
202bool VPlanVerifier::verifyVPBasicBlock(const VPBasicBlock *VPBB) {
203 if (!verifyPhiRecipes(VPBB))
204 return false;
205
206 // Verify that defs in VPBB dominate all their uses.
207 DenseMap<const VPRecipeBase *, unsigned> RecipeNumbering;
208 unsigned Cnt = 0;
209 for (const VPRecipeBase &R : *VPBB)
210 RecipeNumbering[&R] = Cnt++;
211
212 for (const VPRecipeBase &R : *VPBB) {
213 if (isa<VPIRInstruction>(&R) && !isa<VPIRBasicBlock>(VPBB)) {
214 errs() << "VPIRInstructions ";
215#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
216 R.dump();
217 errs() << " ";
218#endif
219 errs() << "not in a VPIRBasicBlock!\n";
220 return false;
221 }
222 for (const VPValue *V : R.definedValues()) {
223 // Verify that we can infer a scalar type for each defined value. With
224 // assertions enabled, inferScalarType will perform some consistency
225 // checks during type inference.
226 if (!TypeInfo.inferScalarType(V)) {
227 errs() << "Failed to infer scalar type!\n";
228 return false;
229 }
230
231 for (const VPUser *U : V->users()) {
232 auto *UI = cast<VPRecipeBase>(U);
233 if (isa<VPIRPhi>(UI) &&
234 UI->getNumOperands() != UI->getParent()->getNumPredecessors()) {
235 errs() << "Phi-like recipe with different number of operands and "
236 "predecessors.\n";
237 return false;
238 }
239
240 if (auto *Phi = dyn_cast<VPPhiAccessors>(UI)) {
241 for (const auto &[IncomingVPV, IncomingVPBB] :
242 Phi->incoming_values_and_blocks()) {
243 if (IncomingVPV != V)
244 continue;
245
246 if (VPDT.dominates(VPBB, IncomingVPBB))
247 continue;
248
249 errs() << "Incoming def does not dominate incoming block!\n";
250#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
251 VPSlotTracker Tracker(VPBB->getPlan());
252 IncomingVPV->getDefiningRecipe()->print(errs(), " ", Tracker);
253 errs() << "\n does not dominate " << IncomingVPBB->getName()
254 << " for\n";
255 UI->print(errs(), " ", Tracker);
256#endif
257 return false;
258 }
259 continue;
260 }
261 // TODO: Also verify VPPredInstPHIRecipe.
263 continue;
264
265 // If the user is in the same block, check it comes after R in the
266 // block.
267 if (UI->getParent() == VPBB) {
268 if (RecipeNumbering[UI] >= RecipeNumbering[&R])
269 continue;
270 } else {
271 if (VPDT.dominates(VPBB, UI->getParent()))
272 continue;
273 }
274
275 errs() << "Use before def!\n";
276#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
277 VPSlotTracker Tracker(VPBB->getPlan());
278 UI->print(errs(), " ", Tracker);
279 errs() << "\n before\n";
280 R.print(errs(), " ", Tracker);
281 errs() << "\n";
282#endif
283 return false;
284 }
285 }
286 if (const auto *VPI = dyn_cast<VPInstruction>(&R)) {
287 switch (VPI->getOpcode()) {
289 if (!verifyLastActiveLaneRecipe(*VPI))
290 return false;
291 break;
292 default:
293 break;
294 }
295 }
296 }
297
298 auto *IRBB = dyn_cast<VPIRBasicBlock>(VPBB);
299 if (!IRBB)
300 return true;
301
302 if (!WrappedIRBBs.insert(IRBB->getIRBasicBlock()).second) {
303 errs() << "Same IR basic block used by multiple wrapper blocks!\n";
304 return false;
305 }
306
307 return true;
308}
309
310/// Utility function that checks whether \p VPBlockVec has duplicate
311/// VPBlockBases.
312static bool hasDuplicates(const SmallVectorImpl<VPBlockBase *> &VPBlockVec) {
314 for (const auto *Block : VPBlockVec) {
315 if (!VPBlockSet.insert(Block).second)
316 return true;
317 }
318 return false;
319}
320
321bool VPlanVerifier::verifyBlock(const VPBlockBase *VPB) {
322 auto *VPBB = dyn_cast<VPBasicBlock>(VPB);
323 // Check block's condition bit.
324 if (VPBB && !isa<VPIRBasicBlock>(VPB)) {
325 if (VPB->getNumSuccessors() > 1 ||
326 (VPBB->getParent() && VPBB->isExiting() &&
327 !VPBB->getParent()->isReplicator())) {
328 if (!VPBB->getTerminator()) {
329 errs() << "Block has multiple successors but doesn't "
330 "have a proper branch recipe!\n";
331 return false;
332 }
333 } else if (VPBB->getTerminator()) {
334 errs() << "Unexpected branch recipe!\n";
335 return false;
336 }
337 }
338
339 // Check block's successors.
340 const auto &Successors = VPB->getSuccessors();
341 // There must be only one instance of a successor in block's successor list.
342 // TODO: This won't work for switch statements.
343 if (hasDuplicates(Successors)) {
344 errs() << "Multiple instances of the same successor.\n";
345 return false;
346 }
347
348 for (const VPBlockBase *Succ : Successors) {
349 // There must be a bi-directional link between block and successor.
350 const auto &SuccPreds = Succ->getPredecessors();
351 if (!is_contained(SuccPreds, VPB)) {
352 errs() << "Missing predecessor link.\n";
353 return false;
354 }
355 }
356
357 // Check block's predecessors.
358 const auto &Predecessors = VPB->getPredecessors();
359 // There must be only one instance of a predecessor in block's predecessor
360 // list.
361 // TODO: This won't work for switch statements.
362 if (hasDuplicates(Predecessors)) {
363 errs() << "Multiple instances of the same predecessor.\n";
364 return false;
365 }
366
367 for (const VPBlockBase *Pred : Predecessors) {
368 // Block and predecessor must be inside the same region.
369 if (Pred->getParent() != VPB->getParent()) {
370 errs() << "Predecessor is not in the same region.\n";
371 return false;
372 }
373
374 // There must be a bi-directional link between block and predecessor.
375 const auto &PredSuccs = Pred->getSuccessors();
376 if (!is_contained(PredSuccs, VPB)) {
377 errs() << "Missing successor link.\n";
378 return false;
379 }
380 }
381 return !VPBB || verifyVPBasicBlock(VPBB);
382}
383
384bool VPlanVerifier::verifyBlocksInRegion(const VPRegionBlock *Region) {
385 for (const VPBlockBase *VPB : vp_depth_first_shallow(Region->getEntry())) {
386 // Check block's parent.
387 if (VPB->getParent() != Region) {
388 errs() << "VPBlockBase has wrong parent\n";
389 return false;
390 }
391
392 if (!verifyBlock(VPB))
393 return false;
394 }
395 return true;
396}
397
398bool VPlanVerifier::verifyRegion(const VPRegionBlock *Region) {
399 const VPBlockBase *Entry = Region->getEntry();
400 const VPBlockBase *Exiting = Region->getExiting();
401
402 // Entry and Exiting shouldn't have any predecessor/successor, respectively.
403 if (Entry->hasPredecessors()) {
404 errs() << "region entry block has predecessors\n";
405 return false;
406 }
407 if (Exiting->getNumSuccessors() != 0) {
408 errs() << "region exiting block has successors\n";
409 return false;
410 }
411
412 return verifyBlocksInRegion(Region);
413}
414
415bool VPlanVerifier::verifyRegionRec(const VPRegionBlock *Region) {
416 // Recurse inside nested regions and check all blocks inside the region.
417 return verifyRegion(Region) &&
419 [this](const VPBlockBase *VPB) {
420 const auto *SubRegion = dyn_cast<VPRegionBlock>(VPB);
421 return !SubRegion || verifyRegionRec(SubRegion);
422 });
423}
424
425bool VPlanVerifier::verify(const VPlan &Plan) {
427 [this](const VPBlockBase *VPB) { return !verifyBlock(VPB); }))
428 return false;
429
430 const VPRegionBlock *TopRegion = Plan.getVectorLoopRegion();
431 // TODO: Verify all blocks using vp_depth_first_deep iterators.
432 if (!TopRegion)
433 return true;
434
435 if (!verifyRegionRec(TopRegion))
436 return false;
437
438 if (TopRegion->getParent()) {
439 errs() << "VPlan Top Region should have no parent.\n";
440 return false;
441 }
442
443 const VPBasicBlock *Entry = dyn_cast<VPBasicBlock>(TopRegion->getEntry());
444 if (!Entry) {
445 errs() << "VPlan entry block is not a VPBasicBlock\n";
446 return false;
447 }
448
449 if (!isa<VPCanonicalIVPHIRecipe>(&*Entry->begin())) {
450 errs() << "VPlan vector loop header does not start with a "
451 "VPCanonicalIVPHIRecipe\n";
452 return false;
453 }
454
455 const VPBasicBlock *Exiting = dyn_cast<VPBasicBlock>(TopRegion->getExiting());
456 if (!Exiting) {
457 errs() << "VPlan exiting block is not a VPBasicBlock\n";
458 return false;
459 }
460
461 if (Exiting->empty()) {
462 errs() << "VPlan vector loop exiting block must end with BranchOnCount, "
463 "BranchOnCond, or BranchOnTwoConds VPInstruction but is empty\n";
464 return false;
465 }
466
467 auto *LastInst = dyn_cast<VPInstruction>(std::prev(Exiting->end()));
468 if (!match(LastInst, m_CombineOr(m_BranchOnCond(),
470 m_BranchOnTwoConds())))) {
471 errs() << "VPlan vector loop exit must end with BranchOnCount, "
472 "BranchOnCond, or BranchOnTwoConds VPInstruction\n";
473 return false;
474 }
475
476 return true;
477}
478
480 VPDominatorTree VPDT(const_cast<VPlan &>(Plan));
481 VPTypeAnalysis TypeInfo(Plan);
482 VPlanVerifier Verifier(VPDT, TypeInfo);
483 return Verifier.verify(Plan);
484}
assert(UImm &&(UImm !=~static_cast< T >(0)) &&"Invalid immediate!")
ppc ctr loops verify
verify safepoint Safepoint IR Verifier
This file defines the SmallPtrSet class.
static TableGen::Emitter::Opt Y("gen-skeleton-entry", EmitSkeleton, "Generate example skeleton entry")
static TableGen::Emitter::OptClass< SkeletonEmitter > X("gen-skeleton-class", "Generate example skeleton class")
This file implements the TypeSwitch template, which mimics a switch() statement whose cases are type ...
This file implements dominator tree analysis for a single level of a VPlan's H-CFG.
This file contains the declarations of different VPlan-related auxiliary helpers.
static bool hasDuplicates(const SmallVectorImpl< VPBlockBase * > &VPBlockVec)
Utility function that checks whether VPBlockVec has duplicate VPBlockBases.
static bool isKnownMonotonic(VPValue *V)
This file declares the class VPlanVerifier, which contains utility functions to check the consistency...
This file contains the declarations of the Vectorization Plan base classes:
Value * RHS
Value * LHS
@ ICMP_ULT
unsigned less than
Definition InstrTypes.h:701
@ ICMP_ULE
unsigned less or equal
Definition InstrTypes.h:702
bool dominates(const DomTreeNodeBase< NodeT > *A, const DomTreeNodeBase< NodeT > *B) const
dominates - Returns true iff A dominates B.
Implements a dense probed hash-table based set with some number of buckets stored inline.
Definition DenseSet.h:291
std::pair< iterator, bool > insert(PtrType Ptr)
Inserts Ptr if and only if there is no element in the container equal to Ptr.
SmallPtrSet - This class implements a set which is optimized for holding SmallSize or less elements.
This class consists of common code factored out of the SmallVector class to reduce code duplication b...
VPBasicBlock serves as the leaf of the Hierarchical Control-Flow Graph.
Definition VPlan.h:4182
iterator end()
Definition VPlan.h:4219
iterator begin()
Recipe iterator methods.
Definition VPlan.h:4217
bool empty() const
Definition VPlan.h:4228
VPBlockBase is the building block of the Hierarchical Control-Flow Graph.
Definition VPlan.h:81
VPRegionBlock * getParent()
Definition VPlan.h:173
size_t getNumSuccessors() const
Definition VPlan.h:219
size_t getNumPredecessors() const
Definition VPlan.h:220
const VPBlocksTy & getPredecessors() const
Definition VPlan.h:204
VPlan * getPlan()
Definition VPlan.cpp:177
const VPBlocksTy & getSuccessors() const
Definition VPlan.h:198
static bool isHeader(const VPBlockBase *VPB, const VPDominatorTree &VPDT)
Returns true if VPB is a loop header, based on regions or VPDT in their absence.
Template specialization of the standard LLVM dominator tree utility for VPBlockBases.
This is a concrete Recipe that models a single VPlan-level instruction.
Definition VPlan.h:1160
unsigned getOpcode() const
Definition VPlan.h:1338
VPBasicBlock * getParent()
Definition VPlan.h:462
VPRegionBlock represents a collection of VPBasicBlocks and VPRegionBlocks which form a Single-Entry-S...
Definition VPlan.h:4370
const VPBlockBase * getEntry() const
Definition VPlan.h:4406
const VPBlockBase * getExiting() const
Definition VPlan.h:4418
An analysis for type-inference for VPValues.
Type * inferScalarType(const VPValue *V)
Infer the type of V. Returns the scalar type of V.
operand_range operands()
Definition VPlanValue.h:326
unsigned getNumOperands() const
Definition VPlanValue.h:296
This is the base class of the VPlan Def/Use graph, used for modeling the data flow into,...
Definition VPlanValue.h:46
VPlan models a candidate for vectorization, encoding various decisions take to produce efficient outp...
Definition VPlan.h:4500
VPBasicBlock * getEntry()
Definition VPlan.h:4592
bool isUnrolled() const
Returns true if the VPlan already has been unrolled, i.e.
Definition VPlan.h:4743
LLVM_ABI_FOR_TEST VPRegionBlock * getVectorLoopRegion()
Returns the VPRegionBlock of the vector loop.
Definition VPlan.cpp:1033
std::pair< iterator, bool > insert(const ValueT &V)
Definition DenseSet.h:202
@ Entry
Definition COFF.h:862
SpecificConstantMatch m_ZeroInt()
Convenience matchers for specific integer values.
BinaryOp_match< LHS, RHS, Instruction::Add > m_Add(const LHS &L, const RHS &R)
bool match(Val *V, const Pattern &P)
cst_pred_ty< is_one > m_One()
Match an integer 1 or a vector with all elements equal to 1.
CmpClass_match< LHS, RHS, ICmpInst > m_ICmp(CmpPredicate &Pred, const LHS &L, const RHS &R)
match_combine_or< LTy, RTy > m_CombineOr(const LTy &L, const RTy &R)
Combine two pattern matchers matching L || R.
VPInstruction_match< VPInstruction::StepVector > m_StepVector()
VPInstruction_match< VPInstruction::BranchOnTwoConds > m_BranchOnTwoConds()
VPDerivedIV_match< Op0_t, Op1_t, Op2_t > m_DerivedIV(const Op0_t &Op0, const Op1_t &Op1, const Op2_t &Op2)
VPInstruction_match< VPInstruction::BranchOnCount > m_BranchOnCount()
class_match< VPValue > m_VPValue()
Match an arbitrary VPValue and ignore it.
VPInstruction_match< VPInstruction::ExplicitVectorLength, Op0_t > m_EVL(const Op0_t &Op0)
VPInstruction_match< VPInstruction::BranchOnCond > m_BranchOnCond()
NodeAddr< PhiNode * > Phi
Definition RDFGraph.h:390
bool isUniformAcrossVFsAndUFs(VPValue *V)
Checks if V is uniform across all VF lanes and UF parts.
bool isHeaderMask(const VPValue *V, const VPlan &Plan)
Return true if V is a header mask in Plan.
This is an optimization pass for GlobalISel generic memory operations.
Definition Types.h:26
bool all_of(R &&range, UnaryPredicate P)
Provide wrappers to std::all_of which take ranges instead of having to pass begin/end explicitly.
Definition STLExtras.h:1739
decltype(auto) dyn_cast(const From &Val)
dyn_cast<X> - Return the argument parameter cast to the specified type.
Definition Casting.h:643
iterator_range< df_iterator< VPBlockShallowTraversalWrapper< VPBlockBase * > > > vp_depth_first_shallow(VPBlockBase *G)
Returns an iterator range to traverse the graph starting at G in depth-first order.
Definition VPlanCFG.h:262
bool isa_and_nonnull(const Y &Val)
Definition Casting.h:676
bool any_of(R &&range, UnaryPredicate P)
Provide wrappers to std::any_of which take ranges instead of having to pass begin/end explicitly.
Definition STLExtras.h:1746
bool isa(const From &Val)
isa<X> - Return true if the parameter to the template is an instance of one of the template type argu...
Definition Casting.h:547
LLVM_ABI raw_fd_ostream & errs()
This returns a reference to a raw_ostream for standard error.
DWARFExpression::Operation Op
decltype(auto) cast(const From &Val)
cast<X> - Return the argument parameter cast to the specified type.
Definition Casting.h:559
bool is_contained(R &&Range, const E &Element)
Returns true if Element is found in Range.
Definition STLExtras.h:1947
LLVM_ABI_FOR_TEST bool verifyVPlanIsValid(const VPlan &Plan)
Verify invariants for general VPlans.