anv: Reduce clear color state alignment to 64B

Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com>
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26793>
This commit is contained in:
Sagar Ghuge
2023-11-15 10:48:46 -08:00
committed by Marge Bot
parent 246e22ff4f
commit 063715ed45
+4 -9
View File
@@ -668,11 +668,9 @@ add_aux_state_tracking_buffer(struct anv_device *device,
binding = ANV_IMAGE_MEMORY_BINDING_PRIVATE; binding = ANV_IMAGE_MEMORY_BINDING_PRIVATE;
} }
/* We believe that 256B alignment may be sufficient, but we choose 4K due to /* The indirect clear color BO requires 64B-alignment on gfx11+. */
* lack of testing. And MI_LOAD/STORE operations require dword-alignment.
*/
return image_binding_grow(device, image, binding, return image_binding_grow(device, image, binding,
state_offset, state_size, 4096, state_offset, state_size, 64,
&image->planes[plane].fast_clear_memory_range); &image->planes[plane].fast_clear_memory_range);
} }
@@ -1122,11 +1120,8 @@ check_memory_bindings(const struct anv_device *device,
binding = ANV_IMAGE_MEMORY_BINDING_PRIVATE; binding = ANV_IMAGE_MEMORY_BINDING_PRIVATE;
} }
/* We believe that 256B alignment may be sufficient, but we choose 4K /* The indirect clear color BO requires 64B-alignment on gfx11+. */
* due to lack of testing. And MI_LOAD/STORE operations require assert(plane->fast_clear_memory_range.alignment == 64);
* dword-alignment.
*/
assert(plane->fast_clear_memory_range.alignment == 4096);
check_memory_range(accum_ranges, check_memory_range(accum_ranges,
.test_range = &plane->fast_clear_memory_range, .test_range = &plane->fast_clear_memory_range,
.expect_binding = binding); .expect_binding = binding);