Write Buffer

A write buffer is a type of data buffer.

In a CPU cache, a write buffer can be used to hold data being written back from the cache to main memory. This is a variation of write-through caching called buffered write-through.

Use of a write buffer in this manner frees the cache to service read requests while the write is taking place. It is especially useful for very slow main memory in that subsequent reads are able to proceed without waiting for long main memory latency. When the write buffer is full (i.e. all buffer entries are occupied), subsequent writes still have to wait until some slots are freed. To further mitigate this stall, one optimization called write buffer merge is proposed. Write buffer merge combines writes that have consecutive destination addresses into one buffer entry. Otherwise, they would occupy separate entries which increases the chance of pipeline stall.

Sometimes the terminology victim buffer is also called write buffer. Victim buffer is a buffer that stores dirty evicted lines in write-back caches (note that write-through caches don't write the evicted cache lines back) before they get written back to the higher level memory. Besides reducing pipeline stall by not waiting for dirty lines to write back as the original write buffer does, victim buffer also serves as a temporary backup storage when subsequent cache accesses exhibit locality, requesting those recently evicted lines, which are still in the victim buffer.

Read more about Write Buffer:  See Also

Famous quotes containing the word write:

    Wherever there are walls I shall inscribe this eternal accusation against Christianity upon them—I can write in letters which make even the blind see ... I call Christianity the one great curse, the one great intrinsic depravity, the one great instinct for revenge for which no expedient is sufficiently poisonous, secret, subterranean, petty—I call it the one immortal blemish of mankind....
    Friedrich Nietzsche (1844–1900)