I’ve been getting micro hiccups on Xorg + gnome-shell using Intel HD Graphics for quite some time now; lag when switching virtual desktops, alt-tabbing apps, and even sometimes when typing in the terminal (local, not over SSH!). I’ve noticed it on both this current machine, a Samsung Series 9 NP900X3C with Intel HD 4000 Graphics, as well as on my previous ThinkPad T420 with Intel HD 3000 Graphics.
I had a look in my Xorg logs and noticed I was using
UXA acceleration, the tried-and-true acceleration for the open-source Intel graphics driver. Sandy Bridge and newer support
SNA (Sandy Bridge New Acceleration), which was experimental at first but has been constantly evolving since 2011 when it was introduced (and there is even discussion of it replacing UXA as the default in Ubuntu at least).
I figure by now it should perform better and use less power, so I’m gonna give it a try to see if it resolves my issues. In Arch Linux at least, it was as simple as adding a config file to Xorg’s modular config directory, /etc/X11/xorg.conf.d/20-intel.conf:
Section "Device" Identifier "Intel Graphics" Driver "intel" Option "AccelMethod" "sna" EndSection
Let’s see if it helps…
So after a few hours I noticed the lag had come back. Xorg even froze once, and I had to hard restart the machine. Someone pointed out that I might want to give the
i915.semaphores=1 kernel cmdline a try. From what I’ve read it seems to be related to power saving, but I’ll see if it makes a difference with the performance hiccups.
Update 2: i915 semaphores are good!
I’ve been running with
i915.semaphores=1 for a week or two now and I can’t recall experiencing hiccups at all, so it seems it’s doing something good…