C# Class Mosa.Compiler.Framework.InstructionNode

Afficher le fichier Open project: tgiphil/MOSA-Project Class Usage Examples

Méthodes publiques

Méthode Description
AddBranchTarget ( BasicBlock block ) : void

Sets the branch target.

AddOperand ( Operand operand ) : void

Adds the operand.

Empty ( ) : void

Empties this context.

GetAdditionalOperand ( int index ) : Operand

Gets the additional operand.

GetOperand ( int opIndex ) : Operand

Gets the operand by index.

GetResult ( int index ) : Operand

Gets the result.

GoBackwardsToNonEmpty ( ) : InstructionNode

Returns the 1st non empty node (including the current) by traversing the instructions backwards

GoForwardToNonEmpty ( ) : InstructionNode

Returns the 1st non empty node (including the current) by traversing the instructions forward

Insert ( InstructionNode node ) : void
InstructionNode ( ) : System
InstructionNode ( BaseInstruction instruction ) : System

Sets the instruction.

InstructionNode ( BaseInstruction instruction, BasicBlock block ) : System

Sets the instruction.

InstructionNode ( BaseInstruction instruction, BasicBlock block1, BasicBlock block2 ) : System

Sets the instruction.

InstructionNode ( BaseInstruction instruction, ConditionCode condition ) : System

Sets the instruction.

InstructionNode ( BaseInstruction instruction, ConditionCode condition, BasicBlock block ) : System

Sets the instruction.

InstructionNode ( BaseInstruction instruction, MosaMethod target ) : System

Sets the instruction.

InstructionNode ( BaseInstruction instruction, Operand result ) : System

Sets the instruction.

InstructionNode ( BaseInstruction instruction, Operand result, Operand operand1 ) : System

Sets the instruction.

InstructionNode ( BaseInstruction instruction, bool updateStatus, Operand result ) : System

Sets the instruction.

InstructionNode ( BaseInstruction instruction, int operandCount, byte resultCount ) : System

Sets the instruction.

Replace ( InstructionNode node ) : void

Replaces the specified node with the given node, the existing node is invalid afterwards

ReplaceInstructionOnly ( BaseInstruction instruction ) : void

Replaces the instruction only.

SetAdditionalOperand ( int index, Operand operand ) : void

Sets the additional operand.

SetInstruction ( BaseInstruction instruction ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, BasicBlock block ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, BasicBlock block1, BasicBlock block2 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, ConditionCode condition ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, ConditionCode condition, BasicBlock block ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, ConditionCode condition, Operand result ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, ConditionCode condition, Operand result, Operand operand1 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, ConditionCode condition, Operand result, Operand operand1, Operand operand2 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, ConditionCode condition, Operand result, Operand operand1, Operand operand2, BasicBlock block ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, ConditionCode condition, bool updateStatus, Operand result, Operand operand1 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, ConditionCode condition, bool updateStatus, Operand result, Operand operand1, Operand operand2 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, InstructionSize size, Operand result, Operand operand1 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, InstructionSize size, Operand result, Operand operand1, Operand operand2 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, InstructionSize size, Operand result, Operand operand1, Operand operand2, Operand operand3 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, InstructionSize size, Operand result, Operand operand1, Operand operand2, Operand operand3, Operand operand4 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, MosaMethod target ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, Operand result ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, Operand result, Operand operand1 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, Operand result, Operand operand1, Operand operand2 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, Operand result, Operand operand1, Operand operand2, Operand operand3 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, Operand result, Operand operand1, Operand operand2, Operand operand3, Operand operand4 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, bool updateStatus, Operand result ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, bool updateStatus, Operand result, Operand operand1 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, bool updateStatus, Operand result, Operand operand1, Operand operand2 ) : void

Sets the instruction.

SetInstruction ( BaseInstruction instruction, int operandCount, byte resultCount ) : void

Sets the instruction.

SetInstruction2 ( BaseInstruction instruction, Operand result, Operand result2 ) : void

Sets the instruction.

SetInstruction2 ( BaseInstruction instruction, Operand result, Operand result2, Operand operand1 ) : void

Sets the instruction.

SetInstruction2 ( BaseInstruction instruction, Operand result, Operand result2, Operand operand1, Operand operand2 ) : void

Sets the instruction.

SetInstruction2 ( BaseInstruction instruction, Operand result, Operand result2, Operand operand1, Operand operand2, Operand operand3 ) : void

Sets the instruction.

SetOperand ( int index, Operand operand ) : void

Sets the operand by index.

SetResult ( int index, Operand operand ) : void

Sets the result by index.

Split ( BasicBlock newblock ) : void

Splits the node list by moving the next instructions into the new block.

ToString ( ) : string

Returns a System.String that represents this instance.

UpdateBranchTarget ( int index, BasicBlock block ) : void

Private Methods

Méthode Description
CheckAddition ( ) : void
Clear ( ) : void

Clears this instance.

ClearOperands ( ) : void
ReplaceOperands ( Operand target, Operand replacement ) : void
SizeAdditionalOperands ( int index ) : void

Method Details

AddBranchTarget() public méthode

Sets the branch target.
public AddBranchTarget ( BasicBlock block ) : void
block BasicBlock The basic block.
Résultat void

AddOperand() public méthode

Adds the operand.
public AddOperand ( Operand operand ) : void
operand Operand The operand.
Résultat void

Empty() public méthode

Empties this context.
public Empty ( ) : void
Résultat void

GetAdditionalOperand() public méthode

Gets the additional operand.
public GetAdditionalOperand ( int index ) : Operand
index int The index.
Résultat Operand

GetOperand() public méthode

Gets the operand by index.
public GetOperand ( int opIndex ) : Operand
opIndex int The index.
Résultat Operand

GetResult() public méthode

Gets the result.
public GetResult ( int index ) : Operand
index int The index.
Résultat Operand

GoBackwardsToNonEmpty() public méthode

Returns the 1st non empty node (including the current) by traversing the instructions backwards
public GoBackwardsToNonEmpty ( ) : InstructionNode
Résultat InstructionNode

GoForwardToNonEmpty() public méthode

Returns the 1st non empty node (including the current) by traversing the instructions forward
public GoForwardToNonEmpty ( ) : InstructionNode
Résultat InstructionNode

Insert() public méthode

public Insert ( InstructionNode node ) : void
node InstructionNode
Résultat void

InstructionNode() public méthode

public InstructionNode ( ) : System
Résultat System

InstructionNode() public méthode

Sets the instruction.
public InstructionNode ( BaseInstruction instruction ) : System
instruction BaseInstruction The instruction.
Résultat System

InstructionNode() public méthode

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, BasicBlock block ) : System
instruction BaseInstruction The instruction.
block BasicBlock The block.
Résultat System

InstructionNode() public méthode

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, BasicBlock block1, BasicBlock block2 ) : System
instruction BaseInstruction The instruction.
block1 BasicBlock The block1.
block2 BasicBlock The block2.
Résultat System

InstructionNode() public méthode

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, ConditionCode condition ) : System
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
Résultat System

InstructionNode() public méthode

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, ConditionCode condition, BasicBlock block ) : System
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
block BasicBlock The block.
Résultat System

InstructionNode() public méthode

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, MosaMethod target ) : System
instruction BaseInstruction The instruction.
target MosaMethod The target.
Résultat System

InstructionNode() public méthode

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, Operand result ) : System
instruction BaseInstruction The instruction.
result Operand The result.
Résultat System

InstructionNode() public méthode

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, Operand result, Operand operand1 ) : System
instruction BaseInstruction The instruction.
result Operand The result.
operand1 Operand The operand1.
Résultat System

InstructionNode() public méthode

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, bool updateStatus, Operand result ) : System
instruction BaseInstruction The instruction.
updateStatus bool if set to true [update status].
result Operand The result.
Résultat System

InstructionNode() public méthode

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, int operandCount, byte resultCount ) : System
instruction BaseInstruction The instruction.
operandCount int The operand count.
resultCount byte The result count.
Résultat System

Replace() public méthode

Replaces the specified node with the given node, the existing node is invalid afterwards
public Replace ( InstructionNode node ) : void
node InstructionNode The node.
Résultat void

ReplaceInstructionOnly() public méthode

Replaces the instruction only.
public ReplaceInstructionOnly ( BaseInstruction instruction ) : void
instruction BaseInstruction The instruction.
Résultat void

SetAdditionalOperand() public méthode

Sets the additional operand.
public SetAdditionalOperand ( int index, Operand operand ) : void
index int The index.
operand Operand The operand.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction ) : void
instruction BaseInstruction The instruction.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, BasicBlock block ) : void
instruction BaseInstruction The instruction.
block BasicBlock The block.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, BasicBlock block1, BasicBlock block2 ) : void
instruction BaseInstruction The instruction.
block1 BasicBlock The block1.
block2 BasicBlock The block2.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition, BasicBlock block ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
block BasicBlock The block.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition, Operand result ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
result Operand The result.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition, Operand result, Operand operand1 ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
result Operand The result.
operand1 Operand The operand1.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition, Operand result, Operand operand1, Operand operand2 ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
result Operand The result.
operand1 Operand The operand1.
operand2 Operand The operand2.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition, Operand result, Operand operand1, Operand operand2, BasicBlock block ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
result Operand The result.
operand1 Operand The operand1.
operand2 Operand The operand2.
block BasicBlock The block.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition, bool updateStatus, Operand result, Operand operand1 ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
updateStatus bool if set to true [update status].
result Operand The result.
operand1 Operand The operand1.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition, bool updateStatus, Operand result, Operand operand1, Operand operand2 ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
updateStatus bool if set to true [update status].
result Operand The result.
operand1 Operand The operand1.
operand2 Operand The operand2.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, InstructionSize size, Operand result, Operand operand1 ) : void
instruction BaseInstruction The instruction.
size InstructionSize The size.
result Operand The result.
operand1 Operand The operand1.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, InstructionSize size, Operand result, Operand operand1, Operand operand2 ) : void
instruction BaseInstruction The instruction.
size InstructionSize The size.
result Operand The result.
operand1 Operand The operand1.
operand2 Operand The operand2.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, InstructionSize size, Operand result, Operand operand1, Operand operand2, Operand operand3 ) : void
instruction BaseInstruction The instruction.
size InstructionSize The size.
result Operand The result.
operand1 Operand The operand1.
operand2 Operand The operand2.
operand3 Operand The operand3.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, InstructionSize size, Operand result, Operand operand1, Operand operand2, Operand operand3, Operand operand4 ) : void
instruction BaseInstruction The instruction.
size InstructionSize The size.
result Operand The result.
operand1 Operand The operand1.
operand2 Operand The operand2.
operand3 Operand The operand3.
operand4 Operand The operand4.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, MosaMethod target ) : void
instruction BaseInstruction The instruction.
target MosaMethod The target.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, Operand result ) : void
instruction BaseInstruction The instruction.
result Operand The result.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, Operand result, Operand operand1 ) : void
instruction BaseInstruction The instruction.
result Operand The result.
operand1 Operand The operand1.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, Operand result, Operand operand1, Operand operand2 ) : void
instruction BaseInstruction The instruction.
result Operand The result.
operand1 Operand The operand1.
operand2 Operand The operand2.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, Operand result, Operand operand1, Operand operand2, Operand operand3 ) : void
instruction BaseInstruction The instruction.
result Operand The result.
operand1 Operand The operand1.
operand2 Operand The operand2.
operand3 Operand The operand3.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, Operand result, Operand operand1, Operand operand2, Operand operand3, Operand operand4 ) : void
instruction BaseInstruction The instruction.
result Operand The result.
operand1 Operand The operand1.
operand2 Operand The operand2.
operand3 Operand The operand3.
operand4 Operand
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, bool updateStatus, Operand result ) : void
instruction BaseInstruction The instruction.
updateStatus bool if set to true [update status].
result Operand The result.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, bool updateStatus, Operand result, Operand operand1 ) : void
instruction BaseInstruction The instruction.
updateStatus bool
result Operand The result.
operand1 Operand The operand1.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, bool updateStatus, Operand result, Operand operand1, Operand operand2 ) : void
instruction BaseInstruction The instruction.
updateStatus bool if set to true [update status].
result Operand The result.
operand1 Operand The operand1.
operand2 Operand The operand2.
Résultat void

SetInstruction() public méthode

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, int operandCount, byte resultCount ) : void
instruction BaseInstruction The instruction.
operandCount int The operand count.
resultCount byte The result count.
Résultat void

SetInstruction2() public méthode

Sets the instruction.
public SetInstruction2 ( BaseInstruction instruction, Operand result, Operand result2 ) : void
instruction BaseInstruction The instruction.
result Operand The result.
result2 Operand The result2.
Résultat void

SetInstruction2() public méthode

Sets the instruction.
public SetInstruction2 ( BaseInstruction instruction, Operand result, Operand result2, Operand operand1 ) : void
instruction BaseInstruction The instruction.
result Operand The result.
result2 Operand The result2.
operand1 Operand The operand1.
Résultat void

SetInstruction2() public méthode

Sets the instruction.
public SetInstruction2 ( BaseInstruction instruction, Operand result, Operand result2, Operand operand1, Operand operand2 ) : void
instruction BaseInstruction The instruction.
result Operand The result.
result2 Operand The result2.
operand1 Operand The operand1.
operand2 Operand The operand2.
Résultat void

SetInstruction2() public méthode

Sets the instruction.
public SetInstruction2 ( BaseInstruction instruction, Operand result, Operand result2, Operand operand1, Operand operand2, Operand operand3 ) : void
instruction BaseInstruction The instruction.
result Operand The result.
result2 Operand The result2.
operand1 Operand The operand1.
operand2 Operand The operand2.
operand3 Operand The operand3.
Résultat void

SetOperand() public méthode

Sets the operand by index.
public SetOperand ( int index, Operand operand ) : void
index int The index.
operand Operand The operand.
Résultat void

SetResult() public méthode

Sets the result by index.
public SetResult ( int index, Operand operand ) : void
index int The index.
operand Operand The operand.
Résultat void

Split() public méthode

Splits the node list by moving the next instructions into the new block.
public Split ( BasicBlock newblock ) : void
newblock BasicBlock The newblock.
Résultat void

ToString() public méthode

Returns a System.String that represents this instance.
public ToString ( ) : string
Résultat string

UpdateBranchTarget() public méthode

public UpdateBranchTarget ( int index, BasicBlock block ) : void
index int
block BasicBlock
Résultat void