LLVM  10.0.0svn
Public Member Functions | List of all members
llvm::DDGBuilder Class Reference

Concrete implementation of a pure data dependence graph builder. More...

#include "llvm/Analysis/DDG.h"

Inheritance diagram for llvm::DDGBuilder:
Inheritance graph
[legend]
Collaboration diagram for llvm::DDGBuilder:
Collaboration graph
[legend]

Public Member Functions

 DDGBuilder (DataDependenceGraph &G, DependenceInfo &D, const BasicBlockListType &BBs)
 
DDGNodecreateRootNode () final override
 Create the root node of the graph. More...
 
DDGNodecreateFineGrainedNode (Instruction &I) final override
 Create an atomic node in the graph given a single instruction. More...
 
DDGEdgecreateDefUseEdge (DDGNode &Src, DDGNode &Tgt) final override
 
DDGEdgecreateMemoryEdge (DDGNode &Src, DDGNode &Tgt) final override
 
DDGEdgecreateRootedEdge (DDGNode &Src, DDGNode &Tgt) final override
 
- Public Member Functions inherited from llvm::AbstractDependenceGraphBuilder< DataDependenceGraph >
 AbstractDependenceGraphBuilder (DataDependenceGraph &G, DependenceInfo &D, const BasicBlockListType &BBs)
 
virtual ~AbstractDependenceGraphBuilder ()
 
void populate ()
 The main entry to the graph construction algorithm. More...
 
void createFineGrainedNodes ()
 Create fine grained nodes. More...
 
void createDefUseEdges ()
 Analyze the def-use chains and create edges from the nodes containing definitions to the nodes containing the uses. More...
 
void createMemoryDependencyEdges ()
 Analyze data dependencies that exist between memory loads or stores, in the graph nodes and create edges between them. More...
 
void createAndConnectRootNode ()
 Create a root node and add edges such that each node in the graph is reachable from the root. More...
 

Additional Inherited Members

- Public Types inherited from llvm::AbstractDependenceGraphBuilder< DataDependenceGraph >
using ClassesType = EquivalenceClasses< BasicBlock *>
 
using NodeListType = SmallVector< NodeType *, 4 >
 
- Protected Types inherited from llvm::AbstractDependenceGraphBuilder< DataDependenceGraph >
using BasicBlockListType = SmallVectorImpl< BasicBlock *>
 
using InstToNodeMap = DenseMap< Instruction *, NodeType *>
 Map types to map instructions to nodes used when populating the graph. More...
 
- Protected Member Functions inherited from llvm::AbstractDependenceGraphBuilder< DataDependenceGraph >
virtual EdgeType & createDefUseEdge (NodeType &Src, NodeType &Tgt)=0
 Create a def-use edge going from Src to Tgt. More...
 
virtual EdgeType & createMemoryEdge (NodeType &Src, NodeType &Tgt)=0
 Create a memory dependence edge going from Src to Tgt. More...
 
virtual EdgeType & createRootedEdge (NodeType &Src, NodeType &Tgt)=0
 Create a rooted edge going from Src to Tgt . More...
 
virtual void destroyEdge (EdgeType &E)
 Deallocate memory of edge E. More...
 
virtual void destroyNode (NodeType &N)
 Deallocate memory of node N. More...
 
- Protected Attributes inherited from llvm::AbstractDependenceGraphBuilder< DataDependenceGraph >
DataDependenceGraphGraph
 Reference to the graph that gets built by a concrete implementation of this builder. More...
 
DependenceInfoDI
 Dependence information used to create memory dependence edges in the graph. More...
 
const BasicBlockListTypeBBList
 The list of basic blocks to consider when building the graph. More...
 
InstToNodeMap IMap
 A mapping from instructions to the corresponding nodes in the graph. More...
 

Detailed Description

Concrete implementation of a pure data dependence graph builder.

This class provides custom implementation for the pure-virtual functions used in the generic dependence graph build algorithm.

For information about time complexity of the build algorithm see the comments near the declaration of AbstractDependenceGraphBuilder.

Definition at line 270 of file DDG.h.

Constructor & Destructor Documentation

◆ DDGBuilder()

llvm::DDGBuilder::DDGBuilder ( DataDependenceGraph G,
DependenceInfo D,
const BasicBlockListType BBs 
)
inline

Definition at line 272 of file DDG.h.

Member Function Documentation

◆ createDefUseEdge()

DDGEdge& llvm::DDGBuilder::createDefUseEdge ( DDGNode Src,
DDGNode Tgt 
)
inlinefinaloverride

Definition at line 287 of file DDG.h.

References assert(), E, and llvm::DDGEdge::RegisterDefUse.

◆ createFineGrainedNode()

DDGNode& llvm::DDGBuilder::createFineGrainedNode ( Instruction I)
inlinefinaloverridevirtual

Create an atomic node in the graph given a single instruction.

Implements llvm::AbstractDependenceGraphBuilder< DataDependenceGraph >.

Definition at line 281 of file DDG.h.

References assert(), and I.

◆ createMemoryEdge()

DDGEdge& llvm::DDGBuilder::createMemoryEdge ( DDGNode Src,
DDGNode Tgt 
)
inlinefinaloverride

Definition at line 293 of file DDG.h.

References assert(), E, and llvm::DDGEdge::MemoryDependence.

◆ createRootedEdge()

DDGEdge& llvm::DDGBuilder::createRootedEdge ( DDGNode Src,
DDGNode Tgt 
)
inlinefinaloverride

Definition at line 299 of file DDG.h.

References assert(), E, G, N, llvm::operator<<(), and llvm::DDGEdge::Rooted.

◆ createRootNode()

DDGNode& llvm::DDGBuilder::createRootNode ( )
inlinefinaloverridevirtual

Create the root node of the graph.

Implements llvm::AbstractDependenceGraphBuilder< DataDependenceGraph >.

Definition at line 275 of file DDG.h.

References assert(), and llvm::NVPTX::PTXCvtMode::RN.


The documentation for this class was generated from the following file: