-
Notifications
You must be signed in to change notification settings - Fork 193
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
[hlsl-out] Insert padding between struct members #1786
Conversation
I noticed |
Is that not defined in the spec? we shouldn't expose f16 (or half) until we figure out the details on how it maps to HLSL. |
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.
Thank you for the PR!
DXC requires the Maybe a better way to do this would be to check if the struct contains a member with a What do you think? |
@teoxoy sounds like a reasonable proposal! |
so, should I open a new PR implementing that logic? |
If you feel that the FP16 spec has issues with |
I looked into this some more and it looks like the WGSL FP16 extension will require generation of DXIL (comment, slide). So I guess when we start implementing the extension, we will just fail if we try to target the HLSL backend when the extension is required. |
we'll just not expose it on DX12 until we are able to generate DXIL |
fixes #1783
With this fix WGSL's
align
&size
attributes and also spir-v'sOffset
decoration are respected since the offset in the IR is affected by those.