Skip to content

wsi: A few minor optimizations for explcit sync

Michel Dänzer requested to merge daenzer/mesa:wsi-optimize-explicit_sync into main

This narrows the gap to implicit sync in terms of vkcube/vkcube-wayland frame rate.

The following numbers (corresponding to the number of frames presented in a minute) were measured with RADV on a system with Ryzen 7 1700 & Radeon RX 5500 (Navi 14). I measured a similar gap for vkcube-wayland with ANV on a laptop with Intel ADL-P iGPU.

vkcube --present_mode 1:

x vkcube.implicit
+ vkcube.explicit-baseline
* vkcube.explicit-patch1
% vkcube.explicit-patch2
# vkcube.explicit-patch3
+------------------------------------------------------------------------------+
|  ++  +  %%  **      %* +  %   + *     %*    #   #   #   #   #           x xxx|
||_____M__|___|_______AM_A_|_______|_|          |_____A______|             |AM||
+------------------------------------------------------------------------------+
    N           Min           Max        Median           Avg        Stddev
x   5        226774        227863        227536      227443.4     408.01324
+   5        208146        215641        209272      211064.2     3440.9758
Difference at 95.0% confidence
	-16379.2 +/- 3573.45
	-7.20144% +/- 1.57114%
	(Student's t, pooled s = 2450.18)
*   5        211013        218027        213276        213983     3054.2957
Difference at 95.0% confidence
	-13460.4 +/- 3177.8
	-5.91813% +/- 1.39718%
	(Student's t, pooled s = 2178.9)
%   5        210090        217827        213177      213219.8     3231.9217
Difference at 95.0% confidence
	-14223.6 +/- 3359.45
	-6.25369% +/- 1.47705%
	(Student's t, pooled s = 2303.45)
#   5        219486        223756        221498      221604.4     1680.3423
Difference at 95.0% confidence
	-5839 +/- 1783.25
	-2.56723% +/- 0.78404%
	(Student's t, pooled s = 1222.71)

vkcube-wayland --present_mode 1:

x vkcube-wayland.implicit
+ vkcube-wayland.explicit-baseline
* vkcube-wayland.explicit-patch1
% vkcube-wayland.explicit-patch2
# vkcube-wayland.explicit-patch3
+------------------------------------------------------------------------------+
|                                     #                                        |
|                                   # #                                        |
|+             + ++   % * %O* *%  % # #                           x        xx  |
|     |_______A__M___| |_|_MA_|__|  |AM                              |____AM__||
+------------------------------------------------------------------------------+
    N           Min           Max        Median           Avg        Stddev
x   5        217648        221326        221053      220409.2     1549.7412
+   5        195262        201002        200726      199612.8     2461.3884
Difference at 95.0% confidence
	-20796.4 +/- 2999.6
	-9.43536% +/- 1.36092%
	(Student's t, pooled s = 2056.71)
*   5        203213        205444        204412        204384     790.62792
Difference at 95.0% confidence
	-16025.2 +/- 1794.18
	-7.27066% +/- 0.814021%
	(Student's t, pooled s = 1230.2)
%   5        202478        206768        204437      204628.8     1662.4607
Difference at 95.0% confidence
	-15780.4 +/- 2343.85
	-7.15959% +/- 1.06341%
	(Student's t, pooled s = 1607.09)
#   5        207501        208113        208000      207840.4     299.00635
Difference at 95.0% confidence
	-12568.8 +/- 1627.68
	-5.70248% +/- 0.738483%
	(Student's t, pooled s = 1116.04)

Merge request reports