]> Joshua Wise's Git repositories - fpgaboy.git/blobdiff - core/insn_rst.v
Move the core to core/
[fpgaboy.git] / core / insn_rst.v
diff --git a/core/insn_rst.v b/core/insn_rst.v
new file mode 100644 (file)
index 0000000..4b65032
--- /dev/null
@@ -0,0 +1,24 @@
+`ifdef EXECUTE
+       `INSN_RST: begin
+               case (cycle)
+               0:      `EXEC_INC_PC            // This goes FIRST in RST
+               1:      `EXEC_WRITE(`_SP - 1, `_PCH)
+               2:      `EXEC_WRITE(`_SP - 2, `_PCL)
+               3:      begin
+                               `EXEC_NEWCYCLE
+                               `_PC <= {10'b0,opcode[5:3],3'b0};
+                       end
+               endcase
+       end
+`endif
+
+`ifdef WRITEBACK
+       `INSN_RST: begin
+               case (cycle)
+               0:      begin /* type F */ end
+               1:      begin /* type F */ end
+               2:      begin /* type F */ end
+               3:      `_SP <= `_SP - 2;
+               endcase
+       end
+`endif
This page took 0.023686 seconds and 4 git commands to generate.