pub struct PrefillOutbox { /* private fields */ }Expand description
Where the forward thread hands a Prefill rank’s peer its work; never waits for a transfer.
A plan’s remote decode is staged when the plan goes to the data plane
(PrefillOutbox::stage_remote_decode) and handed over by the data plane
once the drafter’s pending round finished
(PrefillOutbox::hand_over_remote_decode): the KV it sends includes
what that round writes.
Implementations§
Source§impl PrefillOutbox
impl PrefillOutbox
Sourcepub fn release_registration(&self) -> Result<(), String>
pub fn release_registration(&self) -> Result<(), String>
A sleep releases the cache: deregister it from the transfer engine, refused while a tracked request’s KV may still go out. A room no request here claimed sends nothing, so it does not hold the release.
Sourcepub fn restore_registration(&self) -> Result<(), String>
pub fn restore_registration(&self) -> Result<(), String>
A wake re-mapped the cache: register it again, on the same session (every write starts from this rank’s own registration, so no peer holds its keys).
Sourcepub fn streams_layerwise(&self) -> bool
pub fn streams_layerwise(&self) -> bool
Whether prefill chunks stream their KV layerwise.
Sourcepub fn stage_remote_decode(&self, rows: BatchRows) -> Result<(), String>
pub fn stage_remote_decode(&self, rows: BatchRows) -> Result<(), String>
Stage a plan’s remote decode: the prompts whose KV goes out now.
Sourcepub fn remote_decode_pending(&self) -> bool
pub fn remote_decode_pending(&self) -> bool
Whether a staged remote decode still waits to be handed over.
Sourcepub fn hand_over_remote_decode(&self) -> Result<(), String>
pub fn hand_over_remote_decode(&self) -> Result<(), String>
The staged remote decode’s device prerequisites are met: send each
prompt’s KV to its destinations (HostPrefillPeer.execute). A room
that streams layerwise already sends; it only gets its bootstrap
payload.
Sourcepub fn arm_layerwise(&self, forward: &BatchRows) -> Result<(), String>
pub fn arm_layerwise(&self, forward: &BatchRows) -> Result<(), String>
Layerwise streaming: arm one chunk per extend row of the forward the
plan launches whose request has a destination, ahead of the forward
(HostPrefillPeer.prepare_prefill). Every row is planned before any
is armed, and the forward’s producer steps are counted once.