org.jikesrvm.compilers.opt.ir
Class GenericRegisterPool

java.lang.Object
  extended by org.jikesrvm.compilers.opt.ir.AbstractRegisterPool
      extended by org.jikesrvm.compilers.opt.ir.GenericRegisterPool
Direct Known Subclasses:
RegisterPool

public class GenericRegisterPool
extends AbstractRegisterPool

Pool of symbolic registers. Each IR contains has exactly one register pool object associated with it.

See Also:
Register

Field Summary
protected  ArchitectureSpecificOpt.PhysicalRegisterSet physical
           
 
Fields inherited from class org.jikesrvm.compilers.opt.ir.AbstractRegisterPool
currentNum
 
Constructor Summary
protected GenericRegisterPool(RVMMethod meth)
          Initializes a new register pool for the method meth.
 
Method Summary
 Register getFP()
          Get the Framepointer (FP)
 int getNumberOfSymbolicRegisters()
          Return the number of symbolic registers (doesn't count physical ones)
 ArchitectureSpecificOpt.PhysicalRegisterSet getPhysicalRegisterSet()
           
 RegisterOperand makeFPOp()
          Get a temporary that represents the FP register
 RegisterOperand makeTROp()
          Get a temporary that represents the PR register
 
Methods inherited from class org.jikesrvm.compilers.opt.ir.AbstractRegisterPool
getAddress, getCondition, getDouble, getFirstSymbolicRegister, getFloat, getInteger, getLong, getReg, getReg, getReg, getSecondReg, getValidation, makeTemp, makeTemp, makeTemp, makeTempAddress, makeTempBoolean, makeTempCondition, makeTempDouble, makeTempFloat, makeTempInt, makeTempLong, makeTempOffset, makeTempValidation, release, removeRegister
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

physical

protected final ArchitectureSpecificOpt.PhysicalRegisterSet physical
Constructor Detail

GenericRegisterPool

protected GenericRegisterPool(RVMMethod meth)
Initializes a new register pool for the method meth.

Parameters:
meth - the RVMMethod of the outermost method
Method Detail

getPhysicalRegisterSet

public ArchitectureSpecificOpt.PhysicalRegisterSet getPhysicalRegisterSet()

getNumberOfSymbolicRegisters

public int getNumberOfSymbolicRegisters()
Return the number of symbolic registers (doesn't count physical ones)

Returns:
the number of symbolic registers allocated by the pool

getFP

public Register getFP()
Get the Framepointer (FP)

Returns:
the FP register

makeFPOp

public RegisterOperand makeFPOp()
Get a temporary that represents the FP register

Returns:
the temp

makeTROp

public RegisterOperand makeTROp()
Get a temporary that represents the PR register

Returns:
the temp