pub struct Fp8ActQuant {
pub shared: KernelHandle,
pub hopper: KernelHandle,
}Expand description
2026-09-25: The FP8 activation quantizer a layer launches: the shared kernel, plus the Hopper twin when the image has one.
Fields§
2026-09-25: per_token_group_quant_fp8, or KernelHandle(0) when the
image lacks it.
hopper: KernelHandle2026-09-25: per_token_group_quant_fp8_hopper, or KernelHandle(0)
when the image lacks it.
Implementations§
Source§impl Fp8ActQuant
impl Fp8ActQuant
Sourcepub fn resolve(gpu: &dyn GpuBackend) -> Self
pub fn resolve(gpu: &dyn GpuBackend) -> Self
2026-09-25: Probe both kernels; a missing one resolves to
KernelHandle(0).
2026-09-25: A quantizer with only the shared kernel.
Sourcepub fn available(&self) -> bool
pub fn available(&self) -> bool
2026-09-25: Is there a quantizer to launch at all? True when either
handle is loaded, whatever the width; Self::pick is the per-launch
choice.
Sourcepub fn twin_present(&self) -> bool
pub fn twin_present(&self) -> bool
2026-09-25: Is the twin in this image? Whether a launch uses it is
Fp8QuantPick::twin.
Sourcepub fn pick(&self, m: u32, k: u32) -> Fp8QuantPick
pub fn pick(&self, m: u32, k: u32) -> Fp8QuantPick
2026-09-25: Which kernel this (m, k) launches, on which grid, and why
not the other, from the resolved fp8_act_quant_hopper lever and the
compiled target’s SM count. Self::pick_with is the pure form.
Sourcepub fn pick_with(
&self,
requested: bool,
m: u32,
k: u32,
sm_count: u32,
) -> Fp8QuantPick
pub fn pick_with( &self, requested: bool, m: u32, k: u32, sm_count: u32, ) -> Fp8QuantPick
2026-09-25: Self::pick over an explicit lever value and SM count.
Pure, so CPU tests can grade any (m, k).
Sourcepub fn kernel(&self, m: u32, k: u32) -> KernelHandle
pub fn kernel(&self, m: u32, k: u32) -> KernelHandle
2026-09-25: The handle this (m, k) launches.
Trait Implementations§
Source§impl Clone for Fp8ActQuant
impl Clone for Fp8ActQuant
Source§fn clone(&self) -> Fp8ActQuant
fn clone(&self) -> Fp8ActQuant
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more