论文标题
理解和优化持续的内存分配
Understanding and Optimizing Persistent Memory Allocation
论文作者
论文摘要
快速,密集,字节可调的非易失性存储器的扩散表明,可以在程序运行范围内,甚至流程和系统崩溃中将数据保存在指针填充的“内存中”格式中。对于完整的一般性,此类数据需要动态内存分配,尽管分配器可以原则上“滚入”每个数据结构,但希望将其作为单独的抽象。 为此,我们介绍了可恢复性,持久分配器的正确性标准,以及不满足该标准的非封锁分配器Ralloc。 Ralloc基于Leite和Rocha的Lrmalloc,并具有三项关键的创新。首先,我们在正常操作期间持续足够的信息,以允许在全系统崩溃后正确重建堆。我们的重建机制执行垃圾收集(GC),以识别和补救任何失败引起的内存泄漏。其次,我们介绍了过滤器功能的概念,该函数识别指针在持久块内的位置以减轻保守GC的局限性。第三,为了允许在任意地址映射持续区域,我们对数据和元数据都采用了与位置无关(基于偏移的)指针。 实验表明,Ralloc与Makalu(基于最新的锁定持续分配器)以及LRMALLOC和JEMALLOC等瞬时分配器具有性能竞争力。特别是,依赖GC和离线元数据重建使Ralloc在正常操作期间几乎不需要持续。
The proliferation of fast, dense, byte-addressable nonvolatile memory suggests that data might be kept in pointer-rich "in-memory" format across program runs and even process and system crashes. For full generality, such data requires dynamic memory allocation, and while the allocator could in principle "rolled into" each data structure, it is desirable to make it a separate abstraction. Toward this end, we introduce recoverability, a correctness criterion for persistent allocators, together with a nonblocking allocator, Ralloc, that satisfies this criterion. Ralloc is based on the LRMalloc of Leite and Rocha, with three key innovations. First, we persist just enough information during normal operation to permit correct reconstruction of the heap after a full-system crash. Our reconstruction mechanism performs garbage collection (GC) to identify and remedy any failure-induced memory leaks. Second, we introduce the notion of filter functions, which identify the locations of pointers within persistent blocks to mitigate the limitations of conservative GC. Third, to allow persistent regions to be mapped at an arbitrary address, we employ position-independent (offset-based) pointers for both data and metadata. Experiments show Ralloc to be performance-competitive with both Makalu, the state-of-the-art lock-based persistent allocator, and such transient allocators as LRMalloc and JEMalloc. In particular, reliance on GC and offline metadata reconstruction allows Ralloc to pay almost nothing for persistence during normal operation.