Skip to content

[ET-VK] Add Vulkan 1.0 compatibility for extension feature querying#17160

Merged
meta-codesync[bot] merged 3 commits intogh/SS-JIA/404/basefrom
gh/SS-JIA/404/head
Feb 4, 2026
Merged

[ET-VK] Add Vulkan 1.0 compatibility for extension feature querying#17160
meta-codesync[bot] merged 3 commits intogh/SS-JIA/404/basefrom
gh/SS-JIA/404/head

Conversation

@SS-JIA
Copy link
Contributor

@SS-JIA SS-JIA commented Feb 3, 2026

Stack from ghstack (oldest at bottom):

The previous implementation used vkGetPhysicalDeviceFeatures2 unconditionally,
which is only available in Vulkan 1.1+. Devices running Vulkan 1.0 would fail
to query extension features correctly.

This change refactors PhysicalDevice to detect the API version at runtime and
use the appropriate method:

  • Vulkan 1.0: Uses KHR extension functions (vkGetPhysicalDeviceFeatures2KHR)
    obtained via vkGetInstanceProcAddr, with graceful fallback if unavailable
  • Vulkan 1.1+: Uses core vkGetPhysicalDeviceFeatures2 directly

Also fixes a bug where shader_int_dot_product_properties was incorrectly
chained into the features linked list instead of being queried separately
via vkGetPhysicalDeviceProperties2.

This PR was authored with Claude.

Differential Revision: D92171361

cc @manuelcandales @digantdesai @cbilgin

The previous implementation used `vkGetPhysicalDeviceFeatures2` unconditionally,
which is only available in Vulkan 1.1+. Devices running Vulkan 1.0 would fail
to query extension features correctly.

This change refactors PhysicalDevice to detect the API version at runtime and
use the appropriate method:
- Vulkan 1.0: Uses KHR extension functions (vkGetPhysicalDeviceFeatures2KHR)
  obtained via vkGetInstanceProcAddr, with graceful fallback if unavailable
- Vulkan 1.1+: Uses core vkGetPhysicalDeviceFeatures2 directly

Also fixes a bug where shader_int_dot_product_properties was incorrectly
chained into the features linked list instead of being queried separately
via vkGetPhysicalDeviceProperties2.

This PR was authored with Claude.

Differential Revision: [D92171361](https://our.internmc.facebook.com/intern/diff/D92171361/)

[ghstack-poisoned]
@pytorch-bot pytorch-bot bot added the module: vulkan Issues related to the Vulkan delegate and code under backends/vulkan/ label Feb 3, 2026
@pytorch-bot
Copy link

pytorch-bot bot commented Feb 3, 2026

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/17160

Note: Links to docs will display an error until the docs builds have been completed.

❌ 3 New Failures

As of commit 9e59569 with merge base 593775b (image):

NEW FAILURES - The following jobs have failed:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

SS-JIA pushed a commit that referenced this pull request Feb 3, 2026
The previous implementation used `vkGetPhysicalDeviceFeatures2` unconditionally,
which is only available in Vulkan 1.1+. Devices running Vulkan 1.0 would fail
to query extension features correctly.

This change refactors PhysicalDevice to detect the API version at runtime and
use the appropriate method:
- Vulkan 1.0: Uses KHR extension functions (vkGetPhysicalDeviceFeatures2KHR)
  obtained via vkGetInstanceProcAddr, with graceful fallback if unavailable
- Vulkan 1.1+: Uses core vkGetPhysicalDeviceFeatures2 directly

Also fixes a bug where shader_int_dot_product_properties was incorrectly
chained into the features linked list instead of being queried separately
via vkGetPhysicalDeviceProperties2.

This PR was authored with Claude.

Differential Revision: [D92171361](https://our.internmc.facebook.com/intern/diff/D92171361/)

ghstack-source-id: 337901648
Pull Request resolved: #17160
@meta-cla meta-cla bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Feb 3, 2026
@github-actions
Copy link

github-actions bot commented Feb 3, 2026

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

… querying"

The previous implementation used `vkGetPhysicalDeviceFeatures2` unconditionally,
which is only available in Vulkan 1.1+. Devices running Vulkan 1.0 would fail
to query extension features correctly.

This change refactors PhysicalDevice to detect the API version at runtime and
use the appropriate method:
- Vulkan 1.0: Uses KHR extension functions (vkGetPhysicalDeviceFeatures2KHR)
  obtained via vkGetInstanceProcAddr, with graceful fallback if unavailable
- Vulkan 1.1+: Uses core vkGetPhysicalDeviceFeatures2 directly

Also fixes a bug where shader_int_dot_product_properties was incorrectly
chained into the features linked list instead of being queried separately
via vkGetPhysicalDeviceProperties2.

This PR was authored with Claude.

Differential Revision: [D92171361](https://our.internmc.facebook.com/intern/diff/D92171361/)

cc manuelcandales digantdesai cbilgin

[ghstack-poisoned]
SS-JIA pushed a commit that referenced this pull request Feb 3, 2026
Pull Request resolved: #17160

The previous implementation used `vkGetPhysicalDeviceFeatures2` unconditionally,
which is only available in Vulkan 1.1+. Devices running Vulkan 1.0 would fail
to query extension features correctly.

This change refactors PhysicalDevice to detect the API version at runtime and
use the appropriate method:
- Vulkan 1.0: Uses KHR extension functions (vkGetPhysicalDeviceFeatures2KHR)
  obtained via vkGetInstanceProcAddr, with graceful fallback if unavailable
- Vulkan 1.1+: Uses core vkGetPhysicalDeviceFeatures2 directly

Also fixes a bug where shader_int_dot_product_properties was incorrectly
chained into the features linked list instead of being queried separately
via vkGetPhysicalDeviceProperties2.

This PR was authored with Claude.

ghstack-source-id: 337927970
@exported-using-ghexport

Differential Revision: [D92171361](https://our.internmc.facebook.com/intern/diff/D92171361/)
… querying"

The previous implementation used `vkGetPhysicalDeviceFeatures2` unconditionally,
which is only available in Vulkan 1.1+. Devices running Vulkan 1.0 would fail
to query extension features correctly.

This change refactors PhysicalDevice to detect the API version at runtime and
use the appropriate method:
- Vulkan 1.0: Uses KHR extension functions (vkGetPhysicalDeviceFeatures2KHR)
  obtained via vkGetInstanceProcAddr, with graceful fallback if unavailable
- Vulkan 1.1+: Uses core vkGetPhysicalDeviceFeatures2 directly

Also fixes a bug where shader_int_dot_product_properties was incorrectly
chained into the features linked list instead of being queried separately
via vkGetPhysicalDeviceProperties2.

This PR was authored with Claude.

Differential Revision: [D92171361](https://our.internmc.facebook.com/intern/diff/D92171361/)

cc manuelcandales digantdesai cbilgin

[ghstack-poisoned]
SS-JIA pushed a commit that referenced this pull request Feb 3, 2026
Pull Request resolved: #17160

The previous implementation used `vkGetPhysicalDeviceFeatures2` unconditionally,
which is only available in Vulkan 1.1+. Devices running Vulkan 1.0 would fail
to query extension features correctly.

This change refactors PhysicalDevice to detect the API version at runtime and
use the appropriate method:
- Vulkan 1.0: Uses KHR extension functions (vkGetPhysicalDeviceFeatures2KHR)
  obtained via vkGetInstanceProcAddr, with graceful fallback if unavailable
- Vulkan 1.1+: Uses core vkGetPhysicalDeviceFeatures2 directly

Also fixes a bug where shader_int_dot_product_properties was incorrectly
chained into the features linked list instead of being queried separately
via vkGetPhysicalDeviceProperties2.

This PR was authored with Claude.

ghstack-source-id: 337979631
@exported-using-ghexport

Differential Revision: [D92171361](https://our.internmc.facebook.com/intern/diff/D92171361/)
@meta-codesync meta-codesync bot merged commit 205ac64 into gh/SS-JIA/404/base Feb 4, 2026
180 of 183 checks passed
@meta-codesync meta-codesync bot deleted the gh/SS-JIA/404/head branch February 4, 2026 01:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported meta-exported module: vulkan Issues related to the Vulkan delegate and code under backends/vulkan/

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants