diff options
author | Uli Schlachter <psychon@znc.in> | 2010-12-04 16:36:28 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2010-12-25 09:50:34 +0000 |
commit | 109fcb39502239ff87c70cc99f2baea6e46b36a5 (patch) | |
tree | 1763e250a56c4ed126b4be27ff65c81c43568be8 /src/cairo-xcb-shm.c | |
parent | cf0a4ed862d93b7e6d7d26942cfe98a50beccd4c (diff) | |
download | cairo-109fcb39502239ff87c70cc99f2baea6e46b36a5.tar.gz |
XCB: Stop taking the xcb socket
This makes the xcb backend use the auto-generated xcb API instead of
hand-writing each request. This should also improve parallelism with non-cairo
threads that use the same xcb connection.
Big thanks to Andrea Canciani for taking a look at this and finding lots of good
improvements (especially finding xcb_send_request was great).
cairo-perf-trace and cairo-perf-diff-files between master
(6732dbf2992891be4b1f08b14a5c449fd08b637c) and this change:
$ ./cairo-perf-diff-files ../master_perf ../xcb_no_socket_perf
old: master_perf
new: xcb_no_socket_perf
Speedups
========
xcb-rgba evolution-0 23558.86 (23558.86 0.00%) -> 19338.78 (19338.78 0.00%): 1.22x speedup
▎
xcb-rgba poppler-bug-12266-0 98.43 (98.43 0.00%) -> 82.36 (82.36 0.00%): 1.20x speedup
▎
xcb-rgba gnome-terminal-vim-0 5518.08 (5518.08 0.00%) -> 4905.92 (4905.92 0.00%): 1.12x speedup
▏
xcb-rgba gnome-terminal-20090601-0 45648.46 (45648.46 0.00%) -> 41231.25 (41231.25 0.00%): 1.11x speedup
▏
xcb-rgba evolution-20090607-0 71643.69 (71643.69 0.00%) -> 66314.95 (66314.95 0.00%): 1.08x speedup
▏
xcb-rgba poppler-0 3501.69 (3501.69 0.00%) -> 3322.26 (3322.26 0.00%): 1.05x speedup
Slowdowns
=========
xcb-rgba gnome-system-monitor-0 7500.01 (7500.01 0.00%) -> 7923.70 (7923.70 0.00%): 1.06x slowdown
xcb-rgba swfdec-youtube-full-0 26409.89 (26409.89 0.00%) -> 28430.76 (28430.76 0.00%): 1.08x slowdown
▏
xcb-rgba gnome-system-monitor-20090821-0 34801.61 (34801.61 0.00%) -> 37891.14 (37891.14 0.00%): 1.09x slowdown
Signed-off-by: Uli Schlachter <psychon@znc.in>
Diffstat (limited to 'src/cairo-xcb-shm.c')
-rw-r--r-- | src/cairo-xcb-shm.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/cairo-xcb-shm.c b/src/cairo-xcb-shm.c index 417496eca..cfcf6d19d 100644 --- a/src/cairo-xcb-shm.c +++ b/src/cairo-xcb-shm.c @@ -541,8 +541,7 @@ _cairo_xcb_shm_info_destroy (cairo_xcb_shm_info_t *shm_info) _cairo_freepool_free (&connection->shm_info_freelist, shm_info); /* scan for old, unused pools - hold at least one in reserve */ - if (! cairo_list_is_singular (&connection->shm_pools) && - _cairo_xcb_connection_take_socket (connection) == CAIRO_STATUS_SUCCESS) + if (! cairo_list_is_singular (&connection->shm_pools)) { cairo_xcb_shm_mem_pool_t *pool, *next; cairo_list_t head; |