coins.opt
Class Opt

java.lang.Object
  extended bycoins.opt.Opt

public class Opt
extends java.lang.Object

Optimization driver class. The following command line switches are supported:

hirOpt=cf
HIR constant folding
hirOpt=cpf
HIR constant propagation and folding
hirOpt=cse
HIR common subexpression elimination
hirOpt=dce
HIR dead code elimination
lirOpt=cf
LIR constant folding
lirOpt=cpf
LIR constant propagation and folding
lirOpt=cse
LIR common subexpression elimination
lirOpt=dce
LIR dead code elimination

Each one is done only once, and if multiple items are specified, they will be performed in the order listed above.


Field Summary
 AliasAnal fAlias
           
 int fDbgLevel
           
 java.lang.String fHirOpt
           
protected  java.util.List fInlineSubps
           
 java.util.List fKeyList
           
 Flow flow
           
 FlowRoot flowRoot
           
 java.util.Map fOptionMap
           
 CoinsOptions fOptions
           
protected  java.util.List fReformPatternList
           
protected  SubpFlow fSubpFlow
           
 HirRoot hirRoot
           
 IoRoot ioRoot
           
 SymRoot symRoot
           
 
Constructor Summary
Opt(FlowRoot pFlowRoot)
          Opt.
 
Method Summary
(package private)  void dbg(int level, java.lang.String pHeader, java.lang.Object pObject)
          dbg.
 boolean doHir()
           
 boolean doHir(java.util.List pOpts)
          HIR optimizer.
 void releaseFlowInf(SubpDefinition pSubpDef)
          Release flow information so that storage space can be reused and avoid OutofMemoryException.
(package private)  boolean shouldTrace(int level)
          shouldTrace.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

flowRoot

public final FlowRoot flowRoot

ioRoot

public final IoRoot ioRoot

symRoot

public final SymRoot symRoot

hirRoot

public final HirRoot hirRoot

flow

public final Flow flow

fSubpFlow

protected SubpFlow fSubpFlow

fAlias

public final AliasAnal fAlias

fOptionMap

public final java.util.Map fOptionMap

fOptions

public final CoinsOptions fOptions

fHirOpt

public final java.lang.String fHirOpt

fKeyList

public final java.util.List fKeyList

fDbgLevel

public final int fDbgLevel

fInlineSubps

protected java.util.List fInlineSubps

fReformPatternList

protected java.util.List fReformPatternList
Constructor Detail

Opt

public Opt(FlowRoot pFlowRoot)
Opt.

Method Detail

dbg

void dbg(int level,
         java.lang.String pHeader,
         java.lang.Object pObject)
dbg.


shouldTrace

boolean shouldTrace(int level)
shouldTrace.


doHir

public boolean doHir(java.util.List pOpts)
HIR optimizer.


doHir

public boolean doHir()

releaseFlowInf

public void releaseFlowInf(SubpDefinition pSubpDef)
Release flow information so that storage space can be reused and avoid OutofMemoryException.

Parameters:
pSubpDef - SubpDefinition for which flow information is to be released.