LLVM  17.0.0git
VPlanDominatorTree.h
Go to the documentation of this file.
1 //===-- VPlanDominatorTree.h ------------------------------------*- C++ -*-===//
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 implements dominator tree analysis for a single level of a VPlan's
11 /// H-CFG.
12 ///
13 //===----------------------------------------------------------------------===//
14 
15 #ifndef LLVM_TRANSFORMS_VECTORIZE_VPLANDOMINATORTREE_H
16 #define LLVM_TRANSFORMS_VECTORIZE_VPLANDOMINATORTREE_H
17 
18 #include "VPlan.h"
19 #include "VPlanCFG.h"
20 #include "llvm/ADT/GraphTraits.h"
21 #include "llvm/IR/Dominators.h"
23 
24 namespace llvm {
25 
26 template <> struct DomTreeNodeTraits<VPBlockBase> {
28  using NodePtr = VPBlockBase *;
29  using ParentPtr = VPlan *;
30 
31  static NodePtr getEntryNode(ParentPtr Parent) { return Parent->getEntry(); }
32  static ParentPtr getParent(NodePtr B) { return B->getPlan(); }
33 };
34 
35 ///
36 /// Template specialization of the standard LLVM dominator tree utility for
37 /// VPBlockBases.
39 
41 
42 /// Template specializations of GraphTraits for VPDomTreeNode.
43 template <>
47 
48 template <>
52 } // namespace llvm
53 #endif // LLVM_TRANSFORMS_VECTORIZE_VPLANDOMINATORTREE_H
llvm
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18
llvm::DomTreeNodeTraits< VPBlockBase >::getParent
static ParentPtr getParent(NodePtr B)
Definition: VPlanDominatorTree.h:32
llvm::DomTreeNodeTraits< VPBlockBase >::getEntryNode
static NodePtr getEntryNode(ParentPtr Parent)
Definition: VPlanDominatorTree.h:31
VPlanCFG.h
llvm::VPDomTreeNode
DomTreeNodeBase< VPBlockBase > VPDomTreeNode
Definition: VPlanDominatorTree.h:40
GraphTraits.h
llvm::VPBlockBase
VPBlockBase is the building block of the Hierarchical Control-Flow Graph.
Definition: VPlan.h:390
llvm::DomTreeGraphTraitsBase
Definition: Dominators.h:239
B
static GCRegistry::Add< OcamlGC > B("ocaml", "ocaml 3.10-compatible GC")
VPlan.h
const
aarch64 promote const
Definition: AArch64PromoteConstant.cpp:232
llvm::VPlan::getEntry
VPBlockBase * getEntry()
Definition: VPlan.h:2223
llvm::DominatorTreeBase
Core dominator tree base class.
Definition: LoopInfo.h:66
llvm::DomTreeNodeBase< VPBlockBase >
GenericDomTree.h
llvm::DomTreeNodeBase< VPBlockBase >::const_iterator
typename SmallVector< DomTreeNodeBase *, 4 >::const_iterator const_iterator
Definition: GenericDomTree.h:74
Dominators.h
llvm::GraphTraits
Definition: GraphTraits.h:37
llvm::DomTreeNodeTraits
Default DomTreeNode traits for NodeT.
Definition: GenericDomTree.h:226
llvm::VPlan
VPlan models a candidate for vectorization, encoding various decisions take to produce efficient outp...
Definition: VPlan.h:2160