Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

This problem explores the problem of thrashing in different types of cache. Cons

ID: 658385 • Letter: T

Question

This problem explores the problem of thrashing in different types of cache. Consider a system of 12Kbytes of main memory partitioned into blocks of 1Kbytes each. The system has cache of size 4Kbytes. The main memory blocks are being accessed in the following order: 1, 3, 5, 1, 3, 5, 1, 3, 5, 1 (the numbers are in decimal). Assuming the cache is empty at the start. Show whether each memory block access is a hit or a miss. Then, compute the hit ratio for each of the following cases.

The system uses fully associative cache and first-in-first-out replacement policy;

Memory

Block

Maps to

Cache Block

Hit/Miss

Cache content after action

blk0

Blk1

blk2

blk3

1

3

5

1

3

5

1

3

5

1

Hit ratio:

Memory

Block

Maps to

Cache Block

Hit/Miss

Cache content after action

blk0

Blk1

blk2

blk3

1

3

5

1

3

5

1

3

5

1

Hit ratio:

Explanation / Answer

Memory

Block

Maps to

Cache Block

Hit/Miss

Cache content after action

blk0

Blk1

blk2

blk3

1

Miss

1

3

Miss

1

3

5

Miss

1

3

5

1

Hit

1

3

5

3

Hit

1

3

5

5

Hit

1

3

5

1

Hit

1

3

5

3

Hit

1

3

5

5

Hit

1

3

5

1

Hit

1

3

5

Hit ratio:

7/10=0.7

Memory

Block

Maps to

Cache Block

Hit/Miss

Cache content after action

blk0

Blk1

blk2

blk3

1

Miss

1

3

Miss

1

3

5

Miss

1

3

5

1

Hit

1

3

5

3

Hit

1

3

5

5

Hit

1

3

5

1

Hit

1

3

5

3

Hit

1

3

5

5

Hit

1

3

5

1

Hit

1

3

5

Hit ratio:

7/10=0.7

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote