Poor Performance with Hardware Acceleration Enabled (Proprietary nvidia driver)
Categories
(Core :: Graphics, defect)
Tracking
()
People
(Reporter: b4yf823ap56y457945ty4w7o, Unassigned)
References
(Depends on 1 open bug, Blocks 1 open bug, Regression)
Details
(Keywords: regression)
Attachments
(5 files)
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:89.0) Gecko/20100101 Firefox/89.0
Steps to reproduce:
Using Linux on Ubuntu 20.04.2
Updated from 88 to 89
Checked that hardware acceleration is enabled.
Accessed https://www.testufo.com and checked FPS.
Actual results:
Performance is worse, scrolling seems laggier, videos on Twitch.tv and Youtube.com are not smooth.
Using https://www.testufo.com my frame rate struggles to go over 50FPS whereas on version 88 it sat at a stable 144FPS.
If I disable Hardware Acceleration from the settings menu then my frame rate returns to 144FPS, this worked in version 88.
Expected results:
Framerate should sit at a comfortable 144FPS with Hardware Acceleration enabled.
I've run mozregression the issue affects all builds of 89 but not of 88 from what I found.
Not sure if I can upload a log or something from mozregression?
Comment 2•3 years ago
|
||
The Bugbug bot thinks this bug should belong to the 'Core::Graphics' component, and is moving the bug to that component. Please revert this change in case you think the bot is wrong.
Maybe worth mentioned I am using an Nvidia GTX 1070 GPU with Proprietary Drivers version 465
Comment 4•3 years ago
|
||
Hi Baa, could you please attach your about:support information to this bug?
Not sure if I can upload a log or something from mozregression?
If you could copy the link where it says "pushlog_url" and paste it here that would be great. Thanks!
(In reply to Jamie Nicol [:jnicol] from comment #4)
Hi Baa, could you please attach your about:support information to this bug?
Not sure if I can upload a log or something from mozregression?
If you could copy the link where it says "pushlog_url" and paste it here that would be great. Thanks!
Hi,
Thanks for your help, the about:support log to the bug.
Here's the mozregression url: https://hg.mozilla.org/releases/mozilla-release/pushloghtml?fromchange=f1258acd08f842bbbb76104d6082f9790dd058fa&tochange=93720442b571341fd6
Kind regards,
Baa.
Comment 7•3 years ago
|
||
Thanks for that! It seems to have run the bisection on the mozilla-release repository, and as a result the range is huge. Would you be able to run it again with the repository set to "mozilla-central"? Thanks!
(In reply to Jamie Nicol [:jnicol] from comment #7)
Thanks for that! It seems to have run the bisection on the mozilla-release repository, and as a result the range is huge. Would you be able to run it again with the repository set to "mozilla-central"? Thanks!
yes here's the new pushlog, there are several so not sure which one is needed:
https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=cdd65df84242fa01e9b2c690fb9078d7fba46cb6&tochange=40bd5bbe396ce4cb1a5bfd86d852307d7e71dc97
I don't know how relevant it is but I noticed this FEATURE_FAILURE_GLXTEST_FAILED note on version 89 that isn't on version 88
Comment 10•3 years ago
|
||
(In reply to Baa from comment #8)
(In reply to Jamie Nicol [:jnicol] from comment #7)
Thanks for that! It seems to have run the bisection on the mozilla-release repository, and as a result the range is huge. Would you be able to run it again with the repository set to "mozilla-central"? Thanks!
yes here's the new pushlog, there are several so not sure which one is needed:
https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=cdd65df84242fa01e9b2c690fb9078d7fba46cb6&tochange=40bd5bbe396ce4cb1a5bfd86d852307d7e71dc97
That still seems like a very large range. It's the final pushlog that is output that we want, which should be much shorter. If you can copy and paste all of the output text that would be great.
Reporter | ||
Comment 11•3 years ago
|
||
(In reply to Jamie Nicol [:jnicol] from comment #10)
Hi,
Sorry I was grabbing the first one, it switches from bisecting mozilla-central to autoland so the last url is this:
https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=8471b70b4df960d3599dcd951f0b05fb4f7bd420&tochange=12744d62ec8944fe64bb028a68bcab2c4665cf7b
Comment 12•3 years ago
|
||
That is perfect, thanks!
So it looks like webrender got enabled for your driver, and it doesn't work well, possibly because of the high refresh rate screen.
The FEATURE_FAILURE_GLXTEST_FAILED message could be the same issue as bug 1715245, however it doesn't appear to have caused you to lose webrender from the about:support in comment 6.
Baa, if you could please capture a performance profile with hardware acceleration enabled that would be really helpful:
- Enable hardware acceleration and restart Firefox
- Go to https://profiler.firefox.com
- Click "Enable Firefox Profiler Menu Button"
- An icon should appear in your toolbar
- Navigate to a slow page (eg the ufotest)
- Click the downwards arrow in the new toolbar icon to open the profiler menu
- Select "Firefox Graphics" for the settings
- Click start recording
- Wait around 10 seconds, then click "Capture"
- This should open up a new tab. In the top-right there should be a "Upload Local Profile" button. Click that, then click "upload"
- Then copy the url to here.
If you need any help with that please let me know!
Updated•3 years ago
|
Comment 13•3 years ago
|
||
(In reply to Baa from comment #9)
I don't know how relevant it is but I noticed this FEATURE_FAILURE_GLXTEST_FAILED note on version 89 that isn't on version 88
Hm, this is odd. A failure in glxtest
should trigger a fallback to software Webrender, which currently is very slow on testufo and probably scrolling on high resolutions. Are you sure your about:support
in comment 6 is correct? Normally these errors should be included there.
Reporter | ||
Comment 14•3 years ago
|
||
(In reply to Robert Mader [:rmader] from comment #13)
I downloaded a new seperate copy of Firefox and opened it with a new profile to generate the about:support after confirming the issue could still be recreated. I just checked now and the GLXTEST_FAILED doesn't show up on this copy of Firefox.
It only shows up on my normal Firefox copy on my normal profile, I've now made a new profile on my normal copy of Firefox and it also doesn't show GLXTEST_FAILED, so not sure what's going on there maybe something is just wrong with my normal profile. The framerate issue is re-creatable in all instances though.
Reporter | ||
Comment 15•3 years ago
|
||
(In reply to Jamie Nicol [:jnicol] from comment #12)
Hi,
See here: https://share.firefox.dev/352Cpqj
Thanks
Comment 16•3 years ago
|
||
From the profile you do indeed seem to be running hardware webrender, so the glxtest failure remains a mystery.
It doesn't look like the renderer thread is at all being taxed. But rather it is attempting to render at 60Hz, which I can very much believe causes performance to appear poor on a 144Hz monitor.
In your about:support I can see that we've detected the targetFrameRate
as 144, but obviously something is going wrong.
Comment 17•3 years ago
|
||
Baa, I can see that in about:config you've set layout.frame_rate
to 144
(or maybe Firefox did that for you). Could you try reseting that to -1
, restart, and see if that makes a difference?
Comment 18•3 years ago
|
||
Also, do you have multiple monitors, or just a single 144Hz monitor?
Reporter | ||
Comment 19•3 years ago
|
||
(In reply to Jamie Nicol [:jnicol] from comment #18)
Also, do you have multiple monitors, or just a single 144Hz monitor?
I have three monitors, only one is 144hz.
I had set the layout.frame_rate to 144 manually as a workaround that worked in earlier versions. I've set it back to -1 and it remains at 60FPS regardless of hardware rendering being enabled or not.
Comment 20•3 years ago
|
||
(In reply to Baa from comment #19)
(In reply to Jamie Nicol [:jnicol] from comment #18)
Also, do you have multiple monitors, or just a single 144Hz monitor?
I have three monitors, only one is 144hz.
I had set the layout.frame_rate to 144 manually as a workaround that worked in earlier versions. I've set it back to -1 and it remains at 60FPS regardless of hardware rendering being enabled or not.
I have a theory here:
- your compositor/WM only draws at 60FPS. On X11, WMs always run at the same FPS for all screens and the driver chooses at which one (Gnome can't pick). You may find some advice how to force 144Hz somewhere.
- On FF 88, you probably didn't get HW-WR but had
Basic
orWebrender (Software)
(SW-WR), now on FF 89 you get HW-WR - Software rendering isn't throttled by the hardware, so 144Hz got reported, but you only saw 60Hz either way
- Hardware rendering does get throttled by the hardware, so now you get some odd ~60Hz, maybe with odd hiccups in between
I'd recommend making sure your WM/driver really runs at 144Hz, to be checked with glxgears
. If that runs smoothly, you should be able to get smooth 144Hz with layout.frame_rate:-1
as well.
Reporter | ||
Comment 21•3 years ago
|
||
(In reply to Robert Mader [:rmader] from comment #20)
So I checked glxgears and it did indeed run at 60FPS, until I disabled Sync to VBlank in the Nvidia driver settings as someone suggested. Now glxgears runs at the highest FPS it can.
Firefox 89 still shows 60FPS on https://testufo.com/ when hardware is enabled.
I'll attach the about:support from Firefox 88 where 144FPS is reported, maybe it can prove your theory?
Reporter | ||
Comment 22•3 years ago
|
||
The about:support from Firefox 88 where hardware rendering is supposedly being used and testufo.com runs at 144FPS
Here is the profiler for the same browser https://share.firefox.dev/3v6uuD1
Comment 23•3 years ago
|
||
(In reply to Baa from comment #22)
Created attachment 9226176 [details]
aboutsupport-88.logThe about:support from Firefox 88 where hardware rendering is supposedly being used and testufo.com runs at 144FPS
Here is the profiler for the same browser https://share.firefox.dev/3v6uuD1
This about:support
reports to run Basic
. You can try enabling gfx.webrender.all
in FF 88, then you should get the same result.
(In reply to Baa from comment #21)
(In reply to Robert Mader [:rmader] from comment #20)
So I checked glxgears and it did indeed run at 60FPS, until I disabled Sync to VBlank in the Nvidia driver settings as someone suggested. Now glxgears runs at the highest FPS it can.
Firefox 89 still shows 60FPS on https://testufo.com/ when hardware is enabled.
I'll attach the about:support from Firefox 88 where 144FPS is reported, maybe it can prove your theory?
I'm not sure if disabling VBlank will really make Gnome run at 144Hz - I found a few comments suggesting using xrandr
, maybe that does the trick? https://askubuntu.com/questions/625827/nvidia-control-panel-reporting-60hz-on-144hz-monitor-how-to-make-ubuntu-output
Comment 24•3 years ago
|
||
Ah, this is apparently the right one: https://www.reddit.com/r/Ubuntu/comments/cegacx/issues_with_dual_monitors_with_different_refresh/
Reporter | ||
Comment 25•3 years ago
|
||
I haven't found a working combination but I think this is probably an Nvidia thing and not Firefox's fault. Just the implementation of hardware support makes it look like a regression.
Thanks for your help all, if I find out otherwise I'll update.
Updated•3 years ago
|
Comment 26•3 years ago
|
||
(In reply to Baa from comment #25)
Does this problem still occur?
If yes, can it be fixed by starting Firefox 92 (minimum 91: bug 1646135) with MOZ_X11_EGL=1 environment variable?
$ MOZ_X11_EGL=1 firefox
Reporter | ||
Comment 27•3 years ago
|
||
(In reply to Darkspirit from comment #26)
(In reply to Baa from comment #25)
Does this problem still occur?If yes, can it be fixed by starting Firefox 92 (minimum 91: bug 1646135) with MOZ_X11_EGL=1 environment variable?
$ MOZ_X11_EGL=1 firefox
Hi,
Yes this is still happening, setting MOZ_X11_EGL=1 fixes it :)
Getting 144FPS on max speed UFOs :)
Reporter | ||
Comment 28•3 years ago
|
||
94 enabled EGL, getting 144FPS with hardware acceleration enabled now :)
Comment 29•3 years ago
|
||
Great, let's close it then.
Description
•