Package jminusminus
Class NLIRMove
java.lang.Object
jminusminus.NLIRInstruction
jminusminus.NLIRMove
LIR move instruction.
- 
Field SummaryFields inherited from class jminusminus.NLIRInstructionblock, id, lirMnemonic, reads, write
- 
Constructor SummaryConstructorsConstructorDescriptionNLIRMove(NBasicBlock block, int id, NLIRInstruction from, NLIRInstruction to) Constructs an NLIRMove object.NLIRMove(NBasicBlock block, int id, NRegister from, NRegister to) Constructs an NLIRMove object.
- 
Method SummaryModifier and TypeMethodDescriptionvoidReplace references to virtual registers in this LIR instruction with references to physical registers.voidtoSpim(PrintWriter out) Translates this LIR instruction into SPIM and writes it out to the specified output stream.toString()Returns a string representation of this instruction.
- 
Constructor Details- 
NLIRMoveConstructs an NLIRMove object.- Parameters:
- block- enclosing block.
- id- identifier of the instruction.
- from- LIR to move from.
- to- LIR to move to.
 
- 
NLIRMoveConstructs an NLIRMove object.- Parameters:
- block- enclosing block.
- id- identifier of the instruction.
- from- register (virtual or physical) to move from.
- to- register (virtual or physical) to move to.
 
 
- 
- 
Method Details- 
allocatePhysicalRegisterspublic void allocatePhysicalRegisters()Replace references to virtual registers in this LIR instruction with references to physical registers.- Overrides:
- allocatePhysicalRegistersin class- NLIRInstruction
 
- 
toSpimTranslates this LIR instruction into SPIM and writes it out to the specified output stream.- Overrides:
- toSpimin class- NLIRInstruction
- Parameters:
- out- output stream for SPIM code.
 
- 
toStringReturns a string representation of this instruction.- Overrides:
- toStringin class- NLIRInstruction
- Returns:
- a string representation of this instruction.
 
 
-