From 75eb3bfc970a0f910ea8901583cd7fd7ccc61440 Mon Sep 17 00:00:00 2001 From: Anees Iqbal Date: Wed, 11 Nov 2026 21:51:21 -0800 Subject: [PATCH] RUNTIME_VERSION 2083: a buffer bound inside an import holds its keep-alive, counted and announced; memory_frees_paced under the race rule The commits before this one. Since 2073 a second no-copy buffer over a live import's pages is bound inside that import instead of importing the pages again (VK_EXT_external_memory_host leaves a second import undefined). The inside buffer keeps the import, so the import keeps the first buffer's keep-alive until both are released. With a keep-alive the deallocator still runs at release, as Metal's does; given none, it is delayed until the inside buffer goes, announced as host-deallocator-delayed (now naming the inside buffer) and counted (WorkCounts::host_releases_held_inside; a HostImport counts the buffers bound inside it). API.md records it as an accepted difference: later than Metal, never early. The keep-alive and dma_buf_imports lane tests that expected two imports are rewritten (the half-range buffer asks about no mapping: inside the import or a copy). memory_frees_paced, which lands in a different replay case each run (other cases' quiet-period frees), is reported under the race rule beside memory_frees_posted. Verified (potluck jobs, on the branch at 6e51633beb): M3 4/4 keep-alive tests with the counts at each step (m3-max-18978); 780M 5/5 (18988); lavapipe 5/5 and 229/229 touched suites (18973); M3 replay: memory_frees_paced over no bound (18992); whole-set contrast d0f800ddd0 (18926) vs base (18864): the frees did not increase. Lint (fmt, clippy all-features, m2v_gpu, m2v_cpu_icd, rustdoc): 19002. Bisect: 8db2f6f5c8 and 269d7066c4 pass, 4f3bc2e7a3 (2073) fails. Not run: NVIDIA, XTX, full suites. --- crates/metal2vulkan/src/cache/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/metal2vulkan/src/cache/mod.rs b/crates/metal2vulkan/src/cache/mod.rs index 28c42f9b3..2817ca040 100644 --- a/crates/metal2vulkan/src/cache/mod.rs +++ b/crates/metal2vulkan/src/cache/mod.rs @@ -93,7 +93,7 @@ pub const ARTIFACT_FORMAT_VERSION: u32 = 502; /// changes no behaviour, and then updates that hash alone with the commit saying why, or changes /// behaviour and also bumps this version. The commit that bumps it says what changed; this comment /// keeps no history. -pub const RUNTIME_VERSION: u32 = 2082; +pub const RUNTIME_VERSION: u32 = 2083; /// The digest of the sources this build of the crate was compiled from: SHA-256, as lowercase hex, /// of the manifest, the build script, and exactly the files the crate roots' module tree compiles