• recategorized by
905 views
0 0 votes

Consider a $256k$   $4$- way set associative cache with block size $64$ Bytes. Main memory is $2Gb.$ The number of bits used for tag,set and word will be respectively?

  1. $10,15,6$
  2. $9,16,6$
  3. $8,17,6$
  4. $7,18,6$


I think answer is $15,10,6 $ $\text{(tag,set,word)}$

2 Answers

0 0 votes
See pointing in the beginning only solution is as per 2Gb main memory not 2GB .

2Gb=2^31 bits ie 2^28B

So 28 bit physical address.

Given block size = 64 Bytes ie 2^6 =6 bit for offset inside the block.  

256K cache  ie 2^8.2^10 =2^18 B

Now each block is 64B .  

So no of lines =2^(18-6)=2^12

4 way set associative so no of sets =2^(12-2) =2^10  so 10 bits for set .

 

Total 28 b physical address so for tag 28-10-6=12 b .

Therefore ans should be 12,10,6.

 

 
–1 –1 vote
ans is 9,16,6

16 bcoz ,num of block=256k

and setoffset =s=n/k

                          =256k/4=64k

                            =16bit required
Position:
Show:

Related questions

0 0 votes
1 1 answer
649
649 views
Pankaj Joshi asked Jan 13, 2017
649 views
my question is even in case of a miss the cache will still be accessed and then main memory, right? please explain this when to consider higher memory level access time a...
4 4 votes
3 3 answers
1.3k
1.3k views
just_bhavana asked Oct 10, 2017
1,319 views
In a $2$ level control unit design there exists $1K$ word micro control memory and a $32$ word nano control memory. If it is desired to provide $24$ control signals, what...
1 1 vote
1 answers 1 answer
2.2k
2.2k views
Hradesh patel asked Nov 26, 2016
2,219 views
The false statement about dynamic RAM is(A) Power consumption of dynamic RAM is more than static RAM(B) Gate density of dynamic RAM is higher than that of static RAMs(C) ...
1 1 vote
1 1 answer
692
692 views
jatin khachane 1 asked Jan 26, 2019
692 views
Consider the unpipelined machine with $10$ nanoseconds clock cycles. It uses four cycles for ALU operations and branch whereas 5 cycles for memory operation. Assume that ...