Static Value-Flow Analysis
Loading...
Searching...
No Matches
SVF::SVFArrayType Class Reference

#include <SVFType.h>

Inheritance diagram for SVF::SVFArrayType:
SVF::SVFType

Public Member Functions

 SVFArrayType (u32_t i, u32_t byteSize=1)
 For printing & debugging.
void print (std::ostream &os) const override
const SVFType * getTypeOfElement () const
void setTypeOfElement (const SVFType *elemType)
void setNumOfElement (unsigned elemNum)
Public Member Functions inherited from SVF::SVFType
 SVFType (void)=delete
virtual ~SVFType ()
GNodeK getKind () const
std::string toString () const
u32_t getId () const
void setTypeInfo (StInfo *ti)
StInfo * getTypeInfo ()
const StInfo * getTypeInfo () const
u32_t getByteSize () const
bool isPointerTy () const
bool isArrayTy () const
bool isStructTy () const
bool isSingleValueType () const

Static Public Member Functions

static bool classof (const SVFType *node)
Static Public Member Functions inherited from SVF::SVFType
static SVFType * getSVFPtrType ()
static SVFType * getSVFInt8Type ()

Protected Member Functions

const unsigned getNumOfElement () const
Protected Member Functions inherited from SVF::SVFType
 SVFType (bool svt, SVFTyKind k, u32_t i=0, u32_t Sz=1)

Private Attributes

unsigned numOfElement
const SVFType * typeOfElement
 For printing & debugging.

Friends

class GraphDBClient

Additional Inherited Members

Public Types inherited from SVF::SVFType
enum  SVFTyKind {
  SVFTy , SVFPointerTy , SVFIntegerTy , SVFFunctionTy ,
  SVFStructTy , SVFArrayTy , SVFOtherTy
}
typedef s64_t GNodeK
Static Protected Member Functions inherited from SVF::SVFType
static void setSVFPtrType (SVFType *ptrTy)
 set svfptrty and svfi8ty when initializing SVFType from db query results
static void setSVFInt8Type (SVFType *i8Ty)

Detailed Description

Definition at line 474 of file SVFType.h.

Constructor & Destructor Documentation

◆ SVFArrayType()

SVF::SVFArrayType::SVFArrayType ( u32_t i,
u32_t byteSize = 1 )
inline

For printing & debugging.

Definition at line 489 of file SVFType.h.

490 : SVFType(false, SVFArrayTy, i, byteSize), numOfElement(0), typeOfElement(nullptr)
491 {
492 }
const SVFType * typeOfElement
For printing & debugging.
Definition SVFType.h:486
unsigned numOfElement
Definition SVFType.h:485
u32_t byteSize
LLVM Byte Size.
Definition SVFType.h:237
SVFType(void)=delete

Member Function Documentation

◆ classof()

bool SVF::SVFArrayType::classof ( const SVFType * node)
inlinestatic

Definition at line 494 of file SVFType.h.

495 {
496 return node->getKind() == SVFArrayTy;
497 }

◆ getNumOfElement()

const unsigned SVF::SVFArrayType::getNumOfElement ( ) const
inlineprotected

Definition at line 479 of file SVFType.h.

480 {
481 return numOfElement;
482 }

◆ getTypeOfElement()

const SVFType * SVF::SVFArrayType::getTypeOfElement ( ) const
inline

Definition at line 501 of file SVFType.h.

502 {
503 return typeOfElement;
504 }

◆ print()

void SVF::SVFArrayType::print ( std::ostream & os) const
overridevirtual

Implements SVF::SVFType.

Definition at line 81 of file SVFType.cpp.

82{
83 os << '[' << numOfElement << 'x' << *typeOfElement << ']';
84}

◆ setNumOfElement()

void SVF::SVFArrayType::setNumOfElement ( unsigned elemNum)
inline

Definition at line 511 of file SVFType.h.

512 {
513 numOfElement = elemNum;
514 }

◆ setTypeOfElement()

void SVF::SVFArrayType::setTypeOfElement ( const SVFType * elemType)
inline

Definition at line 506 of file SVFType.h.

507 {
508 typeOfElement = elemType;
509 }

◆ GraphDBClient

friend class GraphDBClient
friend

Definition at line 476 of file SVFType.h.

Member Data Documentation

◆ numOfElement

unsigned SVF::SVFArrayType::numOfElement
private

Definition at line 485 of file SVFType.h.

◆ typeOfElement

const SVFType* SVF::SVFArrayType::typeOfElement
private

For printing & debugging.

Definition at line 486 of file SVFType.h.


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