Caching is a crucial component of many computer systems, so naturally it is a well-studied topic in algorithm design. Much of traditional caching research studies cache management for a single-user or single-processor environment. In this paper, we propose two related generalizations of the classical caching problem that capture issues that arise in a multi-user or multi-processor environment. In the caching with reserves problem, a caching algorithm is required to maintain at least $k_i$ pages belonging to user $i$ in the cache at any time, for some given reserve capacities $k_i$. In the public-private caching problem, the cache of total size $k$ is partitioned into subcaches, a private cache of size $k_i$ for each user $i$ and a shared public cache usable by any user. In both of these models, as in the classical caching framework, the objective of the algorithm is to dynamically maintain the cache so as to minimize the total number of cache misses. We show that caching with reserves and public-private caching models are equivalent up to constant factors, and thus focus on the former. Unlike classical caching, both of these models turn out to be NP-hard even in the offline setting, where the page sequence is known in advance. For the offline setting, we design a 2-approximation algorithm, whose analysis carefully keeps track of a potential function to bound the cost. In the online setting, we first design an $O(\ln k)$-competitive fractional algorithm using the primal-dual framework, and then show how to convert it online to a randomized integral algorithm with the same guarantee.
翻译:缓存是许多计算机系统的关键组成部分, 所以自然它是一个在算法设计中研究周密的话题。 许多传统的缓存研究研究研究为单一用户或单一处理环境的缓存管理。 在本文中, 我们建议对传统缓存问题进行两个相关的概括化分析, 以捕捉多用户或多处理环境中出现的问题。 在缓存问题堆积中, 需要一种缓存算法来保持至少为用户在缓存中拥有的$$( 美元) 的缓存页面, 对于某些特定的储备能力 $( 美元 美元 ) 。 在公共- 私人缓存问题中, 总大小 $( 美元) 的缓存被分割成缓存管理 。 在一次缓存中, 缓存算算法的目的是动态保存缓存, 以便尽可能减少缓存的总数 。 我们通过缓存和公共- 私人缓存模型的缓存和总储能力 $( $ $ i $ $ $ $ $ ) 。 在一次缓存中, 总的缓存中, 总的缓存缓存缓存中, 将总的缓存缓存缓存缓存存储到 等同恒存中, 等同恒存中, 等同恒存 等于常存因素值 等同于常存因素, 。