|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jikesrvm.compilers.opt.controlflow.LTDominatorInfo
class LTDominatorInfo
This class holds data associated with a basic block as computed by the Lengauer-Tarjan dominator calculation.
LTDominators
Field Summary | |
---|---|
private BasicBlock |
ancestor
|
private Enumeration<BasicBlock> |
bbEnum
|
private HashSet<BasicBlock> |
bucket
|
private BasicBlock |
child
|
(package private) static boolean |
DEBUG
|
private BasicBlock |
dominator
the immediate dominator |
private BasicBlock |
label
|
private BasicBlock |
parent
|
private int |
semiDominator
|
private int |
size
|
Constructor Summary | |
---|---|
LTDominatorInfo(BasicBlock block)
|
Method Summary | |
---|---|
void |
addToBucket(BasicBlock block)
Adds the passed block from the bucket for this node |
BitVector |
dominators(BasicBlock block,
IR ir)
This method returns the set of blocks that dominates the passed block, i.e., it answers the question "Who dominates me?" |
BasicBlock |
getAncestor()
Returns the ancestor for this block |
Iterator<BasicBlock> |
getBucketIterator()
Returns an iterator over this block's bucket |
BasicBlock |
getChild()
returns the child |
BasicBlock |
getDominator()
Returns the immediate dominator for this node |
Enumeration<BasicBlock> |
getEnum()
Helper method to return the Info field associated with a block |
static BasicBlock |
getIdom(BasicBlock bb)
return the immediate dominator of a basic block. |
static LTDominatorInfo |
getInfo(BasicBlock block)
Helper method to return the Info field associated with a block |
BasicBlock |
getLabel()
returns the label |
BasicBlock |
getParent()
Returns the parent of this block |
int |
getSemiDominator()
Returns the semidomintor for this node |
int |
getSize()
returns the size |
static boolean |
isDominatedBy(BasicBlock block,
BasicBlock master)
This method determines if the 1st parameter (block) is dominated by the 2nd parameter (master), i.e., must control pass through "master" before reaching "block" |
void |
removeFromBucket(BasicBlock block)
Removes the passed block from the bucket for this node |
void |
setAncestor(BasicBlock value)
Sets the ancestor for the value passed |
void |
setChild(BasicBlock value)
sets the child field |
void |
setDominator(BasicBlock value)
Sets the immediate dominator for this node |
void |
setEnum(Enumeration<BasicBlock> bbEnum)
set the basic block enum field |
void |
setLabel(BasicBlock value)
sets the label |
void |
setParent(BasicBlock value)
Sets the parent of this block |
void |
setSemiDominator(int value)
Sets the semidominator for this node |
void |
setSize(int value)
sets the size |
String |
toString()
Prints a string version of objection |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
static final boolean DEBUG
private int semiDominator
private BasicBlock dominator
private BasicBlock parent
private final HashSet<BasicBlock> bucket
private BasicBlock label
private BasicBlock ancestor
private int size
private BasicBlock child
private Enumeration<BasicBlock> bbEnum
Constructor Detail |
---|
LTDominatorInfo(BasicBlock block)
block
- the basic block this info is associated withMethod Detail |
---|
public BitVector dominators(BasicBlock block, IR ir)
block
- the block of interestir
- the governing ir
public static boolean isDominatedBy(BasicBlock block, BasicBlock master)
block
- the block we care aboutmaster
- the potential dominating block
public void setSemiDominator(int value)
value
- the new valuepublic int getSemiDominator()
public void setDominator(BasicBlock value)
value
- the value to setpublic BasicBlock getDominator()
public void setParent(BasicBlock value)
value
- the valuepublic BasicBlock getParent()
public Iterator<BasicBlock> getBucketIterator()
public void removeFromBucket(BasicBlock block)
block
- the block to remove from the bucketpublic void addToBucket(BasicBlock block)
block
- the block to add to our bucketpublic void setAncestor(BasicBlock value)
value
- the ancestor valuepublic BasicBlock getAncestor()
public void setLabel(BasicBlock value)
value
- the labelpublic BasicBlock getLabel()
public void setSize(int value)
value
- the sizepublic int getSize()
public void setChild(BasicBlock value)
value
- the child valuepublic BasicBlock getChild()
public Enumeration<BasicBlock> getEnum()
public void setEnum(Enumeration<BasicBlock> bbEnum)
bbEnum
- basic block enumpublic static LTDominatorInfo getInfo(BasicBlock block)
block
- the block of interest
public static BasicBlock getIdom(BasicBlock bb)
bb
- the basic block in question
public String toString()
toString
in class Object
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |