-
Notifications
You must be signed in to change notification settings - Fork 32
258 lines (249 loc) · 10.9 KB
/
gem5.yml
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
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
name: gem5 Test
on:
push:
branches: [ xs-dev ]
pull_request:
branches: [ xs-dev ]
jobs:
valgrind_memory_check:
runs-on: self-hosted
continue-on-error: false
name: XS-GEM5 - Check memory corruption
steps:
- uses: actions/checkout@v2
- name: Build DRAMSim
run: |
export GEM5_HOME=$(pwd)
cd ext/dramsim3
git clone [email protected]:umd-memsys/DRAMSim3.git DRAMsim3
cd DRAMsim3 && mkdir -p build
cd build
cmake ..
make -j 48
cd $GEM5_HOME
- name: Build GEM5 debug
run: CC=gcc CXX=g++ scons build/RISCV/gem5.debug --linker=gold -j64
- name: Memory check
run: |
export GEM5_HOME=$(pwd)
bash util/memory_check/run-xs-with-valgrind.sh
cd $GEM5_HOME
new_sim_script_test_gcb:
runs-on: self-hosted
continue-on-error: false
name: XS-GEM5 - Test new simulation script on RV64GCB
steps:
- uses: actions/checkout@v2
- name: Build DRAMSim
run: |
export GEM5_HOME=$(pwd)
cd ext/dramsim3
git clone [email protected]:umd-memsys/DRAMSim3.git DRAMsim3
cd DRAMsim3 && mkdir -p build
cd build
cmake ..
make -j 48
cd $GEM5_HOME
- name: Build GEM5 opt
run: CC=gcc CXX=g++ scons build/RISCV/gem5.opt --linker=gold -j64
- name: XS-GEM5 - Test xiangshan.py simulation scripts
run: |
export GCBV_REF_SO="/nfs-nvme/home/share/zhenhao/ref-h/build/riscv64-nemu-interpreter-so"
export GCB_RESTORER="/nfs/home/share/gem5_shared_tools/normal-gcb-restorer.bin"
export GEM5_HOME=$(pwd)
mkdir -p $GEM5_HOME/util/xs_scripts/test
cd $GEM5_HOME/util/xs_scripts/test
bash ../kmh_6wide.sh /nfs/home/share/jiaxiaoyu/simpoint_checkpoint_archive/spec06_rv64gcb_O3_20m_gcc12.2.0-intFpcOff-jeMalloc/zstd-checkpoint-0-0-0/xalancbmk/133/_133_0.006424_.zstd
new_sim_script_test_gcbv:
runs-on: self-hosted
continue-on-error: false
name: XS-GEM5 - Test new simulation script on RV64GCBV
steps:
- uses: actions/checkout@v2
- name: Build DRAMSim
run: |
export GEM5_HOME=$(pwd)
cd ext/dramsim3
git clone [email protected]:umd-memsys/DRAMSim3.git DRAMsim3
cd DRAMsim3 && mkdir -p build
cd build
cmake ..
make -j 48
cd $GEM5_HOME
- name: Build GEM5 opt
run: CC=gcc CXX=g++ scons build/RISCV/gem5.opt --linker=gold -j64
- name: XS-GEM5 - Test xiangshan.py simulation scripts
run: |
export GCBV_REF_SO="/nfs-nvme/home/share/zhenhao/ref-h/build/riscv64-nemu-interpreter-so"
export GCBV_RESTORER="/nfs/home/share/gem5_shared_tools/gcbv-restorer.bin"
export GEM5_HOME=$(pwd)
mkdir -p $GEM5_HOME/util/xs_scripts/test_v
cd $GEM5_HOME/util/xs_scripts/test_v
bash ../kmh_6wide_vector.sh /nfs/home/share/jiaxiaoyu/simpoint_checkpoint_archive/spec06_hmmer_libquantum_h264_rv64gcv_O3_20m_gcc14.0.0_1218-intFpcOff-ptMalloc/disdain-practical-toll-2023-12-25-11-26/zstd-checkpoint-0-0-0/hmmer_nph3/102/_102_0.0243576.zstd
new_sim_script_test_gcb_multi_core:
runs-on: self-hosted
continue-on-error: false
name: XS-GEM5 - Test Multi-core + RV64GCB
steps:
- uses: actions/checkout@v2
- name: Build GEM5 opt
run: |
source /nfs-nvme/home/share/zyy/shared_apps/setenv_AOCC.sh
CC=clang CXX=clang++ scons build/RISCV_CHI/gem5.opt -j 48 --gold-linker
- name: XS-GEM5 - Test xiangshan.py simulation scripts
run: |
export GCBV_MULTI_CORE_REF_SO="/nfs-nvme/home/share/zhenhao/ref-h/build-multi/riscv64-nemu-interpreter-so"
export GCB_MULTI_CORE_RESTORER="/nfs/home/share/gem5_shared_tools/gcb-2core-restorer.bin"
export GEM5_HOME=$(pwd)
mkdir -p $GEM5_HOME/util/xs_scripts/test_multi_core
cd $GEM5_HOME/util/xs_scripts/test_multi_core
bash ../kmh-ruby-dual.sh /nfs-nvme/home/share/zyy/shared_payloads/bzip_checkpoint_with_sv39_without_rdtime_with_dualmtimecpt_1000M.gz
difftest_check:
runs-on: self-hosted
continue-on-error: false
name: XS-GEM5 - Check difftest
steps:
- uses: actions/checkout@v2
- name: Build DRAMSim
run: |
export GEM5_HOME=$(pwd)
cd ext/dramsim3
git clone [email protected]:umd-memsys/DRAMSim3.git DRAMsim3
cd DRAMsim3 && mkdir -p build
cd build
cmake ..
make -j 48
cd $GEM5_HOME
- name: Build GEM5 debug
run: CC=clang CXX=clang++ scons build/RISCV/gem5.opt -j 48 --gold-linker
- name: difftest check
run: |
export GCBV_REF_SO="/nfs-nvme/home/share/zhenhao/ref-h/build-error/riscv64-nemu-interpreter-so"
export GCB_RESTORER="/nfs-nvme/home/share/zhenhao/LibCheckpointAlpha/build/gcpt.bin"
export GEM5_HOME=$(pwd)
mkdir -p $GEM5_HOME/util/xs_scripts/test
cd $GEM5_HOME/util/xs_scripts/test
bash ../kmh_6wide.sh /nfs/home/share/jiaxiaoyu/simpoint_checkpoint_archive/spec06_rv64gcb_O3_20m_gcc12.2.0-intFpcOff-jeMalloc/zstd-checkpoint-0-0-0/xalancbmk/133/_133_0.006424_.zstd 2>log.txt || exit_code=$?
if [ ${exit_code} -eq 0 ]; then echo "Difftest is broken, it should report error!" exit 1; fi
match=$(grep ".*Difftest failed!.*" log.txt -c)
if [ ${match} -eq 0 ]; then echo "Difftest is broken, it should report at least one agnostic related difference!" exit 1; fi
test_fix_l2tlb_bugs:
runs-on: self-hosted
continue-on-error: false
name: XS-GEM5 - Test fix L2TLB bugs
steps:
- uses: actions/checkout@v2
- name: Build DRAMSim
run: |
export GEM5_HOME=$(pwd)
cd ext/dramsim3
git clone [email protected]:umd-memsys/DRAMSim3.git DRAMsim3
cd DRAMsim3 && mkdir -p build
cd build
cmake ..
make -j 48
cd $GEM5_HOME
- name: Build GEM5 opt
run: CC=gcc CXX=g++ scons build/RISCV/gem5.opt --linker=gold -j64
- name: XS-GEM5 - Test xiangshan.py simulation scripts
run: |
export GCBV_REF_SO="/nfs-nvme/home/share/zhenhao/ref-h/build/riscv64-nemu-interpreter-so"
export GCB_RESTORER=""
export GEM5_HOME=$(pwd)
mkdir -p $GEM5_HOME/util/xs_scripts/test_l2tlb
cd $GEM5_HOME/util/xs_scripts/test_l2tlb
bash ../kmh_6wide.sh /nfs/home/share/yanyue/checkpoints/gcc13_gcb_403_61291.zstd
run_performance_test:
runs-on: self-hosted
continue-on-error: false
name: XS-GEM5 - Run performance test
steps:
- uses: actions/checkout@v2
- name: Build DRAMSim
run: |
export GEM5_HOME=$(pwd)
cd ext/dramsim3
git clone [email protected]:umd-memsys/DRAMSim3.git DRAMsim3
cd DRAMsim3 && mkdir -p build
cd build
cmake ..
make -j 48
cd $GEM5_HOME
- name: Build GEM5 opt
run: CC=gcc CXX=g++ scons build/RISCV/gem5.opt --linker=gold -j64
- name: XS-GEM5 - Run performance test
# run 50% coverage spec06 checkpoints, 275 checkpoints
run: |
export GCBV_REF_SO="/nfs-nvme/home/share/zhenhao/ref-h/build/riscv64-nemu-interpreter-so"
export GCB_RESTORER=""
export GEM5_HOME=$(pwd)
mkdir -p $GEM5_HOME/util/xs_scripts/test
cd $GEM5_HOME/util/xs_scripts/test
bash ../parallel_sim.sh `realpath ../kmh_6wide.sh` \
/nfs/home/yanyue/workspace/spec06_cpts/spec_0.5c.lst \
/nfs/home/share/jiaxiaoyu/simpoint_checkpoint_archive/spec06_rv64gcb_O3_20m_gcc12.2.0-intFpcOff-jeMalloc/zstd-checkpoint-0-0-0 \
spec_all
- name: Setup gem5_data_proc environment
run: |
# 克隆数据处理仓库到 CI 工作目录
cd $GITHUB_WORKSPACE
git clone https://github.com/shinezyy/gem5_data_proc
- name: Check performance test result
run: |
# 添加yanyue的 Python 包路径, 包含pandas等
export PYTHONPATH=/nfs/home/yanyue/.local/lib/python3.10/site-packages:$PYTHONPATH
cd $GITHUB_WORKSPACE/gem5_data_proc
# 使用已有的数据spec_all生成测试报告
bash example-scripts/gem5-score-ci.sh \
$GEM5_HOME/util/xs_scripts/test/spec_all \
/nfs/home/yanyue/workspace/spec06_cpts/spec_5coverage.json \
> $GITHUB_WORKSPACE/score.txt
# 提取最后42行score信息
echo "### performance test result :rocket:" >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
tail -n 42 $GITHUB_WORKSPACE/score.txt >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
# 提取关键指标
FINAL_SCORE=$(grep "Estimated Int score per GHz:" $GITHUB_WORKSPACE/score.txt | awk '{print $NF}')
echo "### Key indicators" >> $GITHUB_STEP_SUMMARY
echo "- Final Int score per GHz: **${FINAL_SCORE}**" >> $GITHUB_STEP_SUMMARY
test_performance_report:
runs-on: self-hosted
continue-on-error: false
name: XS-GEM5 - Test performance report generation
steps:
- uses: actions/checkout@v2
- name: Check Python environment0
run: |
echo "Current user:"
whoami
echo "Home directory:"
echo $HOME
echo "Python path:"
which python3
echo "Python user site:"
python3 -m site --user-site
echo "System Python path:"
python3 -c "import sys; print('\n'.join(sys.path))"
- name: Setup gem5_data_proc environment
run: |
# 克隆数据处理仓库到 CI 工作目录
cd $GITHUB_WORKSPACE
git clone https://github.com/shinezyy/gem5_data_proc
- name: Test performance report generation
run: |
# 添加yanyue的 Python 包路径, 包含pandas等
export PYTHONPATH=/nfs/home/yanyue/.local/lib/python3.10/site-packages:$PYTHONPATH
cd $GITHUB_WORKSPACE/gem5_data_proc
# 使用已有的数据测试报告生成
bash example-scripts/gem5-score-ci.sh \
/nfs/home/yanyue/workspace/GEM5/util/xs_scripts/test/spec_gcc15_gcb_zicond_new \
/nfs/home/yanyue/workspace/checkpoint_scripts/checkpoint_scripts/archive/spec06_gcc15_rv64gcb_zicond_O3_lto_base_nemu_single_core_NEMU_archgroup_2024-11-01-18-30/checkpoint-0-0-0/cluster-0-0.json \
> $GITHUB_WORKSPACE/score.txt
echo "### performance test result :rocket:" >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
tail -n 45 $GITHUB_WORKSPACE/score.txt >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
FINAL_SCORE=$(grep "Estimated Int score per GHz:" $GITHUB_WORKSPACE/score.txt | awk '{print $NF}')
echo "### Key indicators" >> $GITHUB_STEP_SUMMARY
echo "- Final Int score per GHz: **${FINAL_SCORE}**" >> $GITHUB_STEP_SUMMARY