-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Add VK_EXT_pageable_device_local_memory support #5246
base: master
Are you sure you want to change the base?
Conversation
… from 100000 to 1000.
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #5246 +/- ##
===========================================
- Coverage 94.63% 89.53% -5.10%
===========================================
Files 778 318 -460
Lines 243361 96127 -147234
===========================================
- Hits 230302 86072 -144230
+ Misses 13059 10055 -3004 ☔ View full report in Codecov by Sentry. |
Add VK_EXT_pageable_device_local_memory support
Why do this change?
https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/vkAllocateMemory.html
https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkPhysicalDevicePageableDeviceLocalMemoryFeaturesEXT.html
If the VkPhysicalDevicePageableDeviceLocalMemoryFeaturesEXT::pageableDeviceLocalMemory feature is enabled, memory allocations made from a heap that includes VK_MEMORY_HEAP_DEVICE_LOCAL_BIT in VkMemoryHeap::flags may be transparently moved to host-local memory allowing multiple applications to share device-local memory. If there is no space left in device-local memory when this new allocation is made, other allocations may be moved out transparently to make room. The operating system will determine which allocations to move to device-local memory or host-local memory based on platform-specific criteria. To help the operating system make good choices, the application should set the appropriate memory priority with VkMemoryPriorityAllocateInfoEXT and adjust it as necessary with vkSetDeviceMemoryPriorityEXT. Higher priority allocations will moved to device-local memory first.
If the VkPhysicalDevicePageableDeviceLocalMemoryFeaturesEXT structure is included in the pNext chain of the VkPhysicalDeviceFeatures2 structure passed to vkGetPhysicalDeviceFeatures2, it is filled in to indicate whether each corresponding feature is supported. VkPhysicalDevicePageableDeviceLocalMemoryFeaturesEXT can also be used in the pNext chain of VkDeviceCreateInfo to selectively enable these features.
How to use it?