xf86-video-intel: src/sna/gen7_render.c

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Fri Oct 16 12:14:57 UTC 2020


 src/sna/gen7_render.c |    3 +++
 1 file changed, 3 insertions(+)

New commits:
commit 67f15b36faf8c4aa902d953067df0faf43387208
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Thu Aug 20 09:18:19 2020 +0100

    sna/gen7: Prefer blitter for plain copies on Haswell
    
    Since the clear-residuals security fix on gen7, context switches are
    very slow. If X is being used with DRI clients, those clients will
    typically be using the 3D engine for themselves and every frame
    presented will then be copied by X, causing at least a couple of context
    switches per frame. That greatly diminishes throughput, but if we prefer
    to use the blitter engine for X, we can mostly keep off the render engine
    avoiding the context thrash.
    
    Reported-by: Rafael Ristovski <rafael.ristovski at gmail.com>
    Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>

diff --git a/src/sna/gen7_render.c b/src/sna/gen7_render.c
index f58f39d4..e572b785 100644
--- a/src/sna/gen7_render.c
+++ b/src/sna/gen7_render.c
@@ -2960,6 +2960,9 @@ prefer_blt_copy(struct sna *sna,
 	if (sna->kgem.mode == KGEM_BLT)
 		return true;
 
+	if (sna->info->gen == 075) /* avoid clear-residuals context overhead */
+		return true;
+
 	assert((flags & COPY_SYNC) == 0);
 
 	if (untiled_tlb_miss(src_bo) ||


More information about the xorg-commit mailing list