|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--comp.RegBank
Manages a set of registers for use during code generation.
Field Summary | |
(package private) int |
liveCount
|
(package private) boolean[] |
regs
|
Constructor Summary | |
RegBank(int numRegs)
|
Method Summary | |
void |
free(java.lang.String reg)
Return this register to the bank. |
void |
freeAll()
Free all registers currenly in use. |
java.lang.String |
newReg()
Answer a new register name as a String. |
void |
restoreRegs(Assembler asm,
java.util.List saved)
Restore all the registers in the given list. |
java.util.List |
saveRegs(Assembler asm)
Save all registers currently on use. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
boolean[] regs
int liveCount
Constructor Detail |
public RegBank(int numRegs)
Method Detail |
public void free(java.lang.String reg)
public java.lang.String newReg()
public void freeAll()
public java.util.List saveRegs(Assembler asm)
public void restoreRegs(Assembler asm, java.util.List saved)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |