There is still a long road ahead! The UAPI that we are using right now is still a prototype, and there are a lot of new features that need to be added or redesigned in order to support a full Vulkan driver in the future. Since Linux mandates that the UAPI needs to remain stable and backwards compatible across versions (unlike macOS), that means that the kernel driver will not be heading upstream for many months, until we have a more complete understanding of the GPU rendering parameters and have implemented all the new design features needed by Vulkan. The current UAPI also has performance limitations… it can’t even run GPU rendering concurrently with CPU processing yet!
And of course there is still a lot of work to do on the userspace side, improving conformance and performance and adding support for more GL extensions and features! Some features like tesselation and geometry shaders are very tricky to implement (since they need to be partially or fully emulated), so don’t expect full OpenGL 3.2+ for quite a long time.
This article is a detailed look at the work done by Asahi Lina to create a Linux GPU driver for Apple’s M1, after Alyssa Rosenzweig reverse engineered the M1 GPU on macOS. This is a tour de force of excellence, and every current and future M1/M2 Linux user should be thankful for the amazing work these people are doing.
Thom, you didn’t mention something that stuck out to me…the author is going to use rust instead of C…
This is notable and I agree with him about C. That apple’s GPU firmware structures are not stable makes me wonder if these drivers are going to be fragile across apple updates. If they are, it will be ironic that linux could be victim to someone else’s unstable ABIs, haha.
He points out something else we’ve talked about before…
This is why it’s so difficult to simply add rust code next to C code in the linux kernel. Naturally safety is one of the main benefits rust brings to the table, yet it becomes less effective when resorting to unsafe C APIs, they are a limiting factor and tons of wrappers are needed. I’m happy to see a significant driver like this testing the waters, although I’m not sure that linux’s traditional C developers are going to be happy to see these kinds of changes.
Support for vulkan will be pretty neat especially since apple decided not to offer it to their own users.
https://arstechnica.com/gadgets/2018/02/vulkan-is-coming-to-macos-ios-but-no-thanks-to-apple/
Hey Alfman, just a quick note, you’re (unintentionally I’m sure!) mis-gendering Asahi Lina, she is a she.
https://virtualyoutuber.fandom.com/wiki/Asahi_Lina
Virtual YouTuber… lolwut