aboutsummaryrefslogtreecommitdiffstats
path: root/tests/various/dynamic_part_select/nonblocking_gate.v
diff options
context:
space:
mode:
authordiego <diego@symbioticeda.com>2020-04-20 12:45:35 -0500
committerdiego <diego@symbioticeda.com>2020-04-20 12:45:35 -0500
commit22f440506b2b58edc27354d9ac8d474bb6185e63 (patch)
tree2b8b0b389f4935ae4741bf96ac33f46d9d7e1c1b /tests/various/dynamic_part_select/nonblocking_gate.v
parent50581d5a94730b33e2ca1b7f7371f502ef9263c6 (diff)
downloadyosys-22f440506b2b58edc27354d9ac8d474bb6185e63.tar.gz
yosys-22f440506b2b58edc27354d9ac8d474bb6185e63.tar.bz2
yosys-22f440506b2b58edc27354d9ac8d474bb6185e63.zip
Modifications of tests as per Eddie's request
Diffstat (limited to 'tests/various/dynamic_part_select/nonblocking_gate.v')
-rw-r--r--tests/various/dynamic_part_select/nonblocking_gate.v77
1 files changed, 77 insertions, 0 deletions
diff --git a/tests/various/dynamic_part_select/nonblocking_gate.v b/tests/various/dynamic_part_select/nonblocking_gate.v
new file mode 100644
index 000000000..ed1ee2776
--- /dev/null
+++ b/tests/various/dynamic_part_select/nonblocking_gate.v
@@ -0,0 +1,77 @@
+module nonblocking_gate (clk, ctrl, din, sel, dout);
+ input clk;
+ input [4:0] ctrl;
+ input [1:0] din;
+ input [0:0] sel;
+ output reg [31:0] dout;
+ always @(posedge clk)
+ begin
+ dout <= (dout)+(1);
+ case (({(ctrl)*(sel)})+(0))
+ 0:
+ dout[31:0] <= din;
+ 1:
+ dout[31:1] <= din;
+ 2:
+ dout[31:2] <= din;
+ 3:
+ dout[31:3] <= din;
+ 4:
+ dout[31:4] <= din;
+ 5:
+ dout[31:5] <= din;
+ 6:
+ dout[31:6] <= din;
+ 7:
+ dout[31:7] <= din;
+ 8:
+ dout[31:8] <= din;
+ 9:
+ dout[31:9] <= din;
+ 10:
+ dout[31:10] <= din;
+ 11:
+ dout[31:11] <= din;
+ 12:
+ dout[31:12] <= din;
+ 13:
+ dout[31:13] <= din;
+ 14:
+ dout[31:14] <= din;
+ 15:
+ dout[31:15] <= din;
+ 16:
+ dout[31:16] <= din;
+ 17:
+ dout[31:17] <= din;
+ 18:
+ dout[31:18] <= din;
+ 19:
+ dout[31:19] <= din;
+ 20:
+ dout[31:20] <= din;
+ 21:
+ dout[31:21] <= din;
+ 22:
+ dout[31:22] <= din;
+ 23:
+ dout[31:23] <= din;
+ 24:
+ dout[31:24] <= din;
+ 25:
+ dout[31:25] <= din;
+ 26:
+ dout[31:26] <= din;
+ 27:
+ dout[31:27] <= din;
+ 28:
+ dout[31:28] <= din;
+ 29:
+ dout[31:29] <= din;
+ 30:
+ dout[31:30] <= din;
+ 31:
+ dout[31:31] <= din;
+ endcase
+ end
+endmodule