coins.simd
クラス SimdOpt

java.lang.Object
  |
  +--coins.simd.SimdOpt

public class SimdOpt
extends java.lang.Object

Class for SIMD level optimization


フィールドの概要
static int MAX_SIMD_PARALLEL
          Maximum size of elements in SIMD Parallel instructions
 boolean messageFlag
          Flag of printing out trace informations
 
コンストラクタの概要
SimdOpt(Function f)
          Constructs a SimdOpt object and initialize bopList,boneList and simdReg.
 
メソッドの概要
 java.util.Vector allocateSimdReg(java.util.Vector in)
          Allocate SIMD registers.
 java.util.Vector combineSimd(java.util.Vector in)
          Combines SIMD instructions.
 java.util.Vector decompose(java.util.Vector in)
          Decomposes DAG into basic operations(bop).
 boolean defined(Symbol var, LirNode inst)
          Tests if a symbol is defined in an instruction.
 java.util.Vector invoke(BiList live, java.util.Vector in, ReplaceRegNames rrn)
          Invokes methods for SIMD optimization.
 java.util.Vector liveReg(java.util.Vector in)
          Calculate live registers.
 java.util.Vector liveReg(java.util.Vector in, java.util.Vector live)
           
 java.util.Vector restrictInst(java.util.Vector in)
          Applies constraints for instructions and registers.
 boolean used(Symbol var, LirNode inst)
          Tests if a symbol is used in an instruction (LirNode).
 
クラス java.lang.Object から継承したメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

フィールドの詳細

MAX_SIMD_PARALLEL

public static final int MAX_SIMD_PARALLEL
Maximum size of elements in SIMD Parallel instructions

関連項目:
定数フィールド値

messageFlag

public boolean messageFlag
Flag of printing out trace informations

コンストラクタの詳細

SimdOpt

public SimdOpt(Function f)
Constructs a SimdOpt object and initialize bopList,boneList and simdReg.

パラメータ:
f - Function
メソッドの詳細

invoke

public java.util.Vector invoke(BiList live,
                               java.util.Vector in,
                               ReplaceRegNames rrn)
                        throws SimdOptException
Invokes methods for SIMD optimization.

パラメータ:
live - ImList,which has liveness information.
in - Vector,which contains LIR instructions as elements.
rrn - ReplaceRegNames, which replaces and has info. of replaced regs
戻り値:
Vector, which contains SIMD optiimized LIR instructions.
SimdOptException

decompose

public java.util.Vector decompose(java.util.Vector in)
                           throws SimdOptException
Decomposes DAG into basic operations(bop).

パラメータ:
in - Vector,which contains DAGs as its elements.
戻り値:
Vector, which contains basic operations as its elements.
SimdOptException

combineSimd

public java.util.Vector combineSimd(java.util.Vector in)
                             throws SimdOptException
Combines SIMD instructions.

パラメータ:
in - Vector, which contains LirNodes as its elements.
戻り値:
Vector, which contains combined instructions.
SimdOptException

restrictInst

public java.util.Vector restrictInst(java.util.Vector in)
                              throws SimdOptException
Applies constraints for instructions and registers.

パラメータ:
in - Vector, which contains combined instructions(LirNodes).
戻り値:
Vector, which contains constraints satisfied instructions (LirNodes).
SimdOptException

allocateSimdReg

public java.util.Vector allocateSimdReg(java.util.Vector in)
                                 throws SimdOptException
Allocate SIMD registers.

パラメータ:
in - Vector, which contains SIMD instructions (LirNodes).
戻り値:
Vector, which contains SIMD register-allocated instructions.
SimdOptException

liveReg

public java.util.Vector liveReg(java.util.Vector in)
Calculate live registers.

パラメータ:
in - Vector, which contains instruction (LirNodes).
戻り値:
Vector, which contains vectors of live registers (symbols).

liveReg

public java.util.Vector liveReg(java.util.Vector in,
                                java.util.Vector live)

defined

public boolean defined(Symbol var,
                       LirNode inst)
Tests if a symbol is defined in an instruction.

パラメータ:
var - Symbol
inst - LirNode
戻り値:
boolean which is true if var is defined in inst and false o.w.

used

public boolean used(Symbol var,
                    LirNode inst)
Tests if a symbol is used in an instruction (LirNode).

パラメータ:
var - Symbol which is checked.
inst - LirNode which represents an instruction.
戻り値:
boolean which is true if var is used in inst and false otherwise.