A computer system has 4GB of main memory and a 32KB L1 cache with a block size of 64 bytes. What is the tag size in the cache?
Q1. A computer system has 4GB of main memory and a 32KB L1 cache with a block size of 64 bytes. What is the tag size in the cache?
Answer: 22 bits
Explanation: Total bits = 32 (for 4GB), cache size = 32KB, block size = 64B, so number of blocks = 32KB / 64B = 512, number of sets = 512 (fully associative), tag bits = 32 - log2(64) = 32 - 6 = 26, but since it's not fully.