Closed Bug 1862039 Opened 2 years ago Closed 2 years ago

Consider not using GL_CONTEXT_FLAG_NO_ERROR_BIT to avoid crashes in Mesa

Categories

(Core :: Graphics: CanvasWebGL, defect)

defect

Tracking

()

RESOLVED FIXED
122 Branch
Tracking Status
firefox122 --- fixed

People

(Reporter: jrmuizel, Assigned: nical)

References

(Regressed 1 open bug)

Details

Attachments

(2 files)

Blocks: gfx-triage

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

This comes from here: https://searchfox.org/mozilla-central/rev/aa8a99510c0686cdf9d42fb4b8f6d968884c961d/dom/canvas/WebGLContext.cpp#275

Thoughts Kelsey?

That just got added in bug 1841050 and the pref is flipped on Windows only right now. Perhaps we flip the pref on linux as well?

See Also: → CVE-2023-6204
See Also: → 1855911
See Also: → 1850271

It seems to me that the pref is enabled on macOS and Linux but not on Windows, see here. Maybe the intention was to only enable it on Windows and not vice-versa?

I think false + no_error = error, ie return an error in the case of something invalid instead of not checking and letting it through.

We should blocklist to prevent using no_error on unfixed mesa.

Type: enhancement → defect
Assignee: nobody → nical.bugzilla
Pushed by nsilva@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/1e7d530afef0 Don't set GL_CONTEXT_FLAG_NO_ERROR_BIT with mesa. r=gfx-reviewers,jgilbert,jrmuizel
Attachment #9362559 - Attachment description: Bug 1862039 - Don't set GL_CONTEXT_FLAG_NO_ERROR_BIT with mesa. r=#gfx-reviewers → Bug 1862039 - Pref webgl_gl_khr_no_error off on Linux. r=#gfx-reviewers
Pushed by nsilva@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/10f8c40533f1 Pref webgl_gl_khr_no_error off on Linux. r=gfx-reviewers,jgilbert,jrmuizel
Flags: needinfo?(nical.bugzilla)

Backed out for causing mochitest failure on test_2_conformance2__transform_feedback__transform_feedback.html

Backout link

Push with failures

Failure log

Flags: needinfo?(nical.bugzilla)
Flags: needinfo?(nical.bugzilla)
No longer blocks: gfx-triage

The severity field is not set for this bug.
:jgilbert, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(jgilbert)
Attached file about_support
I believe this bug is affecting me, not 100% sure but it smells the same, however FF crashes so bad I never get any crash info, so that may not be entirely identical. Still I wanted to chime in because it means automated crash report would not show this. I'm on a fairly recent ubuntu 23.10 install and using firefox from mozilla stable PPA. On a freshly created profile I load youtube in a few tabs, see a few videos switching around, even switching our of FF to another app, and I quickly get a freeze while the following messages on the command line: ... MESA: error: Failed to query drm device. libEGL warning: egl: failed to create dri2 screen MESA: error: Failed to query drm device. libEGL warning: egl: failed to create dri2 screen ... I started to experience the bug fairly recently, or at least it started to hit me really bad a couple days ago and I may not have bothered before. Let me know if you need more details from me, below are the

I believe this bug is affecting me, not 100% sure but it smells the same, however FF crashes so bad I never get any crash info, so that may not be entirely identical. Still I wanted to chime in because it means automated crash report would not show this.

I'm on a fairly recent ubuntu 23.10 install and using firefox from mozilla stable PPA.
On a freshly created profile I quickly get a freeze loading youtube in a few tabs, seeing a few videos, switching out of FF to another app (something the failed test mentioned in #10 seems to care about), and on the command line I get:

MESA: error: Failed to query drm device.
libEGL warning: egl: failed to create dri2 screen
MESA: error: Failed to query drm device.
libEGL warning: egl: failed to create dri2 screen

I started to experience the bug fairly recently, or at least it started to hit me really bad a couple days ago and I may not have bothered before.
Attached is the about:config report copied listerally just before a freeze.

Nical, where did this end up?

Flags: needinfo?(nical.bugzilla)
Severity: -- → S2
Flags: needinfo?(jgilbert)

There are a couple of tests that fail if GL_CONTEXT_FLAG_NO_ERROR_BIT is set (they generate an error). I haven't investigated that much. I should probably have marked them as failing on linux and re-landed but it fell of the radar.

Flags: needinfo?(nical.bugzilla)
Blocks: 1855911

(In reply to François from comment #13)

I believe this bug is affecting me, not 100% sure but it smells the same, however FF crashes so bad I never get any crash info, so that may not be entirely identical. Still I wanted to chime in because it means automated crash report would not show this.

I'm on a fairly recent ubuntu 23.10 install and using firefox from mozilla stable PPA.
On a freshly created profile I quickly get a freeze loading youtube in a few tabs, seeing a few videos, switching out of FF to another app (something the failed test mentioned in #10 seems to care about), and on the command line I get:

MESA: error: Failed to query drm device.
libEGL warning: egl: failed to create dri2 screen
MESA: error: Failed to query drm device.
libEGL warning: egl: failed to create dri2 screen

I started to experience the bug fairly recently, or at least it started to hit me really bad a couple days ago and I may not have bothered before.
Attached is the about:config report copied listerally just before a freeze.

Release 120.0.1 seems to have fixed my issue which most likely was not related to this ticket.

Pushed by nsilva@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/81395545d414 Pref webgl_gl_khr_no_error off on Linux. r=gfx-reviewers,jgilbert,jrmuizel
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 122 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: