-
Notifications
You must be signed in to change notification settings - Fork 2
/
Dependency_Check_Block_tb.v
executable file
·90 lines (75 loc) · 1.71 KB
/
Dependency_Check_Block_tb.v
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
`timescale 1ns / 1ps
////////////////////////////////////////////////////////////////////////////////
// Company:
// Engineer:
//
// Create Date: 19:17:26 09/23/2017
// Design Name: Dependency_Check_Block
// Module Name: C:/Users/Admin/Desktop/lab5/Lab1/Dependency_Check_Block_tb.v
// Project Name: Lab1
// Target Device:
// Tool versions:
// Description:
//
// Verilog Test Fixture created by ISE for module: Dependency_Check_Block
//
// Dependencies:
//
// Revision:
// Revision 0.01 - File Created
// Additional Comments:
//
////////////////////////////////////////////////////////////////////////////////
module Dependency_Check_Block_tb;
// Inputs
reg [23:0] ins;
reg clk;
reg reset;
// Outputs
wire [7:0] imm;
wire [4:0] RW_dm;
wire [4:0] op_dec;
wire [1:0] mux_sel_A;
wire [1:0] mux_sel_B;
wire imm_sel;
wire mem_en_ex;
wire mem_rw_ex;
wire mem_mux_sel_dm;
// Instantiate the Unit Under Test (UUT)
Dependency_Check_Block uut (
.imm(imm),
.RW_dm(RW_dm),
.op_dec(op_dec),
.mux_sel_A(mux_sel_A),
.mux_sel_B(mux_sel_B),
.imm_sel(imm_sel),
.mem_en_ex(mem_en_ex),
.mem_rw_ex(mem_rw_ex),
.mem_mux_sel_dm(mem_mux_sel_dm),
.ins(ins),
.clk(clk),
.reset(reset)
);
initial begin
reset = 1;
ins = 24'b00000_00001_00010_00011_0000;
clk = 0;
// Initialize Inputs
#200;
reset = 0;
#800;
reset = 1;
#1250;
ins = 24'b10100_00100_00001_00000_0000;
#1000;
ins = 24'b10100_00100_00001_00000_0000;
#1000;
ins = 24'b00100_00101_00001_00100_0000;
#1000;
ins = 24'b01101_00110_00001_00000101_0;
end
always
begin
#500 clk = ~clk;
end
endmodule