coins.backend.sched
Class LirNodeInf

java.lang.Object
  extended bycoins.backend.sched.LirNodeInf

public class LirNodeInf
extends java.lang.Object

Class to generate information of LirNode instruction


Field Summary
(package private)  LirNode lirNode
           
(package private) static int LOAD_LATENCY
           
(package private)  MachineParams machineParams
           
(package private) static LirNode MEM
           
(package private) static int PARALLEL_LATENCY
           
(package private)  Schedule schedule
           
(package private) static LirNode STACK_REG
           
 
Constructor Summary
(package private) LirNodeInf(LirNode ln, Schedule schedule)
           
 
Method Summary
(package private)  void addMemDef(BiList bl, LirNode ln)
          Add constant MEM to BiList bl, if ln is a SET instruction and left hand child has a MEM instruction
(package private)  void addMemUse(BiList bl, LirNode ln)
          Add constant MEM to BiList bl, if ln is a SET instruction and right hand child has a MEM instruction, or if ln is a CALL instruction (because stack memory may be used as parameters)
(package private)  void addReg(BiList bl, LirNode ln)
           
(package private)  void addRegDef(BiList bl, LirNode ln)
          Add registers defined in LirNode ln to BiList bl
(package private)  void addRegUse(BiList bl, LirNode ln)
          Add registers used in LirNode ln to BiList bl
(package private)  boolean containsMEM(LirNode ln)
          Return true if LirNode ln contains Op.MEM
(package private)  LirNode getCalleeReg(LirNode ln)
           
(package private)  BiList input()
          Return list of input(use) registers or MEM of this LirNode
(package private)  int latency(int cost)
          Retrun latency of this LirNode
(package private)  BiList output()
          Return list of output(def) registers or MEM of this LirNode
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOAD_LATENCY

static final int LOAD_LATENCY
See Also:
Constant Field Values

PARALLEL_LATENCY

static final int PARALLEL_LATENCY
See Also:
Constant Field Values

MEM

static final LirNode MEM

STACK_REG

static final LirNode STACK_REG

lirNode

LirNode lirNode

schedule

Schedule schedule

machineParams

MachineParams machineParams
Constructor Detail

LirNodeInf

LirNodeInf(LirNode ln,
           Schedule schedule)
Method Detail

input

BiList input()
Return list of input(use) registers or MEM of this LirNode


output

BiList output()
Return list of output(def) registers or MEM of this LirNode


latency

int latency(int cost)
Retrun latency of this LirNode

Parameters:
cost -

containsMEM

boolean containsMEM(LirNode ln)
Return true if LirNode ln contains Op.MEM

Parameters:
ln -

addMemUse

void addMemUse(BiList bl,
               LirNode ln)
Add constant MEM to BiList bl, if ln is a SET instruction and right hand child has a MEM instruction, or if ln is a CALL instruction (because stack memory may be used as parameters)

Parameters:
bl -
ln -

addMemDef

void addMemDef(BiList bl,
               LirNode ln)
Add constant MEM to BiList bl, if ln is a SET instruction and left hand child has a MEM instruction

Parameters:
bl -
ln -

addRegUse

void addRegUse(BiList bl,
               LirNode ln)
Add registers used in LirNode ln to BiList bl

Parameters:
bl -
ln -

addRegDef

void addRegDef(BiList bl,
               LirNode ln)
Add registers defined in LirNode ln to BiList bl

Parameters:
bl -
ln -

addReg

void addReg(BiList bl,
            LirNode ln)

getCalleeReg

LirNode getCalleeReg(LirNode ln)