Commit 9de7a63
committed
refactor(vfs): single-pass LRU eviction in OverlayVfsRegistry
Replace the snapshot-Vec + two-filter approach with a single
`min_by_key` pass. Tuple-sort `(non_idle_flag, ts)` so idle entries
come first, with the smallest `ts` winning within each group — same
"prefer oldest idle, fall back to globally oldest" semantics, no
per-eviction allocation.
(Addresses Gemini review suggestion.)1 parent a4ad8fd commit 9de7a63
1 file changed
Lines changed: 9 additions & 13 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
266 | 266 | | |
267 | 267 | | |
268 | 268 | | |
269 | | - | |
270 | | - | |
271 | | - | |
272 | | - | |
273 | | - | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
274 | 276 | | |
275 | | - | |
276 | | - | |
| 277 | + | |
| 278 | + | |
277 | 279 | | |
278 | | - | |
279 | | - | |
280 | | - | |
281 | | - | |
282 | | - | |
283 | | - | |
284 | 280 | | |
285 | 281 | | |
286 | 282 | | |
| |||
0 commit comments