[mutter] Revert "renderer-native: Actually use shadow fb when using software rendering"



commit 7049b2f27418f1b484afe14612a750755b5b85b2
Author: Jonas Ådahl <jadahl gmail com>
Date:   Mon Sep 30 11:21:36 2019 +0200

    Revert "renderer-native: Actually use shadow fb when using software rendering"
    
    It was not the lack of forcing the shadow fb that caused slowness, but
    rather due to the method the shadow fb content was copied onto the
    scanout fb. With 'clutter: Use cogl_blit_framebuffer() for shadow FB'
    we'll use a path that shouldn't be slow when copying onto the scanout
    fb.
    
    Also 437f6b3d59f2102f5974bfc430176725f2ed67c2 accidentally enabled
    shadow fb when using hw accelerated contexts, due to the cap being set
    to 1 in majority of drivers. While the kernel documentation for the
    related field says "hint to userspace to prefer shadow-fb rendering",
    the name of the hint when exposed to userspace is
    DRM_CAP_DUMB_PREFER_SHADOW, thus should only be taken into consideration
    for dumb buffers, not rendering in general.
    
    This reverts commit 437f6b3d59f2102f5974bfc430176725f2ed67c2.
    
    https://gitlab.gnome.org/GNOME/mutter/merge_requests/818

 src/backends/native/meta-renderer-native.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/backends/native/meta-renderer-native.c b/src/backends/native/meta-renderer-native.c
index 21d00502c..5c01375c8 100644
--- a/src/backends/native/meta-renderer-native.c
+++ b/src/backends/native/meta-renderer-native.c
@@ -3213,11 +3213,11 @@ should_force_shadow_fb (MetaRendererNative *renderer_native,
     case COGL_GPU_INFO_ARCHITECTURE_SANDYBRIDGE:
     case COGL_GPU_INFO_ARCHITECTURE_SGX:
     case COGL_GPU_INFO_ARCHITECTURE_MALI:
-      break;
+      return FALSE;
     case COGL_GPU_INFO_ARCHITECTURE_LLVMPIPE:
     case COGL_GPU_INFO_ARCHITECTURE_SOFTPIPE:
     case COGL_GPU_INFO_ARCHITECTURE_SWRAST:
-      return TRUE;
+      break;
     }
 
   kms_fd = meta_gpu_kms_get_fd (primary_gpu);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]