Last updated: 2026-11-17
Vulkan Runtime
Compute Prefill Policy
Host-only routing for accelerator CLI, debug and slot prefill.
Share the decisions so prompt batching and SSM reduction selection cannot drift apart.
6 exports shown
constant
batch_threshold
pub const batch_threshold: usize = 32 No public doc comment yet.
struct
Options
pub const Options = struct No public doc comment yet.
function
useBatched
pub fn useBatched(tokens: usize, options: Options) bool No public doc comment yet.
struct
SlotOptions
pub const SlotOptions = struct No public doc comment yet.
function
useCliMoeSlotPrefill
pub fn useCliMoeSlotPrefill(tokens: usize, options: SlotOptions) bool The MoE CLI batches short prompts with the warp SSM scan.
Serial HTTP prefill instead chose "box" where the CLI/reference chose "fridge". Merely enabling slot batching still selects the block scan, so both the scheduler and slot scan must use this decision. Restrict it to the F32 single-slot B=1 path; concurrent serving needs its existing batched-decode reduction.
function
useSlotDecodeQ8
pub fn useSlotDecodeQ8(batched_prefill: bool, options: SlotOptions) bool A long request can allocate Q8 scratch that remains cached for later ones.
Its presence must not switch a fresh serial-prefilled request to different decode arithmetic. Batched prefill still enables the existing Q8 fast path.