Presentation is loading. Please wait.

Presentation is loading. Please wait.

Minimizing Cache Usage in Paging Alejandro Salinger University of Waterloo Joint work with Alex López-Ortiz.

Similar presentations


Presentation on theme: "Minimizing Cache Usage in Paging Alejandro Salinger University of Waterloo Joint work with Alex López-Ortiz."— Presentation transcript:

1 Minimizing Cache Usage in Paging Alejandro Salinger University of Waterloo Joint work with Alex López-Ortiz

2 Outline Paging problem and models Paging with cache usage Offline optimum Online algorithms Simulations Conclusions

3 Paging 3 1 14 5 3 8 7 13 9 11 10 15 24 4 18 21 30 17 22 19 2 3 Cache Memory Hit! Memory

4 Paging 6 1 14 5 3 8 7 13 9 11 10 15 24 4 18 21 30 17 22 19 2 Fault! Cache Memory 6 6

5 Paging Input: sequence of page requests cache size k Paging algorithm = eviction policy What page should be evicted from the cache? Traditional cost model Hit: 0 Fault: 1 Goal: minimize the number of faults

6 Paging Common eviction policies: Least Recently Used (LRU) First In First Out (FIFO) Flush When Full (FWF) Furthest In The Future (FITF) (offline)

7 Competitive Analysis

8 Paging Models Page has fault cost and size Page fault (classic) model Uniform size and fault costs Weighted caching [Chrobak 91] Varying fault costs, uniform page sizes Fault model [Irani 97] Varying sizes, uniform fault cost Bit model [Irani 97] Fault cost equals size General [Young 98] k-competitive algorithms for all above Offline problem is NP-hard

9 Paging Models

10

11 Paging with Cache Usage

12 fault cost cell cost

13 Applications Shared cache multiprocessors

14 Applications Shared cache multiprocessors Cooperative caching

15 Applications Energy efficient caching Content Addressable Memories (CAMs) 1 14 5 3 8 7 13 9 11 10 15 24 4 18 21 30 17 22 19 2 Cache 3

16 Applications Energy efficient caching Content Addressable Memories (CAMs) Power of search proportional to valid cells 15 3 8 7910 15 24 4 30222 Cache 3

17 Offline Optimum

18 …,3,3,4,5,21,3,4,17,5,3,5,5,6,7,8, ??? Offline Optimum But paging is an online problem! Offline algorithm can lead to good online algorithms Classic paging optimum: FITF LRU …,3,3,4,5,21,3,4,17,5,3,5,5,6,7,8,9,6,7,4,4,5,3,15,13,3,3,7,8,9,… 8,7,6,5,5,3,5,17,4

19 Interval Scheduling 12341135234512 12341135234512

20 12341135234512

21 12341135234512

22 Offline Optimum

23 Online Algorithms

24 Marking algorithm: at most k faults in each phase LRU, FWF, CLOCK Conservative algorithm: at most k faults LRU, FIFO, CLOCK ≤ k distinct pages ≤ k

25 Online Algorithms

26 p Not quite…

27 k = 10

28 …1234561234…

29 43167589206231 k = 9

30 For any conservative or marking A k = 10

31 OPT

32

33

34

35 Locality of Reference L = Average length of phase in k-phase partition k = 10 L = 150

36 Simulations

37 Cost Ratio k=5

38 Cost Ratio k=7

39 Faults k=5

40 Faults k=7

41 Average Cache Usage k=5

42 Average Cache Usage k=7

43 Conclusions Introduced Minimum Cache Usage problem Cost-sensitive family of online algorithms 2 ≤ CR(α) ≤ k 2-competitive for sequences with high locality Polynomial time optimal offline algorithm Algorithms highly competitive in practice Future Work: Deeper lower bound analysis Other online algorithms Applications, e.g., shared cache cooperative strategy Thank you


Download ppt "Minimizing Cache Usage in Paging Alejandro Salinger University of Waterloo Joint work with Alex López-Ortiz."

Similar presentations


Ads by Google