amber
amber copied to clipboard
Support enabling ScalarBlockLayout in Vulkan
spirv-val is generating its old Invalid shader thing about Block offsets. DEVICE_EXTENSION VK_EXT_scalar_block_layout
isn't stopping it. How do I get amber to accept my shader's scalar block layout?
If this is fixed in SPIRV-Tools you can update the dependency in Amber and rebuild. If it isn't, you can use --disable-spirv-val
to disable spirv-val usage in Amber.
I'm still getting a scalar_block_layout validation error with --disable-spirv-val. But now it looks like it comes from the Vulkan validator itself.
https://gist.github.com/seanbaxter/5c76583f1f56803794eead0ba4c252c3
The validation layers in Amber are built with the same version of spirv-tools. There is a -d
flag to disable vulkan validation as well.
If this passes with those disabled, and the fix is already in SPIRV-Tools we can create an issue to roll the dependencies of Amber.
I just built amber from source this morning, so this fix isn't there. I've never understood this aspect part of spirv-tools. Shouldn't the presence of GL_EXT_scalar_block_layout disable those alignment checks?
https://github.com/KhronosGroup/SPIRV-Tools/issues/3763
Not sure how you built Amber, but if you used git-sync-deps
, then Amber has a pinned version of SPIRV-Tools which is not tip-of-tree.
It looks like scalar block layout has to be enabled through Vulkan which Amber doesn't know how to do at this point: https://github.com/google/amber/blob/main/samples/config_helper_vulkan.cc#L1001
I just built SPIRV-Tools from top of tree. The issue is still there. It's ignoring GL_EXT_scalar_block_layout and requires --scalar-block-layout not to fail.
I've updated the title of this to add support into Amber for enabling the scalar block layout in the vulkan structures. Between that and fixing SPIRV-Tools, hopefully that's all that would be needed.