WIP: Accelerate XY images in glamor
This is a trivial rebase of a patch series from Keith before the gitlab migration. I've done some quick testing and, in principle, Keith's approach here is far superior to mine, which is only slightly faster than baseline in my testing:
1 2 Operation
-------- ---------------- -------------------------
14800.0 14700.0 (0.993) PutImage XY 10x10 square
1420.0 1240.0 (0.873) PutImage XY 100x100 square
79.2 80.2 (1.013) PutImage XY 500x500 square
7990.0 13300.0 (1.665) PutImage XYBitmap 10x10 square
6380.0 9340.0 (1.464) PutImage XYBitmap 100x100 square
964.0 1140.0 (1.183) PutImage XYBitmap 500x500 square
6430.0 6760.0 (1.051) ShmPutImage XY 10x10 square
1070.0 1090.0 (1.019) ShmPutImage XY 100x100 square
84.5 84.5 (1.000) ShmPutImage XY 500x500 square
69600.0 71800.0 (1.032) ShmPutImage XYBitmap 10x10 square
15000.0 16200.0 (1.080) ShmPutImage XYBitmap 100x100 square
1710.0 1660.0 (0.971) ShmPutImage XYBitmap 500x500 square
Practice, though, says that something very bad happens in glamor: Accelerate up XY pixmap putimage a little
. x11perfcomp of Xephyr -glamor-skip-present
for master and each patch in the series (on a Skylake running
i965, for what it's worth):
1 2 3 4 Operation
-------- ---------------- ----------------- ------------------ -------------------------
14800.0 13100.0 (0.885) 58900.0 ( 3.980) 58400.0 ( 3.946) PutImage XY 10x10 square
1420.0 1010.0 (0.711) 2040.0 ( 1.437) 2050.0 ( 1.444) PutImage XY 100x100 square
79.2 76.0 (0.960) 86.3 ( 1.090) 87.4 ( 1.104) PutImage XY 500x500 square
7990.0 58100.0 (7.272) 73100.0 ( 9.149) 107000.0 (13.392) PutImage XYBitmap 10x10 square
6380.0 48600.0 (7.618) 69000.0 (10.815) 65500.0 (10.266) PutImage XYBitmap 100x100 square
964.0 15800.0 (6.390) 18800.0 (19.502) 18300.0 (18.983) PutImage XYBitmap 500x500 square
6430.0 6000.0 (0.933) 63.4 ( 0.010) 63.5 ( 0.010) ShmPutImage XY 10x10 square
1070.0 1060.0 (0.991) 63.3 ( 0.059) 63.4 ( 0.059) ShmPutImage XY 100x100 square
84.5 86.2 (1.020) 63.1 ( 0.747) 62.6 ( 0.741) ShmPutImage XY 500x500 square
69600.0 72000.0 (1.034) 79200.0 ( 1.138) 83700.0 ( 1.203) ShmPutImage XYBitmap 10x10 square
15000.0 16300.0 (1.087) 15500.0 ( 1.033) 16200.0 ( 1.080) ShmPutImage XYBitmap 100x100 square
1710.0 1860.0 (1.088) 1800.0 ( 1.053) 1800.0 ( 1.053) ShmPutImage XYBitmap 500x500 square
Not that shmputxy is normally a case to care about, but that's not an acceptable regression.
cc @imirkin