1
$\begingroup$

The question is: We need to design a cache with cache size of 128K bytes, block (line) size of 8 words, and word size of 4 bytes. Consider a computer with 64-bit physical address. The cache is addressed by physical address

I need clarification on this: if we have 128k bytes and each block equals 32 bytes (8*4), do we have: 1.($128$ x $2^{10}$)/$32$ or 2. $128k/32$. The problem is that the first gives 4096 blocks and the second gives 4000 blocks. Which is the correct one?

$\endgroup$
1
$\begingroup$

The common usage is for KB, MB, GB, TB, and so on to denote powers of 2 rather than powers of 10. There are ways to denote powers of 10, but they are infrequently used. See for example the Wikipedia page on kibibyte.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.