retagged by
705 views
1 votes
1 votes
A system is having $4$ way set associative cache of $256$ KB. The cache line size is $8$ words and each word has $32$ bits. Suppose memory addresses are $64$ bits long. Then number of bits required for the index field of the cache memory is _______
retagged by

2 Answers

Best answer
1 votes
1 votes

Cache size is 256 KB .

4 way set associative cache means number of blocks per set is 4 .

Cache line size is 8 words( means each block size is 8 words ) and each word has 32 bits = 4 Bytes ,  

so total Block size is 8 * 4 = 32 Bytes 

32 = 2so 5 bits require for block offset .

There are 4 blocks /set and each block size is 32 Bytes .

It is 4 way set associative cache , so number of sets are ( 256 KB/ 4 * 32 B )

= (28 * 210 / 22 * 25 ) =218/27

= 211

Hence 11 bits require to represent the index field .

selected by
0 votes
0 votes
if index offset is set offset in set associativity then answer is 11 bits.
edited by
Answer:

Related questions

427
views
2 answers
0 votes
Bikram asked May 27, 2017
427 views
Consider a memory hierarchy system consisting of two levels. The access time of level $1$ is $2$ ns. The miss penalty (The time to get data from level $2$, in ... $1$ is ___________ $\%$
635
views
2 answers
2 votes
Bikram asked May 27, 2017
635 views
Suppose there are $500$ memory references in which $50$ misses in the $1$st level cache and $20$ misses in the $2$nd level cache . Let ... memory reference/instruction , average number of stall cycles per instruction will be __________
595
views
2 answers
0 votes
Bikram asked May 27, 2017
595 views
Consider a two level memory hierarchy having only one level cache and main memory. Cache and Main memory access times are $20$ ns and $120$ ns/word respectively. ... is referenced $40 \%$ of the times, then average access time is _______ ns
352
views
1 answers
1 votes
Bikram asked May 27, 2017
352 views
Suppose that a direct-mapped cache has $2^{10}$ cache lines, with $2^4$ bytes of data per cache line. If the cache is used to store blocks for a ... bytes of space will be required for storing the tags is ________ (put the integer value)