BlockSyntaxNode Class Reference

#include <include/hllcode.h>

Inheritance diagram for BlockSyntaxNode:

SyntaxNode List of all members.

Detailed Description

Definition at line 176 of file hllcode.h.

Public Member Functions

void addStatement (SyntaxNode *n)
virtual void addSuccessors (SyntaxNode *root, std::vector< SyntaxNode * > &successors)
 BlockSyntaxNode ()
virtual SyntaxNodeclone ()
virtual bool endsWithGoto ()
virtual int evaluate (SyntaxNode *root)
virtual SyntaxNodefindNodeFor (PBB bb)
virtual SyntaxNodegetEnclosingLoop (SyntaxNode *pFor, SyntaxNode *cur=NULL)
virtual int getNumOutEdges ()
int getNumStatements ()
virtual SyntaxNodegetOutEdge (SyntaxNode *root, int n)
SyntaxNodegetStatement (int n)
virtual void ignoreGoto ()
virtual bool isBlock ()
void prependStatement (SyntaxNode *n)
virtual void printAST (SyntaxNode *root, std::ostream &os)
virtual SyntaxNodereplace (SyntaxNode *from, SyntaxNode *to)
void setStatement (int i, SyntaxNode *n)
virtual bool startsWith (SyntaxNode *node)
virtual ~BlockSyntaxNode ()

Private Attributes

std::vector< SyntaxNode * > statements


Constructor & Destructor Documentation

BlockSyntaxNode::BlockSyntaxNode  ) 
 

Definition at line 52 of file syntax.cpp.

Referenced by addSuccessors(), and clone().

BlockSyntaxNode::~BlockSyntaxNode  )  [virtual]
 

Definition at line 56 of file syntax.cpp.

References statements.


Member Function Documentation

void BlockSyntaxNode::addStatement SyntaxNode n  )  [inline]
 

Definition at line 206 of file hllcode.h.

References NULL, SyntaxNode::pbb, and statements.

Referenced by addSuccessors(), clone(), and UserProc::getAST().

void BlockSyntaxNode::addSuccessors SyntaxNode root,
std::vector< SyntaxNode * > &  successors
[virtual]
 

Reimplemented from SyntaxNode.

Definition at line 216 of file syntax.cpp.

References addStatement(), BlockSyntaxNode(), clone(), SyntaxNode::clone(), SyntaxNode::getDepth(), getStatement(), isBlock(), NULL, prependStatement(), SyntaxNode::replace(), replace(), SyntaxNode::setDepth(), and statements.

SyntaxNode * BlockSyntaxNode::clone  )  [virtual]
 

Implements SyntaxNode.

Definition at line 370 of file syntax.cpp.

References addStatement(), BlockSyntaxNode(), SyntaxNode::correspond, SyntaxNode::pbb, and statements.

Referenced by addSuccessors().

virtual bool BlockSyntaxNode::endsWithGoto  )  [inline, virtual]
 

Implements SyntaxNode.

Definition at line 217 of file hllcode.h.

References SyntaxNode::isGoto(), SyntaxNode::pbb, and statements.

int BlockSyntaxNode::evaluate SyntaxNode root  )  [virtual]
 

Implements SyntaxNode.

Definition at line 138 of file syntax.cpp.

References DEBUG_EVAL, getOutEdge(), NULL, SyntaxNode::pbb, and statements.

SyntaxNode * BlockSyntaxNode::findNodeFor PBB  bb  )  [virtual]
 

Implements SyntaxNode.

Definition at line 78 of file syntax.cpp.

References NULL, SyntaxNode::pbb, and statements.

virtual SyntaxNode* BlockSyntaxNode::getEnclosingLoop SyntaxNode pFor,
SyntaxNode cur = NULL
[inline, virtual]
 

Implements SyntaxNode.

Definition at line 227 of file hllcode.h.

References statements.

int BlockSyntaxNode::getNumOutEdges  )  [virtual]
 

Implements SyntaxNode.

Definition at line 62 of file syntax.cpp.

References BasicBlock::getNumOutEdges(), SyntaxNode::pbb, and statements.

int BlockSyntaxNode::getNumStatements  )  [inline]
 

Definition at line 192 of file hllcode.h.

References SyntaxNode::pbb, and statements.

SyntaxNode * BlockSyntaxNode::getOutEdge SyntaxNode root,
int  n
[virtual]
 

Implements SyntaxNode.

Definition at line 70 of file syntax.cpp.

References SyntaxNode::findNodeFor(), BasicBlock::getOutEdge(), NULL, SyntaxNode::pbb, and statements.

Referenced by evaluate().

SyntaxNode* BlockSyntaxNode::getStatement int  n  )  [inline]
 

Definition at line 195 of file hllcode.h.

References NULL, SyntaxNode::pbb, and statements.

Referenced by addSuccessors().

virtual void BlockSyntaxNode::ignoreGoto  )  [inline, virtual]
 

Reimplemented from SyntaxNode.

Definition at line 186 of file hllcode.h.

References SyntaxNode::notGoto, SyntaxNode::pbb, and statements.

virtual bool BlockSyntaxNode::isBlock  )  [inline, virtual]
 

Reimplemented from SyntaxNode.

Definition at line 184 of file hllcode.h.

References NULL, and SyntaxNode::pbb.

Referenced by addSuccessors().

void BlockSyntaxNode::prependStatement SyntaxNode n  )  [inline]
 

Definition at line 199 of file hllcode.h.

References NULL, SyntaxNode::pbb, and statements.

Referenced by addSuccessors().

void BlockSyntaxNode::printAST SyntaxNode root,
std::ostream &  os
[virtual]
 

Implements SyntaxNode.

Definition at line 93 of file syntax.cpp.

References CALL, COMPCALL, COMPJUMP, FALL, BasicBlock::getLowAddr(), BasicBlock::getType(), INVALID, SyntaxNode::nodenum, SyntaxNode::notGoto, NWAY, ONEWAY, SyntaxNode::pbb, RET, and TWOWAY.

SyntaxNode * BlockSyntaxNode::replace SyntaxNode from,
SyntaxNode to
[virtual]
 

Implements SyntaxNode.

Definition at line 382 of file syntax.cpp.

References SyntaxNode::correspond, SyntaxNode::getCorrespond(), NULL, SyntaxNode::pbb, statements, and to.

Referenced by addSuccessors().

void BlockSyntaxNode::setStatement int  i,
SyntaxNode n
[inline]
 

Definition at line 210 of file hllcode.h.

References NULL, SyntaxNode::pbb, and statements.

virtual bool BlockSyntaxNode::startsWith SyntaxNode node  )  [inline, virtual]
 

Reimplemented from SyntaxNode.

Definition at line 224 of file hllcode.h.

References statements.


Member Data Documentation

std::vector<SyntaxNode*> BlockSyntaxNode::statements [private]
 

Definition at line 178 of file hllcode.h.

Referenced by addStatement(), addSuccessors(), clone(), endsWithGoto(), evaluate(), findNodeFor(), getEnclosingLoop(), getNumOutEdges(), getNumStatements(), getOutEdge(), getStatement(), ignoreGoto(), prependStatement(), replace(), setStatement(), startsWith(), and ~BlockSyntaxNode().


The documentation for this class was generated from the following files:
Generated on Tue Sep 19 21:18:40 2006 for Boomerang by  doxygen 1.4.6