From my computer organization lecture power point:
Multiword Block Considerations
…
Write misses (D$)
Can’t use write tag, one word of data from the new
block, and three words allocate or will end up with a “garbled” block
in the cache (e.g., for 4 word blocks, a new if data from the old
block), so must fetch the block from memory first and pay the stall
time
I don’t understand still why not? I can still set a dirty bit and write all words to lower level when data is evicted no problems? How will it garbled things?
You can use write allocate when the cache block contains multiple words. The lecture is just saying that you must read all of the words in the cache line from memory into the cache block when doing a write allocate, and after reading the words you will then write the data from the CPU into the cache block. This means that the pipeline is stalled for the time it takes to read the data from memory in the case of a cache miss on a cacheable write.
This is potentially slower than the case of a cache without write allocation or a write through cache. In those two cases, the write data is stored in a pending write buffer to be written to memory and the pipeline is not stalled waiting for a memory access to complete.