


Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Compilers Design Solutions abcds
Typology: Assignments
1 / 4
This page cannot be seen from the preview
Don't miss anything!



t + s + b = 32 b = 6 because block size is 64B
Here B(block size) is 64B and C(cache size) is 256KB and we use A as an acronym for associativity. Total number of lines are CB , and s = log 2 ( (^) BC×A ).
Here A is 1
(a) 212
(b) b = 6
(c) s = 12
(d) t = 14
Here A is 4
(a) 212
(b) b = 6
(c) s = 10
(d) t = 16
Here A is
(a) 212
(b) b = 6
(c) s = 0
(d) t = 26
Total Size of Cache = 256KB Total Size of A = 128KB
For it = 0 the number of misses will be 32 ×^2 10 8 = 2
(^12) and for the rest of the iterations all the data will
be in the cache. Total Number of Misses = 2^12
For it = 0 the number of misses will be 32 ×^2 10 4 × 2 = 2
(^12) and for the rest of the iterations all the data will
be in the cache. Total Number of Misses = 2^12
For it = 0 the number of misses will be 32 ×^2 10 16 × 1 = 2
(^11) and for the rest of the iterations all the data will
be in the cache. Total Number of Misses = 2^11
For it = 0 the number of misses will be 32 ×^2 10 32 × 1 = 2 (^10) and for the rest of the iterations all the data will
be in the cache. Total Number of Misses = 2^10
For it = 0 the number of misses will be 32 ×^2
10 211 × 1 = 2
(^4) and for the rest of the iterations all the data will
be in the cache. Total Number of Misses = 2^4
For it = 0 the number of misses will be 32 ×^2 10 213 × 1 = 2 (^2) and for the rest of the iterations all the data will
be in the cache. Total Number of Misses = 2^2
For it = 0 the number of misses will be 32 ×^2 10 215 × 1 = 2
(^0) and for the rest of the iterations all the data will
be in the cache. Total Number of Misses = 2^0
Total Size of Cache = 16M B Block Size = 32B ⇒ B = 32 Total Size of Arrays = 4096 × 4096 W ords ⇒ N = 4096 × 8
k N N j N NB i N 1