AdaSlice: Hotness-Aware and Adaptive Slicing for Eviction Algorithms in Database Buffer Manager with Tiered Memory
摘要
Tiered memory leverages emerging interconnect technologies (e.g., CXL) and cheaper alternatives (e.g., PM) to scale databases cost-efficiently. Skewed access patterns are prevalent in DBMS workloads, where a small fraction of tuples dominate most accesses. Therefore, tuple-granularity data migration between fast and slow memory outperforms page-granularity approaches. Tuple-granularity eviction algorithms improve fast memory access ratio (FAR), thereby boosting performance, but incur substantial memory overhead when tracking hotness for ubiquitous small tuples. Grouping adjacent tuples into a slice for hotness tracking can amortize memory overhead, but existing slice-granularity eviction algorithms suffer from poor hot/cold identification accuracy due to rigid page-aligned slicing. This paper proposes AdaSlice, a hotness-aware and adaptive slicing mechanism for tuple eviction algorithms in database buffer manager with tiered memory. The key idea is to drive slice splitting and merging based on four thresholds of size and hotness dispersion, thereby achieving a favorable trade-off between hot/cold identification accuracy and hotness metadata overhead. We further employ simulated annealing to adaptively derive near-optimal thresholds under diverse workloads and configurations. We integrate AdaSlice into six eviction algorithms and implement them within the tiered buffer manager. Experimental results show that AdaSlice increases FAR by 30.5% and improves database throughput by 20.6%.