From: Michel Dänzer Date: Tue, 6 Sep 2016 02:34:49 +0000 (+0900) Subject: loader/dri3: Always use at least two back buffers X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=dc3bb5db8c81e7f08ae12ea5d3ee999e2afcbfd1;p=mesa.git loader/dri3: Always use at least two back buffers This can make a significant difference for performance with some extreme test cases such as vblank_mode=0 glxgears. Fixes: 1e3218bc5ba2 ("loader/dri3: Overhaul dri3_update_num_back") Cc: "12.0 11.2" Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=97549 Reviewed-by: Jason Ekstrand Tested-by: Dieter Nützel --- diff --git a/src/loader/loader_dri3_helper.c b/src/loader/loader_dri3_helper.c index 86ae5aecd5f..3ce03524dac 100644 --- a/src/loader/loader_dri3_helper.c +++ b/src/loader/loader_dri3_helper.c @@ -70,10 +70,8 @@ dri3_update_num_back(struct loader_dri3_drawable *draw) { if (draw->flipping) draw->num_back = 3; - else if (draw->vtable->get_swap_interval(draw) != 0) - draw->num_back = 2; else - draw->num_back = 1; + draw->num_back = 2; } void