[Xorg] Prefetching extensions

Soeren Sandmann sandmann at daimi.au.dk
Fri Aug 6 08:34:32 PDT 2004

People who read the minutes of the recent architecture board meeting
will know that the conclusion wrt. an extension extension was to delay
it until hardware will make it a necessity and instead apply a hack to
Xlib to reduce the number of round-trips on startup.

So here is an Xlib hack that does two things

        (a) It adds a new 

                XPrefetchExtensions (char **names, int count)

        call that in a single roundtrip will query the extensions and
        store the result in a cache. Subsequent calls to
        XQueryExtensions(), both direct and indirect though things like
        XRenderQueryExtension() will then return without any

        (b) Makes XOpenDisplay() use XPrefetchExtensions() to 
        batch together the initial queries for BIGREQUESTS, XKEYBOARD
        with and the initial GetPropeerty it does.

This is not material for the upcoming release of course.

For people worried about the performance of the linked list caching
scheme, remember that only a small number of extensions are ever
queried for.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: prefetch
Type: application/octet-stream
Size: 11458 bytes
Desc: The patch
URL: <http://lists.x.org/archives/xorg/attachments/20040806/b3204e74/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: PrefetchExtensions.c
Type: application/octet-stream
Size: 3828 bytes
Desc: PrefetchExtensions.c
URL: <http://lists.x.org/archives/xorg/attachments/20040806/b3204e74/attachment-0001.obj>

More information about the xorg mailing list