Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Two otherwise identical memory systems, MS1 and MS2, have slightly different cache configurations. Both systems have an 8MB memory that is byte-addressable, and a unified
Two otherwise identical memory systems, MS1 and MS2, have slightly different cache configurations. Both systems have an 8MB memory that is byte-addressable, and a unified single-level cache that is divided into 8 lines. However, the cache in the first memory system (MS1) is: direct-mapped, 64-bit lines, no-write-allocate, write-through, while the cache in the second memory system (MS2) is: 4-way set- associative, 64-bit lines, LRU, write-allocate, write-back. a) Show the address format for each of the two memory systems MS1 and MS2. b) What is the size of the cache used in each of the two memory systems MS1 and MS2? c) Suppose the two memory systems MS1 and MS2 are evaluated using a simple benchmark program (MEMC2020) that contains five 16-bit machine instructions forming a loop that gets executed millions of times. The first instruction in the loop is stored in the main memory starting at location 000FF0 (hexadecimal). Only two of the five loop instructions refer to data in main memory: the third instruction writes a byte to location 001200 (hexadecimal), while the fourth instruction reads a byte from location 001204 (hexadecimal). Fill up the following table according to the read and write operations that instructions make during the first two iterations of the loop. Assume, in both memory systems, the cache is initially empty. 2nd 1st 3rd 4th 5th 1 st 2nd 3rd 4th 5th F F E F E F F F F E F E F R R 000FFO Iteration Instruction 1st 2nd Eetch/Execute (F/E) F Read/Write (R/W) R Address (Hex) 000FF0000FF2 Line (Hex) Tag (Hex) MS1 Hit/Miss (H/M) Allocate line? (Y/N) Set (Hex) Tag (Hex) Hit/Miss (H/M) MS2 Allocate line? (Y/N) Write back? (Y/N) Free Lines (Set 0) Free Lines (Set 1) d) What would be the hit ratio for MS1 and MS2, when executing the benchmarking program, MEMC2020? Hint, consider that MEMC2020 is the only program running in the systems and look for the Hit/Miss pattern after reaching steady state. e) What is the minimum number of lines per set for MS2 that guarantee the same hit ratio when running the benchmarking program, MEMC2020
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started