GATE Exam  >  GATE Questions  >  A direct mapped cache memory of 1 MB has a bl... Start Learning for Free
A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.
    Correct answer is '13.5'. Can you explain this answer?
    Verified Answer
    A direct mapped cache memory of 1 MB has a block size of 256 bytes. Th...
    Word size = 64 bit = 8B
    Block size = 256B
    ∴ 
    Tavg = (0.94 × 3) + (1 – 0.94) [3 + 20 + (31 × 5)]
    = 13.5 ns
    View all questions of this test
    Most Upvoted Answer
    A direct mapped cache memory of 1 MB has a block size of 256 bytes. Th...
    < b="" /> Cache Organization: < />

    - Cache size: 1 MB
    - Block size: 256 bytes
    - Word size: 64 bits

    < b="" /> Number of Blocks and Words: < />

    To find the number of blocks in the cache, we need to divide the cache size by the block size:

    Number of blocks = Cache size / Block size
    = 1 MB / 256 bytes
    = 2^20 bytes / 2^8 bytes
    = 2^12 blocks

    Since each block contains multiple words, we also need to find the number of words in each block:

    Number of words = Block size / Word size
    = 256 bytes / 8 bytes
    = 2^8 words

    < b="" /> Access Time and Hit Rate: < />

    - Cache access time: 3 ns
    - Hit rate: 94%

    < b="" /> Average Memory Access Time Calculation: < />

    The average memory access time can be calculated using the formula:

    Average Memory Access Time = Hit time + Miss rate * Miss penalty

    < b="" /> Hit Time: < />

    The hit time is the time taken to access the cache when a hit occurs:

    Hit time = Cache access time
    = 3 ns

    < b="" /> Miss Rate: < />

    The miss rate is the percentage of cache accesses that result in a cache miss:

    Miss rate = 1 - Hit rate
    = 1 - 0.94
    = 0.06

    < b="" /> Miss Penalty: < />

    The miss penalty is the time taken to bring a block from the main memory to the cache when a miss occurs. In this case, the miss penalty consists of two parts: the time to bring the first word of the block and the time to bring each subsequent word.

    The time to bring the first word of the block is given as 20 ns, while each subsequent word takes 5 ns. Since there are 2^8 words in each block, the total time to bring the entire block can be calculated as:

    Miss penalty = Time for first word + (Number of words - 1) * Time for subsequent word
    = 20 ns + (2^8 - 1) * 5 ns
    = 20 ns + 255 * 5 ns
    = 20 ns + 1275 ns
    = 1295 ns

    < b="" /> Average Memory Access Time: < />

    Using the formula mentioned earlier:

    Average Memory Access Time = Hit time + Miss rate * Miss penalty
    = 3 ns + 0.06 * 1295 ns
    = 3 ns + 77.7 ns
    = 80.7 ns

    Rounding off to 1 decimal place, the average memory access time is 80.7 ns, which is not the correct answer.

    < b="" /> Correct Answer: < />

    The correct answer is given as 13.5 ns. However, the calculation above resulted in 80.7 ns. It seems that there might be a mistake in the given answer or the question itself. Please double-check the provided answer or question to ensure accuracy.
    Explore Courses for GATE exam

    Similar GATE Doubts

    A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.Correct answer is '13.5'. Can you explain this answer?
    Question Description
    A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.Correct answer is '13.5'. Can you explain this answer? for GATE 2025 is part of GATE preparation. The Question and answers have been prepared according to the GATE exam syllabus. Information about A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.Correct answer is '13.5'. Can you explain this answer? covers all topics & solutions for GATE 2025 Exam. Find important definitions, questions, meanings, examples, exercises and tests below for A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.Correct answer is '13.5'. Can you explain this answer?.
    Solutions for A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.Correct answer is '13.5'. Can you explain this answer? in English & in Hindi are available as part of our courses for GATE. Download more important topics, notes, lectures and mock test series for GATE Exam by signing up for free.
    Here you can find the meaning of A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.Correct answer is '13.5'. Can you explain this answer? defined & explained in the simplest way possible. Besides giving the explanation of A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.Correct answer is '13.5'. Can you explain this answer?, a detailed solution for A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.Correct answer is '13.5'. Can you explain this answer? has been provided alongside types of A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.Correct answer is '13.5'. Can you explain this answer? theory, EduRev gives you an ample number of questions to practice A direct mapped cache memory of 1 MB has a block size of 256 bytes. The cache has an access time of 3 ns and a hit rate of 94%. During a cache miss, it takes 20 ns to bring the first word of a block from the main memory, while each subsequent word takes 5 ns. The word size is 64 bits. The average memory access time in ns (round off to 1 decimal place) is ________.Correct answer is '13.5'. Can you explain this answer? tests, examples and also practice GATE tests.
    Explore Courses for GATE exam
    Signup for Free!
    Signup to see your scores go up within 7 days! Learn & Practice with 1000+ FREE Notes, Videos & Tests.
    10M+ students study on EduRev