Skip to content

Commit 96e4833

Browse files
committed
Add new CI job that runs tests with a toolchain built with multiple threads
1 parent ac062fd commit 96e4833

File tree

2 files changed

+41
-0
lines changed
  • src/ci

2 files changed

+41
-0
lines changed
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
FROM ubuntu:22.04
2+
3+
ARG DEBIAN_FRONTEND=noninteractive
4+
RUN apt-get update && apt-get install -y --no-install-recommends \
5+
g++ \
6+
make \
7+
ninja-build \
8+
file \
9+
curl \
10+
ca-certificates \
11+
python3 \
12+
git \
13+
cmake \
14+
sudo \
15+
gdb \
16+
libssl-dev \
17+
pkg-config \
18+
xz-utils \
19+
mingw-w64 \
20+
zlib1g-dev \
21+
libzstd-dev \
22+
&& rm -rf /var/lib/apt/lists/*
23+
24+
COPY scripts/sccache.sh /scripts/
25+
RUN sh /scripts/sccache.sh
26+
27+
ENV RUST_CONFIGURE_ARGS \
28+
--build=x86_64-unknown-linux-gnu \
29+
--enable-sanitizers \
30+
--enable-profiler \
31+
--enable-compiler-docs \
32+
--set llvm.libzstd=true
33+
34+
# Build the toolchain with multiple parallel frontend threads and then run tests
35+
# Tests are still compiled serially at the moment (intended to be changed in follow-ups).
36+
ENV SCRIPT python3 ../x.py --stage 2 test --set rust.parallel-frontend-threads=4

src/ci/github-actions/jobs.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,11 @@ auto:
348348
- name: x86_64-gnu
349349
<<: *job-linux-4c
350350

351+
- name: optional-x86_64-gnu-parallel-frontend
352+
# This test can be flaky, so do not cancel CI if it fails, for now.
353+
continue_on_error: true
354+
<<: *job-linux-4c
355+
351356
- name: x86_64-gnu-gcc
352357
doc_url: https://rustc-dev-guide.rust-lang.org/tests/codegen-backend-tests/cg_gcc.html
353358
<<: *job-linux-4c

0 commit comments

Comments
 (0)