Public Member Functions | Private Attributes

OA::ReachConsts::ConstDef Class Reference

Associates a location pointer with a constValBasic pointer. More...

#include <ReachConstsStandard.hpp>

Inheritance diagram for OA::ReachConsts::ConstDef:
Inheritance graph
[legend]
Collaboration diagram for OA::ReachConsts::ConstDef:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ConstDef (OA_ptr< Location > locP, OA_ptr< ConstValBasicInterface > cvbP, ConstDefType cdType)
 ConstDef (OA_ptr< Location > locP, OA_ptr< ConstValBasicInterface > cvbP)
 ConstDef (OA_ptr< Location > locP, ConstDefType cdType)
 ConstDef (OA_ptr< Location > locP)
 ConstDef (ConstDef &other)
 ConstDef ()
 ~ConstDef ()
OA_ptr< LocationgetLocPtr () const
OA_ptr< ConstValBasicInterfacegetConstPtr () const
ConstDefType getConstDefType () const
ConstDefoperator= (const ConstDef &other)
OA_ptr< ConstDefclone ()
 not doing a deep copy
void output (IRHandlesIRInterface &pIR)
bool operator== (const ConstDef &other) const
 operator== just compares content of locPtr
bool equiv (const ConstDef &other)
 method equiv compares all parts of ConstDef as appropriate
bool operator!= (const ConstDef &other) const
bool operator< (const ConstDef &other) const
bool sameLoc (const ConstDef &other) const
std::string toString (OA_ptr< IRHandlesIRInterface > pIR)
 Return a string that contains a character representation of.
void dump (std::ostream &os, OA_ptr< IRHandlesIRInterface > pIR)

Private Attributes

OA_ptr< LocationmLocPtr
OA_ptr< ConstValBasicInterfacemConstPtr
ConstDefType mCDType

Detailed Description

Associates a location pointer with a constValBasic pointer.

Definition at line 56 of file ReachConstsStandard.hpp.


Constructor & Destructor Documentation

OA::ReachConsts::ConstDef::ConstDef ( OA_ptr< Location locP,
OA_ptr< ConstValBasicInterface cvbP,
ConstDefType  cdType 
)

ConstDef constructor: using given location and given constant and given ConstDefType. Use with caution as ConstDefType indicates ConstValBasicInterface usage in other routines.

Definition at line 28 of file ReachConstsStandard.cpp.

OA::ReachConsts::ConstDef::ConstDef ( OA_ptr< Location locP,
OA_ptr< ConstValBasicInterface cvbP 
)

ConstDef constructor: using given location and given constant and default ConstDefType VALUE.

Definition at line 40 of file ReachConstsStandard.cpp.

References mCDType, mConstPtr, mLocPtr, and OA::OA_ptr< T >::ptrEqual().

Here is the call graph for this function:

OA::ReachConsts::ConstDef::ConstDef ( OA_ptr< Location locP,
ConstDefType  cdType 
)

ConstDef constructor: using given location and given ConstDefType and default ConstValBasicInterface of 0. Correct usage only involves a ConstDefType of TOP or BOTTOM. Using VALUE causes an assertion failure.

Definition at line 55 of file ReachConstsStandard.cpp.

OA::ReachConsts::ConstDef::ConstDef ( OA_ptr< Location locP  ) 

ConstDef constructor: using given location and default ConstDefType of TOP and default ConstValBasicInterface of 0.

Definition at line 66 of file ReachConstsStandard.cpp.

References mCDType, mConstPtr, and mLocPtr.

OA::ReachConsts::ConstDef::ConstDef ( ConstDef other  )  [inline]

Definition at line 66 of file ReachConstsStandard.hpp.

OA::ReachConsts::ConstDef::ConstDef (  )  [inline]

Definition at line 69 of file ReachConstsStandard.hpp.

Referenced by clone().

OA::ReachConsts::ConstDef::~ConstDef (  )  [inline]

Definition at line 70 of file ReachConstsStandard.hpp.


Member Function Documentation

OA_ptr<ConstDef> OA::ReachConsts::ConstDef::clone (  )  [inline]

not doing a deep copy

Definition at line 81 of file ReachConstsStandard.hpp.

References ConstDef().

Here is the call graph for this function:

void OA::ReachConsts::ConstDef::dump ( std::ostream &  os,
OA_ptr< IRHandlesIRInterface pIR 
) [inline]

Definition at line 107 of file ReachConstsStandard.hpp.

References toString().

Here is the call graph for this function:

bool OA::ReachConsts::ConstDef::equiv ( const ConstDef other  ) 

method equiv compares all parts of ConstDef as appropriate

Equality method for ConstDef. If locations are equal and const types are equal, then true for TOP or BOTTOM. If locations are equal and const types are both VALUE, then true when actual const values are equal. False otherwise.

Definition at line 106 of file ReachConstsStandard.cpp.

ConstDefType OA::ReachConsts::ConstDef::getConstDefType (  )  const [inline]

Definition at line 75 of file ReachConstsStandard.hpp.

References mCDType.

Referenced by operator=().

OA_ptr<ConstValBasicInterface> OA::ReachConsts::ConstDef::getConstPtr (  )  const [inline]

Definition at line 74 of file ReachConstsStandard.hpp.

References mConstPtr.

Referenced by operator=().

OA_ptr<Location> OA::ReachConsts::ConstDef::getLocPtr (  )  const [inline]

Definition at line 73 of file ReachConstsStandard.hpp.

References mLocPtr.

Referenced by operator<(), operator=(), and sameLoc().

bool OA::ReachConsts::ConstDef::operator!= ( const ConstDef other  )  const [inline]

Definition at line 94 of file ReachConstsStandard.hpp.

bool OA::ReachConsts::ConstDef::operator< ( const ConstDef other  )  const

Just based on location, this way when insert a new ConstDef it can override the existing ConstDef with same location

Definition at line 93 of file ReachConstsStandard.cpp.

References getLocPtr(), and mLocPtr.

Here is the call graph for this function:

ConstDef & OA::ReachConsts::ConstDef::operator= ( const ConstDef other  ) 

copy a ConstDef, not a deep copy, will refer to same Location and ConstValBasicInterface as other

Definition at line 74 of file ReachConstsStandard.cpp.

References getConstDefType(), getConstPtr(), getLocPtr(), mCDType, mConstPtr, and mLocPtr.

Here is the call graph for this function:

bool OA::ReachConsts::ConstDef::operator== ( const ConstDef other  )  const

operator== just compares content of locPtr

Equality operator for ConstDef. Just inspects location contents.

Definition at line 82 of file ReachConstsStandard.cpp.

void OA::ReachConsts::ConstDef::output ( OA::IRHandlesIRInterface ir  )  [virtual]
bool OA::ReachConsts::ConstDef::sameLoc ( const ConstDef other  )  const [inline]

Definition at line 96 of file ReachConstsStandard.hpp.

References getLocPtr(), and mLocPtr.

Here is the call graph for this function:

std::string OA::ReachConsts::ConstDef::toString ( OA_ptr< IRHandlesIRInterface pIR  ) 

Return a string that contains a character representation of.

Definition at line 159 of file ReachConstsStandard.cpp.

References OA::ReachConsts::BOTTOM, mCDType, OA::ReachConsts::TOP, and OA::ReachConsts::VALUE.

Referenced by dump().


Member Data Documentation

Definition at line 116 of file ReachConstsStandard.hpp.

Referenced by ConstDef(), getConstDefType(), operator=(), output(), and toString().

Definition at line 115 of file ReachConstsStandard.hpp.

Referenced by ConstDef(), getConstPtr(), and operator=().

Definition at line 114 of file ReachConstsStandard.hpp.

Referenced by ConstDef(), getLocPtr(), operator<(), operator=(), output(), and sameLoc().


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