You are not logged in.

#26 2016-06-14 05:41:24

tummychow
Member
Registered: 2014-08-03
Posts: 4

Re: Firefox lag recently

Just wanted to throw in my 2c here, I was also seeing some lag recently after using mpv. After watching a video, all instances of firefox I opened would exhibit significant lag until I restarted X. Some videos could repro, others couldn't, others only repro'd when fullscreened but would not repro if they were smaller than the whole screen area. Other applications didn't seem to show any lag. Ditching xf86-video-intel and switching back to the modesetting driver has resolved the issue for me.

For a while before this I was consistently getting this https://bugs.freedesktop.org/show_bug.cgi?id=95368 delightful bug pretty much whenever I scrolled in firefox, and the kernel update fixed it. I guess it must have broken some other stuff in the process... I'll just have to stick to modesetting for now. Thankfully Firefox and my terminal make up 99% of my windows. Video is not nearly as smooth in the modesetting driver as it was on xf86-video-intel SNA acceleration (I occasionally see flicker or scanlines) but I can live with it, I suppose.

Last edited by tummychow (2016-06-14 05:43:45)

Offline

#27 2016-06-14 10:18:05

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 25,636
Website

Re: Firefox lag recently

raddecen wrote:

I recently ditched the xf86-video-intel driver and it improved the hardware acceleration in Firefox a lot. However, LibreOffice ecrashed with "gpu hang"s everytime I opened it and I had to reinstall it. Did you experience this issue?

No.  But I don't use firefox or libreoffice.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#28 2016-06-15 19:52:39

epinephrine
Member
From: Frankfurt
Registered: 2012-10-18
Posts: 86

Re: Firefox lag recently

I have the same problem in firefox and a couple of other applications like RStudio.  linux-lts helps, like others have noted.

What I just found out is that the firefox window doesn't get refreshed until I move the mouse cursor. So while typing this message, I am typing in the dark until I move the cursor. Super weird.

Edit: I use i3 and start `compton -b` in .xinitrc

Last edited by epinephrine (2016-06-16 15:13:57)

Offline

#29 2016-06-16 02:13:20

karna
Member
Registered: 2015-02-02
Posts: 25

Re: Firefox lag recently

Glad to fins this thread. I am having this probelm since a couple of days. Exactly as epinephrine described it. I use firefox and matlab that have been affected.

Offline

#30 2016-06-16 10:24:19

nesk
Member
Registered: 2011-03-31
Posts: 174

Re: Firefox lag recently

tummychow wrote:

Just wanted to throw in my 2c here, I was also seeing some lag recently after using mpv. After watching a video, all instances of firefox I opened would exhibit significant lag until I restarted X. Some videos could repro, others couldn't, others only repro'd when fullscreened but would not repro if they were smaller than the whole screen area. Other applications didn't seem to show any lag. Ditching xf86-video-intel and switching back to the modesetting driver has resolved the issue for me.

Thanks for posting, I had exactly this, removing xf86-video-intel fixed it.

Offline

#31 2016-06-16 14:15:37

FreeFull
Member
Registered: 2012-07-11
Posts: 2

Re: Firefox lag recently

I have ran into this issue too, with Firefox and sunvox. I kept xf86-video-intel installed, and put xcompmgr & in my .xinitrc, and that seems to have fixed it.

Offline

#32 2016-06-16 18:52:44

karna
Member
Registered: 2015-02-02
Posts: 25

Re: Firefox lag recently

FYI, changing the acceleration method from default 'sna' to 'uxa' solved it for me.
https://bbs.archlinux.org/viewtopic.php … 1#p1634451

Offline

#33 2016-06-16 22:07:20

incertia
Member
Registered: 2014-10-25
Posts: 27

Re: Firefox lag recently

booted into linux-lts instead of normal linux. can confirm that the neweset kernel version has some problems.

Offline

#34 2016-06-18 16:23:42

childerico
Member
From: Italy
Registered: 2015-11-18
Posts: 56

Re: Firefox lag recently

I had the same issues and solved using LTS kernel or 'uxa' acceleration method, as already noted.

However, someone suggested to remove 'xf86-video-intel'. Is this the "real" fix or next releases of kernel/Intel driver will fix the issue as well?

Offline

#35 2016-06-18 16:31:13

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 25,636
Website

Re: Firefox lag recently

childerico, none of these are the "real" fix.  I suspect the root of the problem will be patched up eventually.  But this problem only impacts people using xf86-video-intel.  Well before this problem came up, xf86-video-intel as already optional and advised against by some.

Removing xf86-video-intel is as much a real fix for this problem as an appendectomy is a real fix for appendicitis.  It doesn't get at the root cause of the problem, but if it's so easy to remove the problematic bit which has no real function of it's own, that is the best approach.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#36 2016-06-18 16:38:04

childerico
Member
From: Italy
Registered: 2015-11-18
Posts: 56

Re: Firefox lag recently

@Trillby, thanks for the explanation!

Offline

#37 2016-06-19 12:17:27

Gusar
Member
Registered: 2009-08-25
Posts: 3,605

Re: Firefox lag recently

Rather than just doing something to avoid the issue (switch to UXA, ditch xf86-video-intel, ...), I actually went to find the cause. It seems to be commit 658-g46ffdf2 in xf86-video-intel. What's happening is not "lag", it's that the screen stops updating until something (like moving the mouse) causes an update. Right now I'm using 657-g2205da0 and things are working fine so far.

Edit: Because bugs won't get fixed if everyone just works around them, I opened a bug upstream: https://bugs.freedesktop.org/show_bug.cgi?id=96591

Edit2: It started happening again, so it's not that commit. Jeez. It's not so easy to bisect, because it only starts happening after X has been running for some time. I'll update the upstream report.

Last edited by Gusar (2016-06-19 12:47:53)

Offline

#38 2016-06-19 14:06:25

mrlamud
Member
Registered: 2014-09-27
Posts: 95

Re: Firefox lag recently

I guess the problem is intel gfx specific and it might be caused by this patch : https://patchwork.freedesktop.org/patch/87908/

Previous linux kernel 4.6.1 in official repo had this patch applied in PKGBUILD and it caused playing flash video in full screen mode freeze in firefox , by moving mouse cursor then video would continue playing for a while and then freeze again.

I can confirm this because I recompiled kernel 4.6.1 without those patch and  everything worked as it should, including full screen flash video in Firefox.

And now those patch merged in Kernel 4.6.2 so the symptom remains.

I had to apply some patches in order to solve the problem.

see this post https://bbs.archlinux.org/viewtopic.php?id=213950

Offline

#39 2016-06-19 14:21:55

Gusar
Member
Registered: 2009-08-25
Posts: 3,605

Re: Firefox lag recently

I'm using kernel 4.5.6 though (self-compiled, not provided by Arch), and that patch has to do with panel self-refresh, which doesn't apply to me (VGA connection here, while panel self-refresh only applies to eDP). So while it might be the kernel, it's something other than that particular patch. And I'm starting to think it is the kernel, because no matter which xf86-video-intel version I use, at some point the issue appears. The LTS kernel is 4.4, so maybe both 4.5 and 4.6 are broken. Bisecting the kernel, that's a little less fun than bisecting xf86-video-intel.

Edit: I'm probably going nuts, or maybe not. Rather than go with the lts kernel, I went to 4.7-rc. Things are crazy. Video playback either stutters or tears, go fullscreen and back, things are fine, go fullscreen and back again, everything goes crazy again. Man is Intel a mess lately. I'm this close " " to following the other's lead and go with UXA or ditch xf86-video-intel.

Last edited by Gusar (2016-06-19 15:48:17)

Offline

#40 2016-06-19 17:28:45

AnAkkk
Member
Registered: 2014-03-03
Posts: 148

Re: Firefox lag recently

If removing xf86-video-intel fixes the problem, it might be because modesetting use DRI3 by default and xf86-video-intel doesn't. Have you tried to enable DRI3 on xf86-video-intel?

Offline

#41 2016-06-20 16:17:35

subraizada3
Member
Registered: 2013-06-02
Posts: 90

Re: Firefox lag recently

I have the same problem (extreme lag in FF, plus moderate lag in Thunderbird) with the 4.6 kernel; however, I am not using the Intel drivers. I have a GTX 680 + i7-3930k (no integrated graphics on the CPU). I am using the nvidia proprietary drivers (pacman -Qs intel gives only mesa, lib32-mesa, and intel-tbb). Downgrading to the 4.5 kernel fixed the problem.

Last edited by subraizada3 (2016-06-20 16:20:33)

Offline

#42 2016-06-20 16:58:08

Gusar
Member
Registered: 2009-08-25
Posts: 3,605

Re: Firefox lag recently

@AnAkkk, yes, I tried DRI3, in fact I always use it.

An Intel dev responded on my bug report, he says that, considering mouse movement triggers an update, I should look at the kernel. Which makes sense, because the version of xf86-video-intel doesn't seem to matter. So sometime soon™ I'll be trying out various kernel versions. In the meantime, I've switched to UXA.

Offline

#43 2016-06-21 23:38:06

made_in_nz
Member
From: Wellington, New Zealand
Registered: 2010-01-04
Posts: 53

Re: Firefox lag recently

same issue here - lag in firefox only in second monitor.
switching from SNA to UXA got around the problem

$ cat /etc/X11/xorg.conf.d/20-intel.conf
Section "Device"
   Identifier  "Intel Graphics"
   Driver      "intel"
   Option      "AccelMethod" "uxa"
EndSection

Offline

#44 2016-06-24 23:30:21

fasolt
Member
From: Australia
Registered: 2013-04-07
Posts: 6

Re: Firefox lag recently

The package with which I was having the speed problems (or display problems, as it seems) was Anki, and nothing else was causing any trouble. Removing xf86-video-intel solved the Anki problem, but introduced some strange graphical artifacts when scrolling pages in Chromium. Reinstalling xf86-video-intel and switching from SNA to UXA fixed the Anki and Chromium problems, but I was no longer able to watch videos: the screen ceased to update unless I moved the mouse, so it was essentially impossible to watch anything. Did anyone else experience either the Chromium scrolling artifacts or the inability to watch video with UXA?

Offline

#45 2016-06-25 08:21:05

Gusar
Member
Registered: 2009-08-25
Posts: 3,605

Re: Firefox lag recently

fasolt wrote:

but I was no longer able to watch videos: the screen ceased to update unless I moved the mouse, so it was essentially impossible to watch anything.

Don't use Xv to watch video. Use either OpenGL or the native VAAPI output. Only mpv has a native VAAPI output (--vo=vaapi), but other players should have OpenGL. You should be using mpv anyway smile

Last edited by Gusar (2016-06-25 08:21:51)

Offline

#46 2016-06-25 09:40:43

Gusar
Member
Registered: 2009-08-25
Posts: 3,605

Re: Firefox lag recently

Apologies for double posting, but this is big, I think I figured it out!

It's framebuffer compression. It got turned on by default in the 4.6 kernel. That's why going to the LTS kernel fixes things for people, it's not turned on there. So, with the 4.6 kernel, load the i915 module with enable_fbc=0. Refer to the relevant wiki pages on how to set kernel module parameters.

Last edited by Gusar (2016-06-25 09:41:43)

Offline

#47 2016-06-25 11:24:38

nomorewindows
Member
Registered: 2010-04-03
Posts: 3,286

Re: Firefox lag recently

Hmm....maybe a different problem, but firefox has seemed to all but die on me.  It won't bring up any pages, like a network problem or something.  But opera and firefox-developer-edition seem to be ok.  Maybe some other problems not related to video even though I am using xf86-video-intel.  Could be I have many pages open, but not doing anything with any of them is odd.


I may have to CONSOLE you about your usage of ridiculously easy graphical interfaces...
Look ma, no mouse.

Offline

#48 2016-06-25 12:26:16

fasolt
Member
From: Australia
Registered: 2013-04-07
Posts: 6

Re: Firefox lag recently

Gusar wrote:

Don't use Xv to watch video. Use either OpenGL or the native VAAPI output. Only mpv has a native VAAPI output (--vo=vaapi), but other players should have OpenGL. You should be using mpv anyway smile

Thanks, that solved the problem; hitherto I've been using mplayer like a pleb, so I'll make the switch!

Edit:

Gusar wrote:

Apologies for double posting, but this is big, I think I figured it out!

It's framebuffer compression. It got turned on by default in the 4.6 kernel. That's why going to the LTS kernel fixes things for people, it's not turned on there. So, with the 4.6 kernel, load the i915 module with enable_fbc=0. Refer to the relevant wiki pages on how to set kernel module parameters.

Can confirm that running the 4.6 kernel with enable_fbc=0 and xf86-video-intel reverted to the default SNA acceleration also solves the problem for me.

Last edited by fasolt (2016-06-25 12:41:29)

Offline

#49 2016-06-25 21:29:24

GSF1200S
Member
Registered: 2008-12-24
Posts: 474

Re: Firefox lag recently

Trilby wrote:

A better workaround seems to be just ditching the xf86-video-intel driver.  I couldn't figure out why I had these problems on one computer but not the other until I realized I had tried getting rid of xf86-video-intel on one of them.

Allegedly the intel driver is no longer necessary and there is some debate over whether it or the built in modesetting driver perform better (they each seem to win some battles).  But with this issue, I've ditched the intel driver completely and all is well.

If I remove xf86-video-intel, X fails to start hmm No screens found. I remember reading about being able to remove it before, but after X failed I just reinstalled and figured id deal with it later. Laziness prevails- that was months ago tongue

For guys with this problem, I dont have any problems with the driver. With Compton enabled I dont have tearing while scrolling either. I did have to create an xorg.conf so I could add sna as the accelmethod and to add tearfree true in order to get everything smooth. So:

Section "Device"
   Identifier  "Intel Graphics"
   Driver      "intel"
   Option      "TearFree"    "true"
   Option      "AccelMethod"  "sna"
EndSection

is my /etc/X11/xorg.conf. If you do stick with the driver, hope that helps.

Offline

#50 2016-06-29 06:34:42

gothmog123
Member
Registered: 2012-10-31
Posts: 106

Re: Firefox lag recently

fasolt wrote:

Can confirm that running the 4.6 kernel with enable_fbc=0 and xf86-video-intel reverted to the default SNA acceleration also solves the problem for me.

Me too.

Offline

Board footer

Powered by FluxBB