Imagine a hypothetical cache that uses the high-order s bits of an address as the set index.

Question:

Imagine a hypothetical cache that uses the high-order s bits of an address as the set index. For such a cache, contiguous chunks of memory blocks are mapped to the same cache set.

A. How many blocks are in each of these contiguous array chunks? 

B. Consider the following code that runs on a system with a cache of the form (S, E, B, m) = (512, 1, 32, 32):

int array [4096]; for (i = 0; i < 4096; i++) sum += array[i];

What is the maximum number of array blocks that are stored in the cache at any point in time?

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question

Computer Systems A Programmers Perspective

ISBN: 9781292101767

3rd Global Edition

Authors: Randal E. Bryant, David R. O'Hallaron

Question Posted: