docs(adr): memory + eviction decisions 0006-0008 (closes #41, #45, #46)#171
Merged
Conversation
ADR-0006 default allocator (#41): tikv-jemallocator/jemalloc for mallctl introspection, the je_get_defrag_hint path, and tuned dirty-page decay; per-shard mallctl accounting makes maxmemory honest (invariant 3); mimalloc rejected as default for lacking introspection/defrag-hint. ADR-0007 cache mode by default (#45): host-derived ceiling + eviction ON; strict no-evict is an explicit opt-in, inverting Redis's maxmemory 0 / noeviction footgun. ADR-0008 default eviction policy (#46): S3-FIFO behind a pluggable EvictionPolicy trait; SIEVE and W-TinyLFU-fronted kept selectable; LRU rejected (per-hit relink). INDEX/OPEN/QUESTIONS updated; #42/#47 to be re-milestoned to M1 as empirical validation. Closes #41 Closes #45 Closes #46 Signed-off-by: Zeke <ezequiel.lares@outlook.com>
ADR-0006: correct the accounting model (jemalloc stats.allocated is logical used_memory, NOT RSS; invariant 3 means logical allocated bytes; RSS can exceed it, decay/defrag keep them close); record #41's commitments to enable the jemalloc background purger and lower dirty_decay_ms for eviction churn; narrow the mimalloc rejection to the decisive je_get_defrag_hint gap (mimalloc can report RSS via mi_process_info). ADR-0007: replace the strawman rejected option with issue #45's real Option C (ceiling-on + noeviction default). ADR-0008: cite SIEVE's own >45%-of-traces result and the ~8B/entry W-TinyLFU sketch vs S3-FIFO's 2-bit counter; flag both win-rates as home-corpus, gated on #47; add the sampled-LRU/LFU rejection. refs #41, refs #45, refs #46 Signed-off-by: Zeke <ezequiel.lares@outlook.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Three evidence-grounded decisions on the bytes-per-key / throughput-per-core core.
What
Review focus (engineering)
Closes #41. Closes #45. Closes #46. Part of M0: Vision and Scope.