本文整理汇总了C#中IProcessorArchitecture.CreateProcessorState方法的典型用法代码示例。如果您正苦于以下问题:C# IProcessorArchitecture.CreateProcessorState方法的具体用法?C# IProcessorArchitecture.CreateProcessorState怎么用?C# IProcessorArchitecture.CreateProcessorState使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IProcessorArchitecture
的用法示例。
在下文中一共展示了IProcessorArchitecture.CreateProcessorState方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Setup
public void Setup()
{
arch = new IntelArchitecture(ProcessorMode.Protected32);
m = new ProcedureBuilder();
state = arch.CreateProcessorState();
expSimp = new ExpressionSimplifier(
new IntelArchitecture(ProcessorMode.Protected32).CreateProcessorState());
SCZO = m.Frame.EnsureFlagGroup((uint)(FlagM.SF | FlagM.CF | FlagM.ZF | FlagM.OF), "SCZO", PrimitiveType.Byte);
host = new BackwalkerHost();
}
示例2: Setup
public void Setup()
{
arch = new FakeArchitecture();
m = new ProcedureBuilder();
state = arch.CreateProcessorState();
expSimp = new ExpressionSimplifier(arch.CreateProcessorState());
host = new BackwalkerHost(arch);
}
示例3: Setup
public void Setup()
{
arch = new X86ArchitectureFlat32();
m = new ProcedureBuilder();
state = arch.CreateProcessorState();
expSimp = new ExpressionSimplifier(arch.CreateProcessorState());
SCZO = m.Frame.EnsureFlagGroup(Registers.eflags, (uint)(FlagM.SF | FlagM.CF | FlagM.ZF | FlagM.OF), "SCZO", PrimitiveType.Byte);
host = new BackwalkerHost(arch);
}
示例4: CreateInitialState
private ProcessorState CreateInitialState(IProcessorArchitecture arch, Dictionary<string, object> args)
{
var state = arch.CreateProcessorState();
if (!args.ContainsKey("--reg"))
return state;
var regs = (List<string>)args["--reg"];
foreach (var regValue in regs.Where(r => !string.IsNullOrEmpty(r)))
{
var rr = regValue.Split(':');
if (rr == null || rr.Length != 2)
continue;
var reg = arch.GetRegister(rr[0]);
state.SetRegister(reg, Constant.Create(reg.DataType, Convert.ToInt64(rr[1], 16)));
}
return state;
}