You are not logged in.

#1 2016-10-16 17:48:36

Annisar
Member
Registered: 2015-10-15
Posts: 11

Mouse lag (very short freezes)

I have a problem with mouse under my Arch - after some time spent on lock screen or after some (more than on lockscreen) time spent using computer, mouse cursor starts to "stutter" - it freezes from very short time every second or so. It's like a break in communication between a computer and mouse for few ms - when I start to make circles with cursor, I make polygonal chains. It's very annoying and problably forced me to more reboots in a week than I did since I started to use Arch to moment when a problem popped up.

Problems started when I moved from Xfce to KDE.

What didn't help:
- removing usbhid and modprobing it back.
- enforcing evdev with Xorg.conf magic.
- watching at polling rate (stable 1kHz)
- using xinput do put device offline and back online.
- using different mice.
- using different DM (lightdm in place of SDDM).
- disabling i915's rc6 (as stated in: http://askubuntu.com/questions/231743/m … bit-12-04)

What did help:
- restarting DM (black screen upon restarting it with SDDM, but the cursor performs great wink)

$ uname -r                                                                                                                                                                                                                                                  ~
4.7.6-1-zen
$ pacman -Q xf86-video-intel xf86-input-evdev plasma-workspace xorg-server                                                                                                                                                                                      ~
xf86-video-intel 1:2.99.917+713+geb01cc5-1
xf86-input-evdev 2.10.4-1
plasma-workspace 5.8.1-1
xorg-server 1.18.4-1

Non-standard kernel parameters:

rd.driver.pre=vfio-pci intel_iommu=on i915.preliminary_hw_support=1 i915.enable_rc6=0 i915.i915_enable_rc6=0

KMS enabled, using built in i7-6700K's gpu.

Last edited by Annisar (2016-10-16 17:51:04)

Offline

#2 2016-10-16 18:05:37

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 16,117

Re: Mouse lag (very short freezes)

How much RAM have you?  What is the output of free -h  ?
I have a feeling you've a memory leak and are starting to encounter page faults (your system is using swap and is starting to thrash)


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#3 2016-10-16 21:17:58

Annisar
Member
Registered: 2015-10-15
Posts: 11

Re: Mouse lag (very short freezes)

Problem just occured, and...

$ LC_ALL=C free -h                                                                                                                                                                                                                                              ~
              total        used        free      shared  buff/cache   available
Mem:            15G        3.7G        7.8G        1.1G        4.2G         10G
Swap:            9G          0B          9G

Offline

#4 2016-10-17 08:05:01

seth
Member
Registered: 2012-09-03
Posts: 8,166

Re: Mouse lag (very short freezes)

Some i/o (and/or cpu) intense process on the run?
Check top and iotop - and watch out for baloo.

Online

#5 2016-10-17 14:34:14

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 16,117

Re: Mouse lag (very short freezes)

Not a swap issue sad  Although, your 9GB swap is a bit small for 15G of RAM.
I have not used KDE for some time.  It used to be there were multiple graphics backend (Xv, opengl, ...) you might check which backend you are using and see how any other options behave.


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#6 2016-10-17 20:32:19

Annisar
Member
Registered: 2015-10-15
Posts: 11

Re: Mouse lag (very short freezes)

Seems that it's neither IO nor CPU related issue - and while investigating I narrowed it down to plasmashell, as restarting it fixes the problem temporarily. I tried also with changing the graphics backend - with no success.

Offline

#7 2016-10-17 21:58:21

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 16,117

Re: Mouse lag (very short freezes)

How about disabling akonadi as an experiment? (or whatever nonsense name they call it now)


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#8 2016-10-18 19:06:47

andreigrig
Member
Registered: 2016-02-04
Posts: 20

Re: Mouse lag (very short freezes)

Can you monitor your CPU usage while you are moving the mouse really fast? I am also having the issue right now. The CPU spikes on all cores when I move the mouse fast in KDE. Plasma, Xorg and every other GUI that is opened gets used up to 30%. At least for me this causes also random short freezes. Perhaps the difference is on the CPU performance? This may be yet a bug in plasma. I am not sure if it's Xorg related right now but I doubt it.

EDIT: It seems like the issue is not with Plasma but more like with Xorg. Is there any workaround or fix for this?

Last edited by andreigrig (2016-10-19 14:11:30)

Offline

#9 2016-10-19 21:28:57

Annisar
Member
Registered: 2015-10-15
Posts: 11

Re: Mouse lag (very short freezes)

@up yeah, it spikes, on all cores, to 60%. What makes you think that issue comes from Xorg?

Offline

#10 2016-10-20 07:02:52

seth
Member
Registered: 2012-09-03
Posts: 8,166

Re: Mouse lag (very short freezes)

If clients and X11 spike at the same time, odds are good the clients just repaint like hell.

Online

#11 2016-10-20 09:59:17

andreigrig
Member
Registered: 2016-02-04
Posts: 20

Re: Mouse lag (very short freezes)

Have tried with another mouse. Issue is gone. If I go back to my Logitech G502, the issue reappears. Tried to play with pool rates with no luck mostly. I turned off the pointer acceleration and seems to help a bit. Don't know what to check anymore...

Offline

#12 2016-10-21 16:46:44

Annisar
Member
Registered: 2015-10-15
Posts: 11

Re: Mouse lag (very short freezes)

andreigrig wrote:

Have tried with another mouse. Issue is gone. If I go back to my Logitech G502, the issue reappears. Tried to play with pool rates with no luck mostly. I turned off the pointer acceleration and seems to help a bit. Don't know what to check anymore...

Is this mouse recognized by xorg as keyboard + mouse? I've got Logitech G600 and another mouse I tried was G300.

Offline

#13 2016-10-21 18:16:29

andreigrig
Member
Registered: 2016-02-04
Posts: 20

Re: Mouse lag (very short freezes)

I'm sorry but I do not know how to check that. I don't think so though, this is my xorg.conf file:

Section "InputDevice"
    # generated from default
    Identifier     "Mouse0"
    Driver         "mouse"
    Option         "Protocol" "auto"
    Option         "Device" "/dev/psaux"
    Option         "Emulate3Buttons" "no"
    Option         "ZAxisMapping" "4 5"
EndSection

Section "InputDevice"
    # generated from default
    Identifier     "Keyboard0"
    Driver         "kbd"
EndSection

Does this happen to you as well? Is the pooling rate set to 1ms? Just use htop and move the mouse randomly as fast as you can.

EDIT: Just checked in dmesg and it seems like it is both a KB and a Mouse. How can I fix this? smile

[    3.289060] input: Logitech Gaming Mouse G502 as /devices/pci0000:00/0000:00:12.0/usb8/8-3/8-3:1.0/0003:046D:C332.0001/input/input2
[    3.289104] hid-generic 0003:046D:C332.0001: input,hidraw0: USB HID v1.11 Mouse [Logitech Gaming Mouse G502] on usb-0000:00:12.0-3/input0
[    3.294371] input: Logitech Gaming Mouse G502 as /devices/pci0000:00/0000:00:12.0/usb8/8-3/8-3:1.1/0003:046D:C332.0002/input/input3
[    3.350735] hid-generic 0003:046D:C332.0002: input,hiddev0,hidraw1: USB HID v1.11 Keyboard [Logitech Gaming Mouse G502] on usb-0000:00:12.0-3/input1

Last edited by andreigrig (2016-10-21 19:04:29)

Offline

Board footer

Powered by FluxBB