EEE230_test4

EEE230_test4 - -A cache hit means that the block is located...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
-A cache hit means that the block is located in the cache. – On a read miss the block from the main memory is written to cache . – The “dirty bit” is used to determine if the block has been written . – Why have a memory hierarchy? to speed instruction execution. --If block is dirty need to write-back to memory . *A memory address has 32 bits. A cache is a 2-way set associative cache holding 1024 blocks where each block is 1 word (4bytes). 1. A 2-way set-associate cache means that each set has two words . 2. How many sets are in the cache? 512 3. What are address bits 1. .0 used for? Displacement into the block . 4. How many bits are needed to identify the set? 9 5. How many bits are needed for the tag? 21 * A memory address has 32 bits. Bits are identified as 31 down to 0. A cache holds 1024 blocks A block is a 2 words A word holds 4 bytes The cache is direct-mapped 1. Which bits in the address determine the byte displacement within a word? 1…0 2. Which bits in the address determine the word displacement within a block? 2 3. Which bits in the address determine the block number in the cache? 12…3 4. How many bits are needed for the data in the cache entry? 64 5. How many bits are stored for the tag? 19 1. A cache holds 16 words. For a 32-bit address, give the size of the tag, number of sets, and size of each set. a.
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 2

EEE230_test4 - -A cache hit means that the block is located...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online