mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-03-11 11:20:41 +01:00
Merge branch 'review/anv-disable-slab-with-memoryMapPlaced' into 'main'
anv: disable slab allocator with memoryMapPlaced See merge request mesa/mesa!40239
This commit is contained in:
commit
cf35945a07
1 changed files with 9 additions and 0 deletions
|
|
@ -31,6 +31,15 @@ static enum anv_bo_slab_heap
|
|||
anv_bo_alloc_flags_to_slab_heap(struct anv_device *device,
|
||||
enum anv_bo_alloc_flags alloc_flags)
|
||||
{
|
||||
/* Until we have a uAPI to map memory from a GEM object at an offset, we
|
||||
* cannot use a slab allocator for VkDeviceMemory host visible.
|
||||
*/
|
||||
if (device->vk.enabled_features.memoryMapPlaced &&
|
||||
!(alloc_flags & ANV_BO_ALLOC_MAPPED) &&
|
||||
(alloc_flags & (ANV_BO_ALLOC_HOST_CACHED_COHERENT |
|
||||
ANV_BO_ALLOC_LOCAL_MEM_CPU_VISIBLE)))
|
||||
return ANV_BO_SLAB_NOT_SUPPORTED;
|
||||
|
||||
enum anv_bo_alloc_flags not_supported = ANV_BO_ALLOC_32BIT_ADDRESS |
|
||||
ANV_BO_ALLOC_EXTERNAL |
|
||||
ANV_BO_ALLOC_CAPTURE |
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue