一句话:提出核内硬件加速器 Mallacc,以低延迟和极小面积加速现代内存分配器的 malloc 操作。
动态内存分配在 Google 数据中心中消耗近 7% 的周期,而硬件专用化趋势为加速分配器提供了新机会。本文提出 Mallacc,一种面向多种高性能现代内存分配器的核内硬件加速器。与追求吞吐的传统加速器不同,内存分配请求频繁、快速且分散在应用代码中,因此 Mallacc 以延迟而非吞吐为优化目标,并将面积开销压到最低。它加速一次典型分配请求的三个主要操作:大小类计算、空闲内存块获取以及内存使用采样。评估表明,Mallacc 可将 malloc 延迟最多降低 50%,硬件成本低于 1500 平方微米,不足典型高性能处理器核心面积的 0.006%。
Recent work shows that dynamic memory allocation consumes nearly 7% of all cycles in Google datacenters. With the trend towards increased specialization of hardware, we propose Mallacc, an in-core hardware accelerator designed for broad use across a number of high-performance, modern memory allocators. The design of Mallacc is quite different from traditional throughput-oriented hardware accelerators. Because memory allocation requests tend to be very frequent, fast, and interspersed inside other application code, accelerators must be optimized for latency rather than throughput and area overheads must be kept to a bare minimum. Mallacc accelerates the three primary operations of a typical memory allocation request: size class computation, retrieval of a free memory block, and sampling of memory usage. Our results show that malloc latency can be reduced by up to 50% with a hardware cost of less than 1500 um2 of silicon area, less than 0.006% of a typical high-performance processor core.