/// <summary> /// Copy Constructor. /// </summary> /// <param name="st">The PIC18 state to copy.</param> public PICProcessorState(PICProcessorState st) : base(st) { arch = st.arch; HWStackItems = st.HWStackItems; ValidRegsValues = new Dictionary <PICRegisterStorage, PICRegisterContent>(st.ValidRegsValues); ValidRegs = new HashSet <RegisterStorage>(st.ValidRegs); }
protected Identifier Bsr; // cached BSR register identifier protected PICRewriter(PICArchitecture arch, PICDisassemblerBase disasm, PICProcessorState state, IStorageBinder binder, IRewriterHost host) { this.arch = arch; this.state = state; this.binder = binder; this.host = host; this.disasm = disasm; dasm = disasm.GetEnumerator(); Wreg = GetWReg; Bsr = GetBsr; }
/// <summary> /// Creates the instructions IL rewriter for the target processor. /// </summary> /// <param name="arch">The architecture of the processor.</param> /// <param name="dasm">The disassembler.</param> /// <param name="state">The processor state.</param> /// <param name="binder">The storage binder.</param> /// <param name="host">The host.</param> /// <returns> /// The new rewriter. /// </returns> public abstract PICRewriter CreateRewriter(PICArchitecture arch, PICDisassemblerBase dasm, PICProcessorState state, IStorageBinder binder, IRewriterHost host);