OpenADFortTk (basic)
fortTkSupport::ScalarizedRef Class Reference

#include <ScalarizedRef.h>

Collaboration diagram for fortTkSupport::ScalarizedRef:

List of all members.

Public Member Functions

 ScalarizedRef (WN *const aWNp)
 ScalarizedRef (WN *const aWNp, const std::string &aPostFix)
virtual ~ScalarizedRef ()
const std::string & getName () const
WN * getWN () const
unsigned int getId () const
void dump (std::ostream &o) const
void ddump () const

Static Public Member Functions

static bool isRefTranslatableToXAIF (const WN *wn)
static bool isRefSimple (const WN *wn)
static bool isRefSimpleScalar (const WN *wn)
static bool isRefSimpleArrayElem (const WN *wn)
static bool isRefSimpleArray (const WN *wn)
static bool isRefScalarizable (const WN *wn)
static bool isRefScalar (TY_IDX baseobj_ty, TY_IDX refobj_ty)

Private Member Functions

 ScalarizedRef (const ScalarizedRef &x)
ScalarizedRefoperator= (const ScalarizedRef &x)
void Ctor (WN *wn, const char *x)

Private Attributes

unsigned int myId
std::string myName
WN * myWNp

Static Private Attributes

static unsigned int ourNextId = 0
static const std::string ourPrefix

Detailed Description

this represents a scalarized reference i.e. a dummy variable that represents a (chain of) dereference

Definition at line 13 of file ScalarizedRef.h.


Constructor & Destructor Documentation

there may be no postfix string

Definition at line 15 of file ScalarizedRef.cxx.

References myId, myName, and ourPrefix.

fortTkSupport::ScalarizedRef::ScalarizedRef ( WN *const  aWNp,
const std::string &  aPostFix 
)

Definition at line 23 of file ScalarizedRef.cxx.

References myId, myName, and ourPrefix.

Definition at line 32 of file ScalarizedRef.cxx.


Member Function Documentation

void fortTkSupport::ScalarizedRef::Ctor ( WN *  wn,
const char *  x 
) [private]

Definition at line 51 of file ScalarizedRef.cxx.

References dump().

Here is the call graph for this function:

void fortTkSupport::ScalarizedRef::dump ( std::ostream &  o) const
unsigned int fortTkSupport::ScalarizedRef::getId ( ) const

Definition at line 43 of file ScalarizedRef.cxx.

References myId.

Definition at line 39 of file ScalarizedRef.cxx.

References myWNp.

Referenced by whirl2xaif::xlate_ScalarizedRefTab().

bool fortTkSupport::ScalarizedRef::isRefScalar ( TY_IDX  baseobj_ty,
TY_IDX  refobj_ty 
) [static]
bool fortTkSupport::ScalarizedRef::isRefScalarizable ( const WN *  wn) [static]

Definition at line 136 of file ScalarizedRef.cxx.

References FORTTK_MSG, isRefScalar(), TY_Is_Array(), TY_Is_Pointer(), TY_Is_Scalar(), WN_GetBaseObjType(), and WN_GetRefObjType().

Referenced by fortTkSupport::ForAllScalarizableRefs(), and isRefTranslatableToXAIF().

Here is the call graph for this function:

bool fortTkSupport::ScalarizedRef::isRefSimple ( const WN *  wn) [static]

WHIRL stores represent the lhs var-ref (e.g. OPR_ISTORE,OPR_STID)

Definition at line 59 of file ScalarizedRef.cxx.

References isRefSimpleArray(), isRefSimpleArrayElem(), and isRefSimpleScalar().

Referenced by isRefTranslatableToXAIF().

Here is the call graph for this function:

bool fortTkSupport::ScalarizedRef::isRefSimpleArray ( const WN *  wn) [static]

Definition at line 116 of file ScalarizedRef.cxx.

References TY_Is_Array(), WN_GetBaseObjType(), and WN_GetRefObjType().

Referenced by isRefSimple(), and whirl2xaif::xlate_SymRef().

Here is the call graph for this function:

bool fortTkSupport::ScalarizedRef::isRefSimpleArrayElem ( const WN *  wn) [static]

Definition at line 93 of file ScalarizedRef.cxx.

References isRefScalar(), TY_Is_Array(), WN_GetBaseObjType(), and WN_GetRefObjType().

Referenced by isRefSimple(), and whirl2xaif::xlate_SymRef().

Here is the call graph for this function:

bool fortTkSupport::ScalarizedRef::isRefSimpleScalar ( const WN *  wn) [static]

Definition at line 67 of file ScalarizedRef.cxx.

References isRefScalar(), WN_GetBaseObjType(), and WN_GetRefObjType().

Referenced by isRefSimple(), whirl2xaif::xlate_MemRef(), and whirl2xaif::xlate_SymRef().

Here is the call graph for this function:

Returns whether 'wn' is a variable reference that can be translated into XAIF. 'wn' must be an expression; IOW it cannot be a store (=statement).

Definition at line 55 of file ScalarizedRef.cxx.

References isRefScalarizable(), and isRefSimple().

Referenced by xaif2whirl::XlateExpression::patchWNExpr().

Here is the call graph for this function:

ScalarizedRef& fortTkSupport::ScalarizedRef::operator= ( const ScalarizedRef x) [private]

no def


Member Data Documentation

unsigned int fortTkSupport::ScalarizedRef::myId [private]

Definition at line 68 of file ScalarizedRef.h.

Referenced by getId(), and ScalarizedRef().

std::string fortTkSupport::ScalarizedRef::myName [private]

Definition at line 70 of file ScalarizedRef.h.

Referenced by dump(), getName(), and ScalarizedRef().

the first occurance of the reference in PU

Definition at line 75 of file ScalarizedRef.h.

Referenced by getWN().

unsigned int fortTkSupport::ScalarizedRef::ourNextId = 0 [static, private]

to ensure global uniqueness

Definition at line 80 of file ScalarizedRef.h.

const std::string fortTkSupport::ScalarizedRef::ourPrefix [static, private]

Definition at line 82 of file ScalarizedRef.h.

Referenced by ScalarizedRef().


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines