mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-01 20:30:12 +01:00
iris: Disable compression on sharing without modifier
For an image created either without a modifier to share or as the destination image to get rid of compression by re-allocation, it should have compression disabled. Close: https://gitlab.freedesktop.org/mesa/mesa/-/issues/13729 (Fix firefox misrendering when gfx.wayland.hdr option is true) Backport-to: 25.2 Signed-off-by: Jianxun Zhang <jianxun.zhang@intel.com> Reviewed-by: José Roberto de Souza <jose.souza@intel.com> Reviewed-by: Nanley Chery <nanley.g.chery@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37098>
This commit is contained in:
parent
06dbd4c33c
commit
5aa4dc7f77
1 changed files with 12 additions and 0 deletions
|
|
@ -803,6 +803,18 @@ iris_resource_configure_main(const struct iris_screen *screen,
|
|||
if (res->mod_info && !isl_drm_modifier_has_aux(modifier))
|
||||
usage |= ISL_SURF_USAGE_DISABLE_AUX_BIT;
|
||||
|
||||
/* On pre-Xe2 platforms, we still have a chance to disable CCS compression
|
||||
* in the first query (iris_resource_disable_aux_on_first_query). But that
|
||||
* function won't work on Xe2+ platforms because the compression state has
|
||||
* been set in bo's allocation. We have to disable compression since the
|
||||
* beginning of the image's life cycle in the below case on Xe2, unless a
|
||||
* complicated bo or VMA manipulation is implemented. That is probably
|
||||
* unworthy.
|
||||
*/
|
||||
else if (screen->devinfo->ver >= 20 && !res->mod_info &&
|
||||
(templ->bind & PIPE_BIND_SHARED))
|
||||
usage |= ISL_SURF_USAGE_DISABLE_AUX_BIT;
|
||||
|
||||
else if (!res->mod_info && res->external_format != PIPE_FORMAT_NONE)
|
||||
usage |= ISL_SURF_USAGE_DISABLE_AUX_BIT;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue