-
Notifications
You must be signed in to change notification settings - Fork 335
Allow index < limits.maxBindGroups
in getBindGroupLayout()
#5042
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
Allow index < limits.maxBindGroups
in getBindGroupLayout()
#5042
Conversation
This patch relaxes the check on the parameter `index` in `getBindGroupLayout()` by allowing `index < limits.maxBindGroups` instead of only limiting `index` must be less than the array size of the bind group layouts used in the creation of the pipeline.
Previews, as seen when this build job started (f8a2c1c): |
LGTM. @jimblandy @mwyrzykowski PTAL as well! This is a small improvement found while implementing the "empty BGLs are equivalent to null" in Dawn. Basically any BGL in the pipeline is fine to query, even once past what's specified in the pipeline layout, because it's as if they are null/empty. |
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.
LGTM % working group approval; this makes more sense to me, we shouldn't treat the end of the array differently from other holes.
The build errors are not related to this PR. @kainino0x PTAL, thanks! |
@Jiawei-Shao I created #5046 to address WGSL part of the build issues, thank you for pointing out the presence |
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.
It's technically a breaking change but any site depending on such behavior seems quite unlikely.
Did we notice any CTS differences or sites which break due to this? I imagine not, I think this is fine.
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 in WG meeting. LGTM
Build is broken right now so I'll bypass those checks.
GPU Web WG 2025-01-22 Atlantic-time
|
This patch relaxes the check on the parameter
index
ingetBindGroupLayout()
by allowingindex < limits.maxBindGroups
instead of only limitingindex
must be less than the array size of the bind group layouts used in the creation of the pipeline.