Static Value-Flow Analysis
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Private Attributes | List of all members
SVF::CDGEdge Class Reference

#include <CDG.h>

Inheritance diagram for SVF::CDGEdge:
SVF::GenericEdge< NodeTy >

Public Types

typedef std::pair< const SVFVar *, s32_t > BranchCondition
 
typedef GenericNode< CDGNode, CDGEdge >::GEdgeSetTy CDGEdgeSetTy
 
typedef CDGEdgeSetTy SVFGEdgeSetTy
 
- Public Types inherited from SVF::GenericEdge< NodeTy >
typedef NodeTy NodeType
 Node type.
 
typedef u64_t GEdgeFlag
 
typedef s64_t GEdgeKind
 
typedef struct SVF::GenericEdge::equalGEdge equalGEdge
 Add the hash function for std::set (we also can overload operator< to implement this)
 

Public Member Functions

 CDGEdge (CDGNode *s, CDGNode *d)
 Constructor.
 
 ~CDGEdge ()
 Destructor.
 
virtual const std::string toString () const
 
const Set< BranchCondition > & getBranchConditions () const
 get/set branch condition
 
void insertBranchCondition (const SVFVar *pNode, s32_t branchID)
 
- Public Member Functions inherited from SVF::GenericEdge< NodeTy >
 GenericEdge (NodeTy *s, NodeTy *d, GEdgeFlag k)
 Constructor.
 
virtual ~GenericEdge ()
 Destructor.
 
NodeID getSrcID () const
 get methods of the components
 
NodeID getDstID () const
 
GEdgeKind getEdgeKind () const
 
GEdgeKind getEdgeKindWithoutMask () const
 
NodeType * getSrcNode () const
 
NodeType * getDstNode () const
 
virtual bool operator== (const GenericEdge< NodeType > *rhs) const
 

Private Attributes

Set< BranchCondition > brConditions
 

Additional Inherited Members

- Static Protected Attributes inherited from SVF::GenericEdge< NodeTy >
static constexpr unsigned char EdgeKindMaskBits = 8
 We use the lower 8 bits to denote edge kind.
 
static constexpr u64_t EdgeKindMask = (~0ULL) >> (64 - EdgeKindMaskBits)
 

Detailed Description

Definition at line 48 of file CDG.h.

Member Typedef Documentation

◆ BranchCondition

Definition at line 51 of file CDG.h.

◆ CDGEdgeSetTy

Definition at line 63 of file CDG.h.

◆ SVFGEdgeSetTy

Definition at line 64 of file CDG.h.

Constructor & Destructor Documentation

◆ CDGEdge()

SVF::CDGEdge::CDGEdge ( CDGNode *  s,
CDGNode *  d 
)
inline

Constructor.

Definition at line 54 of file CDG.h.

54 : GenericCDGEdgeTy(s, d, 0)
55 {
56 }
llvm::IRBuilder IRBuilder
Definition BasicTypes.h:76
GenericEdge< CDGNode > GenericCDGEdgeTy
Definition CDG.h:46

◆ ~CDGEdge()

SVF::CDGEdge::~CDGEdge ( )
inline

Destructor.

Definition at line 59 of file CDG.h.

60 {
61 }

Member Function Documentation

◆ getBranchConditions()

const Set< BranchCondition > & SVF::CDGEdge::getBranchConditions ( ) const
inline

get/set branch condition

Definition at line 77 of file CDG.h.

78 {
79 return brConditions;
80 }
Set< BranchCondition > brConditions
Definition CDG.h:90

◆ insertBranchCondition()

void SVF::CDGEdge::insertBranchCondition ( const SVFVar *  pNode,
s32_t  branchID 
)
inline

Definition at line 82 of file CDG.h.

83 {
84 brConditions.insert(std::make_pair(pNode, branchID));
85 }

◆ toString()

virtual const std::string SVF::CDGEdge::toString ( ) const
inlinevirtual

Definition at line 66 of file CDG.h.

67 {
68 std::string str;
69 std::stringstream rawstr(str);
70 rawstr << "CDGEdge " << " [";
71 rawstr << getDstID() << "<--" << getSrcID() << "\t";
72 return rawstr.str();
73 }
NodeID getDstID() const
NodeID getSrcID() const
get methods of the components

Member Data Documentation

◆ brConditions

Set<BranchCondition> SVF::CDGEdge::brConditions
private

Definition at line 90 of file CDG.h.


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