Skip to content

Commit 6d355f6

Browse files
authored
Merge pull request rust-lang#1440 from rust-lang/ci_speedup_and_cleanup
Slightly reduce CI runtime and reduce log verbosity
2 parents 75f1c2b + c55aaa5 commit 6d355f6

File tree

3 files changed

+18
-18
lines changed

3 files changed

+18
-18
lines changed

.github/workflows/main.yml

+6-10
Original file line numberDiff line numberDiff line change
@@ -175,14 +175,10 @@ jobs:
175175
path: build/cg_clif
176176
key: ${{ runner.os }}-x86_64-unknown-linux-gnu-cargo-build-target-${{ hashFiles('rust-toolchain', '**/Cargo.lock') }}
177177

178-
- name: Cache cargo bin dir
179-
uses: actions/cache@v3
180-
with:
181-
path: ~/.cargo/bin
182-
key: ${{ runner.os }}-${{ matrix.env.TARGET_TRIPLE }}-cargo-bin-dir-${{ hashFiles('rust-toolchain', '**/Cargo.lock') }}
183-
184178
- name: Install hyperfine
185-
run: cargo install hyperfine || true
179+
run: |
180+
sudo apt update
181+
sudo apt install -y hyperfine
186182
187183
- name: Prepare dependencies
188184
run: ./y.sh prepare
@@ -257,14 +253,14 @@ jobs:
257253

258254
- name: Upload prebuilt cg_clif
259255
if: matrix.os == 'windows-latest' || matrix.env.TARGET_TRIPLE != 'x86_64-pc-windows-gnu'
260-
uses: actions/upload-artifact@v3
256+
uses: actions/upload-artifact@v4
261257
with:
262258
name: cg_clif-${{ matrix.env.TARGET_TRIPLE }}
263259
path: cg_clif.tar.xz
264260

265261
- name: Upload prebuilt cg_clif (cross compile)
266262
if: matrix.os != 'windows-latest' && matrix.env.TARGET_TRIPLE == 'x86_64-pc-windows-gnu'
267-
uses: actions/upload-artifact@v3
263+
uses: actions/upload-artifact@v4
268264
with:
269265
name: cg_clif-${{ runner.os }}-cross-x86_64-mingw
270266
path: cg_clif.tar.xz
@@ -283,7 +279,7 @@ jobs:
283279
- uses: actions/checkout@v3
284280

285281
- name: Download all built artifacts
286-
uses: actions/download-artifact@v3
282+
uses: actions/download-artifact@v4
287283
with:
288284
path: artifacts/
289285

.github/workflows/rustc.yml

+5
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,11 @@ jobs:
4343
path: build/cg_clif
4444
key: ${{ runner.os }}-cargo-build-target-${{ hashFiles('rust-toolchain', '**/Cargo.lock') }}
4545

46+
- name: Install ripgrep
47+
run: |
48+
sudo apt update
49+
sudo apt install -y ripgrep
50+
4651
- name: Prepare dependencies
4752
run: ./y.sh prepare
4853

scripts/setup_rust_fork.sh

+7-8
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/usr/bin/env bash
22
set -e
33

4-
# CG_CLIF_FORCE_GNU_AS will force usage of as instead of the LLVM backend of rustc as we
4+
# CG_CLIF_FORCE_GNU_AS will force usage of as instead of the LLVM backend of rustc as
55
# the LLVM backend isn't compiled in here.
66
export CG_CLIF_FORCE_GNU_AS=1
77

@@ -11,20 +11,19 @@ export CG_CLIF_FORCE_GNU_AS=1
1111
CG_CLIF_STDLIB_REMAP_PATH_PREFIX=/rustc/FAKE_PREFIX ./y.sh build
1212

1313
echo "[SETUP] Rust fork"
14-
git clone https://github.com/rust-lang/rust.git --filter=tree:0 || true
14+
git clone --quiet https://github.com/rust-lang/rust.git --filter=tree:0 || true
1515
pushd rust
1616
git fetch
17-
git checkout -- .
18-
git checkout "$(rustc -V | cut -d' ' -f3 | tr -d '(')"
17+
git checkout --no-progress -- .
18+
git checkout --no-progress "$(rustc -V | cut -d' ' -f3 | tr -d '(')"
19+
20+
git submodule update --quiet --init src/tools/cargo library/backtrace library/stdarch
1921

2022
git -c user.name=Dummy -c [email protected] -c commit.gpgSign=false \
2123
am ../patches/*-stdlib-*.patch
2224

2325
cat > config.toml <<EOF
24-
change-id = 115898
25-
26-
[llvm]
27-
ninja = false
26+
change-id = 999999
2827
2928
[build]
3029
rustc = "$(pwd)/../dist/bin/rustc-clif"

0 commit comments

Comments
 (0)