@@ -364,8 +364,8 @@ drains and acknowledges them during the same VM exit.
364364Guest ` SlotPool ` instances own all transport buffers. Pool clones share one
365365allocation bitmap with each producer.
366366Each producer pairs its backend with that pool. Completion leases carry the
367- original slot addresses and full capacities. Backing owns fixed scratch-to- alias
368- translation and paging. The backend holds only scratch bounds.
367+ original slot addresses and full capacities. Backing owns alias allocation and
368+ paging. The backend holds only scratch bounds.
369369Guest completion mapping checks scratch bounds. Allocation ownership and
370370initialized lengths follow the ` BufferMap ` safety contract.
371371
@@ -381,8 +381,8 @@ external `ByteChunks`:
381381* G2H host responses can become owner-backed guest ` Bytes ` .
382382* ` VecBytes ` values copy into a contiguous ` Vec<u8> ` .
383383* Multiple ` Bytes ` clones or slices backed by one owner keep one slot live.
384- * The final owner returns its original ` BufferLease ` . Active pool mappings
385- remain available across ordinary calls .
384+ * The final owner unmaps its alias and returns the virtual range for reuse.
385+ Its lease releases the scratch slot only in the slot's current generation .
386386
387387Producer reset releases allocations still owned by queue bookkeeping. After
388388both producers reset and before H2G prefill, every live pool slot belongs to
@@ -393,14 +393,16 @@ handles. The host resets both consumers before processing more queue traffic.
393393
394394### Retained virtual addresses
395395
396- Each pool has a stable virtual alias range, mapped eagerly at initialization.
397- Completed ` GuestMapping ` owners keep their original leases.
398- Capture, restore, and cloning preserve their pointers and contents.
396+ Both pools share one guest-global alias allocator. Its state is captured with
397+ the mappings and keeps retained ranges reserved across pool generations.
398+ Each completed ` GuestMapping ` owns a separate page-aligned range. Mapping occurs
399+ when the guest receives the buffer. Capture, restore, and cloning preserve its
400+ pointer and contents.
399401
400- Checkpoint preparation records the live slots. After restore, aliases of their
401- pages reach captured data. The first transport entry copies the recorded slots
402- into scratch and maps every pool alias to scratch. Only recorded slots are
403- copied, so neighboring slots keep host writes such as the first request .
402+ Retained aliases reach captured memory after restore. The first transport
403+ entry advances the pool generations and recycles slots outside posted chains.
404+ Retained values keep their aliases until their final owner drops. Reusing
405+ freed virtual ranges bounds page-table growth by the alias high-water mark .
404406
405407### Trust boundary
406408
@@ -437,8 +439,6 @@ snapshot uses this flow:
437439 | | reclaim completed G2H work
438440 | | reset G2H producer
439441 | | reset H2G producer
440- | | record live slots
441- | | unmap pages outside live slots
442442 | | prefill free H2G slots
443443 | | mailbox = CheckpointComplete
444444 |<------------------------------------| halt
@@ -459,7 +459,7 @@ The canonical state is:
459459 bounded by queue size. Each descriptor names a distinct, configured-size
460460 slot aligned relative to the pool start. Available descriptors form a prefix
461461 followed by zeroed descriptors.
462- * Guest producer and pool bookkeeping matches the rings and retained leases.
462+ * Guest producer and pool bookkeeping matches the rings and current leases.
463463* Driver and device event suppression is normalized.
464464* Host consumers start at cursor zero.
465465
@@ -490,11 +490,13 @@ The first request fits the H2G capacity posted at checkpoint. Retained slots
490490reduce pool capacity but hold no ring descriptors. Framing, slot rounding, ring
491491size, and the external-byte control reserve still apply.
492492
493- The first transport entry after checkpoint maps missing pool pages to scratch.
494- After restore, it also copies recorded slots from captured aliases into scratch
495- and remaps their pages. This applies to logs and host callbacks before request
496- dispatch as well as ordinary H2G calls. Pool ownership, descriptors, and
497- cursors stay unchanged, preserving the submitted request.
493+ The first transport entry after restore recycles slots held by captured
494+ leases. Posted chains keep their reservations, preserving the submitted
495+ request. Descriptors and cursors stay unchanged. Retained aliases keep their
496+ captured mappings without payload copying.
497+
498+ Source continuation keeps the pool generation and live scratch leases intact.
499+ Checkpointing alone does not detach retained payloads from scratch.
498500
499501Result completion prefills free H2G slots. This requires no preparatory guest
500502entry or application warmup for the checkpoint-posted capacity.
0 commit comments