本文整理匯總了C#中Mosa.Compiler.Framework.Context.GetResult方法的典型用法代碼示例。如果您正苦於以下問題:C# Context.GetResult方法的具體用法?C# Context.GetResult怎麽用?C# Context.GetResult使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Mosa.Compiler.Framework.Context
的用法示例。
在下文中一共展示了Context.GetResult方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: foreach
/// <summary>
/// Performs stage specific processing on the compiler context.
/// </summary>
void IMethodCompilerStage.Run()
{
if (AreExceptions)
return;
foreach (var block in this.basicBlocks)
{
if (block.Label == Int32.MaxValue)
continue;
for (var context = new Context(this.instructionSet, block); !context.EndOfInstruction; context.GotoNext())
{
if (context.Instruction is PhiInstruction)
this.ProcessPhiInstruction(block, context);
for (var i = 0; i < context.OperandCount; ++i)
{
var op = context.GetOperand(i);
if (op is SsaOperand)
context.SetOperand(i, (op as SsaOperand).Operand);
}
for (var i = 0; i < context.ResultCount; ++i)
{
var op = context.GetResult(i);
if (op is SsaOperand)
context.SetResult(i, (op as SsaOperand).Operand);
}
}
}
}