Esempio n. 1
0
        static void Main(string[] args)
        {
            using (var sim = new Simulation()) {
                var simulator = new SingleCycleRISCV_Simulator();

                // Instruction Fetch
                var AND  = new ANDGate();
                var Mux1 = new Mux1();
                var PC   = new PC();
                var Next = new Next();
                var IM   = new IM();
                // Instruction Decode and Register read
                var Reg     = new Register();
                var ImmGen  = new ImmGen();
                var Control = new Control();
                var WB      = new WriteBuffer();
                // Instruction Execute
                var Mux2 = new Mux2();
                var Mux3 = new Mux3();
                var ALU  = new ALU();
                var GoTo = new GoTo();
                // Memory access
                var DM = new DM();
                // Write back
                var Mux4 = new Mux4();

                sim
                .BuildCSVFile()
                .BuildGraph()
                .BuildVHDL()
                .Run();
            }
        }
Esempio n. 2
0
        static void Main(string[] args)
        {
            using (var sim = new Simulation()) {
                var simulator = new SingleCycleRISCV_Simulator();
                var PC        = new PC();
                var Incre     = new Incrementer();
                var incmux    = new Inc_mux();
                var IM        = new IM();
                var immgen    = new ImmGen();
                var Con       = new Control();
                var ALUCon    = new ALU_Control();
                var Reg       = new Register();
                var mALU      = new ALU();
                var mDM       = new DM();
                var regmux    = new Reg_mux();
                var memmux    = new Mem_mux();
                var WB        = new WriteBuffer();

                sim
                .BuildCSVFile()
                .BuildGraph()
                .BuildVHDL()
                .Run();
            }
        }