On Thu, 2011-01-06 at 13:25 +0000, Chris Wilson wrote:
> I noticed that there were no corresponding tests for ShmGetImage to
> attempt to measure the performance of readback without the overhead of
> pushing those pixels over the wire.
> 
> This adds a test based on GetImage, but it has a bug where the Window is
> cleared after the first run - it doesn't seem to affect the results.
> I haven't been able to spot it, so I'm hoping a few more eyes might.
> -Chris

Well that's easy enough:

> +  {"-shmget10", "ShmGetImage 10x10 square", NULL,
> +             InitShmGetImage, DoShmGetImage, MidCopyPix, EndShmGetImage,
> +             V1_2FEATURE, ROP, 0,
> +             {4, 10}},

void
MidCopyPix(XParms xp, Parms p)
{
    XClearWindow(xp->d, xp->w);
}

The only issue I have with this test is that XShmGetImage blocks on the
reply from the server, so you're never going to go any faster than the
roundtrip ceiling of x11perf -prop; the numeric result from -shmget will
only be directly interesting if it's lower than the number from -prop.

But in that sense x11perf isn't set up to do this well at all, you
really want something xcb-ish to fire enough GetImages to be able to
measure the download speed and just collect and discard the replies.

Still, worth adding.  With the MidCopyPix thing fixed:

Reviewed-by: Adam Jackson <[email protected]>

- ajax

Attachment: signature.asc
Description: This is a digitally signed message part

_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to