Skip to main content

Module attention

Module attention 

Source

Structs§

AttentionSchedule
A hardware-safe attention schedule. The generated kernel uses one workgroup per attention head and an online tiled reduction over context.
AttentionShader
Generated attention kernel plus its Naga validation report.
AttentionShaderParams
Uniform parameter block matching AttentionParams in the generated attention shader.
AttentionShape
The attention workload bound into one Forge kernel.

Functions§

causal_attention_oracle
Caller-buffered stable scaled-dot-product attention oracle.
synthesize_causal_attention
Emit and Naga-validate a causal scaled-dot-product attention kernel.