Public Member Functions | Private Member Functions | Private Attributes

OA::Activity::ManagerUsefulStandard Class Reference

#include <ManagerUsefulStandard.hpp>

Inheritance diagram for OA::Activity::ManagerUsefulStandard:
Inheritance graph
[legend]
Collaboration diagram for OA::Activity::ManagerUsefulStandard:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ManagerUsefulStandard (OA_ptr< ActivityIRInterface > _ir)
 ~ManagerUsefulStandard ()
OA_ptr< UsefulStandardperformAnalysis (ProcHandle, OA_ptr< CFG::CFGInterface > cfg, OA_ptr< DepStandard > dep, OA_ptr< DataFlow::LocDFSet > depLocSet, DataFlow::DFPImplement type)

Private Member Functions

OA_ptr< DataFlow::DataFlowSetinitializeTop ()
 Return an initialized top set.
OA_ptr< DataFlow::DataFlowSetinitializeBottom ()
 Return an initialized bottom set.
OA_ptr< DataFlow::DataFlowSetinitializeNodeIN (OA_ptr< CFG::NodeInterface > n)
 Should generate an in and out DataFlowSet for node.
OA_ptr< DataFlow::DataFlowSetinitializeNodeOUT (OA_ptr< CFG::NodeInterface > n)
OA_ptr< DataFlow::DataFlowSetmeet (OA_ptr< DataFlow::DataFlowSet > set1, OA_ptr< DataFlow::DataFlowSet > set2)
OA_ptr< DataFlow::DataFlowSettransfer (OA_ptr< DataFlow::DataFlowSet > in, OA::StmtHandle stmt)
 Core of analysis algorithm. Transfer function for a stmt.

Private Attributes

OA_ptr< ActivityIRInterfacemIR
OA_ptr< DepStandardmDep
OA_ptr< UsefulStandardmUsefulMap
OA_ptr< LocIteratormDepLocIter
OA_ptr< CFG::CFGInterfacemCFG
OA_ptr< DataFlow::CFGDFSolvermSolver

Detailed Description

The AnnotationManager for UsefulStandard. This class can build an UsefulStandard, (eventually) read one in from a file, and write one out to a file.

Definition at line 38 of file ManagerUsefulStandard.hpp.


Constructor & Destructor Documentation

OA::Activity::ManagerUsefulStandard::ManagerUsefulStandard ( OA_ptr< ActivityIRInterface _ir  ) 
OA::Activity::ManagerUsefulStandard::~ManagerUsefulStandard (  )  [inline]

Definition at line 43 of file ManagerUsefulStandard.hpp.


Member Function Documentation

OA_ptr< DataFlow::DataFlowSet > OA::Activity::ManagerUsefulStandard::initializeBottom (  )  [private, virtual]

Return an initialized bottom set.

Implements OA::DataFlow::CFGDFProblem.

Definition at line 40 of file ManagerUsefulStandard.cpp.

OA_ptr< DataFlow::DataFlowSet > OA::Activity::ManagerUsefulStandard::initializeNodeIN ( OA_ptr< CFG::NodeInterface n  )  [private, virtual]

Should generate an in and out DataFlowSet for node.

* * Not doing anything special at entries and exits. * *

Implements OA::DataFlow::CFGDFProblem.

Definition at line 122 of file ManagerUsefulStandard.cpp.

References OA::OA_ptr< T >::convert(), mCFG, mDepLocIter, mUsefulMap, and OA::OA_ptr< T >::ptrEqual().

Here is the call graph for this function:

OA_ptr< DataFlow::DataFlowSet > OA::Activity::ManagerUsefulStandard::initializeNodeOUT ( OA_ptr< CFG::NodeInterface n  )  [private, virtual]

Implements OA::DataFlow::CFGDFProblem.

Definition at line 143 of file ManagerUsefulStandard.cpp.

References OA::OA_ptr< T >::convert(), mCFG, mDepLocIter, mUsefulMap, and OA::OA_ptr< T >::ptrEqual().

Here is the call graph for this function:

OA_ptr< DataFlow::DataFlowSet > OA::Activity::ManagerUsefulStandard::initializeTop (  )  [private, virtual]

Return an initialized top set.

Implements OA::DataFlow::CFGDFProblem.

Definition at line 33 of file ManagerUsefulStandard.cpp.

OA_ptr< DataFlow::DataFlowSet > OA::Activity::ManagerUsefulStandard::meet ( OA_ptr< DataFlow::DataFlowSet set1,
OA_ptr< DataFlow::DataFlowSet set2 
) [private, virtual]

OK to modify set1 and return it as result, because solver only passes a tempSet in as set1

Implements OA::DataFlow::CFGDFProblem.

Definition at line 166 of file ManagerUsefulStandard.cpp.

References OA::DataFlow::LocDFSet::clone(), OA::OA_ptr< T >::convert(), OA::Activity::debug, OA::DataFlow::LocDFSet::dump(), OA::OA_ptr< T >::dump(), and mIR.

Here is the call graph for this function:

OA_ptr< UsefulStandard > OA::Activity::ManagerUsefulStandard::performAnalysis ( ProcHandle  proc,
OA_ptr< CFG::CFGInterface cfg,
OA_ptr< DepStandard dep,
OA_ptr< DataFlow::LocDFSet depLocSet,
DataFlow::DFPImplement  algorithm 
)

depLocIter is a location iterator over dependent locations that the algorithm should calculate InUseful from

Uses the CFGDFProblem::solve functionality to get In and Out Useful sets for each basic block. In transfer function put InUseful locs in UsefulStandard as well.

Definition at line 54 of file ManagerUsefulStandard.cpp.

References OA::Activity::debug, mCFG, mDep, mDepLocIter, mSolver, and mUsefulMap.

OA_ptr< DataFlow::DataFlowSet > OA::Activity::ManagerUsefulStandard::transfer ( OA_ptr< DataFlow::DataFlowSet out,
OA::StmtHandle  stmt 
) [private, virtual]

Core of analysis algorithm. Transfer function for a stmt.

KILL is the set of locations that are must defined in this stmt

GEN is all locations whose use might is needed for locations in OutUseful that may be defined in the statement

Implements OA::DataFlow::CFGDFProblem.

Definition at line 200 of file ManagerUsefulStandard.cpp.

References OA::OA_ptr< T >::convert(), OA::LocSetIterator::current(), OA::Activity::debug, OA::OA_ptr< T >::dump(), OA::IRHandle::hval(), OA::LocSetIterator::isValid(), mDep, mIR, and mUsefulMap.

Here is the call graph for this function:


Member Data Documentation

Definition at line 81 of file ManagerUsefulStandard.hpp.

Referenced by initializeNodeIN(), initializeNodeOUT(), and performAnalysis().

Definition at line 78 of file ManagerUsefulStandard.hpp.

Referenced by performAnalysis(), and transfer().

Definition at line 80 of file ManagerUsefulStandard.hpp.

Referenced by initializeNodeIN(), initializeNodeOUT(), and performAnalysis().

Definition at line 77 of file ManagerUsefulStandard.hpp.

Referenced by meet(), and transfer().

Definition at line 83 of file ManagerUsefulStandard.hpp.

Referenced by ManagerUsefulStandard(), and performAnalysis().


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