private DisassemblyLineViewModel GetLineByAddress(int address) { DisassemblyLineViewModel result; if (addressToLineMap.TryGetValue(address, out result)) { return(result); } return(null); }
internal ZPropertyTable GetPropertyTable(ushort address) { ZPropertyTable propertyTable; if (!propertyTables.TryGetValue(address, out propertyTable)) { propertyTable = new ZPropertyTable(this, address); propertyTables.Add(address, propertyTable); } return(propertyTable); }
internal ZCompilerResult Compile(ZRoutine routine) { ZCompilerResult result; if (!compilationResults.TryGetValue(routine.Address, out result)) { result = ZCompiler.Compile(routine, machine: this); compilationResults.Add(routine.Address, result); if (profiler != null) { profiler.RoutineCompiled(result.Statistics); } } return(result); }
internal ZRoutineCall GetRoutineCall(int address) { ZRoutineCall routineCall; if (!addressToRoutineCallMap.TryGetValue(address, out routineCall)) { cacheMiss++; var routine = GetRoutineByAddress(address); routineCall = new ZRoutineCall(routine, machine: this); addressToRoutineCallMap.Add(address, routineCall); } if (this.precompile && !compiling) { compiling = true; routineCall.Compile(); compiling = false; } return(routineCall); }
internal bool TryGet(int address, out Instruction instruction) { return(map.TryGetValue(address, out instruction)); }
public bool TryGetByAddress(int address, out ZRoutine routine) { return(routines.TryGetValue(address, out routine)); }