Live data from Hacker News

An Update on Apple M1/M2 GPU Drivers

lwn.net

101–110 of 291 posts

Re: An Update on Apple M1/M2 GPU Drivers

#101
post #44

> tessellator.cl is the most unhinged file of my career ...so far. The presenter is only 23 apparently. Maybe I'm speaking only for myself here, but I think career unhingedness does not go down over time as much as one might hope. In all seriousness, she does really impressive work, so when she says this 2,000 lines of C++ is inscrutable, that gives one pause. Glad it's working nonetheless.

It's unfathomable that she's 23 and wrote an open source graphics driver for a closed-source graphics card. At least Einstein had the decency to wait until he was 26 to invent special relativity.

Multiple, before this she wrote panfrost for ARM mali GPUs starting in 2018.

Re: An Update on Apple M1/M2 GPU Drivers

#102

> frankly, I think ray tracing is a bit of a gimmick feature That's incredibly arrogant. The whole industry is adopting ray tracing, and it is a very desired feature people are upgrading video cards to get working on games they play.

Can the hardware for ray tracing be used for anything else? Ray tracing is just math, is that math applicable for any non graphics use?

You'll have to see what the instruction set / features are capable of, but most likely the "hardware ray tracing" support means it can do ray-BVH and ray-triangle intersection in hardware. You can reuse ray-box and ray-triangle intersection for collision detection.

The other parts of ray tracing like shading and so on, are usually just done on the general compute.

Re: An Update on Apple M1/M2 GPU Drivers

#103
post #79
post #37

Earlier quoted context omitted.

They had limited uses and turned out to be incredibly hard to implement efficiently in hardware, so in practice it was nearly always faster to just keep using the proven techniques that GS was supposed to replace. http://www.joshbarczak.com/blog/?p=667

And yet one of the fancy new features being advertised in recent years (in multiple APIs including Metal) is support for mesh shaders – which seem to have a lot in common with geometry shaders, including the output ordering property that that post blames for geometry shaders’ bad performance. I’m not a graphics programmer myself, but this makes me suspect there’s more to the story.

If you’re not a graphics programmer, how did you learn of this? I’d love to read about it.

Re: An Update on Apple M1/M2 GPU Drivers

#104

> tessellator.cl is the most unhinged file of my career ...so far. The presenter is only 23 apparently. Maybe I'm speaking only for myself here, but I think career unhingedness does not go down over time as much as one might hope. In all seriousness, she does really impressive work, so when she says this 2,000 lines of C++ is inscrutable, that gives one pause. Glad it's working nonetheless.

I didn't even know this until now. I looked at her resume and I can't grasp how she's been doing an undergraduate degree from 2019-2023, meaning that writing an entire GPU driver is the side project she made during her degree.

Re: An Update on Apple M1/M2 GPU Drivers

#105
post #87
post #84

Earlier quoted context omitted.

You're looking at years of careful artist and engineer work to get something that looks almost as good as pathtraced visuals. The fact that it's so good without any raytracing is a credit to the developers. Replacing all that effort with raytracing and having one unified lighting system would be a _major_ time saver, and allows much more dynamic lighting than was previously possible. So yeah some current games don't…

> Sure fully pathtraced graphics might not be 100% usable currently, but the fact that they're even 70% usable is amazing! Aside from Cyberpunk 2077 and a handful of ancient games with NVIDIA-sponsored remakes, what even offers fully path traced lighting as an option? The way it went for CP2077 makes your "70% usable" claim seem like quite an exaggeration: performance is only good if you have a current-generation GPU…

> For the foreseeable future, games will still need to look good without fully path traced lighting.

And in 7-10 years when the software stack is matured, we'll be thanking ourselves for doing this in hardware the right way. I don't understand why planning for the future is considered so wasteful - this is an architecture Apple can re-use for future hardware and scale to larger GPUs. Maybe it doesn't make sense for Macs today, but in 5 years that may no longer be the case. Now people don't have to throw away a perfectly good computer made in these twilight years of Moore's law.

For non-games applications like Blender or Cinema4D, having hardware-accelerated ray tracing and denoising is already a game-changer. Instead of switching between preview and render layers, you can interact with a production-quality render in real time. Materials are properly emissive and transmissive, PBR and normal maps composite naturally instead of needing different settings, and you can count the time it takes before getting an acceptable frame in milliseconds, not minutes.

I don't often give Apple the benefit of the doubt, but hardware-accelerated ray tracing is a no-brainer here. If they aren't going to abandon Metal, and they intend to maintain their minuscule foothold in PC gaming, they have to lay the groundwork for future titles to get developed on. They have the hardware investment, they have the capital to invest in their software, and their competitors like Khronos (apparently) and Microsoft both had ray tracing APIs for years when Apple finally released theirs.

Re: An Update on Apple M1/M2 GPU Drivers

#106
post #63
post #41

Earlier quoted context omitted.

OpenGL and Vulkan have tons of tests and Alyssa runs them. I don't know if it's automated through CI.

Reportedly, the lack of M3 support so far is because there is no M3 Mac Mini which they can use for CI.

I’m sure if that is the issue we can together find a way to sponsor a MacBook with an M3? Or does it specifically have to be a Mac mini?

Re: An Update on Apple M1/M2 GPU Drivers

#108

> frankly, I think ray tracing is a bit of a gimmick feature That's incredibly arrogant. The whole industry is adopting ray tracing, and it is a very desired feature people are upgrading video cards to get working on games they play.

Wow! if the industry is pushing it must be good right? Just like the megapixels wars for cameras.

Re: An Update on Apple M1/M2 GPU Drivers

#109

> frankly, I think ray tracing is a bit of a gimmick feature That's incredibly arrogant. The whole industry is adopting ray tracing, and it is a very desired feature people are upgrading video cards to get working on games they play.

I don't know, Hardware Unboxed recently did a review of 30-some games comparing the visuals with and without ray tracing, and the conclusion for the majority of them was that it wasn't worth it. There were only maybe half a dozen games where the ray tracing was an unambiguous improvement. So I think calling it "a bit of a gimmick" is accurate for many of the games that shipped in, even if not all of them.

Hmm I watched the video [1] and in the games where it had an unambiguous improvement, the improvement in reflection quality is extremely stark and noticeable. Anecdotally, when I was playing Black Myth Wukong recently, there were some shiny environments where full path tracing really made a huge difference.

So I guess it's just a "gimmick" in that relatively few games properly take advantage of this currently, rather than the effect not being good enough.

[1] https://www.youtube.com/watch?v=DBNH0NyN8K8

Re: An Update on Apple M1/M2 GPU Drivers

#110
post #87

Earlier quoted context omitted.

> Sure fully pathtraced graphics might not be 100% usable currently, but the fact that they're even 70% usable is amazing! Aside from Cyberpunk 2077 and a handful of ancient games with NVIDIA-sponsored remakes, what even offers fully path traced lighting as an option? The way it went for CP2077 makes your "70% usable" claim seem like quite an exaggeration: performance is only good if you have a current-generation GPU…

> For the foreseeable future, games will still need to look good without fully path traced lighting. And in 7-10 years when the software stack is matured, we'll be thanking ourselves for doing this in hardware the right way. I don't understand why planning for the future is considered so wasteful - this is an architecture Apple can re-use for future hardware and scale to larger GPUs. Maybe it doesn't make sense for M…

I think you have the wrong impression. Apple M2 does not have hw ray tracing. M3 and M4 do.
Post reply on HN