OpenADFortTk (including Open64 and OpenAnalysis references)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
OA::MemRefExpr Class Referenceabstract

#include <MemRefExpr.hpp>

Inheritance diagram for OA::MemRefExpr:
Inheritance graph
Collaboration diagram for OA::MemRefExpr:
Collaboration graph

Public Types

enum  MemRefType { USE, DEF, USEDEF, DEFUSE }
 

Public Member Functions

 MemRefExpr (MemRefType mrType)
 
 MemRefExpr (MemRefExpr &mre)
 copy constructor More...
 
virtual ~MemRefExpr ()
 
virtual void acceptVisitor (MemRefExprVisitor &pVisitor)=0
 
virtual OA_ptr< MemRefExprclone ()=0
 
virtual bool isaNamed ()
 
virtual bool isaUnnamed ()
 
virtual bool isaUnknown ()
 
virtual bool isaRefOp ()
 
virtual bool isaDeref ()
 
virtual bool isaAddressOf ()
 
virtual bool isaSubSetRef ()
 
virtual bool isaIdxAccess ()
 
virtual bool isaIdxExprAccess ()
 
virtual bool isaFieldAccess ()
 
MemRefType getMRType ()
 whether USE/DEF MemRefExpr More...
 
bool isDef ()
 is this a def mem ref More...
 
bool isUse ()
 is this a use mem ref More...
 
bool isDefUse ()
 is this a defuse mem ref More...
 
bool isUseDef ()
 is this a usedef mem ref More...
 
void setMemRefType (MemRefExpr::MemRefType mrType)
 specify the memory reference type More...
 
virtual bool operator< (MemRefExpr &other)
 an ordering for locations, needed for use within STL containers More...
 
virtual bool operator== (MemRefExpr &other)
 
bool operator!= (MemRefExpr &other)
 
void output (IRHandlesIRInterface &ir)
 
virtual std::string typeString ()
 
std::string toString (MemRefType)
 
virtual void dump (std::ostream &os, OA_ptr< IRHandlesIRInterface > pIR)
 
virtual void dump (std::ostream &os, IRHandlesIRInterface &pIR)
 
virtual void dump (std::ostream &os)
 
virtual int getOrder ()
 
- Public Member Functions inherited from OA::Annotation
 Annotation ()
 
virtual ~Annotation ()
 

Private Attributes

MemRefType mMemRefType
 

Static Private Attributes

static const int sOrder = -100
 

Additional Inherited Members

- Static Public Member Functions inherited from OA::Annotation
static void configOutput (OA_ptr< OutputBuilder > ob)
 
- Static Protected Attributes inherited from OA::Annotation
static OA_ptr< OutputBuildersOutBuild
 

Detailed Description

abstract base class that has default implementations for the methods that all MemRefExpr's must provide

Definition at line 76 of file MemRefExpr.hpp.

Member Enumeration Documentation

Enumerator
USE 
DEF 
USEDEF 
DEFUSE 

Definition at line 78 of file MemRefExpr.hpp.

Constructor & Destructor Documentation

OA::MemRefExpr::MemRefExpr ( MemRefType  mrType)
inline

Definition at line 87 of file MemRefExpr.hpp.

OA::MemRefExpr::MemRefExpr ( MemRefExpr mre)
inline

copy constructor

Definition at line 90 of file MemRefExpr.hpp.

virtual OA::MemRefExpr::~MemRefExpr ( )
inlinevirtual

Definition at line 92 of file MemRefExpr.hpp.

Member Function Documentation

void OA::MemRefExpr::dump ( std::ostream &  os,
IRHandlesIRInterface pIR 
)
virtual

Reimplemented in OA::FieldAccess, OA::IdxExprAccess, OA::IdxAccess, OA::SubSetRef, OA::Deref, OA::AddressOf, OA::UnknownRef, OA::UnnamedRef, and OA::NamedRef.

Definition at line 49 of file MemRefExpr.cpp.

References dump().

Here is the call graph for this function:

void OA::MemRefExpr::dump ( std::ostream &  os)
virtual

Reimplemented in OA::FieldAccess, OA::IdxExprAccess, OA::IdxAccess, OA::SubSetRef, OA::Deref, OA::AddressOf, OA::UnknownRef, OA::UnnamedRef, and OA::NamedRef.

Definition at line 60 of file MemRefExpr.cpp.

References mMemRefType, and toString().

Here is the call graph for this function:

virtual bool OA::MemRefExpr::isaDeref ( )
inlinevirtual

Reimplemented in OA::Deref.

Definition at line 107 of file MemRefExpr.hpp.

Referenced by OA::DUG::whatIsIt().

virtual bool OA::MemRefExpr::isaFieldAccess ( )
inlinevirtual

Reimplemented in OA::FieldAccess.

Definition at line 113 of file MemRefExpr.hpp.

Referenced by OA::DUG::whatIsIt().

virtual bool OA::MemRefExpr::isaIdxAccess ( )
inlinevirtual

Reimplemented in OA::IdxAccess.

Definition at line 111 of file MemRefExpr.hpp.

Referenced by OA::DUG::whatIsIt().

virtual bool OA::MemRefExpr::isaIdxExprAccess ( )
inlinevirtual

Reimplemented in OA::IdxExprAccess.

Definition at line 112 of file MemRefExpr.hpp.

Referenced by OA::DUG::whatIsIt().

virtual bool OA::MemRefExpr::isaSubSetRef ( )
inlinevirtual

Reimplemented in OA::SubSetRef.

Definition at line 110 of file MemRefExpr.hpp.

Referenced by Open64IRInterface::findAllMemRefsAndMapToMemRefExprs(), and OA::DUG::whatIsIt().

virtual bool OA::MemRefExpr::isaUnknown ( )
inlinevirtual

Reimplemented in OA::UnknownRef.

Definition at line 104 of file MemRefExpr.hpp.

Referenced by OA::DUG::whatIsIt().

virtual bool OA::MemRefExpr::isaUnnamed ( )
inlinevirtual

Reimplemented in OA::UnnamedRef.

Definition at line 103 of file MemRefExpr.hpp.

Referenced by Open64IRInterface::findAllMemRefsAndMapToMemRefExprs(), and OA::DUG::whatIsIt().

bool OA::MemRefExpr::isDef ( )
inline
bool OA::MemRefExpr::isDefUse ( )
inline

is this a defuse mem ref

Definition at line 131 of file MemRefExpr.hpp.

References DEFUSE, and mMemRefType.

Referenced by NotationGenerator::outputMemRefType().

bool OA::MemRefExpr::isUse ( )
inline
bool OA::MemRefExpr::isUseDef ( )
inline

is this a usedef mem ref

Definition at line 134 of file MemRefExpr.hpp.

References mMemRefType, and USEDEF.

Referenced by NotationGenerator::outputMemRefType().

bool OA::MemRefExpr::operator!= ( MemRefExpr other)
inline

check if two memory references are not equal at the level of accuracy provided by the MemRefExpr approximation

Definition at line 156 of file MemRefExpr.hpp.

bool OA::MemRefExpr::operator< ( MemRefExpr other)
virtual

an ordering for locations, needed for use within STL containers

Need consistent ordering.

Reimplemented in OA::FieldAccess, OA::IdxExprAccess, OA::IdxAccess, OA::SubSetRef, OA::Deref, OA::AddressOf, OA::UnknownRef, OA::UnnamedRef, and OA::NamedRef.

Definition at line 30 of file MemRefExpr.cpp.

References getOrder().

Here is the call graph for this function:

bool OA::MemRefExpr::operator== ( MemRefExpr other)
virtual

check if two memory references are equal at the level of accuracy provided by the MemRefExpr approximation

Reimplemented in OA::FieldAccess, OA::IdxExprAccess, OA::IdxAccess, OA::SubSetRef, OA::Deref, OA::AddressOf, OA::UnknownRef, OA::UnnamedRef, and OA::NamedRef.

Definition at line 37 of file MemRefExpr.cpp.

References getOrder().

Here is the call graph for this function:

void OA::MemRefExpr::setMemRefType ( MemRefExpr::MemRefType  mrType)
inline

specify the memory reference type

Definition at line 141 of file MemRefExpr.hpp.

References mMemRefType.

Referenced by Open64IRInterface::findAllMemRefsAndMapToMemRefExprs().

std::string OA::MemRefExpr::toString ( MemRefType  type)

Definition at line 66 of file MemRefExpr.cpp.

References DEF, DEFUSE, mMemRefType, USE, and USEDEF.

Referenced by dump(), and output().

virtual std::string OA::MemRefExpr::typeString ( )
inlinevirtual

Member Data Documentation

MemRefType OA::MemRefExpr::mMemRefType
private
const int OA::MemRefExpr::sOrder = -100
staticprivate

Definition at line 177 of file MemRefExpr.hpp.

Referenced by getOrder().


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