In an $\alpha$-way set-associative cache, the cache is partitioned into disjoint sets of size $\alpha$, and each item can only be cached in one set, typically selected via a hash function. Set-associative caches are widely used and have many benefits, e.g., in terms of latency or concurrency, over fully associative caches, but they often incur more cache misses. As the set size $\alpha$ decreases, the benefits increase, but the paging costs worsen. In this paper we characterize the performance of an $\alpha$-way set-associative LRU cache of total size $k$, as a function of $\alpha = \alpha(k)$. We prove the following, assuming that sets are selected using a fully random hash function: - For $\alpha = \omega(\log k)$, the paging cost of an $\alpha$-way set-associative LRU cache is within additive $O(1)$ of that a fully-associative LRU cache of size $(1-o(1))k$, with probability $1 - 1/\operatorname{poly}(k)$, for all request sequences of length $\operatorname{poly}(k)$. - For $\alpha = o(\log k)$, and for all $c = O(1)$ and $r = O(1)$, the paging cost of an $\alpha$-way set-associative LRU cache is not within a factor $c$ of that a fully-associative LRU cache of size $k/r$, for some request sequence of length $O(k^{1.01})$. - For $\alpha = \omega(\log k)$, if the hash function can be occasionally changed, the paging cost of an $\alpha$-way set-associative LRU cache is within a factor $1 + o(1)$ of that a fully-associative LRU cache of size $(1-o(1))k$, with probability $1 - 1/\operatorname{poly}(k)$, for request sequences of arbitrary (e.g., super-polynomial) length. Some of our results generalize to other paging algorithms besides LRU, such as least-frequently used (LFU).


翻译:在$\alpha$路组相联缓存中,缓存被划分为大小为$\alpha$的不相交集合,每个项目只能被缓存在一个集合中(通常通过哈希函数选择)。组相联缓存被广泛使用,且相较于全相联缓存具有诸多优势(例如延迟或并发性方面),但通常会导致更多缓存缺失。随着组大小$\alpha$减小,优势增加,但分页开销恶化。本文刻画了总大小为$k$的$\alpha$路组相联LRU缓存的性能随$\alpha = \alpha(k)$变化的规律。假设使用完全随机哈希函数选择集合,我们证明以下结论:- 对于$\alpha = \omega(\log k)$,在长度为$\operatorname{poly}(k)$的所有请求序列上,$\alpha$路组相联LRU缓存的分页开销以概率$1 - 1/\operatorname{poly}(k)$不超过大小为$(1-o(1))k$的全相联LRU缓存分页开销的加性$O(1)$。- 对于$\alpha = o(\log k)$,对所有$c = O(1)$和$r = O(1)$,存在某个长度为$O(k^{1.01})$的请求序列,使得$\alpha$路组相联LRU缓存的分页开销不在大小为$k/r$的全相联LRU缓存分页开销的$c$倍以内。- 对于$\alpha = \omega(\log k)$,若哈希函数可偶尔更换,则对于任意长度(例如超多项式长度)的请求序列,$\alpha$路组相联LRU缓存的分页开销以概率$1 - 1/\operatorname{poly}(k)$不超过大小为$(1-o(1))k$的全相联LRU缓存分页开销的$1 + o(1)$倍。部分结果可推广至除LRU外的其他分页算法(如最不频繁使用(LFU)算法)。

0
下载
关闭预览

相关内容

JCIM丨DRlinker:深度强化学习优化片段连接设计
专知会员服务
7+阅读 · 2022年12月9日
专知会员服务
52+阅读 · 2020年12月14日
Etcd 客户端缓存实践
InfoQ
0+阅读 · 2022年6月10日
Multi-Task Learning的几篇综述文章
深度学习自然语言处理
15+阅读 · 2020年6月15日
图机器学习 2.2-2.4 Properties of Networks, Random Graph
图与推荐
10+阅读 · 2020年3月28日
Transferring Knowledge across Learning Processes
CreateAMind
29+阅读 · 2019年5月18日
R工程化—Rest API 之plumber包
R语言中文社区
11+阅读 · 2018年12月25日
disentangled-representation-papers
CreateAMind
26+阅读 · 2018年9月12日
Capsule Networks解析
机器学习研究会
11+阅读 · 2017年11月12日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
Arxiv
0+阅读 · 2023年5月25日
VIP会员
最新内容
ICML 2026 | 自回归Boltzmann生成器重塑分子采样
专知会员服务
0+阅读 · 6月26日
GNN跨域综述:从消息传递到图基础模型
专知会员服务
0+阅读 · 6月26日
无人机自主控制与人工智能:系统性综述
专知会员服务
11+阅读 · 6月26日
巡飞弹与反无人机系统——现代战场的两大支柱
《打造“黄金舰队”》57页报告
专知会员服务
3+阅读 · 6月26日
《北约数字教官网络发展路径》128页报告
专知会员服务
2+阅读 · 6月26日
ECCV 2026 | MIMFlow:MIM与归一化流统一图像生成
专知会员服务
7+阅读 · 6月25日
网状网络及其在军事领域的运用
专知会员服务
8+阅读 · 6月25日
无美国参与的欧洲战争方式(万字长文)
专知会员服务
8+阅读 · 6月25日
《国防领域敏感性分析白皮书》
专知会员服务
9+阅读 · 6月25日
相关基金
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
Top
微信扫码咨询专知VIP会员