While you're here, please consider supporting GamingOnLinux on:
Reward Tiers:
Patreon. Plain Donations:
PayPal.
This ensures all of our main content remains totally free for everyone! Patreon supporters can also remove all adverts and sponsors! Supporting us helps bring good, fresh content. Without your continued support, we simply could not continue!
You can find even more ways to support us on this dedicated page any time. If you already are, thank you!
Reward Tiers:
This ensures all of our main content remains totally free for everyone! Patreon supporters can also remove all adverts and sponsors! Supporting us helps bring good, fresh content. Without your continued support, we simply could not continue!
You can find even more ways to support us on this dedicated page any time. If you already are, thank you!
Login / Register
- NVIDIA announce a native Linux app for GeForce NOW
- KDE Plasma 6.6 will finally stop the system sleeping when gaming with a controller
- Linaro reveal they're collaborating with Valve for the Steam Frame
- NVIDIA announce DLSS 4.5 with Dynamic Multi Frame Generation, plus DLSS Updater gets Linux support
- Mesa RADV driver on Linux looks set for a big ray tracing performance boost
- > See more over 30 days here
- Will you buy the new Steam Machine?
- Chrisznix - Weekend Players' Club 2026-01-09
- JSVRamirez - New Desktop Screenshot Thread
- Xpander - Browsers
- Xpander - A succesfull Windows-Ubuntu migration the story
- LoudTechie - See more posts
How to setup OpenMW for modern Morrowind on Linux / SteamOS and Steam Deck
How to install Hollow Knight: Silksong mods on Linux, SteamOS and Steam Deck
Since Mesa branched to 24.0.0 in git-master, the ACO shader compiler is now feature complete to use for RadeonSI OpenGL instead of the LLVM back end.
It may seem like a problem that didn't need solving, as OpenGL shaders aren't like Vulkan shaders, but newer OpenGL specs support more features now and I'd rather have a more efficient compiler.
This can be tested with the following environment variable (but defaults to that if built without LLVM)
AMD_DEBUG=useacoHowever, what interests me more than that, is the ability to ditch the dependency on LLVM! It just burns my ass, that upgrading my LLVM toolchain breaks my graphics driver libraries. At the very least I have to have a mesa build ready to go, but it also needs caution because it's more than just a compiler suite, it's the back end for mesa. I don't wait for Arch to curate things either, they are often months behind my toolchain upgrades because of blocking issues with some stupid package.
So this frees me up.
It's not bad to do, but it does involve ditching some things in Mesa that I never use anyway. I long ago stopped building drivers I don't use (i.e. why build intel or nouveau... I'll be having those on the 21st of Never)
Firstly, these are the drivers that can be built like this:
-D gallium-drivers=radeonsi,swrast,zink-D vulkan-drivers=amd
swrast for OpenGL can still be built, because it will fall back to legacy rather than llvmpipe if no LLVM.
swrast for Vulkan can't, because that uses lavapipe (llvmpipe)
OSMesa can still be built (off screen rendering), no need to disable that
-D gallium-nine=falseThe gallium nine state tracker needs LLVM, so Nine can't be built. That's the old D3D9 support, I don't use WineD3D for anything anymore, I use DXVK (D9VK) now for DirectX 9 games.
-D gallium-omx=disabledThe OpenMax state tracker needs LLVM too, so OMX/Bellagio can't be built. I don't have any software that uses openmax, and to be honest I'd never even heard of it before I started compiling Mesa in Arch.
-D gallium-opencl=disabledGallium opencl (uses LLVM's libclc) can't be built. That might be a show stopper for some, but I don't use it. To me it's only ever been good for causing build failures, as it's super fussy on SPIRV headers and tools.
Finally, the business end of the change:
-D llvm=disabledMy Mesa is LLVM free :-)
I have tried every single OpenGL thing that I have and have not seen a single problem caused by this change. EGL in Firefox is fine too, no change to WebGL benchmark scores or anything (slightly better if anything, but didn't do enough repetitions to validate that). I've been using Mesa in this configuration since it branched on Oct. 26, anyway.
Last edited by Grogan on 2 Nov 2023 at 12:37 am UTC
View PC info
And what about gallium-va? Does it need llvm too?
Last edited by Shmerl on 2 Nov 2023 at 1:36 am UTC
I built vaapi support, I don't use it, but it didn't complain
meson setup mesa _build \-D buildtype=release \
-D b_ndebug=true \
-D b_lto=false \
--wrap-mode=nofallback \
-D prefix=/usr \
-D sysconfdir=/etc \
-D platforms=x11,wayland \
-D gallium-drivers=radeonsi,swrast,zink \
-D vulkan-drivers=amd \
-D vulkan-layers=device-select,overlay \
-D dri3=enabled \
-D egl=enabled \
-D gallium-extra-hud=true \
-D gallium-nine=false \
-D gallium-omx=disabled \
-D gallium-va=enabled \
-D gallium-vdpau=enabled \
-D gbm=enabled \
-D gles1=disabled \
-D gles2=enabled \
-D glvnd=true \
-D glx=dri \
-D libunwind=disabled \
-D llvm=disabled \
-D lmsensors=enabled \
-D osmesa=true \
-D shared-glapi=enabled \
-D gallium-opencl=disabled \
-D valgrind=disabled \
-D zstd=enabled \
-D microsoft-clc=disabled \
-D video-codecs=vc1dec,h264dec,h264enc,h265dec,h265enc \
-D tools=[]
Last edited by Grogan on 2 Nov 2023 at 1:44 am UTC
View PC info
View PC info
I'll probably update my Mesa build script to make llvm optional or remove it altogether from there:
https://gist.github.com/shmerl/f4e5f76871239158cf083e37c5da56f4
Last edited by Shmerl on 2 Nov 2023 at 1:52 am UTC
Last edited by Grogan on 2 Nov 2023 at 2:03 am UTC
View PC info
I generally take configuration settings from Debian repos build and simplify it to only have some common set of features for AMD, so similar approach to yours.
Last edited by Shmerl on 2 Nov 2023 at 2:23 am UTC
[My disappointment is immeasurable...... And my day is ruined](https://www.youtube.com/watch?v=17KmNrG9pE4)
So it builds just fine, but I can't seem to get it to work now. I haven't tried it in a long time, so I don't know if it worked before.
$ MESA_LOADER_DRIVER_OVERRIDE=zink glxgearsDRI3 not available
failed to load driver: zink
Error: couldn't get an RGB, Double-buffered visual
I'm going to have to do some more testing here before I can say for sure.
I use the fossilize (.foz) database format though with MESA_DISK_CACHE_SINGLE_FILE=1 (still not the default, I'm a bit surprised by that) so I don't know if that zstd thing comes into play for me.
Since I cannot believe that it could be "broken" for all that time, I must have a misconfiguration somewhere (or need additional configuration, somewhere). I don't think it's the LLVM though.
Now I have to figure out why Zink isn't working lol
Last edited by Grogan on 2 Nov 2023 at 3:45 am UTC
View PC info
Here is a recent build test (llvm is enabled for the build):
Damnit, it was the best tie-in that I could come up with, anyway :-)
Some time later, and currently, I get that DRI3 error above. I kept Zink in my Mesa builds but never got around to trying it again until today. I booted to my from-scratch system and get the same error there too now. In both cases, DRI3 is certainly available, the extension is loaded.
A headscratcher for later.
View PC info
Playing Black Geyser Couriers of Darkness didn't work. It crashes on startup. Plays OK when it's built with llvm. So it's not really ready in this sense.
May be I report it to the developers to take a look.
Last edited by Shmerl on 5 Nov 2023 at 5:57 am UTC
I also still haven't found what I'm missing for Zink to work yet either. It doesn't make sense. Even with a full build of Mesa it doesn't work for me, it's like it's not dispatching correctly or something. I tried a build without glvnd too (which isn't so easy anymore, it uses older sonames than libglvnd now when you do that). I've only got one Vulkan (RADV) and I made sure there are no old .icd files in there. Zink doesn't have to work, it just bugs me when something doesn't.
Last edited by Grogan on 5 Nov 2023 at 11:04 am UTC
However, today I have realized the fruits of my labour, as I was able to rip out and upgrade LLVM without affecting my X session and just carry on with all the rest of my builds after that with no interruption. I just built a mesa yesterday and don't have to do it again because of this either. So I have been successful at solving the problem I set out to, without sacrificing anything I care about.
Last edited by Grogan on 8 Nov 2023 at 2:59 am UTC