Пример #1
0
 //        public static Dictionary<InstructionMnemonic, Action<CpuReg, CpuReg, CpuReg, int>> InstructionsR {
 //            get {
 //                return instructionsR;
 //            }
 //        }
 //
 //        public static Dictionary<InstructionMnemonic, Action<CpuReg, CpuReg, int>> InstructionsI {
 //            get {
 //                return instructionsI;
 //            }
 //        }
 //
 //        public static Dictionary<InstructionMnemonic, Action< int>> InstructionsJ {
 //            get {
 //                return instructionsJ;
 //            }
 //        }
 public static void Exec(InstructionR i)
 {
     instructionsR [i.Instruction] (i.Rd, i.Rs, i.Rt, i.Shamt);
 }
Пример #2
0
        //        public static Dictionary<InstructionMnemonic, Action<CpuReg, CpuReg, CpuReg, int>> InstructionsR {
        //            get {
        //                return instructionsR;
        //            }
        //        }
        //
        //		public static Dictionary<InstructionMnemonic, Action<CpuReg, CpuReg, int>> InstructionsI {
        //            get {
        //                return instructionsI;
        //            }
        //        }
        //
        //		public static Dictionary<InstructionMnemonic, Action< int>> InstructionsJ {
        //            get {
        //                return instructionsJ;
        //            }
        //        }

        public static void Exec(InstructionR i)
        {
            instructionsR [i.Instruction] (i.Rd, i.Rs, i.Rt, i.Shamt);
        }