Bug 2294145 - mesa 24.1.x broke xvfb opengl
Summary: mesa 24.1.x broke xvfb opengl
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: mesa
Version: 40
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: José Expósito
QA Contact: Fedora Extras Quality Assurance
URL: https://buildbot.octave.org/#/builder...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2024-06-25 03:50 UTC by Dmitri A. Sergatskov
Modified: 2024-07-13 02:46 UTC (History)
11 users (show)

Fixed In Version: mesa-24.1.2-8.fc40
Clone Of:
Environment:
Last Closed: 2024-07-13 02:46:29 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
those are bad.svg and good.svg produced on Centos Stream 9 (1010 bytes, application/gzip)
2024-06-25 03:51 UTC, Dmitri A. Sergatskov
no flags Details
those are bad.svg and good.svg produced on Centos Stream 9 (1013 bytes, application/gzip)
2024-06-25 03:52 UTC, Dmitri A. Sergatskov
no flags Details

Description Dmitri A. Sergatskov 2024-06-25 03:50:08 UTC
Octave buildbots (running on fedora host) are using Xvfb for headless printing of opengl figures. After up date to mesa 24.1.x this broke. Octave uses "gl2ps" library to convert opengl figures to pdf/postscript/svg. By inspecting those files one can see a number of "NaNs" where some numbers suppose to be.    

Reproducible: Always

Steps to Reproduce:
1.Run octave in Xvfb buffer: "xvfb-run octave"
2.At the octave prompt execute:
  octave:1> plot(1:3)
  octave:2> print bad.svg
3. For the reference, repeat the same with a "normal" octave session. Start octave and then do 
octave:1> plot(1:3)
octave:2> print good.svg

Actual Results:  
In the bad.svg one can see lines like:
<polyline fill="none" points="-nan,-nan -nan,-nan" stroke="#262626" stroke-dasharray="16,0" stroke-linecap="square" stroke-linejoin="miter" stroke-width="1"/>
<polyline fill="none" points="-nan,-nan -nan,-nan" stroke="#262626" stroke-dasharray="16,0" stroke-linecap="square" stroke-linejoin="miter" stroke-width="1"/>
<polyline fill="none" points="-nan,-nan -nan,-nan" stroke="#262626" stroke-dasharray="16,0" stroke-linecap="square" stroke-linejoin="miter" stroke-width="1"/>
<polyline fill="none" points="-nan,-nan -nan,-nan" stroke="#262626" stroke-dasharray="16,0" stroke-linecap="square" stroke-linejoin="miter" stroke-width="1"/>


Expected Results:  
In a good.svg the corresponding lines are 
<polyline fill="none" points="54.6167,280.435 380.215,280.435" stroke="#262626" stroke-dasharray="16,0" stroke-linecap="square" stroke-linejoin="miter" stroke-width="1"/>
<polyline fill="none" points="54.6167,23.6323 380.215,23.6323" stroke="#262626" stroke-dasharray="16,0" stroke-linecap="square" stroke-linejoin="miter" stroke-width="1"/>
<polyline fill="none" points="54.6167,280.435 54.6167,23.6323" stroke="#262626" stroke-dasharray="16,0" stroke-linecap="square" stroke-linejoin="miter" stroke-width="1"/>
<polyline fill="none" points="380.215,280.435 380.215,23.6323" stroke="#262626" stroke-dasharray="16,0" stroke-linecap="square" stroke-linejoin="miter" stroke-width="1"/>


The problem is reproduced on Fedora 40 with 24.1.1 and 24.1.2 and on Centos Stream 9 with 24.1.0. Try different video card (AMD, Intel, Nvidia with both free and proprietary drivers).

Comment 1 Dmitri A. Sergatskov 2024-06-25 03:51:38 UTC
Created attachment 2038201 [details]
those are bad.svg and good.svg produced on Centos Stream 9

Comment 2 Dmitri A. Sergatskov 2024-06-25 03:52:08 UTC
Created attachment 2038202 [details]
those are bad.svg and good.svg produced on Centos Stream 9

Comment 3 José Expósito 2024-07-01 16:45:53 UTC
Hi @dasergatskov

Are you still able to reproduce this issue in Fedora with the latest mesa? (mesa-24.1.2-7.fc40)

I'm not able to reproduce it, but I'm not sure whether it is because the issue is fixed or because it depends on the hardware used.

Comment 4 Dmitri A. Sergatskov 2024-07-01 18:49:49 UTC
Yes, I still have a problem with mesa-24.1.2-7.fc40.
I played a little bit and now I think the issue is with llvmpipe driver. 
I see the problem if I start octave as:
$ LIBGL_ALWAYS_SOFTWARE=1 octave
That will set renderer to llvmpipe (one can verify that by running "__opengl_info__.renderer" in octave).
The same renderer is used when octave is run in Xvfb environment.

Dmitri.
--

Comment 5 José Expósito 2024-07-02 15:56:50 UTC
Bisected and reported upstream:
https://gitlab.freedesktop.org/mesa/mesa/-/issues/11445

Comment 6 Fedora Update System 2024-07-12 09:47:01 UTC
FEDORA-2024-e4651140c2 (mesa-24.1.2-8.fc40) has been submitted as an update to Fedora 40.
https://bodhi.fedoraproject.org/updates/FEDORA-2024-e4651140c2

Comment 7 José Expósito 2024-07-12 09:48:26 UTC
Hi @dasergatskov

I backported the fix for your issue, please test this version of mesa and confirm if it is solved for you:
https://bodhi.fedoraproject.org/updates/FEDORA-2024-e4651140c2

Comment 8 Dmitri A. Sergatskov 2024-07-12 13:44:48 UTC
Seems to work for me. Please build one for Centos Stream as well.

Comment 9 Fedora Update System 2024-07-13 02:46:29 UTC
FEDORA-2024-e4651140c2 (mesa-24.1.2-8.fc40) has been pushed to the Fedora 40 stable repository.
If problem still persists, please make note of it in this bug report.


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