Mouse/GUI stuttering on X1 Carbon Gen9

Hi,

I have a Lenovo X1 Carbon Gen 9 with an i7-1165G7 and 32 GB of memory, but sometimes the system starts stuttering, the cursor doesn’t move smoothly and audio / windows have micro freezes. I’m not sure I saw this behavior on a fresh boot, it usually starts after a dozen minutes, or after assigning USB devices to Qubes. The system doesn’t use suspend/resume because that doesn’t work.

I also have Qubes OS on an old T470 with an i5-7300U and 8 GB of memory, Qubes OS runs a lot smoother, I never experienced any stuttering there. The processor is much older and way less powerful, but yet the experience is so better that I prefer using this one than the X1.

Any idea what to investigate?

Maybe check dom0 memory usage and CPU load.

I’ve seen similar problems on a Dell with i7-1185G7. The problems starts when I plug-in drives to USB. Interestingly, a USB mouse will work fine, but the trackpad stutters.

Maybe the reason is that xen does not properly distribute load for CPUs. It runs some processes like video playback or copying/encryption on the the same CPU as dom0 is processing mouse.

I also have mouse that is not moving smoothly when I run dd/shred on flash disk or download torrents. But half of the time cursor is completely fine and not affected, it can be explained if xen is selecting utilizing CPU almost randomly.

P.S. There are several similar issues/tickets on github.

1 Like

This could be tested by pinning specific CPU cores to dom0 and leaving the rest to other VMs:

2 Likes

I participated in the linked discussion, but to check my theory I do not have enough expertise, time and motivation. I hope that if the reason of shuttering is what I said, then it will be eventually fixed by xen developers, who way better understand CPU scheduling than I.

I updated (using testing updates) just after the thread, the problem seems gone with kernel 6.1.28 :exploding_head:

2 Likes

Please keep us posted if it happens again. Because for me it happens randomly.

1 Like

I’m not entirely sure, but it seems that memory balooning is doing the stutter. Using firefox in an AppVm with memory balloon just make regular stutter, but just on this computer, not on my older one. It may be that on my older computer, there isn’t much memory so there is less memory management task done.

Interesting idea. On the other hand in my cases the stutter happens during CPU or I/O load (like torrent download, archive unpacking, writing to flash disk), does not look like memory-exhausting process.