Skip to content

Issue 1534's array types differ on stride - #1943

Closed
dneto0 wants to merge 7 commits into
gpuweb:mainfrom
dneto0:issue-1534-array-types-differ-on-stride
Closed

Issue 1534's array types differ on stride#1943
dneto0 wants to merge 7 commits into
gpuweb:mainfrom
dneto0:issue-1534-array-types-differ-on-stride

Conversation

@dneto0

@dneto0 dneto0 commented Jul 14, 2021

Copy link
Copy Markdown
Contributor

This builds on #1792, and is really only the last commit in the chain.

dneto0 added 7 commits July 14, 2021 15:06
It's still an i32; it was only ever an INT_LITERAL in the first place.

Fixed: gpuweb#1431
Not just pipeline-overridable
Remove matrix, array, and nested structs

Fixes: gpuweb#1877
- rename "array size" in many places to the more specific term
  "element count"
- element count may be an unsigned integer literal, as per gpuweb#1135
- describe array type matching in the positive sense, and as an
  if-and-only-if set of rules.
- update example to show array size with unsigned integer literal.
- Reword array layout to make "element stride" a defined term, and
  separately write out how its value is determined.
@dneto0

dneto0 commented Jul 14, 2021

Copy link
Copy Markdown
Contributor Author

This would resolve the only current case for #1534

@github-actions

Copy link
Copy Markdown
Contributor

Previews, as seen when this build job started (423d354):
WebGPU | IDL
WGSL
Explainer

@kvark kvark left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

last commit LGTM

@kdashg kdashg changed the title Issue 1534 array types differ on stride Issue 1534's array types differ on stride Jul 20, 2021
@kdashg

kdashg commented Aug 9, 2021

Copy link
Copy Markdown
Contributor
WGSL meeting minutes 2021-08-03
  • RM: I’ve been trying to understand this. Is it saying that arrays with different strides are the same types? Or the same types? What about runtime sized arrays?
  • DM: This is saying they are different types. Runtime sized arrays cannot be assigned or passed as arguments.
  • AB: We’re still discussing internally.
  • AB: We are discussing whether or not an attribute should have the power to be part of the identity of a type.
  • DM: You’ve been on a crusade against attributes on types
  • AB: There are only 2 left! Maybe we can get rid of [[block]]!!
  • MM: YES PLEASE
  • BC: That would be great but it’s hard
  • AB: THere might be ways of working around it, but describing it would exceed the time sandbox
  • BC: What does naga do? Are they different types?
  • DM: They are different types
  • BC: That matches us
  • AB: If we pull the attribute into the type, that’s a larger change.
  • [Deferred until next week. Google needs more internal discussion]

@kdashg

kdashg commented Aug 10, 2021

Copy link
Copy Markdown
Contributor
WGSL meeting minutes 2021-08-10
  • [Deferred until this week. Google needs more internal discussion]
  • Tabled indefinitely, Google to revive discussion when ready

@kainino0x kainino0x added the wgsl WebGPU Shading Language Issues label Nov 1, 2021
@dneto0 dneto0 mentioned this pull request Jan 10, 2022
@dneto0

dneto0 commented Jan 19, 2022

Copy link
Copy Markdown
Contributor Author

Closing, since the stride of an array only depends on its element type.
The stride attribute was removed. #2503

@dneto0 dneto0 closed this Jan 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

wgsl WebGPU Shading Language Issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants