Data:
Main memory size (MM) = 232 B (32 bit address)
Cache Memory Size (CS) = 2 KB = 211 B
Block Size (BO) = 64 B = 26
Tag = 22 bits
Set Associative Mapped Cache:
let 2x - way set associative mapping
\(number~of~lines=\frac{{{2}^{11}}}{{{2}^{6}}}={{2}^{5}}\)
\(number~of~sets=\frac{{{2}^{5}}}{2^x}={{2}^{5-x}}\)
Formula: To find number of bits in tag in set associative mapping
MM = tag + set + BO
32 = 22 + 5 - x + 6
∴ x = 1
Therefore it is 21 - way set associative mapping
The associativity of the cache is 2.