coins.ssa
クラス Util

java.lang.Object
  |
  +--coins.ssa.Util

class Util
extends java.lang.Object

Utilities for the SSA module


コンストラクタの概要
(パッケージプライベート) Util(SsaEnvironment e, Function function)
          Constructor
 
メソッドの概要
(パッケージプライベート)  void changeLabelRef(boolean isTranslate)
          Change the LabelRef node into the SSA specified ones.
(パッケージプライベート)  BiList findTargetLir(LirNode root, int opCode, BiList l)
          Search and find the LIR nodes which has the specified operation code.
(パッケージプライベート)  LirNode makeNewJump(BasicBlk blk, LirLabelRef labelRef)
          Make a new JUMP node to the specified label.
(パッケージプライベート)  LirNode makePhiInst(Symbol s, BasicBlk blk)
          Make a new Phi instruction.
(パッケージプライベート)  BiList predEdges(BasicBlk blk, boolean getPredBlk)
          Collect the edges from the predecessors or predecessors themselves.
 
クラス java.lang.Object から継承したメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

コンストラクタの詳細

Util

Util(SsaEnvironment e,
     Function function)
Constructor

パラメータ:
e - The environment of the SSA module
function - The current function
メソッドの詳細

makeNewJump

LirNode makeNewJump(BasicBlk blk,
                    LirLabelRef labelRef)
Make a new JUMP node to the specified label.

パラメータ:
blk - The basic block which the new JUMP node put in
labelRef - The label which the new JUMP node go to
戻り値:
A new JUMP node

findTargetLir

BiList findTargetLir(LirNode root,
                     int opCode,
                     BiList l)
Search and find the LIR nodes which has the specified operation code.

パラメータ:
root - The root node of the search
opCode - The specified operation code
l - The list which is stored in the found LIR node
戻り値:
The list of LIR nodes

changeLabelRef

void changeLabelRef(boolean isTranslate)
Change the LabelRef node into the SSA specified ones. Or Change the LabelRef node into the normal ones. This method MUST be called before translating into SSA form.

パラメータ:
isTranslate - True if the translation is for the specified ones

predEdges

BiList predEdges(BasicBlk blk,
                 boolean getPredBlk)
Collect the edges from the predecessors or predecessors themselves.

パラメータ:
blk - The current basic blk
getPredBlk - True means to collect predecessors
戻り値:
The list of edges or basic blocks

makePhiInst

LirNode makePhiInst(Symbol s,
                    BasicBlk blk)
Make a new Phi instruction. The arguments and the variable that defined by this new Phi instruction have the specified symbol.

パラメータ:
s - The specified symbol
blk - The basic block which the new phi instruction is inserted
戻り値:
A new Phi instruction