NALI: NUMA-Aware Adaptive Learned Index for In-Memory Multi-core Databases
摘要
Learned indexes introduce a novel approach to database indexing by conceptualizing indexes as predictive models. These models predict the positions of keys within datasets, which significantly improve efficiency and performance. However, in Non-Uniform Memory Access (NUMA) environments, learned indexes often suffer from performance stagnation or even degradation as the degree of resource contention increases. NALI reduces model error and mitigates write amplification by leveraging precise segment prediction and error-bounded conflict resolution within a semi-ordered structure, effectively balancing model accuracy and write efficiency. To further adapt to dynamic workload patterns, NALI incorporates an adaptive node evolution mechanism, which dynamically adjusts node structures based on real-time access characteristics. Additionally, a NUMA-aware memory management and thread scheduling framework enables efficient thread-query co-location and load balancing. Extensive experimental results demonstrate that NALI consistently outperforms the state-of-the-art learned index AlexOL, delivering 1.80 \(\times \) , 2.63 \(\times \) , and 2.31 \(\times \) performance gains under read-only, write-only, and balanced workloads, respectively, while maintaining comparable space efficiency.