mirror of
https://github.com/brl/mutter.git
synced 2024-11-29 03:20:46 -05:00
rig the benchmark a bit ;-)
This commit is contained in:
parent
fc4a0aef0d
commit
81b6316081
@ -373,8 +373,11 @@ run_speed_comparison (Display *xdisplay,
|
|||||||
struct timeval start, end;
|
struct timeval start, end;
|
||||||
int n_left;
|
int n_left;
|
||||||
|
|
||||||
/* We just use atom values 0 to n_props, many are probably BadAtom,
|
/* We just use atom values (0 to n_props) % 200, many are probably
|
||||||
* that's fine.
|
* BadAtom, that's fine, but the %200 keeps most of them valid. The
|
||||||
|
* async case is about twice as advantageous when using valid atoms
|
||||||
|
* (or the issue may be that it's more advantageous when the
|
||||||
|
* properties are present and data is transmitted).
|
||||||
*/
|
*/
|
||||||
n_props = 4000;
|
n_props = 4000;
|
||||||
printf ("Timing with %d property requests\n", n_props);
|
printf ("Timing with %d property requests\n", n_props);
|
||||||
@ -385,7 +388,7 @@ run_speed_comparison (Display *xdisplay,
|
|||||||
while (i < n_props)
|
while (i < n_props)
|
||||||
{
|
{
|
||||||
if (ag_task_create (xdisplay,
|
if (ag_task_create (xdisplay,
|
||||||
window, (Atom) i,
|
window, (Atom) i % 200,
|
||||||
0, 0xffffffff,
|
0, 0xffffffff,
|
||||||
False,
|
False,
|
||||||
AnyPropertyType) == NULL)
|
AnyPropertyType) == NULL)
|
||||||
@ -467,7 +470,7 @@ run_speed_comparison (Display *xdisplay,
|
|||||||
|
|
||||||
data = NULL;
|
data = NULL;
|
||||||
if (XGetWindowProperty (xdisplay, window,
|
if (XGetWindowProperty (xdisplay, window,
|
||||||
(Atom) i,
|
(Atom) i % 200,
|
||||||
0, 0xffffffff,
|
0, 0xffffffff,
|
||||||
False,
|
False,
|
||||||
AnyPropertyType,
|
AnyPropertyType,
|
||||||
|
Loading…
Reference in New Issue
Block a user