Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Cache behavior
Search
Chen
November 03, 2022
Science
0
79
Cache behavior
Chen
November 03, 2022
Tweet
Share
More Decks by Chen
See All by Chen
Example ROP in MIPS
tiffany_04192
0
50
defense
tiffany_04192
0
69
Dijkstra’s Algorithm
tiffany_04192
0
110
Floyd-Warshall
tiffany_04192
0
87
Topological sort DFS
tiffany_04192
0
86
BFS
tiffany_04192
0
120
DFS
tiffany_04192
0
95
Cache miss paper
tiffany_04192
0
110
Greedy
tiffany_04192
0
100
Other Decks in Science
See All in Science
はじめてのバックドア基準:あるいは、重回帰分析の偏回帰係数を因果効果の推定値として解釈してよいのか問題
takehikoihayashi
2
990
Analysis-Ready Cloud-Optimized Data for your community and the entire world with Pangeo-Forge
jbusecke
0
120
山形とさくらんぼに関するレクチャー(YG-900)
07jp27
1
240
トラブルがあったコンペに学ぶデータ分析
tereka114
2
1.2k
生成AI による論文執筆サポートの手引き(ワークショップ) / A guide to supporting dissertation writing with generative AI (workshop)
ks91
PRO
0
340
butterfly_effect/butterfly_effect_in-house
florets1
1
110
ウェーブレットおきもち講座
aikiriao
1
800
How were Quaternion discovered
kinakomoti321
2
1.1k
ACL読み会2024@名大 REANO: Optimising Retrieval-Augmented Reader Models through Knowledge Graph Generation
takuma_matsubara
0
110
【人工衛星開発】能見研究室紹介動画
02hattori11sat03
0
160
非同期コミュニケーションの構造 -チャットツールを用いた組織における情報の流れの設計について-
koisono
0
180
マテリアルズ・インフォマティクスの先端で起きていること / What's Happening at the Cutting Edge of Materials Informatics
snhryt
1
150
Featured
See All Featured
The Art of Programming - Codeland 2020
erikaheidi
53
13k
Building an army of robots
kneath
302
44k
The World Runs on Bad Software
bkeepers
PRO
66
11k
Raft: Consensus for Rubyists
vanstee
137
6.7k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
49
2.2k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
171
50k
Rails Girls Zürich Keynote
gr2m
94
13k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
3
310
YesSQL, Process and Tooling at Scale
rocio
170
14k
No one is an island. Learnings from fostering a developers community.
thoeni
19
3k
Writing Fast Ruby
sferik
628
61k
The Power of CSS Pseudo Elements
geoffreycrofte
73
5.4k
Transcript
23 Cache Behavior Example Set # Valid Tag Data 0
0 000 00 00 00 00 1 0 000 00 00 00 00 2 0 000 00 00 00 00 3 0 000 00 00 00 00 4 0 000 00 00 00 00 5 0 000 00 00 00 00 6 0 000 00 00 00 00 7 0 000 00 00 00 00 Cache starts empty (valid = 0), 8 blocks (or sets) in cache, 4B blocks, 16-bit address
24 Cache Behavior Example Set # Valid Tag Data 0
0 000 00 00 00 00 1 0 000 00 00 00 00 2 0 000 00 00 00 00 3 0 000 00 00 00 00 4 0 000 00 00 00 00 5 0 000 00 00 00 00 6 0 000 00 00 00 00 7 0 000 00 00 00 00 Access address 0x1234 = 0001 0010 0011 0100 Offset = 0 Index = 5 Tag = 145 Valid bit == 0 à miss
26 Cache Behavior Example Set # Valid Tag Data 0
0 000 00 00 00 00 1 0 000 00 00 00 00 2 0 000 00 00 00 00 3 0 000 00 00 00 00 4 0 000 00 00 00 00 5 1 145 0F 1E 39 EC 6 0 000 00 00 00 00 7 0 000 00 00 00 00 Access address 0x1234 = 0001 0010 0011 0100 lb: 00 00 00 EC lh: 00 00 39 EC lw: 0F 1E 39 EC Offset = 2 Tag = 145 Index = 5 Valid && tag match à hit
27 Cache Behavior Example Set # Valid Tag Data 0
0 000 00 00 00 00 1 0 000 00 00 00 00 2 0 000 00 00 00 00 3 0 000 00 00 00 00 4 0 000 00 00 00 00 5 1 145 0F 1E 39 EC 6 0 000 00 00 00 00 7 0 000 00 00 00 00 Valid && tag match à hit lb: 00 00 00 1E lh: 00 00 0F 1E lw: (unaligned) Access address 0x1236 = 0001 0010 0011 0110 Offset = 2 Index = 5 Tag = 145
28 Cache Behavior Example Set # Valid Tag Data 0
0 000 00 00 00 00 1 0 000 00 00 00 00 2 0 000 00 00 00 00 3 0 000 00 00 00 00 4 0 000 00 00 00 00 5 1 145 0F 1E 39 EC 6 0 000 00 00 00 00 7 0 000 00 00 00 00 Access address 0x1238 = 0001 0010 0011 1000 Offset = 0 Index = 6 Tag = 145 Not valid à miss
29 Cache Behavior Example Set # Valid Tag Data 0
0 000 00 00 00 00 1 0 000 00 00 00 00 2 0 000 00 00 00 00 3 0 000 00 00 00 00 4 0 000 00 00 00 00 5 1 145 0F 1E 39 EC 6 0 000 00 00 00 00 7 0 000 00 00 00 00 Access address 0x1238 = 0001 0010 0011 1000 1 145 Make request to next level... Wait for it…
30 Cache Behavior Example Set # Valid Tag Data 0
0 000 00 00 00 00 1 0 000 00 00 00 00 2 0 000 00 00 00 00 3 0 000 00 00 00 00 4 0 000 00 00 00 00 5 1 145 0F 1E 39 EC 6 1 145 3C 99 11 12 7 0 000 00 00 00 00 Access address 0x2234 = 0010 0010 0011 0100 Offset = 0 Index = 5 Tag = 273 Valid, but tags don’t match à miss
31 Cache Behavior Example Set # Valid Tag Data 0
0 000 00 00 00 00 1 0 000 00 00 00 00 2 0 000 00 00 00 00 3 0 000 00 00 00 00 4 0 000 00 00 00 00 5 1 145 0F 1E 39 EC 6 1 145 3C 99 11 12 7 0 000 00 00 00 00 Access address 0x2234 = 0010 0010 0011 0100 Make request to next level... Wait for it… 273
32 Cache Behavior Example Set # Valid Tag Data 0
0 000 00 00 00 00 1 0 000 00 00 00 00 2 0 000 00 00 00 00 3 0 000 00 00 00 00 4 0 000 00 00 00 00 5 1 273 01 CF D0 87 6 1 145 3C 99 11 12 7 0 000 00 00 00 00 Access address 0x2234 = 0010 0010 0011 0100 Note that now, 0x1234’s data is gone Replaced by 0x2234’s data