Module: Mesa
Branch: main
Commit: 26b2bdcfe01291359edebb1b35239cfd1f5127c0
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=26b2bdcfe01291359edebb1b35239cfd1f5127c0

Author: Sagar Ghuge <[email protected]>
Date:   Wed Aug 16 11:49:03 2023 -0700

iris,crocus: drop unnecessary DEBUG_NO_CCS/NO_HIZ checks

Now isl_surf_supports_ccs helper handles DEBUG_NO_CCS check and
isl_surf_get_hiz_surf handles DEBUG_NO_HIZ, so we don't
need to check it everywhere.

Signed-off-by: Sagar Ghuge <[email protected]>
Reviewed-by: Nanley Chery <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24731>

---

 src/gallium/drivers/crocus/crocus_resource.c | 3 +--
 src/gallium/drivers/iris/iris_resource.c     | 4 ++--
 2 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/src/gallium/drivers/crocus/crocus_resource.c 
b/src/gallium/drivers/crocus/crocus_resource.c
index cecf771ab47..16627914a1e 100644
--- a/src/gallium/drivers/crocus/crocus_resource.c
+++ b/src/gallium/drivers/crocus/crocus_resource.c
@@ -432,11 +432,10 @@ crocus_resource_configure_aux(struct crocus_screen 
*screen,
       isl_surf_get_mcs_surf(&screen->isl_dev, &res->surf, &res->aux.surf);
 
    const bool has_hiz = devinfo->ver >= 6 && !res->mod_info &&
-      !INTEL_DEBUG(DEBUG_NO_HIZ) &&
       isl_surf_get_hiz_surf(&screen->isl_dev, &res->surf, &res->aux.surf);
 
    const bool has_ccs =
-      devinfo->ver >= 7 && !res->mod_info && !INTEL_DEBUG(DEBUG_NO_CCS) &&
+      devinfo->ver >= 7 && !res->mod_info &&
       isl_surf_get_ccs_surf(&screen->isl_dev, &res->surf, NULL,
                             &res->aux.surf, 0);
 
diff --git a/src/gallium/drivers/iris/iris_resource.c 
b/src/gallium/drivers/iris/iris_resource.c
index 30dacda95e3..7bb5b21cb2a 100644
--- a/src/gallium/drivers/iris/iris_resource.c
+++ b/src/gallium/drivers/iris/iris_resource.c
@@ -840,10 +840,10 @@ iris_resource_configure_aux(struct iris_screen *screen,
    const bool has_mcs =
       isl_surf_get_mcs_surf(&screen->isl_dev, &res->surf, &res->aux.surf);
 
-   const bool has_hiz = !INTEL_DEBUG(DEBUG_NO_HIZ) &&
+   const bool has_hiz =
       isl_surf_get_hiz_surf(&screen->isl_dev, &res->surf, &res->aux.surf);
 
-   const bool has_ccs = !INTEL_DEBUG(DEBUG_NO_CCS) &&
+   const bool has_ccs =
       iris_get_ccs_surf_or_support(&screen->isl_dev, &res->surf,
                                    &res->aux.surf, &res->aux.extra_aux.surf);
 

Reply via email to