一个学习索引的微观结构分析
Micro-architectural Analysis of a Learned Index
摘要:
自2018年《习得索引结构案例》出版以来,针对不同领域和不同功能的习得索引的研究有所增加。虽然学习索引作为传统索引结构(如B+树)的替代方案的有效性已经被几项研究所证明,但以前的工作往往集中在更高级别的性能指标上,如吞吐量和索引大小。在本文中,我们的目标是更深入地挖掘和研究与传统索引相比,学习索引在微观架构级别上的行为。更具体地说,我们专注于以前提出的学习索引结构ALEX,这是一个基于树的内存索引结构,由机器学习模型的层次结构。与最初的学习索引提案不同,ALEX是从头开始设计的,允许更新和插入。因此,它可以使用学习的索引实现更动态的工作负载。在这项工作中,我们对ALEX进行了微观架构分析,并将其行为与不基于学习模型的基于树的索引结构进行了比较,即,艺术与B+树我们的研究结果表明,ALEX是绑定的内存失速,主要是由于数据未命中从最后一级缓存的失速。与ART和B+Tree相比,ALEX在不同的工作负载中表现出更少的停顿和更低的每指令周期值。另一方面,在ALEX中处理越界插入所需的指令量可能会使每个请求所需的指令量显著增加(10倍),以应对写任务繁重的工作负载。然而,微体系结构的行为表明,这种指令占用的增加表现出高指令级并行,因此,不会对总体执行时间产生负面影响。
英文摘要:
Since the publication of The Case for Learned Index Structures in 2018, there has been a rise in research that focuses on learned indexes for different domains and with different functionalities. While the effectiveness of learned indexes as an alternative to traditional index structures such as B+Trees have already been demonstrated by several studies, previous work tend to focus on higher-level performance metrics such as throughput and index size. In this paper, our goal is to dig deeper and investigate how learned indexes behave at a micro-architectural level compared to traditional indexes. More specifically, we focus on previously proposed learned index structure ALEX, which is a tree-based in-memory index structure that consists of a hierarchy of machine learned models. Unlike the original proposal for learned indexes, ALEX is designed from the ground up to allow updates and inserts. Therefore, it enables more dynamic workloads using learned indexes. In this work, we perform a micro-architectural analysis of ALEX and compare its behavior to the tree-based index structures that are not based on learned models, i.e., ART and B+Tree. Our results show that ALEX is bound by memory stalls, mainly stalls due to data misses from the last-level cache. Compared to ART and B+Tree, ALEX exhibits fewer stalls and a lower cycles-per-instruction value across different workloads. On the other hand, the amount of instructions required to handle out-of-bound inserts in ALEX can increase the instructions needed per request significantly (10X) for write-heavy workloads. However, the micro-architectural behavior shows that this increase in the instruction footprint exhibit high instruction-level parallelism, and, therefore, does not negatively impact the overall execution time.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。