Use app×
Join Bloom Tuition
One on One Online Tuition
JEE MAIN 2025 Foundation Course
NEET 2025 Foundation Course
CLASS 12 FOUNDATION COURSE
CLASS 10 FOUNDATION COURSE
CLASS 9 FOUNDATION COURSE
CLASS 8 FOUNDATION COURSE
0 votes
784 views
in Computer by (85.4k points)
closed by
Consider a machine with a byte addressable main memory of 232 bytes divided into blocks of size 32 bytes. Assume that a direct mapped cache having 512 cache lines is used with this machine. The size of the tag field in bits is ______.

1 Answer

0 votes
by (88.5k points)
selected by
 
Best answer

Data:

Memory size = 232 bytes

Total address space = 32 bit

Block size = 32 bytes = 25 byte

Cache lines = 512 = 29

Formula:

Tag

No. of line

Block offset

(x bits)

(9 bits)

(5 bit)


In bits:

Total address space = tag + no. of lines + block offset

For direct mapped cache:

Calculation:

32 = x + 9 + 5

∴ x = 18

The size of tag field in bits = 18

Welcome to Sarthaks eConnect: A unique platform where students can interact with teachers/experts/students to get solutions to their queries. Students (upto class 10+2) preparing for All Government Exams, CBSE Board Exam, ICSE Board Exam, State Board Exam, JEE (Mains+Advance) and NEET can ask questions from any subject and get quick answers by subject teachers/ experts/mentors/students.

Categories

...