-
Notifications
You must be signed in to change notification settings - Fork 953
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
Make shader write&read storage buffers match non readonly layouts #3893
Make shader write&read storage buffers match non readonly layouts #3893
Conversation
After doing this, I realised that perhaps write-only storage buffers are not allowed in WGSL? From https://www.w3.org/TR/WGSL/#storage-buffer:
If so, should #2897 be closed instead? |
Welp, lets go ahead and merge this as it fixes the current behavior, thanks! But apparently they aren't anymore. There was never really a point, but whatever. Removing that is a separate issue. |
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.
Some small nits, but code looks good
@cwfitzgerald Thanks for the feedback! I addressed your comments, you could re-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.
Great, thanks!
…outs (gfx-rs#3893)" This reverts commit 17143c1.
Checklist
cargo clippy
.cargo clippy --target wasm32-unknown-unknown
if applicable.Connections
See #2897, write-only storage buffer cannot match a Pipeline Layout.
Description
From the linked issue: When you provide a storage buffer pipeline layout with read-only set to false, if the shader marks the buffer is write, it will complain about a mismatched PLL and shader
Testing
Mark a storage storage buffer as
write
in a shader, and use it with a buffer pipeline layout with read-only set to false. There is also a unit test of theaddress_space_matches
function.