CS 523 Advanced Computer Architecture: Introduction To Cache Coherence Protocols
CS 523 Advanced Computer Architecture: Introduction To Cache Coherence Protocols
Lecture 27
Introduction to Cache Coherence Protocols
John Jose
Assistant Professor
Department of Computer Science & Engineering
Indian Institute of Technology Guwahati, Assam.
Writing in the cache
P P P
P1 P2 P3 P4
A A
Mem.
Mem. A
Two choices:
Write-update: Broadcast the new value of A on the bus
by P2; value of A snooped by cache of P3. Memory is
also updated.
Write-invalidate: Broadcast an invalidation message with
the address of A; the address snooped by cache of P3
which invalidates its copy of A: The copy in memory is not
up-to-date any longer
If instead of P2 requesting to write A, we had a write miss in
P4 for A, the same two choices of protocol apply.
Write-invalidate
x x’ x
x x x’ I x’ I
P1 P2 P3 P1 P2 P3 P1 P2 P3
x x’ x
x x x’ x’ x’ x’
P1 P2 P3 P1 P2 P3 P1 P2 P3
Read
Miss(sh) Read
Invalid Mem Read Shared Hit
Read Invalidate
RWITM Mem Read
Miss(ex) Write
Write Hit
Miss
Read Read
Modified Exclusive Hit
Hit Write
Hit
Write = bus transaction
Hit
MESI – remotely initiated accesses
Mem Read
Invalidate
Invalid Shared
Mem Read
RWITM Mem Read RWITM
Modified Exclusive
= copy back
[email protected]