SVF
Protected Member Functions | Private Member Functions | List of all members
SVF::GepPE Class Reference

#include <PAGEdge.h>

Inheritance diagram for SVF::GepPE:
SVF::PAGEdge SVF::GenericEdge< NodeTy > SVF::NormalGepPE SVF::VariantGepPE

Static Public Member Functions

static bool classof (const GepPE *)
 Methods for support type inquiry through isa, cast, and dyn_cast: More...
 
static bool classof (const PAGEdge *edge)
 
static bool classof (const GenericPAGEdgeTy *edge)
 
- Static Public Member Functions inherited from SVF::PAGEdge
static GEdgeFlag makeEdgeFlagWithCallInst (GEdgeKind k, const ICFGNode *cs)
 Compute the unique edgeFlag value from edge kind and call site Instruction. More...
 
static GEdgeFlag makeEdgeFlagWithStoreInst (GEdgeKind k, const ICFGNode *store)
 
static bool classof (const PAGEdge *)
 ClassOf. More...
 
static bool classof (const GenericPAGEdgeTy *edge)
 

Protected Member Functions

 GepPE (PAGNode *s, PAGNode *d, PEDGEK k)
 constructor More...
 
virtual const std::string toString () const
 

Private Member Functions

 GepPE ()
 place holder More...
 
 GepPE (const GepPE &)
 place holder More...
 
void operator= (const GepPE &)
 place holder More...
 

Additional Inherited Members

- Public Types inherited from SVF::PAGEdge
enum  PEDGEK {
  Addr, Copy, Store, Load,
  Call, Ret, NormalGep, VariantGep,
  ThreadFork, ThreadJoin, Cmp, BinaryOp,
  UnaryOp
}
 
typedef GenericNode< PAGNode, PAGEdge >::GEdgeSetTy PAGEdgeSetTy
 
typedef Map< EdgeID, PAGEdgeSetTy > PAGEdgeToSetMapTy
 
typedef PAGEdgeToSetMapTy PAGKindToEdgeSetMapTy
 
- Public Types inherited from SVF::GenericEdge< NodeTy >
typedef NodeTy NodeType
 Node type. More...
 
typedef u64_t GEdgeFlag
 
typedef s32_t GEdgeKind
 
typedef struct SVF::GenericEdge::equalGEdge equalGEdge
 Add the hash function for std::set (we also can overload operator< to implement this) More...
 
- Public Member Functions inherited from SVF::PAGEdge
 PAGEdge (PAGNode *s, PAGNode *d, GEdgeFlag k)
 Constructor. More...
 
 ~PAGEdge ()
 Destructor. More...
 
EdgeID getEdgeID () const
 Return Edge ID. More...
 
bool isPTAEdge () const
 Whether src and dst nodes are both of pointer type. More...
 
const Instruction * getInst () const
 Get/set methods for llvm instruction. More...
 
void setValue (const Value *val)
 
const Value * getValue () const
 
void setBB (const BasicBlock *bb)
 
const BasicBlock * getBB () const
 
void setICFGNode (ICFGNode *node)
 
ICFGNode * getICFGNode () const
 
- Public Member Functions inherited from SVF::GenericEdge< NodeTy >
 GenericEdge (NodeTy *s, NodeTy *d, GEdgeFlag k)
 Constructor. More...
 
virtual ~GenericEdge ()
 Destructor. More...
 
NodeID getSrcID () const
 get methods of the components More...
 
NodeID getDstID () const
 
GEdgeKind getEdgeKind () const
 
NodeType * getSrcNode () const
 
NodeType * getDstNode () const
 
bool operator== (const GenericEdge< NodeType > *rhs) const
 
- Static Public Attributes inherited from SVF::PAGEdge
static Size_t totalEdgeNum
 Total edge number. More...
 
- Static Protected Attributes inherited from SVF::GenericEdge< NodeTy >
static constexpr unsigned char EdgeKindMaskBits = 8
 We use the lower 8 bits to denote edge kind. More...
 
static constexpr u64_t EdgeKindMask = (~0ULL) >> (64 - EdgeKindMaskBits)
 

Detailed Description

Gep edge

Definition at line 432 of file PAGEdge.h.

Constructor & Destructor Documentation

◆ GepPE() [1/3]

SVF::GepPE::GepPE ( )
private

place holder

◆ GepPE() [2/3]

SVF::GepPE::GepPE ( const GepPE &  )
private

place holder

◆ GepPE() [3/3]

SVF::GepPE::GepPE ( PAGNode *  s,
PAGNode *  d,
PEDGEK  k 
)
inlineprotected

constructor

Definition at line 460 of file PAGEdge.h.

460  : PAGEdge(s,d,k)
461  {
462 
463  }
PAGEdge(PAGNode *s, PAGNode *d, GEdgeFlag k)
Constructor.
Definition: PAG.cpp:1000

Member Function Documentation

◆ classof() [1/3]

static bool SVF::GepPE::classof ( const GepPE *  )
inlinestatic

Methods for support type inquiry through isa, cast, and dyn_cast:

Definition at line 442 of file PAGEdge.h.

443  {
444  return true;
445  }

◆ classof() [2/3]

static bool SVF::GepPE::classof ( const PAGEdge *  edge)
inlinestatic

Definition at line 446 of file PAGEdge.h.

447  {
448  return edge->getEdgeKind() == PAGEdge::NormalGep ||
449  edge->getEdgeKind() == PAGEdge::VariantGep;
450  }

◆ classof() [3/3]

static bool SVF::GepPE::classof ( const GenericPAGEdgeTy *  edge)
inlinestatic

Definition at line 451 of file PAGEdge.h.

452  {
453  return edge->getEdgeKind() == PAGEdge::NormalGep ||
454  edge->getEdgeKind() == PAGEdge::VariantGep;
455  }

◆ operator=()

void SVF::GepPE::operator= ( const GepPE &  )
private

place holder

◆ toString()

const std::string GepPE::toString ( ) const
protectedvirtual

Reimplemented from SVF::PAGEdge.

Reimplemented in SVF::VariantGepPE, and SVF::NormalGepPE.

Definition at line 284 of file PAG.cpp.

284  {
285  std::string str;
286  raw_string_ostream rawstr(str);
287  rawstr << "GepPE: [" << getDstID() << "<--" << getSrcID() << "]\t";
289  rawstr << "\n";
290  }
291  rawstr << value2String(getValue());
292  return rawstr.str();
293 }
const Value * getValue() const
Definition: PAGEdge.h:116
NodeID getDstID() const
Definition: GenericGraph.h:77
NodeID getSrcID() const
get methods of the components
Definition: GenericGraph.h:73
static const llvm::cl::opt< bool > PAGDotGraphShorter
Definition: Options.h:88
llvm::raw_string_ostream raw_string_ostream
Definition: BasicTypes.h:100
const std::string value2String(const Value *value)
Definition: SVFUtil.cpp:359

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