ringkernel-metal
Apple Metal backend for RingKernel.
Status
This crate is scaffolded - the API is defined but implementation is pending.
Overview
This crate will provide GPU compute support for RingKernel on Apple platforms using the Metal framework. It targets macOS, iOS, and Apple Silicon devices.
Requirements (Planned)
- macOS 10.15+ or iOS 13+
- Apple Silicon (M1/M2/M3) or compatible AMD GPU
- Metal feature enabled
Features (Planned)
- Event-driven kernel execution via Metal compute shaders
- MSL (Metal Shading Language) shader support
- Apple Silicon unified memory architecture optimization
- iOS deployment support
Limitations
Like WebGPU, Metal does not support CUDA-style cooperative groups, so persistent kernels will use event-driven execution with host-side dispatch loops.
Usage (API Preview)
use MetalRuntime;
async
Current State
The crate currently provides:
- Stub
MetalRuntimethat returnsBackendUnavailableerrors - MSL kernel template (
RING_KERNEL_MSL_TEMPLATE) is_metal_available()runtime check
Contributing
Contributions to implement the Metal backend are welcome. Key work items:
- Device enumeration via
metal::Device - Compute pipeline creation
- Buffer management with unified memory
- Kernel dispatch and synchronization
License
Apache-2.0