Previous | Next --- Slide 4 of 56
Back to Lecture Thumbnails
gogogo

I'm not sure what "dirty line is written out to memory" means. Shouldn't a dirty line indicate that the cache value at that area is invalidated?

Split_Personality_Computer

Does dirty just mean a write to main memory is required? So is this slide just saying if you want to write to memory, it'll put that new value in the cache (writing out the old one if needed) and then update the main memory value later?

petrichor

The dirty bit indicates that that cache line has been written to, so that when it is evicted, this new value must be written to memory. Notice how this can greatly reduce the memory latency since if you're hitting a cache line, then for reads you're fine and if you only every read a value it can be evicted without ever going back to memory and if it is written to, you can continue to write to it without having to go back to memory, then it will just sit there until it is evicted at which point it's current value will be reflected in memory. Notice however that this increases the cost of cache misses, making it very important that cache misses are minimized.