Skip to content

Commit 29607b6

Browse files
authored
Merge branch 'main' into linker-speedup
2 parents 6dbfe05 + 6e2c84d commit 29607b6

File tree

157 files changed

+3475
-2064
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

157 files changed

+3475
-2064
lines changed

.cargo/config.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ compiletest = "run --release -p compiletests --"
33

44
[target.'cfg(all())']
55
rustflags = [
6+
# FIXME(eddyb) update/review these lints.
7+
#
68
# BEGIN - Embark standard lints v6 for Rust 1.55+
79
# do not change or add/remove here, but one can add exceptions after this section
810
# for more info see: <https://github.com/EmbarkStudios/rust-ecosystem/issues/59>
@@ -47,7 +49,6 @@ rustflags = [
4749
"-Wclippy::match_wild_err_arm",
4850
"-Wclippy::match_wildcard_for_single_variants",
4951
"-Wclippy::mem_forget",
50-
"-Wclippy::mismatched_target_os",
5152
"-Wclippy::missing_enforced_import_renames",
5253
"-Wclippy::mut_mut",
5354
"-Wclippy::mutex_integer",

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
* @eddyb @LegNeato @fornwall
1+
* @eddyb @LegNeato @Firestar99 @schell

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,10 @@
11
---
22
name: Bug Report
33
about: Report a bug with using rust-gpu.
4-
title: '(my bug report)'
5-
labels: 't: bug'
4+
title: "(my bug report)"
5+
labels: bug
6+
assignees: ''
7+
68
---
79

810
<!-- Thank you for filing a bug report! 🐛 -->

.github/ISSUE_TEMPLATE/enhancement.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22
name: Enhancement
33
about: Propose a minor improvement or feature to the project.
44
title: "(My enhancement)"
5-
labels: "t: enhancement"
5+
labels: enhancement
6+
assignees: ''
7+
68
---
79

810
<!--
@@ -15,4 +17,3 @@ Existing Issues: https://github.com/rust-gpu/rust-gpu/issues?q=is%3Aopen+is%3Ais
1517
Closed Issues: https://github.com/rust-gpu/rust-gpu/labels/s%3A%20wontfix
1618
1719
-->
18-

.github/workflows/ci.yaml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -76,13 +76,18 @@ jobs:
7676
- name: build example shaders
7777
if: ${{ matrix.target != 'aarch64-linux-android' }}
7878
env:
79-
OUT_DIR: "target/tmp"
79+
PROFILE: release
80+
OUT_DIR: "target/release/ci/out"
8081
run: cargo run -p example-runner-wgpu-builder --release --no-default-features --features "use-installed-tools"
8182

82-
- name: build example shaders dev
83-
if: ${{ matrix.target != 'aarch64-linux-android' && matrix.target != 'x86_64-apple-darwin' }}
83+
- name: build example shaders (dev aka "debug mode")
84+
if: ${{ matrix.target != 'aarch64-linux-android' }}
8485
env:
85-
OUT_DIR: "target/tmp"
86+
# HACK(eddyb) see `[profile.dev]` in `Cargo.toml` for more on why
87+
# `-Zshare-generics=off` is useful (and why it had to be moved here).
88+
RUSTFLAGS: -Zshare-generics=off
89+
PROFILE: debug
90+
OUT_DIR: "target/debug/ci/out"
8691
run: cargo run -p example-runner-wgpu-builder --no-default-features --features "use-installed-tools"
8792

8893
- name: Build WGPU Example for Android
@@ -98,7 +103,7 @@ jobs:
98103
echo "::endgroup::"
99104
100105
echo "::group::Install cargo-apk"
101-
cargo install cargo-apk
106+
cargo +stable install cargo-apk
102107
echo "::endgroup::"
103108
104109
echo "::group::Add aarch64-linux-android target"
@@ -155,4 +160,4 @@ jobs:
155160
runs-on: ubuntu-22.04
156161
steps:
157162
- uses: actions/checkout@v4
158-
- uses: EmbarkStudios/cargo-deny-action@v1
163+
- uses: EmbarkStudios/cargo-deny-action@v2

.github/workflows/lint.sh

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,16 @@ clippy_no_features examples/shaders/simplest-shader
4949
# which could be disastrous because env vars access can't be tracked by
5050
# `rustc`, unlike its CLI flags (which are integrated with incremental).
5151
if (
52-
egrep -r '::\s*env|env\s*::' crates/rustc_codegen_spirv/src/ |
52+
egrep -r '::\s*env|env\s*::' crates/rustc_codegen_spirv/src |
5353
# HACK(eddyb) exclude the one place in `rustc_codegen_spirv`
5454
# needing access to an env var (only for codegen args `--help`).
55-
egrep -v '^crates/rustc_codegen_spirv/src/codegen_cx/mod.rs: let help_flag_comes_from_spirv_builder_env_var = std::env::var\(spirv_builder_env_var\)$'
55+
egrep -v '^crates/rustc_codegen_spirv/src/codegen_cx/mod.rs: let help_flag_comes_from_spirv_builder_env_var = std::env::var\(spirv_builder_env_var\)$' |
56+
# HACK(LegNeato) exclude logging. This mirrors `rustc` (`RUSTC_LOG`) and
57+
#`rustdoc` (`RUSTDOC_LOG`).
58+
# There is not a risk of this being disastrous as it does not change the build settings.
59+
egrep -v '^crates/rustc_codegen_spirv/src/lib.rs:.*(RUSTGPU_LOG|RUSTGPU_LOG_FORMAT|RUSTGPU_LOG_COLOR).*$' |
60+
egrep -v '^crates/rustc_codegen_spirv/src/lib.rs: use std::env::{self, VarError};$'
61+
5662
); then
5763
echo '^^^'
5864
echo '!!! Found disallowed `std::env` usage in `rustc_codegen_spirv` !!!'
@@ -87,3 +93,16 @@ function version_test() {
8793
# FIXME(eddyb) try to get this working for `spirv-builder`, which has a larger
8894
# dependency graph, with too much imprecision in upstream `Cargo.toml` files.
8995
version_test crates/spirv-std
96+
97+
# 3. Ensure `rustc_codegen_spirv` still compiles with `rustc_codegen_ssa`.
98+
99+
# HACK(eddyb) see `crates/rustc_codegen_spirv/build.rs` for more on `pqp_cg_ssa`
100+
# (a patched copy of `rustc_codegen_ssa`).
101+
echo ::group::rustc_codegen_spirv_disable_pqp_cg_ssa
102+
cargo clippy \
103+
--manifest-path "crates/rustc_codegen_spirv/Cargo.toml" \
104+
--no-default-features \
105+
--features "$FEAT" \
106+
--all-targets \
107+
-- -D warnings --cfg rustc_codegen_spirv_disable_pqp_cg_ssa
108+
echo ::endgroup::

CHANGELOG.md

Lines changed: 77 additions & 13 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)