C# Класс Mosa.Compiler.Framework.InstructionNode

Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
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

Приватные методы

Метод Описание
CheckAddition ( ) : void
Clear ( ) : void

Clears this instance.

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

Описание методов

AddBranchTarget() публичный Метод

Sets the branch target.
public AddBranchTarget ( BasicBlock block ) : void
block BasicBlock The basic block.
Результат void

AddOperand() публичный Метод

Adds the operand.
public AddOperand ( Operand operand ) : void
operand Operand The operand.
Результат void

Empty() публичный Метод

Empties this context.
public Empty ( ) : void
Результат void

GetAdditionalOperand() публичный Метод

Gets the additional operand.
public GetAdditionalOperand ( int index ) : Operand
index int The index.
Результат Operand

GetOperand() публичный Метод

Gets the operand by index.
public GetOperand ( int opIndex ) : Operand
opIndex int The index.
Результат Operand

GetResult() публичный Метод

Gets the result.
public GetResult ( int index ) : Operand
index int The index.
Результат Operand

GoBackwardsToNonEmpty() публичный Метод

Returns the 1st non empty node (including the current) by traversing the instructions backwards
public GoBackwardsToNonEmpty ( ) : InstructionNode
Результат InstructionNode

GoForwardToNonEmpty() публичный Метод

Returns the 1st non empty node (including the current) by traversing the instructions forward
public GoForwardToNonEmpty ( ) : InstructionNode
Результат InstructionNode

Insert() публичный Метод

public Insert ( InstructionNode node ) : void
node InstructionNode
Результат void

InstructionNode() публичный Метод

public InstructionNode ( ) : System
Результат System

InstructionNode() публичный Метод

Sets the instruction.
public InstructionNode ( BaseInstruction instruction ) : System
instruction BaseInstruction The instruction.
Результат System

InstructionNode() публичный Метод

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, BasicBlock block ) : System
instruction BaseInstruction The instruction.
block BasicBlock The block.
Результат System

InstructionNode() публичный Метод

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, BasicBlock block1, BasicBlock block2 ) : System
instruction BaseInstruction The instruction.
block1 BasicBlock The block1.
block2 BasicBlock The block2.
Результат System

InstructionNode() публичный Метод

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, ConditionCode condition ) : System
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
Результат System

InstructionNode() публичный Метод

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, ConditionCode condition, BasicBlock block ) : System
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
block BasicBlock The block.
Результат System

InstructionNode() публичный Метод

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, MosaMethod target ) : System
instruction BaseInstruction The instruction.
target MosaMethod The target.
Результат System

InstructionNode() публичный Метод

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, Operand result ) : System
instruction BaseInstruction The instruction.
result Operand The result.
Результат System

InstructionNode() публичный Метод

Sets the instruction.
public InstructionNode ( BaseInstruction instruction, Operand result, Operand operand1 ) : System
instruction BaseInstruction The instruction.
result Operand The result.
operand1 Operand The operand1.
Результат System

InstructionNode() публичный Метод

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.
Результат System

InstructionNode() публичный Метод

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.
Результат System

Replace() публичный Метод

Replaces the specified node with the given node, the existing node is invalid afterwards
public Replace ( InstructionNode node ) : void
node InstructionNode The node.
Результат void

ReplaceInstructionOnly() публичный Метод

Replaces the instruction only.
public ReplaceInstructionOnly ( BaseInstruction instruction ) : void
instruction BaseInstruction The instruction.
Результат void

SetAdditionalOperand() публичный Метод

Sets the additional operand.
public SetAdditionalOperand ( int index, Operand operand ) : void
index int The index.
operand Operand The operand.
Результат void

SetInstruction() публичный Метод

Sets the instruction.
public SetInstruction ( BaseInstruction instruction ) : void
instruction BaseInstruction The instruction.
Результат void

SetInstruction() публичный Метод

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, BasicBlock block ) : void
instruction BaseInstruction The instruction.
block BasicBlock The block.
Результат void

SetInstruction() публичный Метод

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, BasicBlock block1, BasicBlock block2 ) : void
instruction BaseInstruction The instruction.
block1 BasicBlock The block1.
block2 BasicBlock The block2.
Результат void

SetInstruction() публичный Метод

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
Результат void

SetInstruction() публичный Метод

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition, BasicBlock block ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
block BasicBlock The block.
Результат void

SetInstruction() публичный Метод

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, ConditionCode condition, Operand result ) : void
instruction BaseInstruction The instruction.
condition ConditionCode The condition.
result Operand The result.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, MosaMethod target ) : void
instruction BaseInstruction The instruction.
target MosaMethod The target.
Результат void

SetInstruction() публичный Метод

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, Operand result ) : void
instruction BaseInstruction The instruction.
result Operand The result.
Результат void

SetInstruction() публичный Метод

Sets the instruction.
public SetInstruction ( BaseInstruction instruction, Operand result, Operand operand1 ) : void
instruction BaseInstruction The instruction.
result Operand The result.
operand1 Operand The operand1.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction() публичный Метод

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.
Результат void

SetInstruction2() публичный Метод

Sets the instruction.
public SetInstruction2 ( BaseInstruction instruction, Operand result, Operand result2 ) : void
instruction BaseInstruction The instruction.
result Operand The result.
result2 Operand The result2.
Результат void

SetInstruction2() публичный Метод

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.
Результат void

SetInstruction2() публичный Метод

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.
Результат void

SetInstruction2() публичный Метод

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.
Результат void

SetOperand() публичный Метод

Sets the operand by index.
public SetOperand ( int index, Operand operand ) : void
index int The index.
operand Operand The operand.
Результат void

SetResult() публичный Метод

Sets the result by index.
public SetResult ( int index, Operand operand ) : void
index int The index.
operand Operand The operand.
Результат void

Split() публичный Метод

Splits the node list by moving the next instructions into the new block.
public Split ( BasicBlock newblock ) : void
newblock BasicBlock The newblock.
Результат void

ToString() публичный Метод

Returns a System.String that represents this instance.
public ToString ( ) : string
Результат string

UpdateBranchTarget() публичный Метод

public UpdateBranchTarget ( int index, BasicBlock block ) : void
index int
block BasicBlock
Результат void