Explore BrainMass
Share

Explore BrainMass

    Set Associative Cache

    This content was COPIED from BrainMass.com - View the original, and get the already-completed solution here!

    Please help with the following computer science problems. Provide step by step calculations.

    Suppose that a computer using a set-associative cache has 2^16 words of main memory and a cache of 32 blocks, where each cache block contains 8 words.

    A. If this cache is a 2-way set-associative, what is the format of a memory address as seen by the cache? That is, what are the sizes of the tag, set and word fields?

    B. If this cache is a 4-way set-associative, what is the format of a memory address as seen by the cache?

    © BrainMass Inc. brainmass.com October 10, 2019, 12:46 am ad1c9bdddf
    https://brainmass.com/computer-science/memory/set-associative-cache-306410

    Solution Preview

    Size of main memory = 2^16 words
    Size of cache block = 8 or 2^3 words
    Number of cache blocks (Nc) = 32 or 2^5

    Since nothing is given about the size of memory address, we infer it from size of main memory as 16 bits.

    A. If this cache is a 2-way set-associative, what is the format ...

    Solution Summary

    This solution briefly explains in about 185 words, how the size of different fields of a memory address format are determined. All calculations and formulas pertaining to the cache sets are provided.

    $2.19