Question: Please provide the answer as well as how to solve this problem: Given the following benchmark code and assuming a 1 K bytes two -

Please provide the answer as well as how to solve this problem:
Given the following benchmark code and assuming a 1 K bytes two-way set associative data cache with 32 bytes blocks, compute the number of misses that will occur when the code is executed. Assume the loop index variable resides in a processor register, the cache is initially empty and arrays A,B, and C reside consecutively in memory and have been initialized. Hint: integer variables occupy 4 bytes, variables are fetched from left to right in the right side of an expression and a FIFO replacement algorithm is used when necessary.
int A[128], C[128], B[128]
for (i =1; i 128; i ++)
{ A[i]= C[i]+ B[i]+ A[i-1]* C[i]}
Please provide the answer as well as how to solve

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!