Snapshot memory, host lists and send memory kept for reuse (VICTORY_SNAPSHOT_POOL=8: as before)

Made anew and given back all the time: 30 % of the submitting thread in the opening (profile cpu-1: allocations of snapshots 11, preludes 12, lists dropped 5, send memory 3).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
localandClaude Opus 5.5 committed 2026-11-25 03:50:04 -06:00
1 parent 74005234a2
commit d4943c43fb
3 files changed
+40 -17

No files matched your search

+3 -1
View File
@@ -129,7 +129,9 @@ fn memory(host: &Host, size: u64) -> Option<Memory> {
return Some(spare.swap_remove(i));
}
}
let size = size.next_multiple_of(8 << 20);
// By doubles, so that the next of about this size finds it: what
// submissions send differs from frame to frame.
let size = size.max(8 << 20).next_power_of_two();
let (buffer, data) = host.upload_buffer(size)?;
name(&buffer, || "bytes a submission sends up".into());
Some(Memory {