The Map is to take the Swiss-table layout
This commit is contained in:
parent
af4da764b2
commit
7a1d9c1263
3
TODO.org
3
TODO.org
@ -1264,7 +1264,8 @@ Removal landed, with the loop the spec predicted as its cost. Deferring it was
|
|||||||
what had kept the implementation free of tombstones and of Odin's
|
what had kept the implementation free of tombstones and of Odin's
|
||||||
backward-shift loop; taking it is taking the loop.
|
backward-shift loop; taking it is taking the loop.
|
||||||
|
|
||||||
** TODO The Map is slower than CPython's dict at a million entries
|
** NEXT The Map is slower than CPython's dict at a million entries
|
||||||
|
Decided 2026-09-25: build the Swiss-table layout, one metadata byte a slot. Measured against the current Map at small, game and large sizes before and after.
|
||||||
Keys, values and hashes are three separate runs, so a lookup that misses
|
Keys, values and hashes are three separate runs, so a lookup that misses
|
||||||
everything costs three cache misses where a compact dict costs two. One byte of
|
everything costs three cache misses where a compact dict costs two. One byte of
|
||||||
metadata a slot — the Swiss-table arrangement — is the known answer and is not
|
metadata a slot — the Swiss-table arrangement — is the known answer and is not
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user