[PATCH] xkb: Check and load precompiled .xkm during startup if available
Pat Suwalski
pat at suwalski.net
Tue Mar 16 08:20:30 PDT 2010
On 16/03/10 09:58 AM, Pat Suwalski wrote:
> I wrote a very similar patch, but I based the name of the
> cached/precompiled file on a sha1 hash of source file.
Actually, I had forgotten that in the most recent revision of my method,
I got tired of patching the X server.
Instead, I wrote the attached wrapper to xkbcomp (with a packaging
diversion of the actual xkbcomp to xkbcomp.real). That way, I didn't
have to patch anything.
Ideally, this methodology would be in the real xkbcomp, and then the
rather ugly parameter parsing could be avoided. I'm sure it's error
prone; this program is only meant to react to the "-xkm" switch and pass
everything else along.
In my testing, this was enough to get just about all of the performance
advantage of the patch to the X server itself. Timing tests didn't show
any difference, in fact.
--Pat
-------------- next part --------------
A non-text attachment was scrubbed...
Name: xkbcomp.c
Type: text/x-csrc
Size: 3038 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg-devel/attachments/20100316/19a32d0e/attachment.c>
More information about the xorg-devel
mailing list