Commit Graph

8599 Commits

Author SHA1 Message Date
Erich Gubler
9ea464b85b test(valid): cover select arg. mismatches 2024-12-20 10:34:20 -05:00
Jim Blandy
2587db1c9b [naga] In compaction, fix array lengths as part of type adjustment. (#6790)
Adjust the `Handle<Expression>` values that appear in
`TypeInner::Array` via `PendingArraySize::Expression` as part of the
normal type adjustment process in `ModuleMap::adjust_type`, rather
than cloning the type arena so we can iterate over it and call
`UniqueArena::replace`.

Fixes #6789.
2024-12-20 10:33:29 -05:00
teoxoy
a5c3be575e remove device arg from all CommandEncoder methods 2024-12-20 15:44:15 +01:00
teoxoy
973def4c53 remove old todo 2024-12-20 15:44:15 +01:00
teoxoy
7b2a561402 make open_pass panic if the encoder is open 2024-12-20 15:44:15 +01:00
teoxoy
0fed4dbc16 make close_and_swap panic if the encoder is not open 2024-12-20 15:44:15 +01:00
teoxoy
486967632c rename close to close_if_open and add close that panics if the encoder is not open 2024-12-20 15:44:15 +01:00
teoxoy
7a476fcbf4 use open_pass in some more places 2024-12-20 15:44:15 +01:00
teoxoy
062999658a let open_pass handle hal label mapping 2024-12-20 15:44:15 +01:00
teoxoy
38e09d02cc update code that opens and closes the encoder to
go through `CommandEncoder`'s methods

So that `CommandEncoder.is_open` is always accurate.
2024-12-20 15:44:15 +01:00
Teodor Tanasoaia
53f40794f2 move logic into TextureStateSet (#6689) 2024-12-18 22:40:26 +00:00
Connor Fitzgerald
b38aad994a Fix Skipping Amd RT Tests (#6781) 2024-12-18 15:25:22 -05:00
Connor Fitzgerald
be07f41da7 Make wgpu-info Default to Static-DXC as Well (#6782) 2024-12-18 19:51:02 +00:00
Samson
d63ca09c34 Add usage to TextureViewDescriptor (#6755)
Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2024-12-18 18:38:28 +01:00
Eddie Hatfield
79280bc3d4 Detect a common syntax error case for diagnostic_directive (#6718)
Co-authored-by: Erich Gubler <erichdongubler@gmail.com>
2024-12-18 11:21:45 -05:00
Jim Blandy
a0344cc932 [naga valid]: Clean up validation of Statement::ImageStore.
Ensure that the type we obtain for the `image` operand is correct:
"see through" a binding array to its element type only when `image` is
actually an `Access` or `AccessIndex` expression. (This changes the
set of programs the validator will pass, but it turns out not to
affect the set of WGSL programs that Naga will accept, since the WGSL
front end is already checking the types of the `texture` arguments to
`textureStore` function calls, in order to decide which overload
applies.)

Rename the variables to better reflect their values.
2024-12-18 08:10:50 -08:00
Jim Blandy
87d9ffed56 [naga valid]: Clean up validation of Statement::ImageStore.
Move image class validation to a more natural spot.
2024-12-18 08:10:50 -08:00
Jim Blandy
1a06279ca9 [naga valid]: Clean up validation of Statement::ImageStore.
Use `let-else` statements to keep the main flow of control at the
left. Briefly describe the conditions we're testing.
2024-12-18 08:10:50 -08:00
Leo Kettmeir
df825fec8c chore: update deno (#6068)
---------

Co-authored-by: Luca Casonato <hello@lcas.dev>
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
Co-authored-by: chirsz <chirsz@foxmail.com>
Co-authored-by: Hajime-san <41257923+hajime-san@users.noreply.github.com>
Co-authored-by: Volker Schlecht <47375452+vlkrs@users.noreply.github.com>
2024-12-18 08:01:50 -08:00
Valtteri Vallius
0fe20342e0 Add multiple render targets example (v2) (#5313)
Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
2024-12-18 04:41:21 +00:00
Vecvec
9ed716954f Note way matrix needs to be round. (#6776) 2024-12-18 01:16:58 +00:00
Erich Gubler
8f2f5e913a chore: warn on clippy::ptr_as_ref (#6770) 2024-12-17 17:08:37 -05:00
Erich Gubler
aaac47c24e fix(naga): s/os/target_os/ in xtask's FXC/DXC check (#6774) 2024-12-17 16:12:24 -05:00
Erich Gubler
f6b156e799 test(ci): update NIGHTLY_BUILD to last 1.83.0 Nightly (#6769) 2024-12-17 19:15:54 +00:00
Erich Gubler
f188c3409c chore: update repo MSRV 1.76 → 1.83 2024-12-17 13:30:52 -05:00
Erich Gubler
58cf8e6b1c chore: register wgpu_validate_locks as an expected cfg 2024-12-17 13:30:52 -05:00
Erich Gubler
99dc90f318 chore: suppress manual_c_str_literals in the workspace 2024-12-17 13:30:52 -05:00
Erich Gubler
809ea1d478 chore(benches): add tracy to lints.rust.unexpected_cfgs.check-cfg 2024-12-17 13:30:52 -05:00
Erich Gubler
b2c9b0af5a chore: add web_sys_unstable_apis to lints.rust.unexpected_cfgs.check-cfg in wgpu_{hal,types} 2024-12-17 13:30:52 -05:00
Erich Gubler
143403cad1 build: upgrade cfg_aliases 0.1.1 → 0.2.1
Consumes
[`cfg_aliases`#8](https://github.com/katharostech/cfg_aliases/pull/8) to
eliminate warnings from `rustc`.
2024-12-17 13:30:52 -05:00
Erich Gubler
1f93ea0692 chore: resolve clippy::large_enum_variant 2024-12-17 13:30:52 -05:00
Teodor Tanasoaia
04a10405b3 [d3d12] fix being able to use dispatchWorkgroupsIndirect without validation (#6767) 2024-12-17 17:10:00 +01:00
Schell Carl Scivally
ea7556853d [naga spv-in] Support atomics in fields of global structs
Handle SPIR-V input that performs atomic operations on structs that
have more than one field. Track which fields of which struct types are
used by atomic operations on which global variables, and then give
those global variables new types in which exactly those fields have
had their `Scalar` leaf types changed to `Atomic`.

Add snapshot tests.

Co-authored-by: Jim Blandy <jimb@red-bean.com>
2024-12-17 07:45:41 -08:00
Erich Gubler
3160f81289 fix(types): use correct cfgs for serde(rename…)d VertexFormat variants (#6765) 2024-12-16 17:37:45 -05:00
Erich Gubler
4eb14352b9 chore: satisfy clippy::doc_lazy_continuation (#6764) 2024-12-16 22:33:30 +00:00
Erich Gubler
964a8d99d2 chore: satisfy clippy::unnecessary_map_or (#6710)
Started firing in Rust 1.84.
2024-12-16 17:26:12 -05:00
Samson
f6fec82853 [core] Allow depthClearValue to be empty (#6753) 2024-12-16 16:21:06 -05:00
Vecvec
0d927c244f Add documentation for the raytracing API (#6747)
Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
2024-12-16 20:21:38 +00:00
dependabot[bot]
67df93f3c2 chore(deps): bump mach-dxcompiler-rs from 0.1.3+2024.11.22-df583a3.1 to 0.1.4+2024.11.22-df583a3.1 in the patch-updates group across 1 directory (#6758)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-12-16 14:51:37 -05:00
Connor Fitzgerald
89a8867f9b Enable Partial Binding on DX12 (#6734) 2024-12-16 15:47:19 +00:00
Christofer Nolander
21ff9686a7 Add 1-component ({s,u}{int,norm}{8,16}, float16) and unorm8x4-bgra vertex formats (#6632)
* feat: add missing 8/16-bit vertex formats (and 8-bit bgra) #6614

* add tests for 1-component vertex formats (and bgra)

* metal: unpacking function for 1-component vertex formats

* test: use proper alignment for float16 vertex format

* changelog: new vertex formats
2024-12-16 10:18:50 -05:00
Connor Fitzgerald
bcc962687d Use Static-DXC for tests (#6730) 2024-12-16 10:14:35 -05:00
Samson
4da7c263ed [core] Support optional ops in PassChannel (#6716)
* Support optional ops in PassChannel

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

* respect view format aspect

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
2024-12-16 12:20:20 +01:00
Connor Fitzgerald
411ffa7a5a Make Force Loop Bounding Optional (#6662)
* Make Force Loop Bounding Optional

Co-authored-by: rudderbucky <anandkwork7@gmail.com>

* Deprecate and Rename

---------

Co-authored-by: rudderbucky <anandkwork7@gmail.com>
2024-12-16 04:23:22 -05:00
Connor Fitzgerald
60f8535e12 Add Bind Group Creation Benchmark (#6725)
* Add Bind Group Creation Benchmark

* Mind the Limits
2024-12-16 04:14:04 -05:00
Connor Fitzgerald
7f1e45ff88 Fix Test Failure on AMD GL (#6726) 2024-12-16 04:13:12 -05:00
Connor Fitzgerald
f384a72bf6 Skip AMD GPUs from RT Tests (#6728) 2024-12-16 04:09:50 -05:00
Connor Fitzgerald
286082acef Bindless Tests (#6732)
* Move Partial Binding into Own File

* Texture Bindless Test

* Make It Work

* Tests

* Uniform Buffers

* BadCode

* Bugs!

* Exclude llvmpipe

* Combine Partial Binding Test

* MVK Issue

* Sampler Array Tests

* Make All Tests Partially Bound As Well
2024-12-16 04:08:05 -05:00
dependabot[bot]
2ec87d7c2f chore(deps): bump the patch-updates group with 8 updates (#6749)
Bumps the patch-updates group with 8 updates:

| Package | From | To |
| --- | --- | --- |
| [libc](https://github.com/rust-lang/libc) | `0.2.167` | `0.2.168` |
| [serde](https://github.com/serde-rs/serde) | `1.0.215` | `1.0.216` |
| [tracy-client](https://github.com/nagisa/rust_tracy_client) | `0.17.5` | `0.17.6` |
| [cc](https://github.com/rust-lang/cc-rs) | `1.2.3` | `1.2.4` |
| [crossbeam-deque](https://github.com/crossbeam-rs/crossbeam) | `0.8.5` | `0.8.6` |
| [crossbeam-utils](https://github.com/crossbeam-rs/crossbeam) | `0.8.20` | `0.8.21` |
| [serde_derive](https://github.com/serde-rs/serde) | `1.0.215` | `1.0.216` |
| [tracy-client-sys](https://github.com/nagisa/rust_tracy_client) | `0.24.2` | `0.24.3` |


Updates `libc` from 0.2.167 to 0.2.168
- [Release notes](https://github.com/rust-lang/libc/releases)
- [Changelog](https://github.com/rust-lang/libc/blob/0.2.168/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/libc/compare/0.2.167...0.2.168)

Updates `serde` from 1.0.215 to 1.0.216
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.215...v1.0.216)

Updates `tracy-client` from 0.17.5 to 0.17.6
- [Commits](https://github.com/nagisa/rust_tracy_client/compare/tracy-client-v0.17.5...tracy-client-v0.17.6)

Updates `cc` from 1.2.3 to 1.2.4
- [Release notes](https://github.com/rust-lang/cc-rs/releases)
- [Changelog](https://github.com/rust-lang/cc-rs/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/cc-rs/compare/cc-v1.2.3...cc-v1.2.4)

Updates `crossbeam-deque` from 0.8.5 to 0.8.6
- [Release notes](https://github.com/crossbeam-rs/crossbeam/releases)
- [Changelog](https://github.com/crossbeam-rs/crossbeam/blob/master/CHANGELOG.md)
- [Commits](https://github.com/crossbeam-rs/crossbeam/compare/crossbeam-deque-0.8.5...crossbeam-deque-0.8.6)

Updates `crossbeam-utils` from 0.8.20 to 0.8.21
- [Release notes](https://github.com/crossbeam-rs/crossbeam/releases)
- [Changelog](https://github.com/crossbeam-rs/crossbeam/blob/master/CHANGELOG.md)
- [Commits](https://github.com/crossbeam-rs/crossbeam/compare/crossbeam-utils-0.8.20...crossbeam-utils-0.8.21)

Updates `serde_derive` from 1.0.215 to 1.0.216
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.215...v1.0.216)

Updates `tracy-client-sys` from 0.24.2 to 0.24.3
- [Commits](https://github.com/nagisa/rust_tracy_client/compare/tracy-client-sys-v0.24.2...tracy-client-sys-v0.24.3)

---
updated-dependencies:
- dependency-name: libc
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: patch-updates
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: patch-updates
- dependency-name: tracy-client
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: patch-updates
- dependency-name: cc
  dependency-type: indirect
  update-type: version-update:semver-patch
  dependency-group: patch-updates
- dependency-name: crossbeam-deque
  dependency-type: indirect
  update-type: version-update:semver-patch
  dependency-group: patch-updates
- dependency-name: crossbeam-utils
  dependency-type: indirect
  update-type: version-update:semver-patch
  dependency-group: patch-updates
- dependency-name: serde_derive
  dependency-type: indirect
  update-type: version-update:semver-patch
  dependency-group: patch-updates
- dependency-name: tracy-client-sys
  dependency-type: indirect
  update-type: version-update:semver-patch
  dependency-group: patch-updates
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-12-16 00:38:53 -05:00
dependabot[bot]
bd386c3f0b chore(deps): bump crate-ci/typos from 1.28.2 to 1.28.3 (#6750)
Bumps [crate-ci/typos](https://github.com/crate-ci/typos) from 1.28.2 to 1.28.3.
- [Release notes](https://github.com/crate-ci/typos/releases)
- [Changelog](https://github.com/crate-ci/typos/blob/master/CHANGELOG.md)
- [Commits](https://github.com/crate-ci/typos/compare/v1.28.2...v1.28.3)

---
updated-dependencies:
- dependency-name: crate-ci/typos
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-12-16 00:38:36 -05:00