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

Subclass of DDGNode representing single or multi-instruction nodes. More...

#include "llvm/Analysis/DDG.h"

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

Public Member Functions

 SimpleDDGNode ()=delete
 
 SimpleDDGNode (Instruction &I)
 
 SimpleDDGNode (const SimpleDDGNode &N)
 
 SimpleDDGNode (SimpleDDGNode &&N)
 
 ~SimpleDDGNode ()
 
SimpleDDGNodeoperator= (const SimpleDDGNode &N)
 
SimpleDDGNodeoperator= (SimpleDDGNode &&N)
 
const InstructionListTypegetInstructions () const
 Get the list of instructions in this node. More...
 
InstructionListTypegetInstructions ()
 
InstructiongetFirstInstruction () const
 Get the first/last instruction in the node. More...
 
InstructiongetLastInstruction () const
 
- Public Member Functions inherited from llvm::DDGNode
 DDGNode ()=delete
 
 DDGNode (const NodeKind K)
 
 DDGNode (const DDGNode &N)
 
 DDGNode (DDGNode &&N)
 
virtual ~DDGNode ()=0
 
DDGNodeoperator= (const DDGNode &N)
 
DDGNodeoperator= (DDGNode &&N)
 
NodeKind getKind () const
 Getter for the kind of this node. More...
 
bool collectInstructions (llvm::function_ref< bool(Instruction *)> const &Pred, InstructionListType &IList) const
 Collect a list of instructions, in IList, for which predicate Pred evaluates to true when iterating over instructions of this node. More...
 
- Public Member Functions inherited from llvm::DGNode< NodeType, EdgeType >
 DGNode (EdgeType &E)
 Create a node with a single outgoing edge E. More...
 
 DGNode ()=default
 
 DGNode (const DGNode< NodeType, EdgeType > &N)
 
 DGNode (DGNode< NodeType, EdgeType > &&N)
 
DGNode< NodeType, EdgeType > & operator= (const DGNode< NodeType, EdgeType > &N)
 
DGNode< NodeType, EdgeType > & operator= (const DGNode< NodeType, EdgeType > &&N)
 
bool operator== (const NodeType &N) const
 Static polymorphism: delegate implementation (via isEqualTo) to the derived class. More...
 
bool operator!= (const NodeType &N) const
 
const_iterator begin () const
 
const_iterator end () const
 
iterator begin ()
 
iterator end ()
 
const EdgeType & front () const
 
EdgeType & front ()
 
const EdgeType & back () const
 
EdgeType & back ()
 
bool findEdgesTo (const NodeType &N, SmallVectorImpl< EdgeType *> &EL) const
 Collect in EL, all the edges from this node to N. More...
 
bool addEdge (EdgeType &E)
 Add the given edge E to this node, if it doesn't exist already. More...
 
void removeEdge (EdgeType &E)
 Remove the given edge E from this node, if it exists. More...
 
bool hasEdgeTo (const NodeType &N) const
 Test whether there is an edge that goes from this node to N. More...
 
const EdgeListTygetEdges () const
 Retrieve the outgoing edges for the node. More...
 
EdgeListTygetEdges ()
 
void clear ()
 Clear the outgoing edges. More...
 

Static Public Member Functions

static bool classof (const DDGNode *N)
 Define classof to be able to use isa<>, cast<>, dyn_cast<>, etc. More...
 
static bool classof (const SimpleDDGNode *N)
 

Additional Inherited Members

- Public Types inherited from llvm::DDGNode
enum  NodeKind { NodeKind::Unknown, NodeKind::SingleInstruction, NodeKind::MultiInstruction, NodeKind::Root }
 
using InstructionListType = SmallVectorImpl< Instruction * >
 
- Public Types inherited from llvm::DGNode< NodeType, EdgeType >
using EdgeListTy = SetVector< EdgeType * >
 
using iterator = typename EdgeListTy::iterator
 
using const_iterator = typename EdgeListTy::const_iterator
 
- Protected Member Functions inherited from llvm::DDGNode
void setKind (NodeKind K)
 Setter for the kind of this node. More...
 
- Protected Member Functions inherited from llvm::DGNode< NodeType, EdgeType >
bool isEqualTo (const NodeType &N) const
 
NodeType & getDerived ()
 
const NodeType & getDerived () const
 
const_iterator findEdgeTo (const NodeType &N) const
 Find an edge to N. More...
 
- Protected Attributes inherited from llvm::DGNode< NodeType, EdgeType >
EdgeListTy Edges
 

Detailed Description

Subclass of DDGNode representing single or multi-instruction nodes.

Definition at line 101 of file DDG.h.

Constructor & Destructor Documentation

◆ SimpleDDGNode() [1/4]

llvm::SimpleDDGNode::SimpleDDGNode ( )
delete

◆ SimpleDDGNode() [2/4]

SimpleDDGNode::SimpleDDGNode ( Instruction I)

Definition at line 79 of file DDG.cpp.

References assert().

◆ SimpleDDGNode() [3/4]

SimpleDDGNode::SimpleDDGNode ( const SimpleDDGNode N)

◆ SimpleDDGNode() [4/4]

SimpleDDGNode::SimpleDDGNode ( SimpleDDGNode &&  N)

◆ ~SimpleDDGNode()

SimpleDDGNode::~SimpleDDGNode ( )

Definition at line 99 of file DDG.cpp.

Member Function Documentation

◆ classof() [1/2]

static bool llvm::SimpleDDGNode::classof ( const DDGNode N)
inlinestatic

Define classof to be able to use isa<>, cast<>, dyn_cast<>, etc.

Definition at line 136 of file DDG.h.

References llvm::DDGNode::getKind(), llvm::DDGNode::MultiInstruction, and llvm::DDGNode::SingleInstruction.

◆ classof() [2/2]

static bool llvm::SimpleDDGNode::classof ( const SimpleDDGNode N)
inlinestatic

◆ getFirstInstruction()

Instruction* llvm::SimpleDDGNode::getFirstInstruction ( ) const
inline

Get the first/last instruction in the node.

Definition at line 132 of file DDG.h.

◆ getInstructions() [1/2]

const InstructionListType& llvm::SimpleDDGNode::getInstructions ( ) const
inline

Get the list of instructions in this node.

Definition at line 122 of file DDG.h.

References assert().

Referenced by classof().

◆ getInstructions() [2/2]

InstructionListType& llvm::SimpleDDGNode::getInstructions ( )
inline

Definition at line 126 of file DDG.h.

◆ getLastInstruction()

Instruction* llvm::SimpleDDGNode::getLastInstruction ( ) const
inline

Definition at line 133 of file DDG.h.

◆ operator=() [1/2]

SimpleDDGNode& llvm::SimpleDDGNode::operator= ( const SimpleDDGNode N)
inline

Definition at line 109 of file DDG.h.

References llvm::DDGNode::operator=().

◆ operator=() [2/2]

SimpleDDGNode& llvm::SimpleDDGNode::operator= ( SimpleDDGNode &&  N)
inline

Definition at line 115 of file DDG.h.

References llvm::DDGNode::operator=().


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