Erich Gubler
c4a8f038ee
style: align doc. commentary in TextureFormatFeatureFlags
( #5809 )
2024-06-13 16:40:05 +00:00
Erich Gubler
39534ff342
build: fix individual -p wgpu-info
builds ( #5808 )
2024-06-13 16:37:34 +00:00
Jim Blandy
eb69c5fd2f
[types]: Make Maintain
implement Debug
. ( #5802 )
2024-06-13 12:10:36 -04:00
Jim Blandy
b9b7050bb9
Give wgpu_test::compute_pass_ownership
buffers unique labels.
...
Give each buffer in the
`wgpu_test::compute_pass_ownership::compute_pass_resource_ownership`
test a unique label, for easier debugging.
2024-06-13 12:25:05 +02:00
Jim Blandy
93c6fbe8ba
Skip compute_pass_resource_ownership
on GL/AMD Radeon Pro WX 3200. ( #5801 )
...
Skip
`wgpu_test::compute_pass_ownership::compute_pass_resource_ownership`
on the GL backend on AMD Radeon Pro WX 3200, to avoid the kernel crash
described in #5800 .
2024-06-12 21:27:34 +00:00
Connor Fitzgerald
c6d954e026
Add Release.md ( #5622 )
...
Co-authored-by: Imbris <2002109+Imberflur@users.noreply.github.com>
2024-06-12 14:39:54 -04:00
Elabajaba
2eb872e6f7
Deduplicate submitted surfaces to avoid a vulkan deadlock/crash ( #5799 )
2024-06-12 14:39:26 -04:00
Teodor Tanasoaia
be4eabc71b
[ci] check for untracked naga snapshots ( #5792 )
2024-06-11 19:13:42 +00:00
Teodor Tanasoaia
00f5c57b86
update IR snapshots ( #5793 )
2024-06-10 18:41:07 -04:00
Jim Blandy
6c370522a7
[wgpu] Remove unused ObjectId
field of SubmissionIndex
. ( #5780 )
...
Drop the first field of `wgpu::SubmissionIndex`, as it is unused.
Adjust uses of the types' other field.
Delete the `wgpu::context::Context` trait's `SubmissionIndex`
associated type. Remove it from implementations.
Drop the first field of the `Context` trait's `queue_submit` method's
return value. Adjust implementations.
2024-06-10 14:20:42 -04:00
Andreas Reich
eb24be47e1
Validate for device mismatch during compute pass recording ( #5779 )
...
* compute pass recording device validation
* add changelog entry
* validate device of timestamp query set as well
2024-06-10 12:19:50 +02:00
Vecvec
73401ede25
Fix double decoration if a binding array contains a struct with a runtime array ( #5776 )
2024-06-10 11:20:33 +02:00
Jim Blandy
5790514e63
[naga] Document which Arena
each Handle<Expression>
refers to.
2024-06-10 11:02:43 +02:00
Jim Blandy
1ad1c4ae77
[naga] Add snapshot test output omitted from #5702 .
2024-06-10 10:22:51 +02:00
dependabot[bot]
09acceebca
build(deps): bump the patch-updates group with 12 updates ( #5790 )
...
Bumps the patch-updates group with 12 updates:
| Package | From | To |
| --- | --- | --- |
| [glutin_wgl_sys](https://github.com/rust-windowing/glutin ) | `0.5.0` | `0.6.0` |
| [anstyle-query](https://github.com/rust-cli/anstyle ) | `1.0.3` | `1.1.0` |
| [cc](https://github.com/rust-lang/cc-rs ) | `1.0.98` | `1.0.99` |
| [clap](https://github.com/clap-rs/clap ) | `4.5.4` | `4.5.6` |
| [clap_builder](https://github.com/clap-rs/clap ) | `4.5.2` | `4.5.6` |
| [clap_derive](https://github.com/clap-rs/clap ) | `4.5.4` | `4.5.5` |
| [clap_lex](https://github.com/clap-rs/clap ) | `0.7.0` | `0.7.1` |
| [regex](https://github.com/rust-lang/regex ) | `1.10.4` | `1.10.5` |
| [unicode-width](https://github.com/unicode-rs/unicode-width ) | `0.1.12` | `0.1.13` |
| [utf8parse](https://github.com/alacritty/vte ) | `0.2.1` | `0.2.2` |
| [windows-result](https://github.com/microsoft/windows-rs ) | `0.1.1` | `0.1.2` |
| [xkeysym](https://github.com/notgull/xkeysym ) | `0.2.0` | `0.2.1` |
Updates `glutin_wgl_sys` from 0.5.0 to 0.6.0
- [Release notes](https://github.com/rust-windowing/glutin/releases )
- [Changelog](https://github.com/rust-windowing/glutin/blob/master/CHANGELOG.md )
- [Commits](https://github.com/rust-windowing/glutin/commits )
Updates `anstyle-query` from 1.0.3 to 1.1.0
- [Commits](https://github.com/rust-cli/anstyle/compare/anstyle-query-v1.0.3...anstyle-query-v1.1.0 )
Updates `cc` from 1.0.98 to 1.0.99
- [Release notes](https://github.com/rust-lang/cc-rs/releases )
- [Commits](https://github.com/rust-lang/cc-rs/compare/1.0.98...1.0.99 )
Updates `clap` from 4.5.4 to 4.5.6
- [Release notes](https://github.com/clap-rs/clap/releases )
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md )
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.4...v4.5.6 )
Updates `clap_builder` from 4.5.2 to 4.5.6
- [Release notes](https://github.com/clap-rs/clap/releases )
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md )
- [Commits](https://github.com/clap-rs/clap/compare/v4.5.2...v4.5.6 )
Updates `clap_derive` from 4.5.4 to 4.5.5
- [Release notes](https://github.com/clap-rs/clap/releases )
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md )
- [Commits](https://github.com/clap-rs/clap/compare/v4.5.4...v4.5.5 )
Updates `clap_lex` from 0.7.0 to 0.7.1
- [Release notes](https://github.com/clap-rs/clap/releases )
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md )
- [Commits](https://github.com/clap-rs/clap/compare/clap_lex-v0.7.0...clap_lex-v0.7.1 )
Updates `regex` from 1.10.4 to 1.10.5
- [Release notes](https://github.com/rust-lang/regex/releases )
- [Changelog](https://github.com/rust-lang/regex/blob/master/CHANGELOG.md )
- [Commits](https://github.com/rust-lang/regex/compare/1.10.4...1.10.5 )
Updates `unicode-width` from 0.1.12 to 0.1.13
- [Commits](https://github.com/unicode-rs/unicode-width/compare/v0.1.12...v0.1.13 )
Updates `utf8parse` from 0.2.1 to 0.2.2
- [Release notes](https://github.com/alacritty/vte/releases )
- [Changelog](https://github.com/alacritty/vte/blob/master/CHANGELOG.md )
- [Commits](https://github.com/alacritty/vte/compare/utf8parse_v0.2.1...utf8parse_v0.2.2 )
Updates `windows-result` from 0.1.1 to 0.1.2
- [Release notes](https://github.com/microsoft/windows-rs/releases )
- [Commits](https://github.com/microsoft/windows-rs/commits )
Updates `xkeysym` from 0.2.0 to 0.2.1
- [Release notes](https://github.com/notgull/xkeysym/releases )
- [Changelog](https://github.com/rust-windowing/xkeysym/blob/master/CHANGELOG.md )
- [Commits](https://github.com/notgull/xkeysym/compare/v0.2.0...v0.2.1 )
---
updated-dependencies:
- dependency-name: glutin_wgl_sys
dependency-type: direct:production
update-type: version-update:semver-minor
dependency-group: patch-updates
- dependency-name: anstyle-query
dependency-type: indirect
update-type: version-update:semver-minor
dependency-group: patch-updates
- dependency-name: cc
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: clap
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: clap_builder
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: clap_derive
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: clap_lex
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: regex
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: unicode-width
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: utf8parse
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: windows-result
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: xkeysym
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-06-10 09:51:27 +02:00
dependabot[bot]
532e71efb9
build(deps): bump crate-ci/typos from 1.21.0 to 1.22.3 ( #5789 )
...
Bumps [crate-ci/typos](https://github.com/crate-ci/typos ) from 1.21.0 to 1.22.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.21.0...v1.22.3 )
---
updated-dependencies:
- dependency-name: crate-ci/typos
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-06-10 09:48:42 +02:00
Atlas Dostal
abba12ae4e
Add support for 64 bit integer atomic operations in shaders.
...
Add the following flags to `wgpu_types::Features`:
- `SHADER_INT64_ATOMIC_ALL_OPS` enables all atomic operations on `atomic<i64>` and
`atomic<u64>` values.
- `SHADER_INT64_ATOMIC_MIN_MAX` is a subset of the above, enabling only
`AtomicFunction::Min` and `AtomicFunction::Max` operations on `atomic<i64>` and
`atomic<u64>` values in the `Storage` address space. These are the only 64-bit
atomic operations available on Metal as of 3.1.
Add corresponding flags to `naga::valid::Capabilities`. These are supported by the
WGSL front end, and all Naga backends.
Platform support:
- On Direct3d 12, in `D3D12_FEATURE_DATA_D3D12_OPTIONS9`, if
`AtomicInt64OnTypedResourceSupported` and `AtomicInt64OnGroupSharedSupported` are
both available, then both wgpu features described above are available.
- On Metal, `SHADER_INT64_ATOMIC_MIN_MAX` is available on Apple9 hardware, and on
hardware that advertises both Apple8 and Mac2 support. This also requires Metal
Shading Language 2.4 or later. Metal does not yet support the more general
`SHADER_INT64_ATOMIC_ALL_OPS`.
- On Vulkan, if the `VK_KHR_shader_atomic_int64` extension is available with both the
`shader_buffer_int64_atomics` and `shader_shared_int64_atomics` features, then both
wgpu features described above are available.
2024-06-08 18:36:26 -07:00
Jim Blandy
583cc6ab04
[naga] Ensure that FooResult
expressions are correctly populated.
...
Make Naga module validation require that `CallResult` and
`AtomicResult` expressions are indeed visited by exactly one `Call` /
`Atomic` statement.
2024-06-04 14:39:29 +02:00
Andreas Reich
9a27ba53ca
Fix QuerySet ownership of ComputePass ( #5671 )
...
* add new tests for checking on query set lifetime
* Fix ownership management of query sets on compute passes for write_timestamp, timestamp_writes (on desc) and pipeline statistic queries
* changelog entry
2024-06-04 07:47:27 +00:00
Erich Gubler
d258d6ce73
meta: add GOVERNANCE.md
2024-06-03 21:34:17 -04:00
Andreas Reich
aa2821bff6
Reintroduce computepass->encoder lifetime constraint and make it opt-out via wgpu::ComputePass::forget_lifetime
( #5768 )
...
* Reintroduce computepass->encoder lifetime constraint and make it opt-out via `wgpu::ComputePass::make_static`
* improve comments based on review feedback
* use the same lifetime name for all usages of `ComputePass<'encoder>`
* comment improvement that I missed earlier
* more review based comment improvements
* use suggested zero-overhead lifetime removal
* rename make_static to forge_lifetime
* missed comma
2024-06-03 20:04:12 +02:00
Jim Blandy
badcaee6e3
[naga] Make BlockContext::resolve_pointer_type
infallible.
...
Since `BlockContext::resolve_pointer_type` never returns an error,
change its result type from a `Result` to a `&TypeInner`. Adjust
callers accordingly.
Remove calls (well, there's only one) to `resolve_pointer_type`
entirely when the caller does not need the value, since
`resolve_pointer_type` is now infallible and has no side effects.
2024-06-03 11:30:28 +02:00
Jim Blandy
049db89039
[naga] Remove ExpressionError::DoesntExist
.
...
Remove `valid::expression::ExpressionError::DoesntExist`. This error is reported
when expression validation encounters an invalid `Handle<Expression>`, but we
have already verified that the module is free of invalid handles in
`Validator::validate_module_handles`, so this condition should never arise.
2024-06-03 11:30:28 +02:00
Jim Blandy
91e4be314c
[naga doc] Fix broken links in Naga bitflags
types.
...
Fix links in documentation for types defined using the `bitflags!` macro.
As described in [bitflags#407], for some reason, `cargo doc` doesn't
check for broken links in documentation for types or members defined
using `bitflags::bitflags!`.
[bitflags#407]: https://github.com/bitflags/bitflags/issues/407
2024-06-03 10:26:47 +02:00
dependabot[bot]
dd86dcf8f8
build(deps): bump the patch-updates group with 19 updates ( #5770 )
...
Bumps the patch-updates group with 19 updates:
| Package | From | To |
| --- | --- | --- |
| [parking_lot](https://github.com/Amanieu/parking_lot ) | `0.12.2` | `0.12.3` |
| [serde](https://github.com/serde-rs/serde ) | `1.0.202` | `1.0.203` |
| [tokio](https://github.com/tokio-rs/tokio ) | `1.37.0` | `1.38.0` |
| [syn](https://github.com/dtolnay/syn ) | `2.0.65` | `2.0.66` |
| [backtrace](https://github.com/rust-lang/backtrace-rs ) | `0.3.71` | `0.3.72` |
| [bytemuck_derive](https://github.com/Lokathor/bytemuck ) | `1.6.0` | `1.7.0` |
| [crc32fast](https://github.com/srijs/rust-crc32fast ) | `1.4.0` | `1.4.2` |
| [deno_unsync](https://github.com/denoland/deno_unsync ) | `0.3.3` | `0.3.4` |
| [gimli](https://github.com/gimli-rs/gimli ) | `0.28.1` | `0.29.0` |
| [objc-sys](https://github.com/madsmtm/objc2 ) | `0.3.3` | `0.3.5` |
| [object](https://github.com/gimli-rs/object ) | `0.32.2` | `0.35.0` |
| [plotters](https://github.com/plotters-rs/plotters ) | `0.3.5` | `0.3.6` |
| [plotters-backend](https://github.com/plotters-rs/plotters ) | `0.3.5` | `0.3.6` |
| [plotters-svg](https://github.com/plotters-rs/plotters ) | `0.3.5` | `0.3.6` |
| [polling](https://github.com/smol-rs/polling ) | `3.7.0` | `3.7.1` |
| [proc-macro2](https://github.com/dtolnay/proc-macro2 ) | `1.0.83` | `1.0.85` |
| [serde_derive](https://github.com/serde-rs/serde ) | `1.0.202` | `1.0.203` |
| [tokio-macros](https://github.com/tokio-rs/tokio ) | `2.2.0` | `2.3.0` |
| [wayland-backend](https://github.com/smithay/wayland-rs ) | `0.3.3` | `0.3.4` |
Updates `parking_lot` from 0.12.2 to 0.12.3
- [Changelog](https://github.com/Amanieu/parking_lot/blob/master/CHANGELOG.md )
- [Commits](https://github.com/Amanieu/parking_lot/compare/0.12.2...0.12.3 )
Updates `serde` from 1.0.202 to 1.0.203
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.202...v1.0.203 )
Updates `tokio` from 1.37.0 to 1.38.0
- [Release notes](https://github.com/tokio-rs/tokio/releases )
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.37.0...tokio-1.38.0 )
Updates `syn` from 2.0.65 to 2.0.66
- [Release notes](https://github.com/dtolnay/syn/releases )
- [Commits](https://github.com/dtolnay/syn/compare/2.0.65...2.0.66 )
Updates `backtrace` from 0.3.71 to 0.3.72
- [Release notes](https://github.com/rust-lang/backtrace-rs/releases )
- [Commits](https://github.com/rust-lang/backtrace-rs/compare/0.3.71...0.3.72 )
Updates `bytemuck_derive` from 1.6.0 to 1.7.0
- [Changelog](https://github.com/Lokathor/bytemuck/blob/main/changelog.md )
- [Commits](https://github.com/Lokathor/bytemuck/compare/bytemuck_derive-v1.6.0...bytemuck_derive-v1.7.0 )
Updates `crc32fast` from 1.4.0 to 1.4.2
- [Commits](https://github.com/srijs/rust-crc32fast/compare/v1.4.0...v1.4.2 )
Updates `deno_unsync` from 0.3.3 to 0.3.4
- [Commits](https://github.com/denoland/deno_unsync/commits )
Updates `gimli` from 0.28.1 to 0.29.0
- [Changelog](https://github.com/gimli-rs/gimli/blob/master/CHANGELOG.md )
- [Commits](https://github.com/gimli-rs/gimli/compare/0.28.1...0.29.0 )
Updates `objc-sys` from 0.3.3 to 0.3.5
- [Commits](https://github.com/madsmtm/objc2/compare/objc-sys-0.3.3...objc-sys-0.3.5 )
Updates `object` from 0.32.2 to 0.35.0
- [Changelog](https://github.com/gimli-rs/object/blob/master/CHANGELOG.md )
- [Commits](https://github.com/gimli-rs/object/compare/0.32.2...0.35.0 )
Updates `plotters` from 0.3.5 to 0.3.6
- [Changelog](https://github.com/plotters-rs/plotters/blob/master/CHANGELOG.md )
- [Commits](https://github.com/plotters-rs/plotters/compare/v0.3.5...v0.3.6 )
Updates `plotters-backend` from 0.3.5 to 0.3.6
- [Changelog](https://github.com/plotters-rs/plotters/blob/master/CHANGELOG.md )
- [Commits](https://github.com/plotters-rs/plotters/compare/v0.3.5...v0.3.6 )
Updates `plotters-svg` from 0.3.5 to 0.3.6
- [Changelog](https://github.com/plotters-rs/plotters/blob/master/CHANGELOG.md )
- [Commits](https://github.com/plotters-rs/plotters/compare/v0.3.5...v0.3.6 )
Updates `polling` from 3.7.0 to 3.7.1
- [Release notes](https://github.com/smol-rs/polling/releases )
- [Changelog](https://github.com/smol-rs/polling/blob/master/CHANGELOG.md )
- [Commits](https://github.com/smol-rs/polling/compare/v3.7.0...v3.7.1 )
Updates `proc-macro2` from 1.0.83 to 1.0.85
- [Release notes](https://github.com/dtolnay/proc-macro2/releases )
- [Commits](https://github.com/dtolnay/proc-macro2/compare/1.0.83...1.0.85 )
Updates `serde_derive` from 1.0.202 to 1.0.203
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.202...v1.0.203 )
Updates `tokio-macros` from 2.2.0 to 2.3.0
- [Release notes](https://github.com/tokio-rs/tokio/releases )
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-macros-2.2.0...tokio-macros-2.3.0 )
Updates `wayland-backend` from 0.3.3 to 0.3.4
- [Release notes](https://github.com/smithay/wayland-rs/releases )
- [Changelog](https://github.com/Smithay/wayland-rs/blob/master/historical_changelog.md )
- [Commits](https://github.com/smithay/wayland-rs/commits )
---
updated-dependencies:
- dependency-name: parking_lot
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: tokio
dependency-type: direct:production
update-type: version-update:semver-minor
dependency-group: patch-updates
- dependency-name: syn
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: backtrace
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: bytemuck_derive
dependency-type: indirect
update-type: version-update:semver-minor
dependency-group: patch-updates
- dependency-name: crc32fast
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: deno_unsync
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: gimli
dependency-type: indirect
update-type: version-update:semver-minor
dependency-group: patch-updates
- dependency-name: objc-sys
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: object
dependency-type: indirect
update-type: version-update:semver-minor
dependency-group: patch-updates
- dependency-name: plotters
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: plotters-backend
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: plotters-svg
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: polling
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: proc-macro2
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: tokio-macros
dependency-type: indirect
update-type: version-update:semver-minor
dependency-group: patch-updates
- dependency-name: wayland-backend
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-06-03 09:20:29 +02:00
Vecvec
7954a6bd3e
Add missing acceleration structure buffer flag ( #5760 )
...
* add the missing acceleration structure buffer flag
* fmt
2024-06-02 07:59:41 +00:00
Kevin Reid
e7a528b62b
Document WebGPU spec rule that an Adapter
should be used only once. ( #5764 )
2024-06-01 01:25:42 +00:00
Connor Fitzgerald
c7458638d1
[hal/vk] Rework Submission and Surface Synchronization ( #5681 )
...
Fix two major synchronization issues in `wgpu_val::vulkan`:
- Properly order queue command buffer submissions. Due to Mesa bugs, two semaphores are required even though the Vulkan spec says that only one should be necessary.
- Properly manage surface texture acquisition and presentation:
- Acquiring a surface texture can return while the presentation engine is still displaying the texture. Applications must wait for a semaphore to be signaled before using the acquired texture.
- Presenting a surface texture requires a semaphore to ensure that drawing is complete before presentation occurs.
Co-authored-by: Jim Blandy <jimb@red-bean.com>
2024-05-30 13:53:34 -07:00
Brad Werth
9b7a965667
Add an experimental vertex pulling flag to Metal pipelines.
...
This proves a flag in msl::PipelineOptions that attempts to write all
Metal vertex entry points to use a vertex pulling technique. It does
this by:
1) Forcing the _buffer_sizes structure to be generated for all vertex
entry points. The structure has additional buffer_size members that
contain the byte sizes of the vertex buffers.
2) Adding new args to vertex entry points for the vertex id and/or
the instance id and for the bound buffers. If there is an existing
@builtin(vertex_index) or @builtin(instance_index) param, then no
duplicate arg is created.
3) Adding code at the beginning of the function for vertex entry points
to compare the vertex id or instance id against the lengths of all the
bound buffers, and force an early-exit if the bounds are violated.
4) Extracting the raw bytes from the vertex buffer(s) and unpacking
those bytes into the bound attributes with the expected types.
5) Replacing the varyings input and instead using the unpacked
attributes to fill any structs-as-args that are rebuilt in the entry
point.
A new naga test is added which exercises this flag and demonstrates the
effect of the transform. The msl generated by this test passes
validation.
Eventually this transformation will be the default, always-on behavior
for Metal pipelines, though the flag may remain so that naga
translation tests can be run with and without the tranformation.
2024-05-30 13:08:59 +02:00
Schell Carl Scivally
480d4dbd73
spv-in parsing Op::AtomicIIncrement ( #5702 )
...
Parse spirv::Op::AtomicIIncrement, add atomic_i_increment test.
2024-05-30 04:39:32 +00:00
Mads Marquart
60a14c67fb
Remove the link
Cargo feature ( #5752 )
2024-05-29 15:55:33 -07:00
Andreas Reich
588950110a
Remove lifetime dependency of ComputePass
to its parent command encoder ( #5620 )
...
* lift encoder->computepass lifetime constraint and add now failing test
* compute passes now take an arc to their parent command encoder, thus removing compile time dependency to it
* Command encoder goes now into locked state while compute pass is open
* changelog entry
* share most of the code between get_encoder and lock_encoder
2024-05-29 22:43:24 +00:00
Douglas Dwyer
071fb14e15
Add support for pipeline-overridable constants in web backend ( #5688 )
...
* Add support for pipeline-overridable constants in WebGPU
* Add utility function for setting constants map
* Panic on failure to set constants map
---------
Co-authored-by: Andreas Reich <r_andreas2@web.de>
2024-05-29 19:33:04 +00:00
Valaphee The Meerkat
23307e1dc3
gles: Return the version as driver_info ( #5753 )
2024-05-29 14:01:32 -04:00
Vladas Zakrevskis
de809c8f96
Fix missing family check flag ( #5754 )
...
Co-authored-by: Jim Blandy <jimb@red-bean.com>
Co-authored-by: Xiaopeng Li <x.friday@outlook.com>
Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
Co-authored-by: Samson <16504129+sagudev@users.noreply.github.com>
Co-authored-by: Valaphee The Meerkat <32491319+valaphee@users.noreply.github.com>
Co-authored-by: Andreas Reich <r_andreas2@web.de>
2024-05-29 14:00:32 -04:00
Teodor Tanasoaia
b5b39f670d
remove redundant code in module interface validation
...
`TypeInner.size()` already handles the array case
2024-05-28 14:09:56 -04:00
Jim Blandy
89a0ebfbd6
[naga] Test CallResult
and AtomicResult
population.
...
Add tests to ensure that validation checks that `CallResult` and
`AtomicResult` expressions actually have their values provided by
`Call` and `Atomic` statements, and not `Emit` statements.
2024-05-28 09:17:16 +02:00
Jim Blandy
59cd0e964b
[naga] Validate CallResult
and AtomicResult
population.
...
Validate that `CallResult` and `AtomicResult` expressions actually
have their values provided by `Call` and `Atomic` statements, and not
`Emit` statements.
Fixes #5740 .
2024-05-28 09:17:16 +02:00
dependabot[bot]
d9c054c645
build(deps): bump the patch-updates group with 19 updates ( #5720 )
...
Bumps the patch-updates group with 19 updates:
| Package | From | To |
| --- | --- | --- |
| [anyhow](https://github.com/dtolnay/anyhow ) | `1.0.83` | `1.0.86` |
| [bytemuck](https://github.com/Lokathor/bytemuck ) | `1.15.0` | `1.16.0` |
| [libc](https://github.com/rust-lang/libc ) | `0.2.154` | `0.2.155` |
| [raw-window-handle](https://github.com/rust-windowing/raw-window-handle ) | `0.6.1` | `0.6.2` |
| [serde](https://github.com/serde-rs/serde ) | `1.0.201` | `1.0.202` |
| [thiserror](https://github.com/dtolnay/thiserror ) | `1.0.60` | `1.0.61` |
| [syn](https://github.com/dtolnay/syn ) | `2.0.63` | `2.0.65` |
| [cc](https://github.com/rust-lang/cc-rs ) | `1.0.97` | `1.0.98` |
| [crossbeam-utils](https://github.com/crossbeam-rs/crossbeam ) | `0.8.19` | `0.8.20` |
| [either](https://github.com/rayon-rs/either ) | `1.11.0` | `1.12.0` |
| [instant](https://github.com/sebcrozet/instant ) | `0.1.12` | `0.1.13` |
| [linux-raw-sys](https://github.com/sunfishcode/linux-raw-sys ) | `0.4.13` | `0.4.14` |
| [miniz_oxide](https://github.com/Frommi/miniz_oxide ) | `0.7.2` | `0.7.3` |
| [proc-macro2](https://github.com/dtolnay/proc-macro2 ) | `1.0.82` | `1.0.83` |
| [rustversion](https://github.com/dtolnay/rustversion ) | `1.0.16` | `1.0.17` |
| [serde_derive](https://github.com/serde-rs/serde ) | `1.0.201` | `1.0.202` |
| [smol_str](https://github.com/rust-analyzer/smol_str ) | `0.2.1` | `0.2.2` |
| [thiserror-impl](https://github.com/dtolnay/thiserror ) | `1.0.60` | `1.0.61` |
| [toml_datetime](https://github.com/toml-rs/toml ) | `0.6.5` | `0.6.6` |
Updates `anyhow` from 1.0.83 to 1.0.86
- [Release notes](https://github.com/dtolnay/anyhow/releases )
- [Commits](https://github.com/dtolnay/anyhow/compare/1.0.83...1.0.86 )
Updates `bytemuck` from 1.15.0 to 1.16.0
- [Changelog](https://github.com/Lokathor/bytemuck/blob/main/changelog.md )
- [Commits](https://github.com/Lokathor/bytemuck/compare/v1.15.0...v1.16.0 )
Updates `libc` from 0.2.154 to 0.2.155
- [Release notes](https://github.com/rust-lang/libc/releases )
- [Commits](https://github.com/rust-lang/libc/compare/0.2.154...0.2.155 )
Updates `raw-window-handle` from 0.6.1 to 0.6.2
- [Release notes](https://github.com/rust-windowing/raw-window-handle/releases )
- [Changelog](https://github.com/rust-windowing/raw-window-handle/blob/master/CHANGELOG.md )
- [Commits](https://github.com/rust-windowing/raw-window-handle/compare/v0.6.1...v0.6.2 )
Updates `serde` from 1.0.201 to 1.0.202
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.201...v1.0.202 )
Updates `thiserror` from 1.0.60 to 1.0.61
- [Release notes](https://github.com/dtolnay/thiserror/releases )
- [Commits](https://github.com/dtolnay/thiserror/compare/1.0.60...1.0.61 )
Updates `syn` from 2.0.63 to 2.0.65
- [Release notes](https://github.com/dtolnay/syn/releases )
- [Commits](https://github.com/dtolnay/syn/compare/2.0.63...2.0.65 )
Updates `cc` from 1.0.97 to 1.0.98
- [Release notes](https://github.com/rust-lang/cc-rs/releases )
- [Commits](https://github.com/rust-lang/cc-rs/compare/1.0.97...1.0.98 )
Updates `crossbeam-utils` from 0.8.19 to 0.8.20
- [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.19...crossbeam-utils-0.8.20 )
Updates `either` from 1.11.0 to 1.12.0
- [Commits](https://github.com/rayon-rs/either/compare/1.11.0...1.12.0 )
Updates `instant` from 0.1.12 to 0.1.13
- [Changelog](https://github.com/sebcrozet/instant/blob/master/CHANGELOG.md )
- [Commits](https://github.com/sebcrozet/instant/commits )
Updates `linux-raw-sys` from 0.4.13 to 0.4.14
- [Commits](https://github.com/sunfishcode/linux-raw-sys/compare/v0.4.13...v0.4.14 )
Updates `miniz_oxide` from 0.7.2 to 0.7.3
- [Changelog](https://github.com/Frommi/miniz_oxide/blob/master/CHANGELOG.md )
- [Commits](https://github.com/Frommi/miniz_oxide/compare/0.7.2...0.7.3 )
Updates `proc-macro2` from 1.0.82 to 1.0.83
- [Release notes](https://github.com/dtolnay/proc-macro2/releases )
- [Commits](https://github.com/dtolnay/proc-macro2/compare/1.0.82...1.0.83 )
Updates `rustversion` from 1.0.16 to 1.0.17
- [Release notes](https://github.com/dtolnay/rustversion/releases )
- [Commits](https://github.com/dtolnay/rustversion/compare/1.0.16...1.0.17 )
Updates `serde_derive` from 1.0.201 to 1.0.202
- [Release notes](https://github.com/serde-rs/serde/releases )
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.201...v1.0.202 )
Updates `smol_str` from 0.2.1 to 0.2.2
- [Commits](https://github.com/rust-analyzer/smol_str/commits/v0.2.2 )
Updates `thiserror-impl` from 1.0.60 to 1.0.61
- [Release notes](https://github.com/dtolnay/thiserror/releases )
- [Commits](https://github.com/dtolnay/thiserror/compare/1.0.60...1.0.61 )
Updates `toml_datetime` from 0.6.5 to 0.6.6
- [Commits](https://github.com/toml-rs/toml/compare/toml_datetime-v0.6.5...toml_datetime-v0.6.6 )
---
updated-dependencies:
- dependency-name: anyhow
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: bytemuck
dependency-type: direct:production
update-type: version-update:semver-minor
dependency-group: patch-updates
- dependency-name: libc
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: raw-window-handle
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: thiserror
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: syn
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-utils
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: either
dependency-type: indirect
update-type: version-update:semver-minor
dependency-group: patch-updates
- dependency-name: instant
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: linux-raw-sys
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: miniz_oxide
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: proc-macro2
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: rustversion
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: smol_str
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: thiserror-impl
dependency-type: indirect
update-type: version-update:semver-patch
dependency-group: patch-updates
- dependency-name: toml_datetime
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-05-26 18:34:50 +02:00
dependabot[bot]
665e35d5a5
build(deps): bump JamesIves/github-pages-deploy-action ( #5719 )
...
Bumps [JamesIves/github-pages-deploy-action](https://github.com/jamesives/github-pages-deploy-action ) from 4.6.0 to 4.6.1.
- [Release notes](https://github.com/jamesives/github-pages-deploy-action/releases )
- [Commits](https://github.com/jamesives/github-pages-deploy-action/compare/v4.6.0...v4.6.1 )
---
updated-dependencies:
- dependency-name: JamesIves/github-pages-deploy-action
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>
Co-authored-by: Andreas Reich <r_andreas2@web.de>
2024-05-26 18:32:06 +02:00
Samson
dfd912ec6f
Make DeviceLostReason
serializable and deserializable. ( #5732 )
2024-05-26 09:07:06 +02:00
Jason de Wolff
cd744ef68b
Buffer as hal ( #5724 )
...
* Add `as_hal` for `Buffer`
* fmt & CHANGELOG.md update
* Update CHANGELOG.md
* fixed callback name
* allow nested buffer as_hal callbacks
2024-05-26 08:58:30 +02:00
Bruce Mitchener
b4abd65659
chore: Fix more unused_qualifications
( #5746 )
2024-05-26 08:37:53 +02:00
Bruce Mitchener
7368e5107c
chore: Fix legacy_numeric_constants
lints ( #5747 )
...
These are being deprecated in the future in favor of the associated
constants (which are already being used in some code here), so this
consistently uses the preferred forms.
2024-05-26 08:36:19 +02:00
Bruce Mitchener
5da72a94d5
Prefer default-features
instead of default_features
( #5745 )
2024-05-26 04:33:02 +00:00
Andreas Reich
2fd09945cd
Make compute pass end consume the pass ( #5575 )
...
* rename `command_encoder_run_*_pass` to `*_pass_end` and make it a method of compute/render pass instead of encoder
* executing a compute pass consumes it now such that it can't be executed again
* use handle_error instead of handle_error_nolabel for wgpu compute pass
* use handle_error instead of handle_error_nolabel for render_pass_end
* changelog addition
* feat: `compute_pass_set_push_constant`: move panics to error variants
Co-Authored-By: Erich Gubler <erichdongubler@gmail.com>
---------
Co-authored-by: Erich Gubler <erichdongubler@gmail.com>
2024-05-25 18:54:48 +02:00
Jim Blandy
aaefc7c10d
[naga] Fix cargo doc --document-private-items
. Add to CI.
2024-05-24 10:38:06 +02:00
Jim Blandy
9e0fd17726
[hal] Document resource destruction methods, and a few other things. ( #5627 )
...
Document some more safety expectations for
- resource destruction methods
- `CommandEncoder` methods
- `Queue::submit`
Document `Fence` creation a bit.
Document the `Queue` trait a bit.
Document `vulkan` shader module handling a bit.
2024-05-23 22:39:56 +00:00
Jim Blandy
b898cdf908
[naga spv-in] Doc fix: Parser
-> Frontend
...
Fix documentation left unchanged when `Parser` was renamed to
`Frontend`.
2024-05-23 12:59:11 +02:00
Daniel McNab
9f74b15f0c
Remove historical comment in rust-toolchain.toml
...
A version of rustup which doesn't understand toml-formatted `rust-toolchain` files won't be looking in `rust-toolchain.toml`
The file was renamed to `rust-toolchain.toml` in #4204
rust-toolchain.toml support was added in rustup 1.23, which was released
on 2020-11-27 [1], 3 and a half years ago.
[1]: https://blog.rust-lang.org/2020/11/27/Rustup-1.23.0.html
2024-05-22 09:49:35 -04:00