UTM: NOTICE: Mesa after 22.1.7 is broken (black screen, crashing apps)
Thanks everyone who’s reported this issue, I’ve found that it’s because of a switch to NIR-to-TGSI between 22.1.7 and 22.2.0.
There’s 2 mitigations currently, pick between 1 and 2 based on your priorities (if its keeping your distro configs, then choose 1, or if you need GPU acceleration, then choose 2):
- Change the Emulated Display Card to
virtio-ramfbor any other card without a-glsuffix. - Switch to a distro that ships mesa<=22.1.7, such as Debian 11 or Alpine 3.16
If anyone has knowledge on how this can be debugged or fixed, please don’t hesitate to comment on this issue (or join the UTM Discord server if this issue has comments locked). Please note that I don’t particularly need logs (I already have virglrenderer traces), but if you have logs that point to the problematic code, please share them 😃
About this issue
- Original URL
- State: closed
- Created a year ago
- Reactions: 4
- Comments: 46 (15 by maintainers)
This is such a major issue, not having hardware accl on apple silicon in a VM really sucks. I hate OSX so I basically use a VM to host a Linux desktop running i3. Because I lack hardware acceleration, I can’t run Slack and Zoom in the VM. Because of that, I can’t give the VM the sound card because I need it for Slack and Zoom. So my VM has no sound.
Can we bug bounty this? This M1 mac is a total nightmare.
This seems to be fixed in 4.2.4. Tested with Fedora 38, GNOME Wayland session, booted with
initcall_blacklist=sysfb_init; usedglmark2andglmark2-waylandprograms. Oddly enough and contrary to the known issues list, it seems to work fine with the Metal ANGLE backend as well.It’s a Mesa driver bug and we need either help from them or someone to test and send feedback to them.
I opened an issue with mesa and hopefully we can get some help root causing it: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8382
In the meantime, we will revert the change in 4.1 so by default GPU acceleration is disabled again.
@osy It’s not Mesa bug but ANGLE one. (Well, TGSI-to-NIR change is so big that actually there can be other bugs, but the major issue is in ANGLE.) The bug is fixed with: https://chromium-review.googlesource.com/c/angle/angle/+/3996520
So updating ANGLE should fix it.
Reason being that it’s been 24 hours (v4.2.4 was approved but I pulled it last second due to the Monterey mouse cursor problem).
@osy I guess that problem is fixed with: https://gitlab.freedesktop.org/mesa/mesa/-/commit/36d050210ea854f2632c8c2a960dca94dabbf526
Metal backend is marked ready in the latest
mainbranch but not in stable release. OpenGL backend is still the default and Chromium also doesn’t use it. You cannot still use Metal backend.Use latest stable ANGLE and Mesa with my patched virglrenderer and QEMU. Expect any kind of failures if you use something outdated.
Fedora 38 beta (just upgraded) runs again fine with acceleration enabled (using virtio-gpu-gl-pci). Here’s a screenshot:
Please note the broken (not round) right-top and left-bottom corners of the settings window. I think I’ve had them like this since I started using accelerated drivers. Did anyone else notice the same issue?