Skip to content

Commit 103a8d5

Browse files
brandonrosclaude
authored andcommitted
ci: split docs job to skip llvm19-feature crates with --all-features
`--all-features` on the docs job activates `cuda_builder/llvm19`, which now propagates `rustc_codegen_nvvm/llvm19` (added in ebfe81b for feature-graph consistency). That forces the dep build of `rustc_codegen_nvvm` onto the LLVM 19 path, which fails in CI because no LLVM 19 toolchain is installed. Run docs in two passes: `--all-features` over the workspace minus the three crates that gate behind `llvm19`, then default-features over those three. This restores green CI on the LLVM 7 path the existing images support. Known gap: `cfg(feature = "llvm19")` code paths inside those three crates aren't rustdoc-checked. Closing that gap properly needs LLVM 19 in the CI images and is left as a follow-up. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 6a0bf22 commit 103a8d5

2 files changed

Lines changed: 17 additions & 6 deletions

File tree

.github/workflows/ci_linux.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -152,14 +152,19 @@ jobs:
152152
--exclude cust
153153
'
154154
155-
# Exclude rustc_codegen_nvvm: `--all-features` enables its `llvm19` feature,
156-
# whose build.rs requires an LLVM 19 toolchain not present in the CI image.
155+
# The `llvm19` feature on `nvvm` / `cuda_builder` / `rustc_codegen_nvvm` requires
156+
# an LLVM 19 toolchain that isn't in the CI image, so we can't run a single
157+
# `--all-features` pass over the whole workspace. Doc those three crates with
158+
# default features (the LLVM 7 path the CI image already supports) and the rest
159+
# of the workspace with `--all-features`.
157160
- name: Check documentation
158161
run: |
159162
docker exec "$CONTAINER_NAME" bash -lc 'set -euo pipefail
160163
export RUSTDOCFLAGS=-Dwarnings
161164
cargo doc --workspace --all-features --document-private-items --no-deps \
162-
--exclude rustc_codegen_nvvm
165+
--exclude rustc_codegen_nvvm --exclude cuda_builder --exclude nvvm
166+
cargo doc -p rustc_codegen_nvvm -p cuda_builder -p nvvm \
167+
--document-private-items --no-deps
163168
'
164169
165170
- name: Stop build container

.github/workflows/ci_windows.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -123,14 +123,20 @@ jobs:
123123
--exclude blastoff --exclude cudnn --exclude cudnn-sys --exclude cust
124124
125125
# Exclude crates that require cuDNN, not available on Windows CI: cudnn, cudnn-sys.
126-
# Exclude rustc_codegen_nvvm: `--all-features` enables its `llvm19` feature,
127-
# whose build.rs requires an LLVM 19 toolchain not present in the CI image.
126+
# The `llvm19` feature on `nvvm` / `cuda_builder` / `rustc_codegen_nvvm` requires
127+
# an LLVM 19 toolchain that isn't in the CI image, so we can't run a single
128+
# `--all-features` pass over the whole workspace. Doc those three crates with
129+
# default features (the LLVM 7 path the CI image already supports) and the rest
130+
# of the workspace with `--all-features`.
128131
- name: Check documentation
129132
env:
130133
RUSTDOCFLAGS: -Dwarnings
131134
run: |
132135
cargo doc --workspace --all-features --document-private-items --no-deps `
133-
--exclude cudnn --exclude cudnn-sys --exclude rustc_codegen_nvvm
136+
--exclude cudnn --exclude cudnn-sys `
137+
--exclude rustc_codegen_nvvm --exclude cuda_builder --exclude nvvm
138+
cargo doc -p rustc_codegen_nvvm -p cuda_builder -p nvvm `
139+
--document-private-items --no-deps
134140
135141
# Disabled due to dll issues, someone with Windows knowledge needed
136142
# - name: Compiletest

0 commit comments

Comments
 (0)