Exploring the Practical Implementation of Apple’s Metal 3 with GPU Programming

GPU programming: New features of Apple's Metal 3 in practice

Apple announced a major update to Metal 3 at WWDC 2022, which focuses on enhancing performance. The new features that Metal 3 offers include Optimized Ray Tracing, Metal FX Upscaling, Offline Shader Loading, Fast Resource Loading, and mesh shaders.

Optimized Ray Tracing allows the GPU to deliver high-speed performance, while Metal FX Upscaling converts small images into larger ones. Offline Shader Loading compiles shaders during the build of apps, and Fast Resource Loading speeds up the loading of large textures. Mesh shaders process entire hierarchies of geometric objects on the GPU instead of vertex shaders.

Most of the features of Metal 3 are dedicated to performance and require the latest hardware and operating systems. Metal 3 is part of the iOS 16, iPadOS 16, tvOS 16, and macOS Ventura operating systems. It requires at least one A13 Bionic or M1 SoC in the iPhone and iPad, and Macs with Apple Silicon, AMD, or Intel chips are also suitable.

The showcase app for Metal 3 is SpeedMetal, which presents a simple ray tracer with controls for some of the new features. The app has three scenes with one, four, and nine Cornell boxes. A runtime indicator for the render pipeline is visible when features are on or off.

Xcode 14 offers improved and new GUIs for debugging Metal 3 apps. Under macOS, Metal 3 offers backends for the machine learning frameworks TensorFlow and PyTorch. Apple summarizes the functional limitations of older devices in the Metal Feature Set Tables table.

In conclusion, Metal 3 is a significant update that offers several new features for enhancing performance. Apple’s efforts have resulted in accelerated ray tracing, faster loading of large textures, and better rendering of images. Metal 3 can be used with existing code and requires the latest hardware and operating systems.

Leave a Reply