mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 13:18:04 +02:00
radv: Use stricter HW resolve swizzle compat check.
D and linear are both DISPLAY micro tiling according to ac_surface but don't work together. This fixes an issue with GFX9+. This fixes the SkQP WritePixelsNonTexture_Gpu test. Fixes:69ea473eeb("amd/addrlib: update to the latest version") Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8665> (cherry picked from commit12ce72fcfc) Conflicts: src/amd/vulkan/radv_meta_resolve.c
This commit is contained in:
parent
fcb61d4b46
commit
fd5c91e656
2 changed files with 19 additions and 3 deletions
|
|
@ -373,7 +373,7 @@
|
|||
"description": "radv: Use stricter HW resolve swizzle compat check.",
|
||||
"nominated": true,
|
||||
"nomination_type": 1,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"master_sha": null,
|
||||
"because_sha": "69ea473eeb91b2c4db26402c3bc2ed5799d26605"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -353,6 +353,19 @@ enum radv_resolve_method {
|
|||
RESOLVE_FRAGMENT,
|
||||
};
|
||||
|
||||
static bool image_hw_resolve_compat(const struct radv_device *device,
|
||||
struct radv_image *src_image,
|
||||
struct radv_image *dst_image)
|
||||
{
|
||||
if (device->physical_device->rad_info.chip_class >= GFX9) {
|
||||
return dst_image->planes[0].surface.u.gfx9.surf.swizzle_mode ==
|
||||
src_image->planes[0].surface.u.gfx9.surf.swizzle_mode;
|
||||
} else {
|
||||
return dst_image->planes[0].surface.micro_tile_mode ==
|
||||
src_image->planes[0].surface.micro_tile_mode;
|
||||
}
|
||||
}
|
||||
|
||||
static void radv_pick_resolve_method_images(struct radv_device *device,
|
||||
struct radv_image *src_image,
|
||||
VkFormat src_format,
|
||||
|
|
@ -376,8 +389,11 @@ static void radv_pick_resolve_method_images(struct radv_device *device,
|
|||
if (radv_layout_dcc_compressed(device, dest_image, dest_image_layout,
|
||||
dest_render_loop, queue_mask)) {
|
||||
*method = RESOLVE_FRAGMENT;
|
||||
} else if (dest_image->planes[0].surface.micro_tile_mode !=
|
||||
src_image->planes[0].surface.micro_tile_mode) {
|
||||
} else if (!image_hw_resolve_compat(device, src_image, dest_image)) {
|
||||
/* The micro tile mode only needs to match for the HW
|
||||
* resolve path which is the default path for non-DCC
|
||||
* resolves.
|
||||
*/
|
||||
*method = RESOLVE_COMPUTE;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue