File tree 2 files changed +19
-7
lines changed
2 files changed +19
-7
lines changed Original file line number Diff line number Diff line change @@ -638,6 +638,7 @@ define_config! {
638
638
dist_stage: Option <u32 > = "dist-stage" ,
639
639
bench_stage: Option <u32 > = "bench-stage" ,
640
640
patch_binaries_for_nix: Option <bool > = "patch-binaries-for-nix" ,
641
+ // NOTE: only parsed by bootstrap.py, `--feature build-metrics` enables metrics unconditionally
641
642
metrics: Option <bool > = "metrics" ,
642
643
}
643
644
}
Original file line number Diff line number Diff line change 56
56
if ! isCI || isCiBranch auto || isCiBranch beta || isCiBranch try || isCiBranch try-perf; then
57
57
RUST_CONFIGURE_ARGS=" $RUST_CONFIGURE_ARGS --set build.print-step-timings --enable-verbose-tests"
58
58
RUST_CONFIGURE_ARGS=" $RUST_CONFIGURE_ARGS --set build.metrics"
59
+ HAS_METRICS=1
59
60
fi
60
61
61
62
RUST_CONFIGURE_ARGS=" $RUST_CONFIGURE_ARGS --enable-sccache"
@@ -157,13 +158,6 @@ trap datecheck EXIT
157
158
# sccache server at the start of the build, but no need to worry if this fails.
158
159
SCCACHE_IDLE_TIMEOUT=10800 sccache --start-server || true
159
160
160
- if [ " $RUN_CHECK_WITH_PARALLEL_QUERIES " != " " ]; then
161
- $SRC /configure --set rust.parallel-compiler
162
- CARGO_INCREMENTAL=0 $PYTHON ../x.py check
163
- rm -f config.toml
164
- rm -rf build
165
- fi
166
-
167
161
$SRC /configure $RUST_CONFIGURE_ARGS
168
162
169
163
retry make prepare
@@ -193,4 +187,21 @@ else
193
187
do_make " $RUST_CHECK_TARGET "
194
188
fi
195
189
190
+ if [ " $RUN_CHECK_WITH_PARALLEL_QUERIES " != " " ]; then
191
+ rm -f config.toml
192
+ $SRC /configure --set rust.parallel-compiler
193
+
194
+ # Save the build metrics before we wipe the directory
195
+ if [ $HAS_METRICS = 1 ]; then
196
+ mv build/metrics.json .
197
+ fi
198
+ rm -rf build
199
+ if [ $HAS_METRICS = 1 ]; then
200
+ mkdir build
201
+ mv metrics.json build
202
+ fi
203
+
204
+ CARGO_INCREMENTAL=0 $PYTHON ../x.py check
205
+ fi
206
+
196
207
sccache --show-stats || true
You can’t perform that action at this time.
0 commit comments