vulkane_kernels_source/lib.rs
1// SPDX-License-Identifier: MIT OR Apache-2.0
2//! # vulkane-kernels-source
3//!
4//! Home for GPU kernel source files (`.slang`, `.glsl`) and the `compile.sh`
5//! script that turns them into SPIR-V. Moved from Fuel's `fuel-kernels-source`
6//! with its git history; see `README.md` and `THIRD-PARTY-NOTICES.md`.
7//!
8//! This crate intentionally has no Rust code. Consumers read the sources from
9//! the published package (`kernels/`) and build or embed SPIR-V themselves.
10//!
11//! ## Layout
12//!
13//! - `kernels/*.slang` — Slang sources (preferred for new kernels:
14//! autodiff-ready, cross-backend output).
15//! - `kernels/*.glsl` — GLSL sources, kept where GLSL is more ergonomic
16//! (e.g. cooperative-matrix matmul).
17//! - `kernels/compile.sh [--out-dir DIR] [files...]` — ahead-of-time compiler
18//! invocation; SPIR-V goes to `DIR` (default: `spv/` next to `kernels/`).
19//! - `kernels/hoist_extinst_imports.py` — post-pass that hoists
20//! `OpExtInstImport` out of function bodies in `slangc` output.