-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathMakefileTests.mk
More file actions
189 lines (138 loc) · 6.56 KB
/
MakefileTests.mk
File metadata and controls
189 lines (138 loc) · 6.56 KB
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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
test_cpu_alu:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/cpu_alu.vvp -s cpu_alu_tb test/cpu_alu_tb.sv
vvp -N graph/cpu_alu.vvp
mv ./cpu_alu_tb.vcd ./graph/cpu_alu_32.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/cpu_alu.vvp -s cpu_alu_tb test/cpu_alu_tb.sv
vvp -N graph/cpu_alu.vvp
mv ./cpu_alu_tb.vcd ./graph/cpu_alu_64.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/cpu_alu.vvp
test_cpu_mdu:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/cpu_mdu.vvp -s cpu_mdu_tb test/cpu_mdu_tb.sv
vvp -N graph/cpu_mdu.vvp
mv ./cpu_mdu_tb.vcd ./graph/cpu_mdu_32.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/cpu_mdu.vvp -s cpu_mdu_tb test/cpu_mdu_tb.sv
vvp -N graph/cpu_mdu.vvp
mv ./cpu_mdu_tb.vcd ./graph/cpu_mdu_64.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/cpu_mdu.vvp
test_cpu_bmu:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/cpu_bmu.vvp -s cpu_bmu_tb test/cpu_bmu_tb.sv
vvp -N graph/cpu_bmu.vvp
mv ./cpu_bmu_tb.vcd ./graph/cpu_bmu_32.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/cpu_bmu.vvp -s cpu_bmu_tb test/cpu_bmu_tb.sv
vvp -N graph/cpu_bmu.vvp
mv ./cpu_bmu_tb.vcd ./graph/cpu_bmu_64.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/cpu_bmu.vvp
test_cpu_csr:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/cpu_csr.vvp -s cpu_csr_tb test/cpu_csr_tb.sv
vvp -N graph/cpu_csr.vvp
mv ./cpu_csr_tb.vcd ./graph/cpu_csr_32.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/cpu_csr.vvp -s cpu_csr_tb test/cpu_csr_tb.sv
vvp -N graph/cpu_csr.vvp
mv ./cpu_csr_tb.vcd ./graph/cpu_csr_64.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/cpu_csr.vvp
test_cpu_regfile:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/cpu_regfile.vvp -s cpu_regfile_tb test/cpu_regfile_tb.sv
vvp -N graph/cpu_regfile.vvp
mv ./cpu_regfile_tb.vcd ./graph/cpu_regfile_32.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/cpu_regfile.vvp -s cpu_regfile_tb test/cpu_regfile_tb.sv
vvp -N graph/cpu_regfile.vvp
mv ./cpu_regfile_tb.vcd ./graph/cpu_regfile_64.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/cpu_regfile.vvp
test_cpu_insdecode:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/cpu_insdecode.vvp -s cpu_insdecode_tb test/cpu_insdecode_tb.sv
vvp -N graph/cpu_insdecode.vvp
mv ./cpu_insdecode_tb.vcd ./graph/cpu_insdecode_32.vcd
# Second Run: With SUPPORT_ZICSR defined
iverilog -g2012 -I src/ -DSUPPORT_ZICSR -o graph/cpu_insdecode_csr.vvp -s cpu_insdecode_tb test/cpu_insdecode_tb.sv
vvp -N graph/cpu_insdecode_csr.vvp
mv ./cpu_insdecode_tb.vcd ./graph/cpu_insdecode_32_csr.vcd
# Fourth Run: With SUPPORT_M defined
iverilog -g2012 -I src/ -DSUPPORT_M -o graph/cpu_insdecode_m.vvp -s cpu_insdecode_tb test/cpu_insdecode_tb.sv
vvp -N graph/cpu_insdecode_m.vvp
mv ./cpu_insdecode_tb.vcd ./graph/cpu_insdecode_32_m.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/cpu_insdecode.vvp -s cpu_insdecode_tb test/cpu_insdecode_tb.sv
vvp -N graph/cpu_insdecode.vvp
mv ./cpu_insdecode_tb.vcd ./graph/cpu_insdecode_64.vcd
# Second Run: With SUPPORT_ZICSR defined
iverilog -g2012 -I src/ -DXLEN=64 -DSUPPORT_ZICSR -o graph/cpu_insdecode_csr.vvp -s cpu_insdecode_tb test/cpu_insdecode_tb.sv
vvp -N graph/cpu_insdecode_csr.vvp
mv ./cpu_insdecode_tb.vcd ./graph/cpu_insdecode_64_csr.vcd
# Fourth Run: With SUPPORT_M defined
iverilog -g2012 -I src/ -DXLEN=64 -DSUPPORT_M -o graph/cpu_insdecode_m.vvp -s cpu_insdecode_tb test/cpu_insdecode_tb.sv
vvp -N graph/cpu_insdecode_m.vvp
mv ./cpu_insdecode_tb.vcd ./graph/cpu_insdecode_64_m.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/cpu_insdecode_tb.vvp graph/cpu_insdecode_m.vvp graph/cpu_insdecode_csr.vvp graph/cpu_insdecode_fence.vvp
test_tl_cpu:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/tl_cpu.vvp -s tl_cpu_tb test/tl_cpu_tb.sv
vvp -N graph/tl_cpu.vvp
mv ./tl_cpu_tb.vcd ./graph/tl_cpu_32.vcd
iverilog -g2012 -I src/ -DSUPPORT_M -o graph/tl_cpu.vvp -s tl_cpu_tb test/tl_cpu_tb.sv
vvp -N graph/tl_cpu.vvp
mv ./tl_cpu_tb.vcd ./graph/tl_cpu_32_m.vcd
iverilog -g2012 -I src/ -DSUPPORT_B -o graph/tl_cpu.vvp -s tl_cpu_tb test/tl_cpu_tb.sv
vvp -N graph/tl_cpu.vvp
mv ./tl_cpu_tb.vcd ./graph/tl_cpu_32_b.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/tl_cpu.vvp -s tl_cpu_tb test/tl_cpu_tb.sv
vvp -N graph/tl_cpu.vvp
mv ./tl_cpu_tb.vcd ./graph/tl_cpu_64.vcd
iverilog -g2012 -I src/ -DXLEN=64 -DSUPPORT_M -o graph/tl_cpu.vvp -s tl_cpu_tb test/tl_cpu_tb.sv
vvp -N graph/tl_cpu.vvp
mv ./tl_cpu_tb.vcd ./graph/tl_cpu_64_m.vcd
iverilog -g2012 -I src/ -DXLEN=64 -DSUPPORT_B -o graph/tl_cpu.vvp -s tl_cpu_tb test/tl_cpu_tb.sv
vvp -N graph/tl_cpu.vvp
mv ./tl_cpu_tb.vcd ./graph/tl_cpu_64_b.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/tl_cpu.vvp
test_tl_interface:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/tl_interface_32.vvp -s tl_interface_tb test/tl_interface_tb.sv
vvp -N graph/tl_interface_32.vvp
mv ./tl_interface_tb.vcd ./graph/tl_interface_32.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/tl_interface_64.vvp -s tl_interface_tb test/tl_interface_tb.sv
vvp -N graph/tl_interface_64.vvp
mv ./tl_interface_tb.vcd ./graph/tl_interface_64.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/tl_interface_32.vvp graph/tl_interface_64.vvp
test_tl_memory:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/tl_memory_32.vvp -s tl_memory_tb test/tl_memory_tb.sv
vvp -N graph/tl_memory_32.vvp
mv ./tl_memory_tb.vcd ./graph/tl_memory_32.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/tl_memory_64.vvp -s tl_memory_tb test/tl_memory_tb.sv
vvp -N graph/tl_memory_64.vvp
mv ./tl_memory_tb.vcd ./graph/tl_memory_64.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/tl_memory_32.vvp graph/tl_memory_64.vvp
test_tl_ul_uart:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/tl_ul_uart_32.vvp -s tl_ul_uart_tb test/tl_ul_uart_tb.sv
vvp -N graph/tl_ul_uart_32.vvp
mv ./tl_ul_uart_tb.vcd ./graph/tl_ul_uart_32.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/tl_ul_uart_64.vvp -s tl_ul_uart_tb test/tl_ul_uart_tb.sv
vvp -N graph/tl_ul_uart_64.vvp
mv ./tl_ul_uart_tb.vcd ./graph/tl_ul_uart_64.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/tl_ul_uart_32.vvp graph/tl_ul_uart_64.vvp
test_tl_switch:
mkdir -p ./graph
iverilog -g2012 -I src/ -o graph/tl_switch.vvp -s tl_switch_tb test/tl_switch_tb.sv
vvp -N graph/tl_switch.vvp
mv ./tl_switch_tb.vcd ./graph/tl_switch_32.vcd
iverilog -g2012 -I src/ -DXLEN=64 -o graph/tl_switch.vvp -s tl_switch_tb test/tl_switch_tb.sv
vvp -N graph/tl_switch.vvp
mv ./tl_switch_tb.vcd ./graph/tl_switch_63.vcd
# Clean Up: Remove intermediate .vvp files
rm -f graph/tl_switch.vvp