3 ms·
The goal is to handle things similar to how rust on the CPU does (shared traits with different implementations, intrinsics, platform-specific modules, user repl
by LegNeato 2y ago
The goal is to handle things similar to how rust on the CPU does (shared traits with different implementations, intrinsics, platform-specific modules, user replaceable traits like alloc or panic handler and "asm" as a last ditch case).
We already have a lot (we have many intrinsics and an `arch` module like `std::arch`, asm! to include raw spirv, etc). For example, here are the intrinsics: https://rust-gpu.github.io/rust-gpu/api/spirv_std/arch/index.html https://rust-gpu.github.io/rust-gpu/api/spirv_std/arch/index... and here is support for ray tracing (which obviously is not on every card: https://rust-gpu.github.io/rust-gpu/api/spirv_std/ray_tracing/index.html https://rust-gpu.github.io/rust-gpu/api/spirv_std/ray_tracin...).
Vulkan has a way to query and specify different GPU capabilities and Rust-GPU uses that.
Rust and Vulkan have many of the tools we need for progressive enhancement, we are not focused on lowest common denominator.