Skip to content

Commit efa9016

Browse files
committed
Add a CI job for parallel rustc using x.py check
1 parent a7170b0 commit efa9016

File tree

4 files changed

+12
-0
lines changed

4 files changed

+12
-0
lines changed

config.toml.example

+3
Original file line numberDiff line numberDiff line change
@@ -268,6 +268,9 @@
268268
# Whether or not `panic!`s generate backtraces (RUST_BACKTRACE)
269269
#backtrace = true
270270

271+
# Build rustc with experimental parallelization
272+
#experimental-parallel-queries = false
273+
271274
# The default linker that will be hard-coded into the generated compiler for
272275
# targets that don't specify linker explicitly in their target specifications.
273276
# Note that this is not the linker used to link said compiler.

src/bootstrap/configure.py

+1
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ def v(*args):
4444
o("docs", "build.docs", "build standard library documentation")
4545
o("compiler-docs", "build.compiler-docs", "build compiler documentation")
4646
o("optimize-tests", "rust.optimize-tests", "build tests with optimizations")
47+
o("experimental-parallel-queries", "rust.experimental-parallel-queries", "build rustc with experimental parallelization")
4748
o("test-miri", "rust.test-miri", "run miri's test suite")
4849
o("debuginfo-tests", "rust.debuginfo-tests", "build tests with debugger metadata")
4950
o("quiet-tests", "rust.quiet-tests", "enable quieter output when running tests")

src/ci/docker/x86_64-gnu-debug/Dockerfile

+1
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
1616
COPY scripts/sccache.sh /scripts/
1717
RUN sh /scripts/sccache.sh
1818

19+
ENV PARALLEL_CHECK 1
1920
ENV RUST_CONFIGURE_ARGS \
2021
--build=x86_64-unknown-linux-gnu \
2122
--enable-debug \

src/ci/run.sh

+7
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,13 @@ fi
7272
# sccache server at the start of the build, but no need to worry if this fails.
7373
SCCACHE_IDLE_TIMEOUT=10800 sccache --start-server || true
7474

75+
if [ "$PARALLEL_CHECK" != "" ]; then
76+
$SRC/configure --enable-experimental-parallel-queries
77+
python2.7 ../x.py check
78+
rm -f config.toml
79+
rm -rf build
80+
fi
81+
7582
travis_fold start configure
7683
travis_time_start
7784
$SRC/configure $RUST_CONFIGURE_ARGS

0 commit comments

Comments
 (0)