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

1. A generic computer has a cache with a 50nsec access time and main memory with

ID: 3882506 • Letter: 1

Question

1. A generic computer has a cache with a 50nsec access time and main memory with 200nsec access time. The CPU makes 5000 memory accesses, of these 450 were cache misses.

a. Calculate the actual number of hits and the average hit rate h

b. Calculate the average access time

2. Consider these proposed nod4 memory configurations. First determine if each configuration is possible, if so draw the corresponding memory map, indicating the first and last address of each region where a device appears. Also explain why each might be or not be recommended for use with nod4.

a. 192 bytes of ROM starting at address $00, followed by 8 bytes set aside for peripherals, as well as 32 bytes of RAM ending at the highest system address.

b. 192 bytes of ROM starting at address $00 and 64 bytes of RAM ending at the highest system

c. 8 addresses set aside for peripheral devices starting at address $00, immediately followed by 160 bytes of ROM and then RAM continuing to the highest system address.

Explanation / Answer

Solution:

1.

a)

So when the operation is a cache hit it takes 50 ns to access the data but when it is a miss then the data will be accessed from the main memory which will take 200 ns of time to access the data.

Cache hit time= 50 ns

Caches miss time= 200 ns

Number of memory accesses= 5000

Number of cache misses= 450

which means number of cache hits= 5000-450= 4550

hit rate= (4550/5000)*100= 91%

This means that 91% of thee operations are a cache hit.

b)

Average access time= hit rate*(time taken to access the cache memory)+ (1-hit rate)(time taken to access the cache memory+ time taken to access the data from main memory)

= 0.91*(50)+ 0.09*(50+200)= 68 ns

Average access time= 68 ns.

I hope this helps if you find any problem. Please comment below. Don't forget to give a thumbs up if you liked it. :)