Commit Graph

757 Commits

Author SHA1 Message Date
khyperia
df5b41137b Cargo update 2021-08-12 17:16:07 +03:00
Ashley Hauck
44c9fdd8c5
Release v0.4.0-alpha.12 (#719) 2021-08-12 10:46:32 +00:00
Eduard-Mihai Burtescu
908499744f spirv-builder: switch to \x1f-separated CARGO_ENCODED_RUSTFLAGS. 2021-08-10 16:53:28 +03:00
Eduard-Mihai Burtescu
7501f1895c rustup: update to nightly-2021-08-10. 2021-08-10 16:53:28 +03:00
Ashley Hauck
1a3a12f505
Implement some float packing/unpacking instructions (#709)
* Implement some float packing/unpacking instructions

* Rename f32xN to vecN in packing functions
2021-08-10 13:54:44 +02:00
Markus Siglreithmaier
46c9ea0c9c
book: Add section for storage class interference (#714)
* book: add section for workgroup memory

* book: add section regarding storage class interference
2021-08-10 11:21:49 +00:00
Eduard-Mihai Burtescu
7f5e2e778e Fix unit tests to not have dead params. 2021-08-10 12:43:15 +03:00
Eduard-Mihai Burtescu
cf56b95dc1 Add #[track_caller] test. 2021-08-10 12:43:15 +03:00
Eduard-Mihai Burtescu
0bbea9e93e Introduce remove_unused_params pass, to run just before zombie removal. 2021-08-10 12:43:15 +03:00
Eduard-Mihai Burtescu
5e23a73c85 Move CallGraph into a new ipo module. 2021-08-10 12:43:15 +03:00
Eduard-Mihai Burtescu
f951203534 Add test accounting for https://github.com/rust-lang/rust/pull/87723. 2021-08-10 10:55:39 +03:00
Eduard-Mihai Burtescu
340816ae75 abi: make dig_scalar_pointee search for offsets in all layout fields. 2021-08-10 10:55:39 +03:00
Eduard-Mihai Burtescu
7393c3884f abi: switch scalar_pair_field_index to an offset. 2021-08-10 10:55:39 +03:00
Eduard-Mihai Burtescu
c1cdc4707c abi: use scalar_pair_field_index instead of index in some places. 2021-08-10 10:55:39 +03:00
Markus Siglreithmaier
2ddae102eb
book: add section for workgroup memory (#713) 2021-08-10 08:32:51 +02:00
Ashley Hauck
12c09cbc5a
Remove implicit bindless and kernel modes (#710)
* Remove +bindless mode

* Remove +kernel mode
2021-08-10 08:23:24 +02:00
Ashley Hauck
a43a174220
Ignore tar vulnerability (#708) 2021-08-09 09:15:29 +00:00
Daniel McNab
9fcc4824af
Use just the small version (#705) 2021-08-09 08:58:52 +02:00
Ashley Hauck
a93d6e0f2a
Add sample_bias and gather functions (#704)
* 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
2021-08-06 15:26:30 +02:00
Alex Es
bca7656c8c
Added a transformation that gets rid of temporary composites. (#690)
* 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
2021-08-06 10:52:56 +02:00
Alex Es
d548268140
Aggressively prune no-side-effect instructions during DCE. (#691)
* 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.
2021-08-04 08:03:38 +00:00
bjorn3
cccb9737d7
Use DefaultMetadataLoader for loading dylib metadata (#698) 2021-08-03 10:20:46 +00:00
hatoo
710e6ab4d6
Fix example-runner-ash (#693)
* Fix example-runner-ash

Fix compile_shaders() to return correct shader name.

* Refactor example-runner-ash

- Stop to get shader name from path. It was too complicated.
2021-08-03 08:03:36 +00:00
hatoo
d77cc6d360
Fix example-runner-ash's validation layer errors (#700) 2021-08-03 07:57:24 +00:00
Ashley Hauck
819365cbae
Release v0.4.0-alpha.11 (#702) 2021-08-02 14:02:02 +00:00
Ashley Hauck
62799d06cc
Make BuilderSpirv::has_capability and has_extension O(1) (#688) 2021-08-02 13:13:48 +02:00
Ashley Hauck
ca53cbefd8
Fix android CI (#701) 2021-08-02 11:00:25 +02:00
Gray Olson
b9867d0e84
add vision & contribution guidelines to readme (#687) 2021-06-28 08:29:47 +02:00
Eduard-Mihai Burtescu
f224b5aa1a tests: update the documented error counts in ui/spirv-attr/invalid-target. 2021-06-24 18:10:32 +03:00
khyperia
febd253d7b Bypass rspirv O(n^2) deduplication 2021-06-24 16:55:40 +03:00
Daniel McNab
7974817539
Upgrade wgpu (#676)
* Use the workaround from

https://github.com/gfx-rs/wgpu/issues/1374#issuecomment-839359307

* Upgrade to wgpu 0.9

We can't remove MPL from the deny.toml yes, as wgpu-subscriber
is still MPL

* swap to env-logger and log in all example paths

This also does let us remove MPL-2.0

As of https://github.com/EmbarkStudios/rust-gpu/pull/674, the crate of the
advisory is no longer in our tree

* Add a workaround for our *erm* strange codegen
2021-06-23 12:28:20 +02:00
Ashley Hauck
06f0aa2c3a
Release v0.4.0-alpha.10 (#679) 2021-06-23 09:32:09 +02:00
Ashley Hauck
428824be94
Add option to treat warnings as errors (#683) 2021-06-22 13:44:51 +00:00
Ashley Hauck
22e4bf4022
Clarify and fix up some image documentation (#678) 2021-06-21 14:31:33 +02:00
evopen
8c05636f53
fix NO_SPIRV_OPT (#675) 2021-06-19 19:01:27 +02:00
Ashley Hauck
8924fe7b4c
Clean up DUMP environment variables (#673) 2021-06-17 17:07:35 +02:00
Ashley Hauck
1cef56bcf3
Cargo update (#674) 2021-06-17 17:06:26 +02:00
khyperia
efd97e6d22 Fix issue with --disassemble-entry 2021-06-17 18:03:38 +03:00
Ashley Hauck
db5e5fd336
rustup update and embark standard lints v0.4 (#672)
* rustup update

* update to embark standard lints v0.4
2021-06-17 13:10:19 +02:00
Ashley Hauck
04dfa80266
Nuke arithmetic.rs (#666) 2021-06-15 09:43:13 +02:00
Ashley Hauck
f7ac6a09e7
Small linker refactorings (#664)
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.
2021-06-15 09:20:03 +02:00
Ashley Hauck
fff2b9bce1
Add common image type aliases (#662) 2021-06-15 09:19:40 +02:00
Ashley Hauck
e1a000d408
Nuke const generics feature (#661)
* Nuke const generics feature

* Remove spirv(image_type) attribute
2021-06-15 09:19:23 +02:00
Daniel McNab
e66e72b049
Fix the output filename collision warning (#669)
This works simply by naming the binary crate
anything other than the name of the lib, which is example-runner-wgpu
As far as I know, the warning started in
https://github.com/EmbarkStudios/rust-gpu/pull/215

Since there is only one binary crate in the package, the command
(`cargo run -p example-runner-wgpu --release`)
maintains the same behaviour

The cargo issue is https://github.com/rust-lang/cargo/issues/6313

This warning caused problems for me in testing
https://github.com/Lokathor/bytemuck/pull/67
since I didn't notice the warning that my patch was not applied
2021-06-14 09:22:29 +02:00
Daniel McNab
364590e05f
Use bytemuck for the push constants (#668)
* Use bytemuck for the push constants

* Use the released version of bytemuck

https://github.com/Lokathor/bytemuck/pull/69 landed

That version also works 🎉
2021-06-14 09:20:55 +02:00
Daniel McNab
4b2011476b
Clean up the interface of the watching support (#663)
* 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
2021-06-14 09:19:41 +02:00
Eduard-Mihai Burtescu
95bc1914e2
compiletests: add missing use spirv_std as _; imports. (#665) 2021-06-11 08:36:03 +00:00
Ashley Hauck
c3eff4d4a5
Add name_variables option to spirv-builder (#660) 2021-06-09 15:27:08 +02:00
Ashley Hauck
b072b5ebdc
Nuke the old structurizer (#658) 2021-06-09 12:22:04 +02:00
Ashley Hauck
c829157b8b
Fix up some outdated documentation (#650) 2021-06-09 12:21:42 +02:00