Skip to content
Related Articles

Related Articles

Improve Article

GATE | Gate IT 2008 | Question 78

  • Difficulty Level : Medium
  • Last Updated : 19 Nov, 2018

Consider a computer with a 4-ways set-associative mapped cache of the following character­istics: a total of 1 MB of main memory, a word size of 1 byte, a block size of 128 words and a cache size of 8 KB.

While accessing the memory location 0C795H by the CPU, the contents of the TAG field of the corresponding cache line is
(A) 000011000
(B) 110001111
(C) 00011000
(D) 110010101

Answer: (A)


TAG will take 9 bits
SET will need 4 bits and
WORD will need 7 bits of the cache memory location
Thus, using the above conclusion as derived in previous question.
The memory location 0C795H can be written as 0000 1100 0111 1001 0101
Thus TAG= 9 bits = 0000 1100 0
SET =4 bits =111 1
WORD = 7 bits =001 0101
Therefore, the matching option is option A.


This solution is contributed by Namita Singh .

Quiz of this Question

Attention reader! Don’t stop learning now.  Practice GATE exam well before the actual exam with the subject-wise and overall quizzes available in GATE Test Series Course.

Learn all GATE CS concepts with Free Live Classes on our youtube channel.

My Personal Notes arrow_drop_up
Recommended Articles
Page :