ac/gpu_info: Add different sparse features
The following sparse features are not supported by all GPUs, so keep track of their support individually: has_sparse_image_3d has_sparse_image_standard_3d has_sparse_unaligned_mip_size Signed-off-by: Timur Kristóf <timur.kristof@gmail.com> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38553>
This commit is contained in:
@@ -718,6 +718,7 @@ ac_query_gpu_info(int fd, void *dev_p, struct radeon_info *info,
|
||||
ac_drm_query_has_vm_always_valid(dev, info);
|
||||
info->has_bo_metadata = true;
|
||||
info->has_eqaa_surface_allocator = info->gfx_level < GFX11;
|
||||
|
||||
/* Disable sparse mappings on GFX6 due to VM faults in CP DMA. Enable them once
|
||||
* these faults are mitigated in software.
|
||||
* Disable sparse mappings on GFX7-8 due to GPU hangs in the VK CTS,
|
||||
@@ -725,6 +726,10 @@ ac_query_gpu_info(int fd, void *dev_p, struct radeon_info *info,
|
||||
* Enable them when these are investigated and fixed in the driver.
|
||||
*/
|
||||
info->has_sparse = info->family >= CHIP_POLARIS10;
|
||||
info->has_sparse_image_3d = info->gfx_level >= GFX7;
|
||||
info->has_sparse_image_standard_3d = info->gfx_level >= GFX9;
|
||||
info->has_sparse_unaligned_mip_size = info->gfx_level >= GFX7;
|
||||
|
||||
info->has_gang_submit = info->drm_minor >= 49;
|
||||
info->has_gpuvm_fault_query = info->drm_minor >= 55;
|
||||
info->has_tmz_support = device_info.ids_flags & AMDGPU_IDS_FLAGS_TMZ;
|
||||
|
||||
@@ -238,7 +238,14 @@ struct radeon_info {
|
||||
bool has_vm_always_valid;
|
||||
bool has_bo_metadata;
|
||||
bool has_eqaa_surface_allocator;
|
||||
/* Sparse bindings and basic sparse features (2D image, etc.) */
|
||||
bool has_sparse;
|
||||
/* 3D sparse images */
|
||||
bool has_sparse_image_3d;
|
||||
/* 3D sparse images with standard block shape */
|
||||
bool has_sparse_image_standard_3d;
|
||||
/* Mip levels do not need to be aligned to the sparse block size */
|
||||
bool has_sparse_unaligned_mip_size;
|
||||
bool has_gang_submit;
|
||||
bool has_gpuvm_fault_query;
|
||||
bool has_pcie_bandwidth_info;
|
||||
|
||||
Reference in New Issue
Block a user