|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.jikesrvm.compilers.opt.driver.CompilerPhase
org.jikesrvm.compilers.opt.ssa.GlobalCSE
public final class GlobalCSE
This class provides global common sub expression elimination.
| Field Summary | |
|---|---|
private HashMap<Integer,Instruction> |
avail
Available expressions. |
private static Constructor<CompilerPhase> |
constructor
Constructor for this compiler phase |
private DominatorTree |
dominator
Cache of dominator tree that should be computed prior to this phase |
private IR |
ir
Cache of IR being processed by this phase |
private GlobalValueNumberState |
valueNumbers
Cache of the value numbers from the IR |
boolean |
verbose
Output debug messages |
| Fields inherited from class org.jikesrvm.compilers.opt.driver.CompilerPhase |
|---|
container |
| Constructor Summary | |
|---|---|
GlobalCSE()
Constructor |
|
| Method Summary | |
|---|---|
Constructor<CompilerPhase> |
getClassConstructor()
Get a constructor object for this compiler phase |
String |
getName()
Returns the name of the phase |
private RegisterOperand |
getResult(Instruction inst)
Get the result operand of the instruction |
private void |
globalCSE(BasicBlock b)
Recursively descend over all blocks dominated by b. |
void |
perform(IR ir)
Perform the GlobalCSE compiler phase |
private boolean |
shouldCSE(Instruction inst)
should this instruction be cse'd ? |
boolean |
shouldPerform(OptOptions options)
Redefine shouldPerform so that none of the subphases will occur unless we pass through this test. |
| Methods inherited from class org.jikesrvm.compilers.opt.driver.CompilerPhase |
|---|
dumpIR, dumpIR, getCompilerPhaseConstructor, getCompilerPhaseConstructor, newExecution, performPhase, printingEnabled, reportAdditionalStats, setContainer, verify |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public boolean verbose
private IR ir
private GlobalValueNumberState valueNumbers
private DominatorTree dominator
private final HashMap<Integer,Instruction> avail
private static final Constructor<CompilerPhase> constructor
| Constructor Detail |
|---|
public GlobalCSE()
| Method Detail |
|---|
public boolean shouldPerform(OptOptions options)
shouldPerform in class CompilerPhaseoptions - the compiler options for the compilation
public Constructor<CompilerPhase> getClassConstructor()
getClassConstructor in class CompilerPhasepublic String getName()
getName in class CompilerPhasepublic void perform(IR ir)
perform in class CompilerPhaseir - the IR on which to apply the phaseprivate void globalCSE(BasicBlock b)
b - the current block to processprivate RegisterOperand getResult(Instruction inst)
inst - private boolean shouldCSE(Instruction inst)
inst -
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||