Module Tolk_metal.State
The type for Metal device state. Holds the GPU device handle, command queue, shared timeline event, and in-flight command buffer list.
val create : unit -> tcreate () initializes the system default Metal device, command queue, and shared event.
Raises Failure if no Metal GPU is available.
val synchronize : t -> unitsynchronize t blocks until all in-flight command buffers complete. After return, the in-flight list is empty.
Raises Failure if any command buffer completed with an error.
val shutdown : t -> unitshutdown t synchronizes and releases all Metal resources (command queue, shared event, device). Subsequent calls are no-ops.
val is_virtual : t -> boolis_virtual t is true iff the device name contains "virtual", indicating a paravirtualized Metal device (e.g. macOS VM). ICB-based graph execution is unreliable on virtual devices.