Skip to content

Commit 27a25c2

Browse files
committed
Merge remote-tracking branch 'upstream/trunk' into barrier-with-queue-properties
2 parents 59ad206 + 4d4c1e1 commit 27a25c2

561 files changed

Lines changed: 41617 additions & 10659 deletions

File tree

Some content is hidden

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

.config/nextest.toml

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,6 @@ slow-timeout = { period = "45s", terminate-after = 2 }
66
fail-fast = false
77
retries = 0
88

9-
[profile.default-miri]
10-
# Miri is very very slow, so give it a much longer timeout.
11-
slow-timeout = { period = "120s", terminate-after = 4 }
12-
139
# Use two threads for tests with "2 threads" in their name
1410
[[profile.default.overrides]]
1511
filter = 'test(~2_threads) | test(~2 threads)'
@@ -51,3 +47,13 @@ threads-required = "num-test-threads"
5147
[[profile.default.overrides]]
5248
priority = 1
5349
filter = 'test(clear_texture) | test(clear_buffer_range_respected) | test(compile_fail) | test(test_api)'
50+
51+
[profile.wasm]
52+
default-filter = "test([wasm])"
53+
slow-timeout = { period = "45s", terminate-after = 2 }
54+
fail-fast = false
55+
retries = 0
56+
57+
[profile.default-miri]
58+
# Miri is very very slow, so give it a much longer timeout.
59+
slow-timeout = { period = "120s", terminate-after = 4 }

.deny.toml

Lines changed: 19 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -1,85 +1,36 @@
1+
[graph]
2+
# This configuration is tuned for the published `wgpu`/`naga` library crates and
3+
# their dependencies *only* -- the skip/ignore/allow entries below assume that
4+
# scope. The binaries, tests, examples, and tooling in this workspace pull in many
5+
# more dependencies that would produce false-positive advisory/ban/license noise.
6+
exclude-unpublished = true
7+
# Dev dependencies are not relevant to the published library crates, so we ignore them.
8+
exclude-dev = true
9+
110
[bans]
211
multiple-versions = "deny"
3-
skip-tree = [
4-
{ name = "rustc-hash", version = "1.1.0" },
5-
6-
# introduced by Deno, to be investigated
7-
{ name = "petgraph", version = "0.6.5" },
8-
9-
# Winit 0.30 uses an older objc2
10-
{ name = "objc2-foundation", version = "0.2" },
11-
12-
# glutin and tracy-client-sys use windows-sys 0.52, pulling older windows-targets
13-
{ name = "windows-targets", version = "0.52" },
14-
]
12+
skip-tree = [{ name = "rustc-hash", version = "1.1.0" }]
1513
skip = [
16-
# the ecosystem is migrating from getrandom 0.3 to 0.4, so this captures many stragglers
17-
{ name = "getrandom", version = "0.3.4" },
18-
19-
# Deno uses an old version
20-
{ name = "bincode", version = "1.3.3" },
21-
{ name = "which", version = "6.0.3" },
22-
23-
# Winit uses an old version via calloop → rustix 0.38
24-
{ name = "linux-raw-sys", version = "0.4" },
25-
{ name = "rustix", version = "0.38" },
26-
{ name = "windows-sys", version = "0.59" },
27-
28-
# Winit uses an old version via android-activity
29-
{ name = "thiserror", version = "1" },
30-
{ name = "thiserror-impl", version = "1" },
31-
32-
# glutin uses an old version
33-
{ name = "windows-sys", version = "0.52" },
34-
35-
# getrandom 0.3 uses an old version
36-
{ name = "r-efi", version = "5" },
37-
38-
# winit uses this old version
39-
{ name = "redox_syscall", version = "0.4.1" },
40-
# parking-lot uses this old version
41-
{ name = "redox_syscall", version = "0.5.18" },
42-
43-
# deno uses an old version
44-
{ name = "bit-vec", version = "0.8.0" },
45-
{ name = "bit-set", version = "0.8.0" },
46-
47-
# drm uses an older version via drm-sys, and a newer version via rustix
48-
{ name = "linux-raw-sys", version = "0.9.4" },
49-
50-
# getrandom -> wasip3 -> wit-bindgen uses an old version but
51-
# getrandom -> wasip2 -> wit-bindgen uses a newer version
52-
{ name = "wit-bindgen", version = "0.51.0" },
53-
54-
# android-activity -> ndk -> jni-sys uses an old version but
55-
# android-activity -> jni -> jni-sys uses a newer version
56-
{ name = "jni-sys", version = "0.3.1" },
57-
58-
# v8 -> bindgen -> itertools uses an old version
59-
{ name = "itertools", version = "0.13" },
60-
61-
# gpu-descriptor and petgraph use an old version
14+
# naga -> petgraph uses an old version
6215
{ name = "hashbrown", version = "0.15.5" },
63-
6416
# Used by hashbrown 0.15.5
6517
{ name = "foldhash", version = "0.1.5" },
18+
19+
# naga depends on hashbrown 0.16 directly, while naga -> indexmap pulls hashbrown 0.17
20+
{ name = "hashbrown", version = "0.16.1" },
21+
22+
# wgpu-hal -> drm -> drm-sys uses an older version, while wgpu-hal -> drm -> rustix uses a newer one
23+
{ name = "linux-raw-sys", version = "0.9.4" },
6624
]
6725
wildcards = "deny"
6826
allow-wildcard-paths = true
6927

7028
[advisories]
7129
ignore = [
7230
# `paste` crate is no longer maintained https://rustsec.org/advisories/RUSTSEC-2024-0436
73-
# It's a dependency of `metal` (which is to be replaced with `objc2-metal`), and a
74-
# transitive dependency of `deno`. https://github.com/gfx-rs/wgpu/issues/7873
31+
# It's a transitive dependency of `wgpu-core` via `macro_rules_attribute`.
32+
# https://github.com/gfx-rs/wgpu/issues/7873
7533
"RUSTSEC-2024-0436",
76-
# `unic-*` crates are no longer maintained https://rustsec.org/advisories/RUSTSEC-2025-0100
77-
# These are used via `deno`. https://github.com/gfx-rs/wgpu/issues/8393
78-
"RUSTSEC-2025-0075",
79-
"RUSTSEC-2025-0080",
80-
"RUSTSEC-2025-0081",
81-
"RUSTSEC-2025-0098",
82-
"RUSTSEC-2025-0100",
8334
# `bincode` is no longer maintained https://rustsec.org/advisories/RUSTSEC-2025-0141
8435
# We only use it directly for tests and tools. It is also used indirectly via deno.
8536
"RUSTSEC-2025-0141",
@@ -88,27 +39,16 @@ ignore = [
8839
[licenses]
8940
allow = [
9041
"Apache-2.0",
91-
"Apache-2.0 WITH LLVM-exception",
9242
"BSD-2-Clause",
9343
"BSD-3-Clause",
9444
"ISC",
95-
"MPL-2.0",
9645
"MIT",
97-
"MIT-0",
9846
"Unicode-3.0",
9947
"Zlib",
10048
]
10149
private = { ignore = true }
10250

10351
[sources]
104-
allow-git = [
105-
# Waiting on releases; used in examples/tests only
106-
107-
# Pending a release for https://github.com/rust-cli/env_logger/commit/143fa647ab33ed3acc9f160dfa3cb075cc62b5a3
108-
"https://github.com/rust-cli/env_logger",
109-
# Pending merge/release for https://github.com/LukasKalbertodt/libtest-mimic/pull/58
110-
"https://github.com/cwfitzgerald/libtest-mimic",
111-
]
11252
unknown-registry = "deny"
11353
unknown-git = "deny"
11454
required-git-spec = "rev"

.github/actions/install-dxc/action.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,12 @@ runs:
77
run: |
88
set -e
99
10-
export DXC_RELEASE="v1.8.2505.1"
11-
export DXC_FILENAME="dxc_2025_07_14.zip"
10+
export DXC_RELEASE="v1.9.2602.24"
11+
export DXC_FILENAME="dxc_2026_05_27.zip"
1212
1313
curl.exe -L --retry 5 https://github.com/microsoft/DirectXShaderCompiler/releases/download/$DXC_RELEASE/$DXC_FILENAME -o dxc.zip
1414
7z.exe e dxc.zip -odxc bin/x64/{dxc.exe,dxcompiler.dll}
1515
1616
# We need to use cygpath to convert PWD to a windows path as we're using bash.
17-
cygpath --windows "$PWD/dxc" >> "$GITHUB_PATH"
17+
echo "WGPU_DX12_COMPILER=$(cygpath --windows "$PWD/dxc/dxcompiler.dll")" >> "$GITHUB_ENV"
18+
echo "DENO_WEBGPU_DX12_COMPILER=$(cygpath --windows "$PWD/dxc/dxcompiler.dll")" >> "$GITHUB_ENV"

.github/actions/install-mesa/action.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ inputs:
44
# Sourced from https://archive.mesa3d.org/. Bumping this requires
55
# updating the mesa build in https://github.com/gfx-rs/ci-build and creating a new release.
66
version:
7-
default: "25.2.7"
7+
default: "26.1.3"
88
# Corresponds to https://github.com/gfx-rs/ci-build/releases
99
ci-binary-build:
10-
default: "build26"
10+
default: "build29"
1111
target-dir:
1212
description: "The directory into which to install the Mesa libraries."
1313
default: "target/llvm-cov-target/debug"
@@ -33,10 +33,11 @@ runs:
3333
cat <<- EOF > icd.json
3434
{
3535
"ICD": {
36-
"api_version": "1.1.255",
36+
"api_version": "1.4.348",
37+
"library_arch": "64",
3738
"library_path": "$PWD/mesa/lib/x86_64-linux-gnu/libvulkan_lvp.so"
3839
},
39-
"file_format_version": "1.0.0"
40+
"file_format_version": "1.0.1"
4041
}
4142
EOF
4243

.github/workflows/ci.yml

Lines changed: 44 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ on:
1414
merge_group:
1515

1616
env:
17+
#
18+
# Keep in sync with cts.yml
19+
#
20+
1721
#
1822
# Dependency versioning
1923
#
@@ -27,12 +31,11 @@ env:
2731
CORE_MSRV: "1.87"
2832

2933
#
30-
# Environment variables
34+
# Build and test configuration
3135
#
3236

3337
CARGO_INCREMENTAL: false
3438
CARGO_TERM_COLOR: always
35-
WGPU_DX12_COMPILER: dxc
3639
RUST_LOG: debug,wasm_bindgen_wasm_interpreter=warn,wasm_bindgen_cli_support=warn,walrus=warn,naga=info
3740
RUST_BACKTRACE: full
3841
PKG_CONFIG_ALLOW_CROSS: 1 # allow android to work
@@ -42,6 +45,13 @@ env:
4245
CACHE_SUFFIX: e # cache busting
4346
WGPU_CI: true
4447

48+
#
49+
# Runtime configuration
50+
#
51+
52+
LVP_POISON_MEMORY: true # to test memory init; see docs/testing.md
53+
WGPU_DX12_COMPILER: dxc
54+
4555
# Every time a PR is pushed to, cancel any previous jobs. This
4656
# makes us behave nicer to github and get faster turnaround times
4757
# on PRs that are pushed to multiple times in rapid succession.
@@ -178,6 +188,13 @@ jobs:
178188
tier: 2
179189
kind: web
180190

191+
- name: WebAssembly 64-bit
192+
os: ubuntu-24.04
193+
target: wasm64-unknown-unknown
194+
kind: wgpu-only
195+
tier: 3
196+
extra-flags: -Zbuild-std=std,panic_abort
197+
181198
- name: Emscripten
182199
os: ubuntu-24.04
183200
target: wasm32-unknown-emscripten
@@ -309,13 +326,15 @@ jobs:
309326
310327
# check with no features
311328
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p wgpu-types --no-default-features
329+
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p naga-types --no-default-features
312330
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p naga --no-default-features
313331
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p wgpu-hal --no-default-features
314332
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p wgpu --no-default-features
315333
316334
# Check with all compatible features
317335
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p wgpu-types --no-default-features --features strict_asserts,fragile-send-sync-non-atomic-wasm,serde,counters
318-
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p naga --no-default-features --features dot-out,spv-in,spv-out
336+
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p naga-types --no-default-features --features serialize,deserialize
337+
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p naga --no-default-features --features dot-out,spv-in,spv-out,glsl-out,msl-out,serialize,deserialize,wgsl-in,wgsl-out,hlsl-out
319338
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p wgpu-hal --no-default-features --features fragile-send-sync-non-atomic-wasm
320339
cargo --locked clippy --target ${{ matrix.target }} ${{ matrix.extra-flags }} -p wgpu --no-default-features --features serde
321340
@@ -577,16 +596,25 @@ jobs:
577596
rustup override set ${{ env.REPO_MSRV }}
578597
cargo -V
579598
580-
- name: Install `wasm-pack`
599+
- name: Get `wasm-bindgen` version
600+
run: |
601+
WASM_BINDGEN_VERSION=$(cargo metadata --format-version 1 --all-features | jq '.packages[] | select(.name == "wasm-bindgen") | .version' | tr -d '"')
602+
603+
echo $WASM_BINDGEN_VERSION
604+
605+
echo "WASM_BINDGEN_VERSION=$WASM_BINDGEN_VERSION" >> "$GITHUB_ENV"
606+
607+
- name: Install `wasm-bindgen`
608+
run: cargo +stable install wasm-bindgen-cli --version=$WASM_BINDGEN_VERSION
609+
610+
- name: Install `cargo-nextest`
581611
uses: taiki-e/install-action@v2
582612
with:
583-
tool: wasm-pack
613+
tool: cargo-nextest
584614

585615
- name: Execute tests
586616
run: |
587-
cd wgpu
588-
589-
wasm-pack test --headless --chrome --no-default-features --features wgsl,webgl,web --workspace
617+
cargo xtask test-wasm
590618
591619
gpu-test:
592620
# runtime is normally 5-15 minutes
@@ -727,7 +755,7 @@ jobs:
727755
cargo --locked llvm-cov report --lcov --output-path lcov.info
728756
729757
- name: Upload coverage report to Codecov
730-
uses: codecov/codecov-action@v6
758+
uses: codecov/codecov-action@v7
731759
if: steps.coverage.outcome == 'success'
732760
with:
733761
files: lcov.info
@@ -819,26 +847,22 @@ jobs:
819847
# NOTE: Keep this above the others, because this will fail if there are _any_ changes to
820848
# files, even ones this step doesn't modify.
821849
- name: "Format `**/*.{md,js,html,yml}` files"
822-
uses: creyD/prettier_action@v4.6
823-
with:
824-
prettier_version: 3.8.1
825-
prettier_options: --check --write .
826-
dry: true
850+
run: "npx --yes prettier@3.8.1 --check --write . && git diff --exit-code"
827851

828852
- name: Run `cargo fmt`
829853
run: |
830854
cargo --locked fmt -- --check
831855
832-
- name: Install Taplo
833-
uses: uncenter/setup-taplo@v2
856+
- name: Install Tombi
857+
uses: tombi-toml/setup-tombi@v1.2.0
834858
with:
835-
version: "0.9.3"
859+
version: "1.1.3"
836860

837-
- name: Run `taplo fmt`
838-
run: taplo format --check --diff
861+
- name: Format TOML files
862+
run: tombi format --check --diff
839863

840864
- name: Check for typos
841-
uses: crate-ci/typos@v1.46.3
865+
uses: crate-ci/typos@v1.47.2
842866

843867
check-cts-runner:
844868
# runtime is normally 2 minutes

.github/workflows/cts.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,24 @@ on:
1414
merge_group:
1515

1616
env:
17+
#
18+
# Keep in sync with ci.yml
19+
#
20+
1721
REPO_MSRV: "1.93"
1822
CARGO_INCREMENTAL: false
1923
CARGO_TERM_COLOR: always
2024
RUST_BACKTRACE: full
2125
RUSTFLAGS: -D warnings
2226
RUSTDOCFLAGS: -D warnings
2327

28+
#
29+
# Runtime configuration
30+
#
31+
32+
LVP_POISON_MEMORY: true # to test memory init; see docs/testing.md
33+
# cts_runner uses dxc by default
34+
2435
# Every time a PR is pushed to, cancel any previous jobs. This
2536
# makes us behave nicer to github and get faster turnaround times
2637
# on PRs that are pushed to multiple times in rapid succession.
@@ -172,7 +183,7 @@ jobs:
172183
cargo --locked llvm-cov report --lcov --output-path lcov.info
173184
174185
- name: Upload coverage report to Codecov
175-
uses: codecov/codecov-action@v6
186+
uses: codecov/codecov-action@v7
176187
if: steps.coverage.outcome == 'success'
177188
with:
178189
files: lcov.info

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,14 @@ wgpu/red.png
4141

4242
# Cached GPU config
4343
.gpuconfig
44+
.wasmgpuconfig
4445

4546
# Temporary clone location for wasm-bindgen mirroring
4647
wgpu/src/backend/webgpu/webgpu_sys/wasm_bindgen_clone_tmp
4748

4849
# LLM-related
4950
.claude/settings.local.json
51+
52+
# Wasm test generated files
53+
/tests/wasm/dist
54+
/tests/wasm/runner/node_modules

0 commit comments

Comments
 (0)