Graphical corruption Intel HD Graphics 630 when using Firefox nightly in Wayland mode

Bug #1858120 reported by Asif Youssuff
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mozilla Firefox
Invalid
Medium
gnome-shell (Ubuntu)
Fix Released
Undecided
Unassigned
mutter (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Also tracked in: https://bugzilla.mozilla.org/show_bug.cgi?id=1604948

Once every few starts of Firefox on my machine ends up corrupting the display of my Wayland session badly - what looks like a lot of stray marks on my display are seen overlaid on top of all windows, not just Firefox.

Logging out and logging back in resolves the issue, but there is a chance that it recurs on next launch.

Steps to reproduce:

1. Start Gnome session in Wayland mode.
2. Start Firefox Nightly with MOZ_ENABLE_WAYLAND=1

What happens:

Various issues, including "unknown" application appearing in task switcher, stray marks on screen, and dead/inactive windows that persist over other windows even when switching virtual desktops.

Response from Firefox bugzilla says:

This is likely a bug in GS 3.34, fixed by https://gitlab.gnome.org/GNOME/mutter/merge_requests/924 and https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/815, included in 3.34.2 which should arrive soon in Ubuntu 19.10.
---
ProblemType: Bug
ApportVersion: 2.20.11-0ubuntu15
Architecture: amd64
CurrentDesktop: GNOME
DisplayManager: gdm3
DistroRelease: Ubuntu 20.04
InstallationDate: Installed on 2020-01-01 (1 days ago)
InstallationMedia: Ubuntu 20.04 LTS "Focal Fossa" - Alpha amd64 (20191230)
Package: gnome-shell 3.34.1+git20191024-1ubuntu1
PackageArchitecture: amd64
ProcEnviron:
 TERM=xterm-256color
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=en_US.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 5.3.0-24.26-generic 5.3.10
RelatedPackageVersions: mutter-common 3.34.2-2ubuntu1
Tags: focal wayland-session
Uname: Linux 5.3.0-24-generic x86_64
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm cdrom dip lpadmin lxd plugdev sambashare sudo
_MarkForUpload: True

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Created attachment 9116831
Screenshot from 2019-12-18 17-38-52.png

Happy to run debug builds or enable logging to dig into this further.

Once every few starts of Firefox on my machine ends up corrupting the display of my Wayland session badly - what looks like a lot of stray marks on my display are seen overlaid on top of all windows, not just Firefox.

This may be a driver bug, but I am not sure how to dig into that, and I only see this issue when starting Firefox -- but not on every start.

Logging out and logging back in resolves the issue, but there is a chance that it recurs on next launch.

I just experienced this happening 3 times in a row, so finally reporting a bug. Really just want to figure out what is going on.

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Created attachment 9116832
about:support

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Created attachment 9116833
Screenshot from 2019-12-18 17-38-05.png

Revision history for this message
In , Jbonisteel (jbonisteel) wrote :

This seems maybe different from the other UI glitches we have seen recently?

Revision history for this message
In , Jmuizelaar (jmuizelaar) wrote :

Yeah, I think this is different. Asif, do you have an idea of how long this has been happening for?

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

At least a few weeks -- I don't know how to reproduce it consistently, so I never bothered to file a bug. It happened enough times in a row today for me to decide to file a bug to get to the bottom of it.

I will also note that since it corrupts my display and persists until logout, I also never bothered to run a mozregression, because it'd be hard to determine whether the issue is recurring or whether I am seeing the corruption from previous builds.

Revision history for this message
In , Jmuizelaar (jmuizelaar) wrote :

Since the problem persists until logout it suggests there's probably some kind of driver bug that Firefox is hitting. It may be worth filing a bug here https://gitlab.freedesktop.org/mesa/mesa/issues and perhaps with the help of the mesa developers we can figure out what's happening.

Revision history for this message
In , Asif Youssuff (yoasif) wrote :
Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Team, I realized that I could use mozregression inside tmux to persist my mozregression session while logging in and out.

Hope this helps -- it's a pretty big pushlog and I don't want to hazard a guess as to what the issue might be:

43:52.31 INFO: Narrowed inbound regression window from [25bf8e09, db1ddab2] (3 builds) to [425af188, db1ddab2] (2 builds) (~1 steps left)
43:52.31 INFO: No more inbound revisions, bisection finished.
43:52.31 INFO: Last good revision: 425af188aae948e80e6095f096c7835809b2197f
43:52.31 INFO: First bad revision: db1ddab2985dfee5be9524e305cd314b6dcac501
43:52.31 INFO: Pushlog:
https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=425af188aae948e80e6095f096c7835809b2197f&tochange=db1ddab2985dfee5be9524e305cd314b6dcac501

Revision history for this message
In , Release-mgmt-account-bot (release-mgmt-account-bot) wrote :

[Bugbug](https://github.com/mozilla/bugbug/) thinks this bug is a regression, but please revert this change in case of error.

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Created attachment 9117745
visual-corruption-wayland.log

Based on the comments on https://gitlab.freedesktop.org/mesa/mesa/issues/2249:

>To me that looks like an actor stuck in the scene graph of the compositor. You see it even in the overview mode. It's not visible on the Alt-tab widget (which must be above in the scene graph tree).

this seems like a regression from bug 1592350.

The issue doesn't occur for me when I am using a Xorg session.

I took a log using ```WAYLAND_DEBUG=1``` and am attaching it here -- I'll attach a video that corresponds to this log in the next comment.

I opened Firefox, waited to see the issue, then quit Firefox using Ctrl-q.

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Created attachment 9117746
Screencast from 12-25-2019 05:14:28 PM.webm

Revision history for this message
In , Robert Mader (robert.posteo) wrote :

This is likely a bug in GS 3.34, fixed by https://gitlab.gnome.org/GNOME/mutter/merge_requests/924 and https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/815, included in 3.34.2 which should arrive soon in Ubuntu 19.10.

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

FWIW, I am running Ubuntu 20.04 and I surprisingly don't have the latest GNOME Shell, so I am waiting for it. Hoping that resolves it.

Revision history for this message
In , Stransky (stransky) wrote :

Thanks for the info Robert.

Revision history for this message
In , Robert Mader (robert.posteo) wrote :

According to https://packages.ubuntu.com/search?suite=focal&keywords=mutter Ubuntu 20.04 now has GS 3.34.2, so if my guess was correct the issue should be gone now. Asif, can you confirm?

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Robert, I have had that version of mutter for a while, but am still seeing the issue. gnome-shell isn't at 3.34.2 though.

Revision history for this message
In , Stransky (stransky) wrote :

Asif I expect you can't reproduce it when WebRender is disabled, correct? Can you try GL compositor instead of it?

Revision history for this message
In , Stransky (stransky) wrote :

btw. I have the same gfx hw but I don't see it although I'm running Fedora 31 / gnome-shell-3.34.2-1.

Revision history for this message
In , Robert Mader (robert.posteo) wrote :

(In reply to Asif Youssuff from comment #16)
> Robert, I have had that version of mutter for a while, but am still seeing the issue. gnome-shell isn't at 3.34.2 though.

Ah my bad, I somehow assumed they release them in tandem. Then we still have to wait.

Concerning Fedora 31: it has the Mutter/GS patches for a while already, similar to how you backport Firefox Wayland patches. So the Ubuntu Wayland experience is always 1-2 month behind :/

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

(In reply to Martin Stránský [:stransky] from comment #17)
> Asif I expect you can't reproduce it when WebRender is disabled, correct? Can you try GL compositor instead of it?

It works fine when WebRender is disabled.

However, with GL acceleration (layers.acceleration.force-enabled:true), I experienced some of the same issues I see when WR is enabled -- an entry in the alt-tab switcher of "unknown" and stuck windows (cannot see other windows over a dead Firefox window, even when switching virtual desktops). When using alt-`, I can see other windows updating, but I cannot see them if I switch to them.

I tried this twice - I didn't reproduce it the second time (after logging out and logging in again), so it is similar to the WR scenario in that it doesn't happen every time Firefox is started.

I also didn't see the same stray marks on the screen left on top of windows - I have seen the above issues, but wanted to report the stray marks first, since that issue appeared first and I surmised that the other issues might be related.

Revision history for this message
In , Asif Youssuff (yoasif) wrote :
Revision history for this message
In , Robert Mader (robert.posteo) wrote :

(In reply to Asif Youssuff from comment #20)
> ...(cannot see other windows over a dead Firefox window, even when switching virtual desktops). When using alt-`, I can see other windows updating, but I cannot see them if I switch to them. ...

I think this part makes it quite obvious that it is not a Firefox issue but a compositor one: an app like Firefox should *never* be able to stop you from seeing other windows (at least on Wayland, X11 might be another story). And it sounds exactly like the bug fixed in Mutter/GS 3.34.2.

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

New wrinkle -- I just now saw the issue with Basic compositing (no WR or OpenGL acceleration). Screenshot and about:support to follow. Saw this after Firefox crashed and I restarted it (crash was likely Fission related, not this issue).

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Created attachment 9118372
about:support with Basic compositing

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Created attachment 9118373
stray marks on screen with basic acceleration

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Seems like a widget gtk issue now.

Revision history for this message
Asif Youssuff (yoasif) wrote : Dependencies.txt

apport information

tags: added: apport-collected focal wayland-session
description: updated
Revision history for this message
Asif Youssuff (yoasif) wrote : GsettingsChanges.txt

apport information

Revision history for this message
Asif Youssuff (yoasif) wrote : ProcCpuinfoMinimal.txt

apport information

Revision history for this message
Asif Youssuff (yoasif) wrote : ShellJournal.txt

apport information

Revision history for this message
Asif Youssuff (yoasif) wrote : monitors.xml.txt

apport information

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

Went ahead and filed a report with Ubuntu as well: https://bugs.launchpad.net/ubuntu/+source/gnome-shell/+bug/1858120

Revision history for this message
In , Release-mgmt-account-bot (release-mgmt-account-bot) wrote :

The component has been changed since the backlog priority was decided, so we're resetting it.
For more information, please visit [auto_nag documentation](https://wiki.mozilla.org/Release_Management/autonag#prod_comp_changed_with_priority.py).

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

If the problem really was mutter#655 then this would be a duplicate of bug 1844222. But you seem to have the fix for that already (mutter 3.34.2) so it sounds like this is not mutter#655.

Can you please provide a screenshot or photo of the issue?

affects: gnome-shell → ubuntu
no longer affects: ubuntu
affects: gnome-shell (Ubuntu) → mutter (Ubuntu)
Changed in firefox (Ubuntu):
status: New → Incomplete
Changed in mutter (Ubuntu):
status: New → Incomplete
Revision history for this message
Asif Youssuff (yoasif) wrote :

It looks like the latest gnome-shell fixed the issue for me:

apt policy gnome-shell
gnome-shell:
  Installed: 3.34.3-1ubuntu1
  Candidate: 3.34.3-1ubuntu1
  Version table:
 *** 3.34.3-1ubuntu1 500
        500 http://us.archive.ubuntu.com/ubuntu focal/main amd64 Packages
        100 /var/lib/dpkg/status

Revision history for this message
In , Asif Youssuff (yoasif) wrote :

It looks like the latest gnome-shell fixed the issue for me:

apt policy gnome-shell
gnome-shell:
  Installed: 3.34.3-1ubuntu1
  Candidate: 3.34.3-1ubuntu1
  Version table:
 *** 3.34.3-1ubuntu1 500
        500 http://us.archive.ubuntu.com/ubuntu focal/main amd64 Packages
        100 /var/lib/dpkg/status

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

More likely I think it was the mutter 3.34.3 update, but still good news.

Changed in mutter (Ubuntu):
status: Incomplete → Fix Released
affects: firefox (Ubuntu) → gnome-shell (Ubuntu)
Changed in gnome-shell (Ubuntu):
status: Incomplete → Fix Released
Changed in firefox:
importance: Unknown → Medium
status: Unknown → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.