[PATCH v3 libX11 3/3] config: Add --enable-checked-locks to catch missing XInitThreads calls.

Gaetan Nadon memsize at videotron.ca
Fri Feb 4 13:23:19 PST 2011


On Fri, 2011-02-04 at 16:42 +0200, Rami Ylimäki wrote:

> This change makes it possible to detect missing XInitThreads calls in
> X clients. If a client hasn't called XInitThreads and enters a
> critical section in Xlib concurrently, the client will be aborted with
> a message informing about the missing call.
> 
> Enabling thread safety by default causes a minor performance
> regression for single threaded X clients. However, the performance
> regression is only noticeable in the worst case situation. In
> realistic use cases the overhead from unnecessary locking is difficult
> to see.
> 
> Relative x11perf results showing the amount of regression for worst
> case and some common operations are shown below.
> 
>  unlocked/locked   Operation
> ----------------- ------------------------------------
>            1.001   500-pixel line
>            1.000   Copy 500x500 from window to window
>            2.609   X protocol NoOperation
> 
> Signed-off-by: Rami Ylimäki <rami.ylimaki at vincit.fi>
> Reviewed-by: Erkki Seppälä <erkki.seppala at vincit.fi>
> 

For the configuration part,

Reviewed-by: Gaetan Nadon <memsize at videotron.ca>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.x.org/archives/xorg-devel/attachments/20110204/f563e34e/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
URL: <http://lists.x.org/archives/xorg-devel/attachments/20110204/f563e34e/attachment.pgp>


More information about the xorg-devel mailing list