Assume that a virtual memory is managed using a buffer pool. The buffer pool contains five buffersand each buffer stores one block of data. Memory accesses are bydiskblock ID. Assume thefollowing series of memory accesses takes place: 5 2 5 12 3 6 5 9 3 2 4 1 5 9 8 15 3 7 2 5 9 10 4 6 8 5 For each of the following buffer pool replacement strategies, show the contents of the buffer poolat the end of the series, and indicate how many times a block was found in the buffer pool (insteadof being readinto memory). Assume that the buffer pool is initially empty a.First in, first out. b.Least frequently used (with counts kept only for blocks currently in memory, counts for a pageare lost when that page is removed, and the oldest item with smallestcount is removed whenthere is a tie). c.Least frequently used (with counts kept for all blocks, and the oldest item with the smallestcount is removed when there is a tie). d.Least recently used.

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

Assume that a virtual memory is managed using a buffer pool. The buffer pool contains five buffersand each buffer stores one block of data. Memory accesses are bydiskblock ID. Assume thefollowing series of memory accesses takes place:

5 2 5 12 3 6 5 9 3 2 4 1 5 9 8 15 3 7 2 5 9 10 4 6 8 5

For each of the following buffer pool replacement strategies, show the contents of the buffer poolat the end of the series, and indicate how many times a block was found in the buffer pool (insteadof being readinto memory). Assume that the buffer pool is initially empty

a.First in, first out.

b.Least frequently used (with counts kept only for blocks currently in memory, counts for a pageare lost when that page is removed, and the oldest item with smallestcount is removed whenthere is a tie).

c.Least frequently used (with counts kept for all blocks, and the oldest item with the smallestcount is removed when there is a tie).

d.Least recently used.

LIFO
Least Recently Used
2
5
12
3
9.
3
2
4
1
9.
15
3
7
2
5
9.
10
4
6.
8
5
5
2
12
3
6.
5
9.
3
2
4
1
9.
8
15
3
7
10
4
8.
5
2
2
2
12
3
6.
6
9.
4
1
8
15
7
2
9.
10
2
12
3
6.
3
2
4
1
8
15
3
7
2
10
4
6
8
5
1
2
2
2
2
2
12
12
12
3
6.
9.
9.
4
8
15
3
7
2
5
9.
10
4
1
2
5
12
3
9
3
2
4
1
9.
8
15
3
7
2
5
9.
10
4
6.
8
2
12
12
12
12
3
3
3
6
4
8
15
7
9.
10
4
2
2
12
3
6
5
3
2
4
1
5
9
8
15
3
7
9
10
4
6.
3
3
6.
6.
9.
4
1
1
8
15
3
7
2
10
4
6.
8
3
12
3
6.
9.
2
4
1
8
15
3
7
2
10
4
4
6.
9.
9.
9.
4
1
8
15
3
7
2
9.
10
4
8.
4
2
2
12
12
6.
9
3
2
4
8
15
7
2
10
Least frequently used (with counts kept only for blocks currently in memory, counts for a page are lost when that page is removed, and the
oldest item with smallest count is removed when there is a tie).
12
3
6.
5
9.
3
4
1
8.
15
7
9
10
4
6.
8
5-
5-
5-
5-1 5-1 5-1
5-2| 5-2
1
1
2-
2-
2-0 2-0 | 2-0
2-0
2-0
12-
12-
12-
12-
12-
3
3-0| 3-0
3-0
6-0
4
6-0| 6-0
9-0
Least frequently used (with counts kept for allI blocks, and the oldest item with the smallest count is removed when there is a tie).
5
12
3
9.
3
2
1
8
15
3
7
2
10
4
6.
8
5-
5-
5-
5-1 5-1 5-1 5-2 | 5-2
1
1
2-
2-
2-0
2-0 2-0
2-0
2-0
2
12- 12- 12- 12-
12-
3
3-0| 3-0 3-0 6-0
4
6-0
6-0
9-0
a lco lunlu
5.
9.
5.
T.
9.
3.
Transcribed Image Text:LIFO Least Recently Used 2 5 12 3 9. 3 2 4 1 9. 15 3 7 2 5 9. 10 4 6. 8 5 5 2 12 3 6. 5 9. 3 2 4 1 9. 8 15 3 7 10 4 8. 5 2 2 2 12 3 6. 6 9. 4 1 8 15 7 2 9. 10 2 12 3 6. 3 2 4 1 8 15 3 7 2 10 4 6 8 5 1 2 2 2 2 2 12 12 12 3 6. 9. 9. 4 8 15 3 7 2 5 9. 10 4 1 2 5 12 3 9 3 2 4 1 9. 8 15 3 7 2 5 9. 10 4 6. 8 2 12 12 12 12 3 3 3 6 4 8 15 7 9. 10 4 2 2 12 3 6 5 3 2 4 1 5 9 8 15 3 7 9 10 4 6. 3 3 6. 6. 9. 4 1 1 8 15 3 7 2 10 4 6. 8 3 12 3 6. 9. 2 4 1 8 15 3 7 2 10 4 4 6. 9. 9. 9. 4 1 8 15 3 7 2 9. 10 4 8. 4 2 2 12 12 6. 9 3 2 4 8 15 7 2 10 Least frequently used (with counts kept only for blocks currently in memory, counts for a page are lost when that page is removed, and the oldest item with smallest count is removed when there is a tie). 12 3 6. 5 9. 3 4 1 8. 15 7 9 10 4 6. 8 5- 5- 5- 5-1 5-1 5-1 5-2| 5-2 1 1 2- 2- 2-0 2-0 | 2-0 2-0 2-0 12- 12- 12- 12- 12- 3 3-0| 3-0 3-0 6-0 4 6-0| 6-0 9-0 Least frequently used (with counts kept for allI blocks, and the oldest item with the smallest count is removed when there is a tie). 5 12 3 9. 3 2 1 8 15 3 7 2 10 4 6. 8 5- 5- 5- 5-1 5-1 5-1 5-2 | 5-2 1 1 2- 2- 2-0 2-0 2-0 2-0 2-0 2 12- 12- 12- 12- 12- 3 3-0| 3-0 3-0 6-0 4 6-0 6-0 9-0 a lco lunlu 5. 9. 5. T. 9. 3.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 2 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY