in CO and Architecture
1,801 views
4 votes
4 votes

If main memory  $=128 \ KB$ and cache memory is of $2KB$ with $16B$ lines .and uses associative mapping .
What would be the # of bits used for Tag for each block?

in CO and Architecture
1.8k views

4 Comments

.......................................................

0
0
clearly none of the options are matching !
1
1
Yes!!
0
0

1 Answer

0 votes
0 votes
the correct answer is option a

main memory size = 128 kb = 2 ^7 * 2^10  = 2^17 bytes

cache memory size = 2 kb = 2^10 bytes

no of lines = 16 bytes

cache offset = cache memory size \ no of lines = 2^10\2^4 = 2^6 bytes

number of bits in cache offset = 6 bits

as total main memory size = 17 bits

tag bits = 17 - 6 = 11 bits

Related questions