-
Notifications
You must be signed in to change notification settings - Fork 278
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
Implement VK_MSFT_layered_driver extension support #1342
Implement VK_MSFT_layered_driver extension support #1342
Conversation
CI Vulkan-Loader build queued with queue ID 66786. |
CI Vulkan-Loader build # 2266 running. |
CI Vulkan-Loader build # 2266 passed. |
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.
I reviewed some pieces before exceeding my time budget to review, and I left review comments along the way.
Very long functions with very deep nesting are difficult to review.
@jjulianoatnv Thank you for the deep review! You are absolutely right that deeply nested functions are tough to review. Means that it needs some refactoring to make it more understandable for sure, as evidenced by some of your comments. |
I'm just returning from parental leave, and Dozen doesn't yet implement the relevant extension here. When I get a chance I'll get that hooked up and then give this a try, as well as a review. Thanks! |
3ca622e
to
74a5bc2
Compare
CI Vulkan-Loader build queued with queue ID 74340. |
CI Vulkan-Loader build # 2305 running. |
@jjulianoatnv You were absolutely right about the function being waaay to big. That happened due to just wanting to implement the logic without regard for clarity. The force push renames some variables for clarity, adds several needed comments, and breaks the big function into 3, the original one which calls the two child functions, one for actually calling EnumerateAdapterPhysicalDevices, and the other for sorting the physical devices based on whether they are layered or not. |
CI Vulkan-Loader build # 2305 passed. |
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.
One outstanding comment that's definitely a bug and needs to be fixed. Other than that LGTM.
74a5bc2
to
f13fc9f
Compare
CI Vulkan-Loader build queued with queue ID 76515. |
CI Vulkan-Loader build # 2310 running. |
CI Vulkan-Loader build # 2310 passed. |
f13fc9f
to
fc999f6
Compare
CI Vulkan-Loader build queued with queue ID 76541. |
CI Vulkan-Loader build # 2311 running. |
CI Vulkan-Loader build # 2311 failed. |
fc999f6
to
fa7474a
Compare
CI Vulkan-Loader build queued with queue ID 76559. |
CI Vulkan-Loader build # 2312 running. |
CI Vulkan-Loader build # 2312 failed. |
fa7474a
to
5e39148
Compare
CI Vulkan-Loader build queued with queue ID 76574. |
CI Vulkan-Loader build # 2313 running. |
CI Vulkan-Loader build # 2313 failed. |
5e39148
to
7a69627
Compare
CI Vulkan-Loader build queued with queue ID 76594. |
1 similar comment
CI Vulkan-Loader build queued with queue ID 76594. |
With both reviewers noting that The Apologies for the force push spam - my windows VM has decided to die on me and so I'm making the changes to windows only codepaths without a compiler in front of me. |
CI Vulkan-Loader build # 2314 running. |
CI Vulkan-Loader build # 2314 failed. |
This extension reorders physical devices enumerated through the windows EnumerateAdapterPhysicalDevices whenever multiple drivers exist for the same LUID. This is so that if a driver is considered a 'layered implementation', eg Dozen's Vulkan on Dx12, the physical device corresponding to the native vulkan driver is preferred. The implementation of this extension cause some renaming of structs, variables, and parameters to make the code easier to understand, such as renaming the struct loader_phys_devs_per_icd to loader_icd_physical_devices. During the review process there was quite a bit of confusion about what the struct's purpose was that should be much clearer now.
7a69627
to
30c9553
Compare
CI Vulkan-Loader build queued with queue ID 77203. |
CI Vulkan-Loader build # 2316 running. |
CI Vulkan-Loader build # 2316 passed. |
This extension reorders physical devices enumerated through the windows EnumerateAdapterPhysicalDevices whenever multiple drivers exist for the same LUID. This is so that if a driver is considered a 'layered implementation', eg Dozen's Vulkan on Dx12, the physical device corresponding to the native vulkan driver is preferred.
@jenatali Would greatly appreciate it if you could verify this works for the situations described.
Fixes #981