Skip to content
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

spv-out: support version 1.4 #2230

Merged
merged 2 commits into from
Feb 1, 2023
Merged

spv-out: support version 1.4 #2230

merged 2 commits into from
Feb 1, 2023

Conversation

kvark
Copy link
Member

@kvark kvark commented Jan 31, 2023

Looks like 1.4 expects all global variables to be a part of the interface:

Starting with version 1.4, the interface’s storage classes are all storage classes used in declaring all global variables referenced by the entry point’s call tree.

@kvark kvark mentioned this pull request Jan 31, 2023
11 tasks
tests/snapshots.rs Show resolved Hide resolved
src/back/spv/writer.rs Show resolved Hide resolved
@kvark
Copy link
Member Author

kvark commented Jan 31, 2023

@teoxoy unfortunately the test validation is blocked on a thing. Our make validate-spv has "vulkan1.0" environment hard-coded currently, so it doesn't pass validation. We need to select the environment based on the SPV version that we generate. We could do this, for example, by changing the naming scheme ("xxx.spv14asm"), or by having sub-folders inside, e.g "tests/out/spv/1.4".

@teoxoy
Copy link
Member

teoxoy commented Jan 31, 2023

I think it would be feasible to read the version from the file and map it to a vulkan version but that sounds quite involved.
We can go with a sub-folder for now - up to you.

@kvark
Copy link
Member Author

kvark commented Jan 31, 2023

I think we should just merge this with some sort of a workaround, not blocking for a general solution (be it subfolders or not). Even without a test would be fine, since it's not a regression.

@kvark kvark force-pushed the spv1.4 branch 11 times, most recently from 8ac533c to b7e5742 Compare February 1, 2023 06:52
@kvark
Copy link
Member Author

kvark commented Feb 1, 2023

@teoxoy PR now comes with the general solution that extracts SPV version from the comment

Copy link
Member

@teoxoy teoxoy left a comment

Choose a reason for hiding this comment

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

PR now comes with the general solution that extracts SPV version from the comment

That's great, thanks for addressing it here!

@teoxoy teoxoy merged commit 16be1a9 into gfx-rs:master Feb 1, 2023
@kvark kvark deleted the spv1.4 branch February 1, 2023 19:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants