xmodmap really slow
Alan Hourihane
alanh at fairlite.co.uk
Fri Nov 30 11:27:14 UTC 2018
On 30/11/2018 09:38, Alan Hourihane wrote:
> On 30/07/2018 23:25, Alan Hourihane wrote:
>> On 30/07/18 22:00, Adam Jackson wrote:
>>> On Thu, 2018-07-26 at 12:25 +0100, Alan Hourihane wrote:
>>>> Anyone tried just doing this recently....
>>>>
>>>> xmodmap -pke > /tmp/keydump
>>>> xmodmap /tmp/keydump
>>>>
>>>> And watch the Xserver hang for quite some time.
>>> Seems to be nearly instantaneous against an Xvfb, but did cause a
>>> noticable hiccup with Xorg. Haven't investigated more closely, so I'd
>>> suspect (in rough order of likelihood):
>>>
>>> a) something super-linear in the number of input devices
>>> b) some weird slow ioctl syncing the X state to the kernel
>>> c) somehow you end up on the "lets spawn xkbcomp" path and the
>>> fork/exec overhead kills you
>>>
>> Definitely not the last, moving "xkbcomp" from /usr/bin results in the
>> same issue.
> Just checking.....
>
> Has anyone looked into this issue ?
Running perf top while it's happening shows this....
26.77% Xorg [.] ResourceClientBits
15.09% Xorg [.] GrabMatchesSecond
12.62% Xorg [.] DetailSupersedesSecond.isra.1
12.55% Xorg [.] DeletePassiveGrabFromList
8.83% Xorg [.] GrabSupersedesSecond
5.55% Xorg [.] AddPassiveGrabToList
3.09% Xorg [.] DeletePassiveGrab
2.00% Xorg [.] xi2mask_merge
1.16% libc-2.27.so [.] _int_malloc
0.92% libc-2.27.so [.] _int_free
0.59% Xorg [.] XkbSendMap
Xorg is totally frozen while this is happening. No rendering occurs at all.
Alan.
More information about the xorg-devel
mailing list