@Write Miss Message by P to Directory Home Directory: block是 Modified态 Directory发送 Fetch- validate message给处理器Q的 Cache ( Remote cache拥有该块的最新值) 处理器Q的 cache直接发送数据应答消息给P Q的 cache将对应块的状态修改为 invalid P的 Icache(Loca)将接收到的块的状态信息修改为 modified Directory将对应于Q的 presence b复位,并将对应于P的 presence bit置位 Home Directory: block是 Shared or owned态 Directory根据 presence bi位给所有的共享者发送 Invalidate messages Directory接收 acknowledge消息并将对应的 presence bits复位 Directory发送数据回复信息给P,并将P对应的 presence bit置位 P的 Icache和 directory将该块的状态修改为 modified Home Directory: Uncached->从存储器获取数据 2021/22 计算机体系结构
Write Miss Message by P to Directory • Home Directory: block 是Modified态 – Directory 发送 Fetch-Invalidate message 给处理器Q的Cache (Remote Cache 拥有该块的最新值) – 处理器Q的cache 直接发送数据应答消息给P – Q的cache将对应块的状态修改为invalid – P的cache (Local) 将接收到的块的状态信息修改为modified – Directory 将对应于Q的presence bit复位,并将对应于P的 presence bit 置位 • Home Directory: block 是 Shared or Owned态 – Directory 根据presence bit位给所有的共享者发送invalidate messages – Directory接收 acknowledge消息并将对应的presence bits复位 – Directory 发送数据回复信息给P, 并将P对应的 presence bit 置位 – P的cache 和directory 将该块的状态修改为modified • Home Directory: Uncached -> 从存储器获取数据 2021/2/2 计算机体系结构 13
e Write Miss to a Block in Modified State Re questor Processor p 1. Write Miss by p Shared cache Private cache Requesting block A emory Directory 3. Data block a 2. Fetch-Invalidate reply message to P Block a Requested by p Total of 3 messages Processor Q Processor Q sends data reply to p Private Cache Q invalidates its copy of block A Block a is then modified by p 2021/22 计算机体系结构
Write Miss to a Block in Modified State 2021/2/2 计算机体系结构 14
O Write Miss to a Block with Sharers Requestor 1. Write Miss by p Requesting block A Processor p Shared Cache Private Cache Memory Directory 5. Data block a reply message to P 2. Invalidate A Directory sends invalidate messages to all sharers Processor Q Private Cache Directory receives acknowledge message for all invalidates and 3. Invalidate A clears their presence bits dooo3o Directory sends data reply Processor r message, and changes state of Private Cache block a to modified 2021/22 计算机体系结构
Write Miss to a Block with Sharers 2021/2/2 计算机体系结构 15
e Invalidating a Block with Sharers Requestor 1. Invalidate block a Requested by p Processor p Shared cache Private Cache Memory Directory 5. Acknowledge a 2. Invalidate A Directory sends invalidate messages to all sharers Processor Q Private Cache Directory receives acknowledge message for all invalidates and 3. Invalidate a clears their presence bits Directory sends acknowledge Processor r message to p, and changes state Private Cache of block a to modified 2021/22 计算机体系结构
Invalidating a Block with Sharers 2021/2/2 计算机体系结构 16
to Directory Protocol Messages Message Type Source Destination Message Function Read miss Home Processor p has a read miss at address a Cache Directory Request data and make p a read sharer Local Home Write miss Processor p has a write miss at address a Cache Directory Request data and make p the exclusive owner Invalidate Local Home Processor P wants to invalidate all copies of the same Cache Directory block at address a in all remote caches Invalidate ome Remote Directory sends invalidate message to all remote caches to Directory Caches invalidate shared block at address a Acknowledge Remote Home Remote cache sends an acknowledgement message back Cache Directory to home directory after invalidating last shared block a Acknowledge Home oca Directory sends acknowledgment message back to local Directory Cache cache of p after invalidating all shared copies of block a Home Remote Directory sends a fetch message to a remote cache to fetch Directory Cache block a and to change its state to shared Fetch Home Remote Directory sends message to a remote cache to fetch block Invalidate Directory Cache A and to change its state to invalid Data block Director Local Directory or remote cache sends data block reply message Reply or Cache Cache to local cache of processor P that requested data block A Data block Remote Home Remote Cache sends a write-back message to home Write Back Cache Director directory containing data block A 2021/22 计算机体系结构
Directory Protocol Messages 2021/2/2 计算机体系结构 17