Skip to main content

validate_program_for_backend

Function validate_program_for_backend 

Source
pub fn validate_program_for_backend(
    backend: &dyn VyreBackend,
    program: &Program,
    config: &DispatchConfig,
) -> Result<(), BackendError>
Expand description

Validate a program’s effective workgroup shape against a backend’s reported limits.

This is the shared pre-dispatch gate for callers that have a VyreBackend trait object but have not entered a concrete driver yet.

§Errors

Returns when any workgroup axis is zero, exceeds the backend’s per-axis limit, or when total invocations exceed the backend’s workgroup limit.