Mesa (main): isl: disable CPB surface compression

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Wed Feb 2 17:39:54 UTC 2022


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

Author: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
Date:   Thu Jan 27 10:26:58 2022 +0200

isl: disable CPB surface compression

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
Reviewed-by: Nanley Chery <nanley.g.chery at intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13739>

---

 src/intel/isl/isl.c          | 6 ++++++
 src/intel/isl/isl_emit_cpb.c | 5 +++++
 2 files changed, 11 insertions(+)

diff --git a/src/intel/isl/isl.c b/src/intel/isl/isl.c
index e16661dcc15..bd41684c1fe 100644
--- a/src/intel/isl/isl.c
+++ b/src/intel/isl/isl.c
@@ -2161,6 +2161,12 @@ isl_surf_supports_ccs(const struct isl_device *dev,
    if (surf->tiling == ISL_TILING_LINEAR)
       return false;
 
+   /* TODO: Disable for now, as we're not sure about the meaning of
+    * 3DSTATE_CPSIZE_CONTROL_BUFFER::CPCBCompressionEnable
+    */
+   if (isl_surf_usage_is_cpb(surf->usage))
+      return false;
+
    if (ISL_GFX_VER(dev) >= 12) {
       if (isl_surf_usage_is_stencil(surf->usage)) {
          /* HiZ and MCS aren't allowed with stencil */
diff --git a/src/intel/isl/isl_emit_cpb.c b/src/intel/isl/isl_emit_cpb.c
index 024fba9e478..eeb3337645b 100644
--- a/src/intel/isl/isl_emit_cpb.c
+++ b/src/intel/isl/isl_emit_cpb.c
@@ -96,6 +96,11 @@ isl_genX(emit_cpb_control_s)(const struct isl_device *dev, void *batch,
        * Start LOD" to 15 to prevent the hardware from trying to use them.
        */
       cpb.MipTailStartLOD        = 15;
+      /* TODO:
+       *
+       * cpb.CPCBCompressionEnable is this CCS compression? Currently disabled
+       * in isl_surf_supports_ccs() for CPB buffers.
+       */
    } else {
       cpb.SurfaceType  = SURFTYPE_NULL;
       cpb.TiledMode    = TILE64;



More information about the mesa-commit mailing list