Expand description
Program-level capability bits surfaced from the runtime. Program → required-capability analysis.
Scan a Program and report the hardware capabilities its lowering will
need. Callers (backends, conformance harnesses, certificate emitters)
compare the required set against what a backend advertises and surface
MissingCapability before handing the kernel to the device, avoiding
panics inside create_shader_module / createComputePipeline.
The scanner is strictly syntactic: it walks every Expr and Node in
the program and checks the IR surface. It intentionally does not
know anything about backend-specific lowering rules — that would make it
a circular dependency of the very thing it is supposed to gate.
Structs§
- Missing
Capability - The reason a backend cannot execute a program.
- Required
Capabilities - Capabilities a
Programneeds from whichever backend executes it.
Functions§
- check_
backend_ capabilities - Return
Ok(())when a backend with the given advertised capabilities can run a program whose required set isrequired, otherwise return the missing-capability explanation. - scan
- Walk the program and collect the union of capabilities it requires.