These examples use the Part 9 LLC model: the LLC sits at H, a PutM writes the LLC line, and memory is written only when the LLC evicts a dirty line. An inclusive LLC holds every line any private cache holds. An exclusive LLC holds a line only while no private cache does. A non-inclusive, non-exclusive (NINE) LLC follows neither rule. The three differ in four events:
Policy | Fill from memory goes to | Private eviction goes to | LLC hit does | LLC eviction does |
|---|---|---|---|---|
Inclusive | The LLC and the private cache: the LLC allocates on every fill | Dirty PutM writes the LLC copy, which is always present. Clean PutS or PutE is dataless and the LLC copy stays | Supplies the data, keeps the LLC copy and sets the requester's presence bit | Back-invalidates every private copy, then writes the line to memory if dirty |
Exclusive | The private cache only | The LLC, clean evictions too: the LLC is a victim cache. This needs a data-carrying clean eviction, unlike the course's dataless PutS and PutE | Moves the line up to the private cache and deallocates it from the LLC | Writes the line to memory if dirty. No private copy exists to invalidate |
NINE | The LLC and the private cache, as in inclusive | Dirty PutM writes the LLC line, allocating it if absent. Clean PutS or PutE is dataless | Supplies the data and keeps the LLC copy: filling the private cache does not deallocate it | Writes the line to memory if dirty. Private copies are not invalidated |
"Exclusive" here is a relation between two storage levels, not the MESI E state, and not a ban on two private S copies. The course's clean evictions (PutS and PutE) carry no data, which is fine for inclusive and NINE because memory or the LLC already has the clean value. An exclusive LLC has no copy of a privately held line, so a clean eviction must carry the data down or the line leaves the cache hierarchy.
From X = 0 uncached, C0's GetM misses everywhere, memory supplies 0 and C0 stores 1. Later C0 evicts X with PutM. Each row is an independent case.
Case | C0 state / value | C1 state / value | H directory | LLC: tag / value / dirty | Memory | Newest data |
|---|---|---|---|---|---|---|
Inclusive, after C0's fill and store | M / 1 | I / - | exclusive(C0) (presence bits in LLC tag) | X / 0 / clean | 0 | C0: 1 |
Inclusive, after C0's PutM | I / - | I / - | U (presence bits in LLC tag) | X / 1 / dirty | 0 | LLC: 1 |
Exclusive, after C0's fill and store | M / 1 | I / - | exclusive(C0) (snoop filter) | no tag | 0 | C0: 1 |
Exclusive, after C0's PutM | I / - | I / - | U (snoop filter) | X / 1 / dirty | 0 | LLC: 1 |
NINE, after C0's fill and store | M / 1 | I / - | exclusive(C0) (snoop filter) | X / 0 / clean | 0 | C0: 1 |
NINE, the LLC then evicts its clean X | M / 1 | I / - | exclusive(C0) (snoop filter) | no tag | 0 | C0: 1 |
The inclusive and NINE LLCs hold a stale 0 while C0 holds M / 1, so an LLC value is never the answer while a private exclusive holder exists. The exclusive LLC has no tag at all, so the separate snoop filter is the only record of C0. In the last row the NINE LLC dropped a clean line without touching C0, which an inclusive LLC could not do. Had C0 evicted E / 0 instead, the exclusive LLC would still need X / 0: that is the data-carrying clean eviction.
Yes, and inclusion requires it; the LLC copy may become stale after a silent E-to-M store.