Open Bug 1800175 Opened 2 years ago Updated 11 months ago

Hardware support disabled by default but only on Wayland (on XOrg works fine)

Categories

(Core :: Graphics: WebRender, defect)

Firefox 102
defect

Tracking

()

UNCONFIRMED

People

(Reporter: white_wolf, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(3 files)

Attached image firefox_01.png

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Firefox/102.0

Steps to reproduce:

  1. Open Firefox on Debian 11 (Firefox 102.4.0esr)
  2. Launch videos on YouTube

Actual results:

Low frame rate during playing any videos and poor quality (low resolution).
I checked in "about:support", that "Compositing" is set as "WebRender (Software)"(attachment firefox_01.png). It's mean, that hardware support for decoding videos is disabled. But, after switching from Wayland to XOrg, everything working fine. After switching to Wayland again, I manually set gfx.webrender.all to true. Now everything works fine.

Expected results:

"Compositing" should be set as "WebRender" on default, but on Wayland is not.

I assume the security checkbox was set by mistake.

Group: firefox-core-security

The Bugbug bot thinks this bug should belong to the 'Core::Graphics: WebRender' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: Untriaged → Graphics: WebRender
Product: Firefox → Core

(In reply to :Gijs (he/him) from comment #1)

I assume the security checkbox was set by mistake.

Of course. I'm sorry. My fault

Can you attach the entire Graphics section of about:support?

Flags: needinfo?(glowacki.jaroslaw)
Flags: needinfo?(glowacki.jaroslaw)

(In reply to Jeff Muizelaar [:jrmuizel] from comment #4)

Can you attach the entire Graphics section of about:support?

Yes, of course. I have already added it to the "Attachments" section.
Best Regards

Can you try Firefox Nightly and attach the Graphics section of about:support?

Flags: needinfo?(glowacki.jaroslaw)
Flags: needinfo?(glowacki.jaroslaw)

(In reply to Jeff Muizelaar [:jrmuizel] from comment #7)

Can you try Firefox Nightly and attach the Graphics section of about:support?
Hi
I have added another doc: "Graphics section of about:support - from Nightly" in Attachments section. I don't know how to switch language to English, so document is in Polish. If there is a problem, please let me know how set language to English.
Best regards

Andrew, it's not clear to me from the about:support what's going on. Do you have an interpretation? Can we make it clearer?

Flags: needinfo?(aosmond)

User's info:

The reason why HW WR is blocked for GLX/Xwayland is bug 1635186 comment 49:
Switching to EGL and RenderCompositorEGL fixed that Xwayland bug, therefore EGL is required for HW WR on Xwayland.
Mesa 21 is required for HW WR on Xwayland because Mesa 21 is required for X11_EGL. It could be lowered.
https://searchfox.org/mozilla-central/rev/3d01e045479a6e5237958bd9aa8eb64306e1f48a/widget/gtk/GfxInfo.cpp#745

Other relevant Xwayland bug:
EGL partial present has been broken below xwayland 1.20.10 (Mesa version doesn't matter): bug 1677892
Debian stable has the fix: xwayland 1.20.11 https://packages.debian.org/stable/xwayland

I assume the Mesa version requirement for xwayland and X11_EGL could be lowered from Mesa 21 to Mesa 20 if I haven't forgotten another bug.

Supported GL version seems high enough:

WebGL 1: 3.0 Mesa 20.3.5
WebGL 2: 3.3 (Core Profile) Mesa 20.3.5

EGL requires OpenGL 3.2 core or GLES 3.

(In reply to [:white_wolf] from comment #0)
To enable hardware rendering on Xwayland on Mesa 20, open about:config, set gfx.webrender.all to true, gfx.x11-egl.force-enabled to true, restart Firefox.

(In reply to Darkspirit from comment #12)

(In reply to [:white_wolf] from comment #0)
To enable hardware rendering on Xwayland on Mesa 20, open about:config, set gfx.webrender.all to true, gfx.x11-egl.force-enabled to true, restart Firefox.

Hi. Thanks for the reply.
I know the way how to fix it manually, but I'm wondering why hardware support for WebRendering is disabled by default in this scenario.
Best Regards

Flags: needinfo?(jan)

comment 11 contained the full explanation:

  • EGL_X11 is blocked for Mesa 20 (>=Mesa 21 was an arbitrary limit), therefore GLX is used.
  • EGL is required for HW WR on Xwayland to avoid bug 1635186 comment 49, therefore SW WR is used.
Flags: needinfo?(jan)

So that changes my question for aosmond. The new question is: Shouldn't "FEATURE_FAILURE_WEBRENDER_BUG_1635186" or some better explanation show up in the about:support as the reason things are disabled?

Flags: needinfo?(aosmond)
Flags: needinfo?(aosmond)
Severity: -- → S3

(In reply to Darkspirit from comment #14)

comment 11 contained the full explanation:

  • EGL_X11 is blocked for Mesa 20 (>=Mesa 21 was an arbitrary limit), therefore GLX is used.
  • EGL is required for HW WR on Xwayland to avoid bug 1635186 comment 49, therefore SW WR is used.

Hi
That explains everything.
Thank you all.
Best

Appears to be a regression of bug 1625474. I will file a bug about fixing this.

Flags: needinfo?(aosmond)

(In reply to Andrew Osmond [:aosmond] (he/him) from comment #17)

Appears to be a regression of bug 1625474. I will file a bug about fixing this.

Actually I am not sure now....

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: