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

Fixes for VK_EXT_extended_dynamic_state. #2042

Conversation

billhollings
Copy link
Contributor

  • MVKPipeline only work around zero stride if stride is static.
  • Ensure dynamic vertex stride is not enabled on builds before Xcode 15.
  • Add MVKRenderStateType::LineWidth for track all default options (unrelated).

Fixes issue #2041.

Copy link
Collaborator

@cdavis5e cdavis5e left a comment

Choose a reason for hiding this comment

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

Just one more check that you missed.

MoltenVK/MoltenVK/GPUObjects/MVKPipeline.mm Show resolved Hide resolved
- MVKPipeline only work around zero stride if stride is static.
- Ensure dynamic vertex stride is not enabled on builds before Xcode 15.
- Add MVKRenderStateType::LineWidth for track all default options (unrelated).
@billhollings billhollings force-pushed the VK_EXT_extended_dynamic_state-fixes branch from b455fa2 to d706ed0 Compare October 17, 2023 00:52
@billhollings billhollings requested a review from cdavis5e October 17, 2023 00:53
@billhollings billhollings merged commit 107cf2c into KhronosGroup:main Oct 17, 2023
5 checks passed
@billhollings billhollings deleted the VK_EXT_extended_dynamic_state-fixes branch October 17, 2023 02:25
setConfigurationResult(reportError(VK_ERROR_INITIALIZATION_FAILED, "Under Metal, vertex attribute binding strides must be aligned to %llu bytes.", mtlVtxStrideAlignment));
// Vulkan allows any stride, but Metal requires multiples of 4 on older GPUs.
if (isVtxStrideStatic && (pVKVB->stride % _device->_pMetalFeatures->vertexStrideAlignment) != 0) {
setConfigurationResult(reportError(VK_ERROR_INITIALIZATION_FAILED, "Under Metal, vertex attribute binding strides must be aligned to %llu bytes.", _device->_pMetalFeatures->vertexStrideAlignment));
return false;
Copy link

Choose a reason for hiding this comment

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

FYI, there's some significant indentation inconsistency here.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's the typical tab-spacing issue. Everything is aligned when tab-spacing is set to 4. Github uses 8.

We never got around to mechanically enforce formatting. Formatting consistency is maintained by the devs, and some use spaces instead of tabs.

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.

3 participants