* Add 'SampledImage::sample_by_lod'
* Add a compiletest
* Format the compiletest, but manually because running cargo fmt doesn't seem to do anything 🤷
* Run rustfmt
* Convert Image<> parameters from enums to integers to make spirv-std build on stable
* Remove access_qualifier from Image type
It's kernel-mode-only, and we won't ever support kernel mode.
* Implement OpTypeMatrix
* clippy
* Use cached Symbol
* Implement #[spirv(matrix(ty, m, n))] instead of Matrix trait
* Update #[spirv(matrix(..))]
- #[spirv(matrix(ty, m, n))]
Specify all of type, rows, columns.
- #[spirv(matrix(ty, m))]
Specify all of type, rows. Infer columns.
- #[spirv(matrix(ty))]
Specify all of type. Infer others.
- #[spirv(matrix)]
Infer all.
* Drop #[spirv(matrix(..))] (with arguments)
* Fix IntrinsicType::Matrix type construction
* Update matrix-type.rs
* Update tests/ui/spirv-attr/multiple.rs to test Matrix
* Fix tests/ui/spirv-attr/matrix-type.rs
* Add failing tests for #[spirv(matrix)
* Update error messages for #[spirv(matrix)]
* Various fixes and cleanup
While working on other patches that ended up not being applicable, I've
gathered these changes unrelated to the irrelevant patch. So, submitting
them as a seperate change, since the bigger change isn't going in.
* Revert change superseded by #732
* asm: add support for noreturn option
OpUnreachable will be appended as terminator at the end of the asm block.
* asm: implicit label after return or abort terminator
* rework handling
* fix tests and add few comments
* fix tests
* Add sample_bias function
* Update line numbers
* Add gather function
* Update spirv-tools
CI was failing on "Capability SampledRect is not allowed by Vulkan 1.1
specification (or requires extension)", except locally it was fine, and
I have more up to date spirv-tools than CI, so try bumping the CI
version to see if it's just an out-of-date spirv-val
* Fix gather() in vulkan
* Convert compiler valication into marker traits
* Added an optimization that gets rid of temporary composites.
Those temporary composites result from inlining of multi-argument
closures. Not only are they rather useless, they're also sometimes
invalid, when an argument to said closure is e.g. a pointer.
* Correctness fixes to transitive unused removal:
- delay only if the instruction is in reference set
- properly mark composites being inserted into composites as used
* cargo fmt
* clippy
* Make transformation per-function & rely on DCE for eliminating dead constructs.
* Forgot to mark CompositeInsert as pure & additional line cleaning
* Rustfmt
* Remove duplicate lines only once
* Aggressively prune no-side-effect instructions during DCE.
Since we're walking all the instructions anyway, it's practically
zero-cost.
* Reverse iteration order within a function.
This allows to root more instructions per `spread_roots`
invocation, becoming zero-cost in absence of loops.
* Manually iterate over function instructions in reverse order.
Not actually many interesting things here, just cleaning up some crud
from previous work where things were added/removed without full
knowledge of the surrounding code, so it becomes a bit of a "wait, why
the heck is it done this way" confusing mess for those trying to
understand it for the first time.
* Clean up the interface of the watching support
This allows us to avoid the seperate thread just for looping through
the graphics rx to the eventloop, for example
In almost all cases, intial results are blocked on the first result, and
then needs notifications for later changes
* Fix test failures
* fmt
* Remove the comment again
* Update builder to use a shared validation method
* Add the error for using print_metadata and watching
We cannot use print_metadata with watching
because print_metadata only makes sense
in build scripts, but watching does not
and would instead stall the script
* Add the initial implementation of watching
* Make hot reloading work in the wgpu example
* Attempt to address CI failures
* Add exception for notify CC0-1.0 license
* Address review comments
Co-authored-by: khyperia <github@khyperia.com>
* Added read_subpass for SubpassData images, and necessary attrs for it.
* Fix CI; test bless + rustfmt
* Rename attachment_index => input_attachment_index.
* Rustfmt
* Fix clippy warning.
* Review: check for cap rather than adding cap, fix error messages.
`v0` mangling mangles generics, but can only handle const generic
arguments of simple types. As `Image!` types use const generic enums,
things break horribly and compiler panics.
`legacy` doesn't even attempt to mangle generics, which is probably
fine.
This adds the initial support for basic bindless types into rust-gpu. Using this requires a compilation with the `-Ctarget-features=+bindless` flag, or through `.bindless` in the `SpirvBuilder`.