coins.aflow
Class BBlockImpl

java.lang.Object
  extended bycoins.aflow.BBlockImpl
All Implemented Interfaces:
BBlock
Direct Known Subclasses:
BBlockHirImpl

public abstract class BBlockImpl
extends java.lang.Object
implements BBlock


Field Summary
protected  int fBBlockNumber
           
protected  IR fIrLink
           
 FlowRoot flowRoot
           
protected  BBlock fNextInDFO
           
protected  BBlock fNextInInverseDFO
           
protected  java.util.LinkedList fPredEdgeList
           
protected  java.util.LinkedList fPredList
           
(package private)  FlowResults fResults
           
protected  java.util.LinkedList fSuccEdgeList
           
protected  java.util.LinkedList fSuccList
           
protected  java.lang.Object fWork
           
 
Constructor Summary
protected BBlockImpl(SubpFlow pSubpFlow)
           
 
Method Summary
 void addEdge(Exp pConditionalExp, BBlock pToBlock)
          addEdge: Add edge from this block to pToBlock that is to be taken when pConditionalExp is true.
 void addToPredList(BBlock pPred)
          addToPredList: addToSuccList: Add the basic block pPred/pSucc to the list of predecessors/successors of this basic block, and this block is added to the list of successors/predecessors of pPred/pSucc.
 void addToSuccList(BBlock pSucc)
           
 void changePredEdge(BBlock pBefore, BBlock pAfter)
           
 void changeSuccEdge(BBlock pBefore, BBlock pAfter)
          changeEdge: Change the edge between this block and pBefore to a new edge between this block and pAfter.
 void deleteBBlock()
          deleteBBlock: Delete this block and add successors of this block to the set of successors of all predecessors of this block.
 void deleteEdge(BBlock pToBlock)
          deleteEdge: Delete the edge from this block to pToBlock and adjust related addresses and links so as to keep consistency.
 void deleteFromPredList(BBlock pPred)
          deleteFromPredList: deleteFromSuccList: Delete the basic block pPred/pSucc from to the list of predecessors/successors of this basic block, and this block is deleted from the list of successors/predecessors of pPred/pSucc.
 void deleteFromSuccList(BBlock pSucc)
           
 void deleteFromSuccList0(BBlock pSucc)
           
 void fuseSuccessor(BBlock pToBlock)
          fuseSuccessor: Fuse the successor pToBlock with this block and make all successors of pToBlock as successors of this block.
 int getBBlockNumber()
          getBBlockNumber: Get the block number attached to this basic block.
 ExpVector getDAvailIn()
          getAvailIn: Get bit vector showing AvailIn set of this block.
 ExpVector getDAvailOut()
          getAvailOut: Get bit vector showing AvailOut set of this block.
 DefVector getDDef()
           
 FlowAnalSymVector getDDefIn()
          getDefIn: Get bit vector showing DefIn set of this block.
 FlowAnalSymVector getDDefined()
          getDefined: Get bit vector showing Defined set of this block.
 FlowAnalSymVector getDDefOut()
          getDefOut: Get bit vector showing DefOut set of this block.
 DefVector getDef()
          getDef: Get bit vector showing Def set of this block.
 ExpVector getDEGen()
          getEGen: Get bit vector showing EGen set of this block.
 FlowAnalSymVector getDExposed()
          getExposed: Get bit vector showing Exposed set of this block.
 DefVector getDKill()
          getKill: Get bit vector showing Kill set of this block.
 java.util.List getDomForSubpFlow()
          Get the list of BBlocks that dominate this BBlock in the SubpFlow this BBlock belongs to.
 java.util.List getDominatedChildrenForSubpFlow()
          getDominatedChildren: Get the list of basic blocks immediately dominated by this block.
 FlowAnalSymVector getDUsed()
          getDUsed: //##12 Get bit vector showing DUsed set of this block.
 BBlock getImmediateDominatorForSubpFlow()
          getImmediateDominator: Get a basic block immediately dominating this block.
 BBlock getImmediatePostdominatorForSubpFlow()
          getImmediatePostDominator: Get a basic block immediately post dominating this block.
 IR getIrLink()
          getIrLink: Get the top-subtree that starts this basic block.
 BBlock getNextInDFO()
           
 BBlock getNextInInverseDFO()
           
 DefVector getPDef()
          getPDef: Get bit vector showing PDef set of this block.
 FlowAnalSymVector getPDefined()
          getPDefined: Get bit vector showing PDefined set of this block.
 ExpVector getPEKill()
          getEKill: Get bit vector showing EKill set of this block.
 FlowAnalSymVector getPExposed()
          getExposed: Get bit vector showing Exposed set of this block.
 DefVector getPKill()
          getDestroy: Get bit vector showing Destroy set of this block.
 FlowAnalSymVector getPLiveIn()
          getLiveIn: Get bit vector showing LiveIn set of this block.
 FlowAnalSymVector getPLiveOut()
          getLiveOut: Get bit vector showing LiveOut set of this block.
 java.util.List getPostdomForSubpFlow()
           
 java.util.List getPostdominatedChildrenForSubpFlow()
          getPostDominatedChildren: setPostDominatedChildren: Get/set the list of basic blocks post dominated by this block.
 DefVector getPReach()
          getReach0: Get bit vector showing Reach0 set of this block.
 Edge getPredEdge(BBlock pFromBBlock)
          getPredEdge: getSuccEdge: Get the edge corresponding to the predecessor/successor to/from this basic block.
 java.util.List getPredList()
          getPredList: getSuccList: Get the predecessor/successor list of this basic block.
 FlowAnalSymVector getPUsed()
          getUsed: //##12 Get bit vector showing Used set of this block.
 DefVector getReach()
          getReach: Get bit vector showing Reach set of this block.
 SetRefReprList getSetRefReprs()
          Gets the SetRefReprList object that is the list of SetRefRepr objects, each of which wrap a statement/instruction.
 java.util.List getStrictDomForSubpFlow()
          Get the strict dominator for this BBlock in the SubpFlow this BBlock belongs to.
 java.util.List getStrictPostdomForSubpFlow()
           
 SubpFlow getSubpFlow()
          Returns the SubpFlow object this BBlock belongs to.
 Edge getSuccEdge(BBlock pToBBlock)
           
 java.util.List getSuccList()
           
 java.lang.Object getWork()
          getWork: setWork: get/set information privately used in each phase.
protected  void initiateFields()
           
 BBlock insertConditionalInitPart()
          insertConditionalInitPart: Insert a basic block as the conditional initiation block (conditionalInitBlock) of this loop (the loop starting with this basic block having loop header flag).
 BBlock insertLoopPreheader()
           
 boolean isDAvailIn(FlowExpId pExpId)
          isAvailIn: See if the expression represented by pExpId is available (value is always computed) at entry to this block.
 boolean isDAvailOut(FlowExpId pExpId)
          isAvailOut: See if the expression represented by pExpId is available (value is always computed) at exit from this block.
 boolean isDDef(SetRefRepr pSetRefRepr)
          isDef: See if definition at position pPos is done in this block.
 boolean isDDefIn(Sym pSym)
          isDefIn: See if pSym is always defined at entry to this block whichever path may be take.
 boolean isDDefined(Sym pSym)
          isDefined: See if the value of pSym is defined in this block.
 boolean isDDefOut(Sym pSym)
          isDefOut: See if pSym is always defined at exit from this block.
 boolean isDEGen(FlowExpId pExpId)
          isEGen: See if expression designated by pReg is generated (computed in this block and afterwards its operand is not changed) in this block.
 boolean isDExposed(Sym pSym)
          isExposed: See if the variable of pSym is used in this block without setting its value in this block.
 boolean isDKill(SetRefRepr pSetRefRepr)
          isKill: See if definition at position pPos is killed in this block.
 boolean isDUsed(Sym pSym)
          isUsed: //##12 See if the value of pSym is used in this block.
 boolean isEntryBBlock()
          isEntryBlock: See if this block is the entry block in the graph of basic blocks.
 boolean isEntryBlock()
           
 boolean isExitBBlock()
          isExitBlock: See if this block is the exit block in the graph of basic blocks.
 boolean isExitBlock()
          isExitBlock: See if this block is the exit block in the graph of basic blocks.
 boolean isPDef(SetRefRepr pSetRefRepr)
           
 boolean isPDefined(Sym pSym)
          isModified: See if the value of pSym is modified in this block.
 boolean isPEKill(FlowExpId pExpId)
          isEKill: See if expression designated by pReg is killed (its operand is defined) in this block.
 boolean isPExposed(Sym pSym)
           
 boolean isPKill(SetRefRepr pSetRefRepr)
           
 boolean isPLiveIn(Sym pSym)
          isLiveIn: See if pSym is live at entry to this block (value at entry is used in this block or in some successor of this block).
 boolean isPLiveOut(Sym pSym)
          isLiveOut: See if pSym is live at exit from this block (value at exit is used in some successor of this block).
 boolean isPReach(SetRefRepr pSetRefRepr)
          isReach: See if definition at position pPos reaches to the entry point of this block.
 boolean isPUsed(Sym pSym)
           
 void printSubtrees()
          printSubtrees: Print the sequence of subtrees contained in this block.
 FlowResults results()
          Returns the FlowResults object that holds data flow information.
 void setDAvailIn(ExpVector pVect)
           
 void setDAvailOut(ExpVector pVect)
           
 void setDDef(DefVector pVect)
           
 void setDDefIn(FlowAnalSymVector pVect)
           
 void setDDefined(FlowAnalSymVector pVect)
           
 void setDDefOut(FlowAnalSymVector pVect)
           
 void setDef(DefVector pVect)
           
 void setDEGen(ExpVector pVect)
           
 void setDExposed(FlowAnalSymVector pVect)
           
 void setDKill(DefVector pVect)
           
 void setDomForSubpFlow(java.util.List pDom)
          Set the list of BBlocks that dominate this BBlock in the SubpFlow this BBlock belongs to.
 void setDominatedChildrenForSubpFlow(java.util.List pDominatedChildren)
           
 void setDReach(DefVector pVect)
           
 void setDUsed(FlowAnalSymVector pVect)
           
 void setImmediateDominatorForSubpFlow(BBlock pDominator)
           
 void setImmediatePostdominatorForSubpFlow(BBlock pPostDominator)
           
 void setNextInDFO(BBlock pNext)
           
 void setNextInInveseDFO(BBlock pNext)
           
 void setPDef(DefVector pVect)
           
 void setPDefined(FlowAnalSymVector pVect)
           
 void setPEKill(ExpVector pVect)
           
 void setPExposed(FlowAnalSymVector pVect)
           
 void setPKill(DefVector pVect)
           
 void setPLiveIn(FlowAnalSymVector pVect)
           
 void setPLiveOut(FlowAnalSymVector pVect)
           
 void setPostdomForSubpFlow(java.util.List pPostdom)
           
 void setPostdominatedChildrenForSubpFlow(java.util.List pPostDominatedChildren)
           
 void setPReach(DefVector pVect)
           
 void setPUsed(FlowAnalSymVector pVect)
           
 void setReach(DefVector pVect)
           
 void setSetRefReprs(SetRefReprList pSetRefReprs)
          Sets the SetRefReprList object that is the list of SetRefRepr objects, each of which wrap a statement/instruction.
 void setWork(java.lang.Object pWork)
           
 java.lang.String toString()
           
 java.lang.String toStringDetail()
          toStringDetail: //##10
 java.lang.String toStringShort()
          toStringShort: //##10
 java.lang.String toStringVeryShort()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface coins.aflow.BBlock
bblockNodeIterator, bblockSubtreeIterator, getLabel, setIrLink, setRefRepr
 

Field Detail

flowRoot

public final FlowRoot flowRoot

fBBlockNumber

protected final int fBBlockNumber

fIrLink

protected IR fIrLink

fPredList

protected java.util.LinkedList fPredList

fSuccList

protected java.util.LinkedList fSuccList

fPredEdgeList

protected java.util.LinkedList fPredEdgeList

fSuccEdgeList

protected java.util.LinkedList fSuccEdgeList

fNextInDFO

protected BBlock fNextInDFO

fNextInInverseDFO

protected BBlock fNextInInverseDFO

fWork

protected java.lang.Object fWork

fResults

final FlowResults fResults
Constructor Detail

BBlockImpl

protected BBlockImpl(SubpFlow pSubpFlow)
Method Detail

initiateFields

protected void initiateFields()

getIrLink

public IR getIrLink()
Description copied from interface: BBlock
getIrLink: Get the top-subtree that starts this basic block. See getLirTreeList for using LIRTreeListIterator. returned value of getIrLink is not applicable for LIRTreeListIterator.

Specified by:
getIrLink in interface BBlock
Returns:
LabeledStmt or DefLabel subtree that is the first top-subtree in this basic block.

getBBlockNumber

public int getBBlockNumber()
Description copied from interface: BBlock
getBBlockNumber: Get the block number attached to this basic block.

Specified by:
getBBlockNumber in interface BBlock
Returns:
the block number attached to this basic block.

results

public FlowResults results()
Description copied from interface: BBlock
Returns the FlowResults object that holds data flow information.

Specified by:
results in interface BBlock

getSetRefReprs

public SetRefReprList getSetRefReprs()
Description copied from interface: BBlock
Gets the SetRefReprList object that is the list of SetRefRepr objects, each of which wrap a statement/instruction.

Specified by:
getSetRefReprs in interface BBlock

setSetRefReprs

public void setSetRefReprs(SetRefReprList pSetRefReprs)
Description copied from interface: BBlock
Sets the SetRefReprList object that is the list of SetRefRepr objects, each of which wrap a statement/instruction.

Specified by:
setSetRefReprs in interface BBlock

getPredList

public java.util.List getPredList()
Description copied from interface: BBlock
getPredList: getSuccList: Get the predecessor/successor list of this basic block. Elements of the list can be accessed by List methods. See ListIterator for traversing BBlocks in the predecessor/successor list.

Specified by:
getPredList in interface BBlock
Returns:
the predecessor/successor list of this basic block. If this has no predecessor/successor, empty list is returned.

getSuccList

public java.util.List getSuccList()
Specified by:
getSuccList in interface BBlock

getPredEdge

public Edge getPredEdge(BBlock pFromBBlock)
Description copied from interface: BBlock
getPredEdge: getSuccEdge: Get the edge corresponding to the predecessor/successor to/from this basic block. getPredEdge: Get the edge spanning from pFromBBlock to this. getSuccEdge: Get the edge spanning from this to pToBBlock.

Specified by:
getPredEdge in interface BBlock

getSuccEdge

public Edge getSuccEdge(BBlock pToBBlock)
Specified by:
getSuccEdge in interface BBlock

isEntryBlock

public boolean isEntryBlock()

isEntryBBlock

public boolean isEntryBBlock()
Description copied from interface: BBlock
isEntryBlock: See if this block is the entry block in the graph of basic blocks.

Specified by:
isEntryBBlock in interface BBlock
Returns:
true if this is the entry block in the graph of basic blocks, else return false.

isExitBlock

public boolean isExitBlock()
isExitBlock: See if this block is the exit block in the graph of basic blocks.

Returns:
true if this is the exit block in the graph of basic blocks, else return false.

isExitBBlock

public boolean isExitBBlock()
Description copied from interface: BBlock
isExitBlock: See if this block is the exit block in the graph of basic blocks.

Specified by:
isExitBBlock in interface BBlock
Returns:
true if this is the exit block in the graph of basic blocks, else return false.

getDomForSubpFlow

public java.util.List getDomForSubpFlow()
Description copied from interface: BBlock
Get the list of BBlocks that dominate this BBlock in the SubpFlow this BBlock belongs to.

Specified by:
getDomForSubpFlow in interface BBlock

setDomForSubpFlow

public void setDomForSubpFlow(java.util.List pDom)
Description copied from interface: BBlock
Set the list of BBlocks that dominate this BBlock in the SubpFlow this BBlock belongs to.

Specified by:
setDomForSubpFlow in interface BBlock

getStrictDomForSubpFlow

public java.util.List getStrictDomForSubpFlow()
Description copied from interface: BBlock
Get the strict dominator for this BBlock in the SubpFlow this BBlock belongs to. A strict dominator is the dominator list minus the BBlock itself.

Specified by:
getStrictDomForSubpFlow in interface BBlock

getImmediateDominatorForSubpFlow

public BBlock getImmediateDominatorForSubpFlow()
getImmediateDominator: Get a basic block immediately dominating this block.

Specified by:
getImmediateDominatorForSubpFlow in interface BBlock
Returns:
the basic block immediately dominating this block.

setImmediateDominatorForSubpFlow

public void setImmediateDominatorForSubpFlow(BBlock pDominator)
Specified by:
setImmediateDominatorForSubpFlow in interface BBlock

getDominatedChildrenForSubpFlow

public java.util.List getDominatedChildrenForSubpFlow()
getDominatedChildren: Get the list of basic blocks immediately dominated by this block. Elements of the list can be handled by List methods.

Specified by:
getDominatedChildrenForSubpFlow in interface BBlock
Returns:
the list of basic blocks immediately dominated by this block.

setDominatedChildrenForSubpFlow

public void setDominatedChildrenForSubpFlow(java.util.List pDominatedChildren)
Specified by:
setDominatedChildrenForSubpFlow in interface BBlock

getPostdomForSubpFlow

public java.util.List getPostdomForSubpFlow()
Specified by:
getPostdomForSubpFlow in interface BBlock

setPostdomForSubpFlow

public void setPostdomForSubpFlow(java.util.List pPostdom)
Specified by:
setPostdomForSubpFlow in interface BBlock

getStrictPostdomForSubpFlow

public java.util.List getStrictPostdomForSubpFlow()
Specified by:
getStrictPostdomForSubpFlow in interface BBlock

getImmediatePostdominatorForSubpFlow

public BBlock getImmediatePostdominatorForSubpFlow()
getImmediatePostDominator: Get a basic block immediately post dominating this block.

Specified by:
getImmediatePostdominatorForSubpFlow in interface BBlock
Returns:
the basic block immediately post dominating this block.

setImmediatePostdominatorForSubpFlow

public void setImmediatePostdominatorForSubpFlow(BBlock pPostDominator)
Specified by:
setImmediatePostdominatorForSubpFlow in interface BBlock

getPostdominatedChildrenForSubpFlow

public java.util.List getPostdominatedChildrenForSubpFlow()
Description copied from interface: BBlock
getPostDominatedChildren: setPostDominatedChildren: Get/set the list of basic blocks post dominated by this block. Elements of the list can be handled by List methods. getPostDominatedChildren: return the list of basic blocks post dominated by this block. setPostDominatedChildren: set pPostDominatedChildren as the list of basic blocks post dominated by this block. See ListIterator for traversing dominated children.

Specified by:
getPostdominatedChildrenForSubpFlow in interface BBlock

setPostdominatedChildrenForSubpFlow

public void setPostdominatedChildrenForSubpFlow(java.util.List pPostDominatedChildren)
Specified by:
setPostdominatedChildrenForSubpFlow in interface BBlock

getNextInDFO

public BBlock getNextInDFO()

setNextInDFO

public void setNextInDFO(BBlock pNext)

getNextInInverseDFO

public BBlock getNextInInverseDFO()

setNextInInveseDFO

public void setNextInInveseDFO(BBlock pNext)

getWork

public java.lang.Object getWork()
Description copied from interface: BBlock
getWork: setWork: get/set information privately used in each phase.

Specified by:
getWork in interface BBlock

setWork

public void setWork(java.lang.Object pWork)
Specified by:
setWork in interface BBlock

toStringShort

public java.lang.String toStringShort()
Description copied from interface: BBlock
toStringShort: //##10

Specified by:
toStringShort in interface BBlock
Returns:
Basic block number and predecessor/successor list.

toStringDetail

public java.lang.String toStringDetail()
Description copied from interface: BBlock
toStringDetail: //##10

Specified by:
toStringDetail in interface BBlock
Returns:
toStringShort(), linked node, and flags.

printSubtrees

public void printSubtrees()
printSubtrees: Print the sequence of subtrees contained in this block. The order of print is the same as that of bblockSubtreeIterator. "this" is any basic block.


insertLoopPreheader

public BBlock insertLoopPreheader()

insertConditionalInitPart

public BBlock insertConditionalInitPart()
                                 throws CompileError
insertConditionalInitPart: Insert a basic block as the conditional initiation block (conditionalInitBlock) of this loop (the loop starting with this basic block having loop header flag). The inserted conditionalInitBlock is preceeded by the expression statement built by copying the start condition of the loop so that the conditionalInitBlock is executed only when the start condition is satisfied. Edges from predecessors of this block are changed to go to the inserted start condition except loop back edge. The destination of the loop back edge is not changed. The conditionalInitBlock goes to loop body part of this loop treating the body part as its only one successor. Branch addresses of this block and its predecessors are changed so that consistency is kept. "this" should be a loop header basic block that dominates all basic blocks in the loop.

Returns:
the inserted conditionalInitBlock.
Throws:
CompileError

changeSuccEdge

public void changeSuccEdge(BBlock pBefore,
                           BBlock pAfter)
Description copied from interface: BBlock
changeEdge: Change the edge between this block and pBefore to a new edge between this block and pAfter. Branch addresses of this block and linkages between successors of this block are changed so that consistency is kept.

Specified by:
changeSuccEdge in interface BBlock

changePredEdge

public void changePredEdge(BBlock pBefore,
                           BBlock pAfter)
Specified by:
changePredEdge in interface BBlock

addEdge

public void addEdge(Exp pConditionalExp,
                    BBlock pToBlock)
addEdge: Add edge from this block to pToBlock that is to be taken when pConditionalExp is true. Branch addresses of this block and linkages between successors of this block are changed so that consistency is kept. "this" is a basic block having only one successor.

Specified by:
addEdge in interface BBlock

deleteEdge

public void deleteEdge(BBlock pToBlock)
deleteEdge: Delete the edge from this block to pToBlock and adjust related addresses and links so as to keep consistency. If pToBlock has this block as its only one predecessor, then pToBlock is deleted.

Specified by:
deleteEdge in interface BBlock

deleteBBlock

public void deleteBBlock()
deleteBBlock: Delete this block and add successors of this block to the set of successors of all predecessors of this block. Branch statement or instructions in this block is moved to all predecessors of this block so as to keep consistency. "this" is a basic block whose predecessors have this block as their only one successor. If the successors have more than one successors, they should be modified before invoking this method.

Specified by:
deleteBBlock in interface BBlock

addToPredList

public void addToPredList(BBlock pPred)
addToPredList: addToSuccList: Add the basic block pPred/pSucc to the list of predecessors/successors of this basic block, and this block is added to the list of successors/predecessors of pPred/pSucc. Note: For method xxxPredxxx, take 1st word of predecessor/successor or the like, and for method xxxSuccxxx, take 2nd word of predecessor/successor or the like. The same rule applies to other methods in this interface.

Specified by:
addToPredList in interface BBlock

addToSuccList

public void addToSuccList(BBlock pSucc)
Specified by:
addToSuccList in interface BBlock

deleteFromPredList

public void deleteFromPredList(BBlock pPred)
deleteFromPredList: deleteFromSuccList: Delete the basic block pPred/pSucc from to the list of predecessors/successors of this basic block, and this block is deleted from the list of successors/predecessors of pPred/pSucc.

Specified by:
deleteFromPredList in interface BBlock

deleteFromSuccList

public void deleteFromSuccList(BBlock pSucc)
Specified by:
deleteFromSuccList in interface BBlock

deleteFromSuccList0

public void deleteFromSuccList0(BBlock pSucc)

fuseSuccessor

public void fuseSuccessor(BBlock pToBlock)
fuseSuccessor: Fuse the successor pToBlock with this block and make all successors of pToBlock as successors of this block. "this" is a basic block having pToBlock as its only one successor, and pToBlock should have "this" as its only one predecessor. Before invoking this method, this block should be changed to have only one successor pToBlock if the condition is not satisfied. This class(BBlockImpl)'s implementation changes only the predecessor/successor relations.

Specified by:
fuseSuccessor in interface BBlock

getSubpFlow

public SubpFlow getSubpFlow()
Description copied from interface: BBlock
Returns the SubpFlow object this BBlock belongs to.

Specified by:
getSubpFlow in interface BBlock

toString

public java.lang.String toString()

toStringVeryShort

public java.lang.String toStringVeryShort()

getDef

public DefVector getDef()
getDef: Get bit vector showing Def set of this block.

Returns:
bit vector representing Def(B) of this block B.

setDef

public void setDef(DefVector pVect)

getDDef

public DefVector getDDef()

setDDef

public void setDDef(DefVector pVect)

getPDef

public DefVector getPDef()
Description copied from interface: BBlock
getPDef: Get bit vector showing PDef set of this block. The PDef set of this BBlock corresponds to the DefVector whose set bits correspond to SetRefReprs execution of which may write some data to a memory location and the data on the the location may not have been overwritten when the program control exits this BBlock.

Specified by:
getPDef in interface BBlock
Returns:
bit vector representing PDef(B) of this block B.

setPDef

public void setPDef(DefVector pVect)
Specified by:
setPDef in interface BBlock

getDKill

public DefVector getDKill()
getKill: Get bit vector showing Kill set of this block.

Specified by:
getDKill in interface BBlock
Returns:
bit vector representing Kill(B) of this block B.

setDKill

public void setDKill(DefVector pVect)
Specified by:
setDKill in interface BBlock

getPKill

public DefVector getPKill()
getDestroy: Get bit vector showing Destroy set of this block.

Specified by:
getPKill in interface BBlock
Returns:
bit vector representing Destroy(B) of this block B.

setPKill

public void setPKill(DefVector pVect)
Specified by:
setPKill in interface BBlock

getReach

public DefVector getReach()
getReach: Get bit vector showing Reach set of this block.

Returns:
bit vector representing Reach(B) of this block B.

setReach

public void setReach(DefVector pVect)

getPReach

public DefVector getPReach()
getReach0: Get bit vector showing Reach0 set of this block.

Specified by:
getPReach in interface BBlock
Returns:
bit vector representing Reach0(B) of this block B.

setPReach

public void setPReach(DefVector pVect)
Specified by:
setPReach in interface BBlock

setDReach

public void setDReach(DefVector pVect)

getDDefined

public FlowAnalSymVector getDDefined()
getDefined: Get bit vector showing Defined set of this block.

Specified by:
getDDefined in interface BBlock
Returns:
bit vector representing Defined(B) of this block B.

setDDefined

public void setDDefined(FlowAnalSymVector pVect)
Specified by:
setDDefined in interface BBlock

getPDefined

public FlowAnalSymVector getPDefined()
Description copied from interface: BBlock
getPDefined: Get bit vector showing PDefined set of this block. The DDefined set is the set of FlowAnalSyms whose value may have changed in this BBlock..

Specified by:
getPDefined in interface BBlock
Returns:
bit vector representing PDefined(B) of this block B.

setPDefined

public void setPDefined(FlowAnalSymVector pVect)
Specified by:
setPDefined in interface BBlock

getPUsed

public FlowAnalSymVector getPUsed()
getUsed: //##12 Get bit vector showing Used set of this block.

Specified by:
getPUsed in interface BBlock
Returns:
bit vector representing Used(B) of this block B.

setPUsed

public void setPUsed(FlowAnalSymVector pVect)
Specified by:
setPUsed in interface BBlock

getDExposed

public FlowAnalSymVector getDExposed()
getExposed: Get bit vector showing Exposed set of this block.

Specified by:
getDExposed in interface BBlock
Returns:
bit vector representing Exposed(B) of this block B.

setDExposed

public void setDExposed(FlowAnalSymVector pVect)
Specified by:
setDExposed in interface BBlock

getPExposed

public FlowAnalSymVector getPExposed()
getExposed: Get bit vector showing Exposed set of this block.

Specified by:
getPExposed in interface BBlock
Returns:
bit vector representing Exposed(B) of this block B.

setPExposed

public void setPExposed(FlowAnalSymVector pVect)
Specified by:
setPExposed in interface BBlock

getDEGen

public ExpVector getDEGen()
getEGen: Get bit vector showing EGen set of this block.

Specified by:
getDEGen in interface BBlock
Returns:
bit vector representing EGen(B) of this block B.

setDEGen

public void setDEGen(ExpVector pVect)
Specified by:
setDEGen in interface BBlock

getPEKill

public ExpVector getPEKill()
getEKill: Get bit vector showing EKill set of this block.

Specified by:
getPEKill in interface BBlock
Returns:
bit vector representing EKill(B) of this block B.

setPEKill

public void setPEKill(ExpVector pVect)
Specified by:
setPEKill in interface BBlock

getDAvailIn

public ExpVector getDAvailIn()
getAvailIn: Get bit vector showing AvailIn set of this block.

Specified by:
getDAvailIn in interface BBlock
Returns:
bit vector representing AvailIn(B) of this block B.

setDAvailIn

public void setDAvailIn(ExpVector pVect)
Specified by:
setDAvailIn in interface BBlock

getDAvailOut

public ExpVector getDAvailOut()
getAvailOut: Get bit vector showing AvailOut set of this block.

Specified by:
getDAvailOut in interface BBlock
Returns:
bit vector representing AvailOut(B) of this block B.

setDAvailOut

public void setDAvailOut(ExpVector pVect)
Specified by:
setDAvailOut in interface BBlock

getPLiveIn

public FlowAnalSymVector getPLiveIn()
getLiveIn: Get bit vector showing LiveIn set of this block.

Specified by:
getPLiveIn in interface BBlock
Returns:
bit vector representing LiveIn(B) of this block B.

setPLiveIn

public void setPLiveIn(FlowAnalSymVector pVect)
Specified by:
setPLiveIn in interface BBlock

getPLiveOut

public FlowAnalSymVector getPLiveOut()
getLiveOut: Get bit vector showing LiveOut set of this block.

Specified by:
getPLiveOut in interface BBlock
Returns:
bit vector representing LiveOut(B) of this block B.

setPLiveOut

public void setPLiveOut(FlowAnalSymVector pVect)
Specified by:
setPLiveOut in interface BBlock

getDDefIn

public FlowAnalSymVector getDDefIn()
getDefIn: Get bit vector showing DefIn set of this block.

Specified by:
getDDefIn in interface BBlock
Returns:
bit vector representing DefIn(B) of this block B.

setDDefIn

public void setDDefIn(FlowAnalSymVector pVect)
Specified by:
setDDefIn in interface BBlock

getDDefOut

public FlowAnalSymVector getDDefOut()
getDefOut: Get bit vector showing DefOut set of this block.

Specified by:
getDDefOut in interface BBlock
Returns:
bit vector representing DefOut(B) of this block B.

setDDefOut

public void setDDefOut(FlowAnalSymVector pVect)
Specified by:
setDDefOut in interface BBlock

isDDef

public boolean isDDef(SetRefRepr pSetRefRepr)
Description copied from interface: BBlock
isDef: See if definition at position pPos is done in this block.

Specified by:
isDDef in interface BBlock
Returns:
true if the definition is done in this block, false otherwise.

isPDef

public boolean isPDef(SetRefRepr pSetRefRepr)
Specified by:
isPDef in interface BBlock

isDKill

public boolean isDKill(SetRefRepr pSetRefRepr)
Description copied from interface: BBlock
isKill: See if definition at position pPos is killed in this block.

Specified by:
isDKill in interface BBlock
Returns:
true if the definition at pPos is killed in this block, false otherwise.

isPKill

public boolean isPKill(SetRefRepr pSetRefRepr)
Specified by:
isPKill in interface BBlock

isPReach

public boolean isPReach(SetRefRepr pSetRefRepr)
isReach: See if definition at position pPos reaches to the entry point of this block.

Specified by:
isPReach in interface BBlock
Returns:
true if the definition at pPos reaches to the entry point of this block, false otherwise.

isDDefined

public boolean isDDefined(Sym pSym)
Description copied from interface: BBlock
isDefined: See if the value of pSym is defined in this block.

Specified by:
isDDefined in interface BBlock
Returns:
true if p(def(pSym)) is included in this block, false otherwise.

isPDefined

public boolean isPDefined(Sym pSym)
Description copied from interface: BBlock
isModified: See if the value of pSym is modified in this block.

Specified by:
isPDefined in interface BBlock
Returns:
true if p(mod(pSym)) is included in this block, false otherwise.

isDUsed

public boolean isDUsed(Sym pSym)
Description copied from interface: BBlock
isUsed: //##12 See if the value of pSym is used in this block.

Specified by:
isDUsed in interface BBlock
Returns:
true if p(use(pSym)) is included in this block, false otherwise.

isPUsed

public boolean isPUsed(Sym pSym)
Specified by:
isPUsed in interface BBlock

isDExposed

public boolean isDExposed(Sym pSym)
Description copied from interface: BBlock
isExposed: See if the variable of pSym is used in this block without setting its value in this block.

Specified by:
isDExposed in interface BBlock
Returns:
true if pSym is used in this block and it is not set in this block before the use point.

isPExposed

public boolean isPExposed(Sym pSym)
Specified by:
isPExposed in interface BBlock

isDEGen

public boolean isDEGen(FlowExpId pExpId)
Description copied from interface: BBlock
isEGen: See if expression designated by pReg is generated (computed in this block and afterwards its operand is not changed) in this block.

Specified by:
isDEGen in interface BBlock
Returns:
true if the expression is generated in this block, false otherwise.

isPEKill

public boolean isPEKill(FlowExpId pExpId)
Description copied from interface: BBlock
isEKill: See if expression designated by pReg is killed (its operand is defined) in this block.

Specified by:
isPEKill in interface BBlock
Returns:
true if the expression is killed in this block, false otherwise.

isDAvailIn

public boolean isDAvailIn(FlowExpId pExpId)
Description copied from interface: BBlock
isAvailIn: See if the expression represented by pExpId is available (value is always computed) at entry to this block.

Specified by:
isDAvailIn in interface BBlock
Returns:
true if pExpId is available at entry to this block, false otherwise.

isDAvailOut

public boolean isDAvailOut(FlowExpId pExpId)
Description copied from interface: BBlock
isAvailOut: See if the expression represented by pExpId is available (value is always computed) at exit from this block.

Specified by:
isDAvailOut in interface BBlock
Returns:
true if pExpId is available at exit from this block, false otherwise.

isPLiveIn

public boolean isPLiveIn(Sym pSym)
Description copied from interface: BBlock
isLiveIn: See if pSym is live at entry to this block (value at entry is used in this block or in some successor of this block).

Specified by:
isPLiveIn in interface BBlock
Returns:
true if pSym is live at entry to this block, false otherwise.

isPLiveOut

public boolean isPLiveOut(Sym pSym)
Description copied from interface: BBlock
isLiveOut: See if pSym is live at exit from this block (value at exit is used in some successor of this block).

Specified by:
isPLiveOut in interface BBlock
Returns:
true if pSym is live at exit from this block, false otherwise.

isDDefIn

public boolean isDDefIn(Sym pSym)
Description copied from interface: BBlock
isDefIn: See if pSym is always defined at entry to this block whichever path may be take.

Specified by:
isDDefIn in interface BBlock
Returns:
true if pSym is always defined at entry to this block, false otherwise.

isDDefOut

public boolean isDDefOut(Sym pSym)
Description copied from interface: BBlock
isDefOut: See if pSym is always defined at exit from this block.

Specified by:
isDDefOut in interface BBlock
Returns:
true if pSym is always defined at exit from this block, false otherwise.

getDUsed

public FlowAnalSymVector getDUsed()
Description copied from interface: BBlock
getDUsed: //##12 Get bit vector showing DUsed set of this block. DUsed set is the union of all used sets of SetRefReprs (specified by SetRefRepr#getUseSyms()).

Specified by:
getDUsed in interface BBlock
Returns:
bit vector representing DUsed(B) of this block B.

setDUsed

public void setDUsed(FlowAnalSymVector pVect)
Specified by:
setDUsed in interface BBlock