内存再分配的近似二次改进
A Nearly Quadratic Improvement for Memory Reallocation
AI总结:
本研究推翻Kuszmaul关于大项内存再分配传统算法最优的推测,提出实现O(ε^{-1/2}polylogε^{-1})期望更新成本的分配器,给出首个非平凡下界,并证明随机场景下大项区间仍可达O(logε^{-1})成本。
摘要:
在内存再分配问题中,一组不同大小的项必须被动态分配到不重叠的连续内存块中。该问题保证任意时刻所有存在项的大小之和至多为内存总大小的$(1-\varepsilon)$倍(即负载因子至多为$1-\varepsilon$)。分配器在线接收插入和删除请求,可通过重新排列现有项来处理请求,但需承担再分配成本,其定义为被移动项的大小之和除以被插入/删除项的大小。\n 内存再分配的传统算法每次更新的成本为$O(\varepsilon^{-1})$。在FOCS'23的近期工作中,Kuszmaul证明,在每个项都保证小于内存大小的$\varepsilon^4$倍这一特殊情况下,可实现$O(\log\varepsilon^{-1})$的期望更新成本。但Kuszmaul推测,对于更大的项,传统算法是最优的。\n 在本研究中我们推翻了Kuszmaul的推测,提出一种分配器,在任意输入序列上均可实现$O(\varepsilon^{-1/2} \operatorname*{polylog} \varepsilon^{-1})$的期望更新成本。我们还给出了内存再分配问题的首个非平凡下界:证明存在一类输入序列,使得任何可调整大小的分配器(即使是离线的)都必须承担至少$\Omega(\log\varepsilon^{-1})$的摊销更新成本。\n 最后,我们分析了插入和删除为随机序列、项的大小随机取自$[\delta, 2\delta]$($\delta$为某一常数)的内存再分配问题。结果表明,在这一简化场景下,即使处于“大项”参数区间($\delta> \varepsilon^4$),仍可实现$O(\log\varepsilon^{-1})$的期望更新成本。
英文摘要:
In the Memory Reallocation Problem a set of items of various sizes must be dynamically assigned to non-overlapping contiguous chunks of memory. It is guaranteed that the sum of the sizes of all items present at any time is at most a $(1-\varepsilon)$-fraction of the total size of memory (i.e., the load-factor is at most $1-\varepsilon$). The allocator receives insert and delete requests online, and can re-arrange existing items to handle the requests, but at a reallocation cost defined to be the sum of the sizes of items moved divided by the size of the item being inserted/deleted. The folklore algorithm for Memory Reallocation achieves a cost of $O(\varepsilon^{-1})$ per update. In recent work at FOCS'23, Kuszmaul showed that, in the special case where each item is promised to be smaller than an $\varepsilon^4$-fraction of memory, it is possible to achieve expected update cost $O(\log\varepsilon^{-1})$. Kuszmaul conjectures, however, that for larger items the folklore algorithm is optimal. In this work we disprove Kuszmaul's conjecture, giving an allocator that achieves expected update cost $O(\varepsilon^{-1/2} \operatorname*{polylog} \varepsilon^{-1})$ on any input sequence. We also give the first non-trivial lower bound for the Memory Reallocation Problem: we demonstrate an input sequence on which any resizable allocator (even offline) must incur amortized update cost at least $Ω(\log\varepsilon^{-1})$. Finally, we analyze the Memory Reallocation Problem on a stochastic sequence of inserts and deletes, with random sizes in $[δ, 2 δ]$ for some $δ$. We show that, in this simplified setting, it is possible to achieve $O(\log\varepsilon^{-1})$ expected update cost, even in the ``large item'' parameter regime ($δ> \varepsilon^4$).
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。