Esempio n. 1
0
 private CPUTracer EnsureTracer(Arm cpu)
 {
     CPUTracer tracer;
     var tracerName = FindTracerName(cpu);
     if(!EmulationManager.Instance.CurrentEmulation.TryGetFromBag(tracerName, out tracer))
     {
         cpu.CreateCPUTracer(tracerName);
     }
     if(!EmulationManager.Instance.CurrentEmulation.TryGetFromBag(tracerName, out tracer))
     {
         throw new RecoverableException("Could not initialize CPUTracer.");
     }
     return tracer;
 }
Esempio n. 2
0
 public CPUTracer(Arm cpu)
 {
     this.cpu = cpu;
     this.bus = cpu.Bus;
 }
Esempio n. 3
0
 private string FindTracerName(Arm cpu)
 {
     string cpuName;
     if(!cpu.Bus.Machine.TryGetAnyName(cpu, out cpuName))
     {
         throw new Exception("This should never have happened!");
     }
     return "{0}.{1}-{2}".FormatWith(EmulationManager.Instance.CurrentEmulation[cpu.Bus.Machine], cpuName, TracerName);
 }