pub fn build_seq_slot_host(
adapter_slots: &[i32],
padded_n: usize,
active: i32,
) -> Vec<i32>Expand description
Build the per-step seq_slot[padded_n] host buffer the batched bgmv reads,
from each real sequence’s adapter_slot. Resolution rules (graph-safe:
contents vary per step, buffer address is fixed):
real row i (< n): adapter_slots[i] if >= 0, else active — a request
with no adapter field carries -1 and DEFERS to the installed active
adapter, so a single global adapter (or a rotate re-point) applies to
every default row exactly like the n==1 path.
pad row i (n..padded_n): -1 — base / no delta (bgmv early-returns).
A row that explicitly names the base model (some future -1-means-base
convention) is out of scope here; -1 uniformly means “defer to active”.