7.4Adding the Owned State (MOSI)

book pp. 126–133 · ~2 min read

  • MOSI
  • ownership retention
  • OM^A upgrade
  • MorO
  • PutM consolidation

7.4.1 Motivation

The Owned state targets one specific, important situation: a cache holds a block in M (or E) and another core issues a GetS. In MSI and MESI, the owner must downgrade to S and send the data twice — to the requestor and to the memory controller, because ownership returns to the LLC/memory, which then needs an up-to-date copy. Adding O buys two things:

  1. No extra data message to update the LLC/memory on that downgrade;
  2. No potentially useless LLC write — if the block is written again before ever being evicted, the update was wasted anyway.

(Historically there was a third: cache-to-cache responses beat far-slower off-chip memory. With an inclusive on-chip LLC, that advantage has shrunk.)

7.4.2–7.4.3 The protocol

The high-level change is one arc: M —Other-GetS→ O, with the cache retaining ownership. From O — valid, potentially dirty, read-only, owner — the cache answers others’ GetS requests (staying O) and hands the block to GetM requestors. The detailed protocol adds two transient states: OM^A (upgrading O→M — note no D: the owner already has the data, and waits only for its GetM’s serialization) and OI^A (evicting O — via the consolidated PutM transaction; there is no separate PutO, purely for specification conciseness):

Figure 7.6 (recreated): MOSI stable states — the M→O arc is the point

Own-GetSOwn-GetMOwn-GetMOther-GetM · Repl (silent)Other-GetS (keep ownership!)Own-GetM (no data needed)Other-GetM · Own-PutMOther-GetM · Own-PutMI — Invalid: No usable copy.IS — Shared: Read-only, not owned; silent eviction; invalidates on Other-GetM.SO — Owned: Valid, potentially DIRTY, read-only, and THE OWNER: responds to others' GetS (keeping O) and GetM (→I). Other caches may hold S copies. Memory's copy is potentially stale — which is why O may not evict silently.OM — Modified: Read-write owner. THE MOSI DIFFERENCE: an Other-GetS moves M to O — ownership stays here, memory is NOT updated, and only ONE data message is sent.M

Solid = stable state · dashed = transient · click a state or an arrow.

Table 7.14 (recreated): MOSI snooping — cache controller

Core eventsBus: own transactionBus: other coresBus: own transaction
StateLoadStoreReplacementOwn-GetSOwn-GetMOwn-PutMOther-GetSOther-GetMOther-PutMOwn Data

Cell format: action / next state (next state omitted when unchanged) · blank = event ignored · shaded = impossible. Click any cell or state chip.

Click a transition cell for its plain-English explanation, or a state chip for its invariants.

Cells worth clicking: M × Other-GetS (one message, keep ownership), O × store (the data-less upgrade begins), and OMA × Other-GetM — the subtle one: an upgrading owner that loses the race must respond with data (it’s still the owner!) and restart from IM^AD, where data will be needed.

The memory controller simplifies rather than grows: it merges M and O into MorO, because memory has no reason to distinguish them — either way a cache owns the block and memory stays quiet. Watch what happens on a GetS in MorO: nothing — no transient state, no data reclaim, unlike MSI’s M state:

Figure 7.7 (recreated): MOSI memory controller stable states

GetMPutM (with data)IorS — Memory is owner: All caches in I or S: memory answers GetS and GetM.IorSMorO — Some cache owns the block (M or O): The merged state MOSI adds: memory need not distinguish M from O — either way a cache owns the block and responds, and memory stays quiet. Note memory does NOT change state on a GetS here (unlike MSI's M → IorS^D): the owner keeps ownership.MorO

Solid = stable state · dashed = transient · click a state or an arrow.

Table 7.15 (recreated): MOSI snooping — memory controller

Bus events
StateGetSGetMPutMData from ownerNoData

Cell format: action / next state (next state omitted when unchanged) · blank = event ignored · shaded = impossible. Click any cell or state chip.

Click a transition cell for its plain-English explanation, or a state chip for its invariants.

7.4.4 Running example

The MOSI run tracks the MSI run exactly until C1’s second GetS reaches the bus. In MSI, C2 (the M owner) answered it with data to C1 and to the LLC/memory, downgrading to S. In MOSI, C2 answers C1 alone and moves to O — retaining ownership, leaving memory untouched (it sits happily in MorO), and deferring any memory update until C2 actually evicts the block (if ever). One data message saved now, one possibly-pointless LLC write saved later.

Check yourself

1.What exactly does the Owned state buy, compared with MSI/MESI?

2.In MOSI, a cache in M observes an Other-GetS. Compare the action with MSI's.

3.Why can the memory controller merge M and O into a single MorO state?

4.A cache in OM^A (upgrading O→M) sees an Other-GetM ordered before its own GetM. What must it do?

5.Why must an O block's eviction use a transaction (the consolidated PutM), when S evictions are silent?

5 questions