-
Notifications
You must be signed in to change notification settings - Fork 963
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add parsing support for un/pack4xI/U8 #5424
Conversation
I have no idea how to use those magic words that make the spir-v backend, so I really would appreciate some help here |
I would look at some of the existing polyfills. For ex.: wgpu/naga/src/back/spv/block.rs Line 734 in c613fbb
wgpu/naga/src/back/spv/block.rs Line 987 in c613fbb
|
80aec2c
to
89a8b16
Compare
@teoxoy Hey, it's been a week since this pr has been finished. Do I need to signal someone that it's ready ready or just wait for it to be reviewed, squashed and merged? |
It's on my radar, there have been other PRs that need/needed attention as well. |
I squashed all the commits, rebased and extracted the match refactor to make it easier to review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since the code for the MSL, GLSL and HLSL backends is the same, we should try to put it in the back
module instead.
5a2c551
to
7d48c17
Compare
It would be great if you could put together some execution tests that make sure the polyfills work properly. There are some existing ones at this path: https://github.com/gfx-rs/wgpu/tree/54740d5982fa5ae004eee95dd6c037356ce9ea17/tests/tests/shader. |
a10a80c
to
85f1046
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small nits, but wgpu/test side looks good, by and large!
Sorry for the delay on the naga review, all the naga reviewers are pretty busy right now.
(Reminder: please re-request a review from me once the changes are addressed to make sure I see it!)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved from wgpu side :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
Could you squash the last 3 commits so that we end up with the refactor + the implementation? We can then land this without squashing it. |
Done |
Connections
Description
WGSL spec defined new builtin functions. This PR tries to implement them
Current writer impls:
Testing
I think I added the necessary tests to
naga/tests/in/bits.wgsl
.Checklist
cargo fmt
.cargo clippy
. If applicable, add:--target wasm32-unknown-unknown
--target wasm32-unknown-emscripten
cargo xtask test
to run tests.CHANGELOG.md
. See simple instructions inside file.