mesa 18.0.0 will cause rendering errors in Qt applications

Bug #1749472 reported by Rik Mills
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
mesa (Ubuntu)
Invalid
Undecided
Unassigned
Bionic
Invalid
Undecided
Unassigned

Bug Description

From: https://bugreports.qt.io/browse/QTBUG-66348

** extract **

The `QOpenGLShaderProgram` class in Qt can be used to compile and link OpenGL shaders. If the `GL_ARB_get_program_binary` OpenGL extension is available, it can cache those shaders on disk (~/.cache/qtshadercache). The i965 driver in Mesa supports this extension since version 18.0.0.

When the shader is loaded using the `glProgramBinary` function, OpenGL can refuse it if for example some hardware or software component changed. Mesa refuses binaries that were created by any other build of Mesa (using among other things the build_id of the library).

If the shader is refused, Qt should fallback to compiling it from sources, but it incorrectly calls glLinkProgram first. The glLinkProgram succeeds, because it actually links 0 shaders together. That is allowed in OpenGL compatibility profile and the resulting program works as a fixed pipeline. Which of course does not render as expected.

This causes rendering errors in Qt applications every time Mesa is updated since version 18.0.0. For example white screen in sddm.

This issue was originally reported in openSUSE (https://bugzilla.opensuse.org/show_bug.cgi?id=1080578).

** end extract **

As this potentially effects Qt applications, and could even render display manager login unusable, this should be a blocking bug in mesa and Qt until Qt mitigations patches pass codereview and can be included in Qtbase for 18.04.

Rik Mills (rikmills)
tags: added: block-proposed
Revision history for this message
Timo Aaltonen (tjaalton) wrote :

sigh, is this filed upstream?

Revision history for this message
Timo Aaltonen (tjaalton) wrote :

oh it's a qt bug not mesa, got it

Revision history for this message
Dimitri John Ledkov (xnox) wrote :

why is this filed with "block-proposed" tag? Do you intend to prevent mesa from migrating or qt? At the moment this bug is blocking qtbase migration, which is a rebuild against openssl1.1 and I do not see how that change can be related to this bug report.

Revision history for this message
Dimitri John Ledkov (xnox) wrote :

mesa is blocked, in addition to this bug, by other issues, and qtbase is unrelated (e.g. migrating qtbase will not regress this further, nor fix this issue). Thus removing block-proposed tag to migrate qtbase update.

tags: removed: block-proposed
Revision history for this message
Simon Quigley (tsimonq2) wrote :

block-proposed still belongs for mesa, having it blocked for other reasons isn't good enough because this bug will break the Kubuntu and Lubuntu Next desktops.

no longer affects: qtbase-opensource-src (Ubuntu Bionic)
no longer affects: qtbase-opensource-src (Ubuntu)
tags: added: block-proposed
Revision history for this message
Jeremy Bícha (jbicha) wrote :

Is it possible to get just this fix in to bionic now without needing to do an entire Qt transition? The mesa transition has been blocking multiple GNOME transitions for a week and a half already.

Revision history for this message
Simon Quigley (tsimonq2) wrote :

That would be the ideal way to do it because the fix is already installable in the CI Train PPA for the next Qt transition: https://launchpad.net/~ci-train-ppa-service/+archive/ubuntu/3113/+packages

That should be in -proposed before Feature Freeze, if not before then.

Is there a compelling case to get this in *now* and not wait the (maybe) two days?

Revision history for this message
Simon Quigley (tsimonq2) wrote :

Qt 5.9.4 is now in bionic-proposed.

tags: removed: block-proposed
Revision history for this message
Iain Lane (laney) wrote :

That tag means we don't track this as a desktop team commitment, please feel free to still fix the bug though if it's still relevant.

tags: added: rls-bb-notfixing
Revision history for this message
Timo Aaltonen (tjaalton) wrote :

was a qt bug

Changed in mesa (Ubuntu Bionic):
status: New → Invalid
Changed in mesa (Ubuntu):
status: New → 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.