summaryrefslogtreecommitdiff
path: root/verilog/S3.v
diff options
context:
space:
mode:
Diffstat (limited to 'verilog/S3.v')
-rwxr-xr-xverilog/S3.v53
1 files changed, 53 insertions, 0 deletions
diff --git a/verilog/S3.v b/verilog/S3.v
new file mode 100755
index 0000000..2fa74ef
--- /dev/null
+++ b/verilog/S3.v
@@ -0,0 +1,53 @@
+`timescale 1ns / 1ps
+//////////////////////////////////////////////////////////////////////////////////
+// Company:
+// Engineer:
+//
+// Create Date: 02:50:52 10/22/2012
+// Design Name:
+// Module Name: Stage3
+// Project Name:
+// Target Devices:
+// Tool versions:
+// Description:
+//
+// Dependencies:
+//
+// Revision:
+// Revision 0.01 - File Created
+// Additional Comments:
+//
+//////////////////////////////////////////////////////////////////////////////////
+module Stage3(
+ alu_in,
+ wsel_in,
+ alu_out,
+ wsel_out,
+ clk,
+ reset
+ );
+parameter BITS=32;
+parameter RSELW=5;
+input clk, reset;
+input [BITS-1:0] alu_in;
+input [RSELW-1:0] wsel_in;
+
+output [BITS-1:0] alu_out;
+output [RSELW-1:0] wsel_out;
+
+nbit_reg #(BITS) rreg(
+ .nD(alu_in),
+ .nQ(alu_out),
+ .Write(1'b1),
+ .Clk(clk),
+ .Reset(reset)
+);
+
+nbit_reg #(RSELW) wreg(
+ .nD(wsel_in),
+ .nQ(wsel_out),
+ .Write(1'b1),
+ .Clk(clk),
+ .Reset(reset)
+);
+endmodule