diff options
author | Polina Dudnik <pdudnik@gmail.com> | 2009-09-11 10:58:37 -0500 |
---|---|---|
committer | Polina Dudnik <pdudnik@gmail.com> | 2009-09-11 10:58:37 -0500 |
commit | 2af2e590e1e87226c0f5c6b763dbb4225fece2e4 (patch) | |
tree | 34a86ac7f011b8cecb7474a8dfa2fe071ae33b8b /src/mem/protocol/MOESI_CMP_directory-dir.sm | |
parent | ca0e0c368357f1e31b69c92ada4e3021b84d5560 (diff) | |
download | gem5-2af2e590e1e87226c0f5c6b763dbb4225fece2e4.tar.xz |
MOESI data corruption bug fix
Diffstat (limited to 'src/mem/protocol/MOESI_CMP_directory-dir.sm')
-rw-r--r-- | src/mem/protocol/MOESI_CMP_directory-dir.sm | 32 |
1 files changed, 25 insertions, 7 deletions
diff --git a/src/mem/protocol/MOESI_CMP_directory-dir.sm b/src/mem/protocol/MOESI_CMP_directory-dir.sm index f1fb687bb..8e48fc9ab 100644 --- a/src/mem/protocol/MOESI_CMP_directory-dir.sm +++ b/src/mem/protocol/MOESI_CMP_directory-dir.sm @@ -331,6 +331,23 @@ machine(Directory, "Directory protocol") } } + action(p_fwdDataToDMA, "\d", desc="Send data to requestor") { + peek(requestQueue_in, RequestMsg) { + enqueue(responseNetwork_out, ResponseMsg, latency="1") { + out_msg.Address := address; + out_msg.Sender := machineID; + out_msg.SenderMachine := MachineType:Directory; + out_msg.Destination.add(in_msg.Requestor); + out_msg.DataBlk := directory[in_msg.Address].DataBlk; + out_msg.Dirty := false; // By definition, the block is now clean + out_msg.Type := CoherenceResponseType:DATA_EXCLUSIVE; + out_msg.MessageSize := MessageSizeType:Response_Data; + } + } + } + + + action(e_ownerIsUnblocker, "e", desc="The owner is now the unblocker") { peek(unblockNetwork_in, ResponseMsg) { directory[address].Owner.clear(); @@ -592,7 +609,7 @@ machine(Directory, "Directory protocol") i_popIncomingRequestQueue; } - transition(XI_M, Memory_Data, XI_U) { + transition(XI_M, Memory_Data, I) { d_sendDataMsg; // ack count may be zero q_popMemQueue; } @@ -609,9 +626,10 @@ machine(Directory, "Directory protocol") i_popIncomingRequestQueue; } - transition(S, DMA_READ, XI_M) { - qf_queueMemoryFetchRequest; - g_sendInvalidations; // the DMA will collect the invalidations then send an Unblock Exclusive + transition(S, DMA_READ, S) { + //qf_queueMemoryFetchRequest; + p_fwdDataToDMA; + //g_sendInvalidations; // the DMA will collect the invalidations then send an Unblock Exclusive i_popIncomingRequestQueue; } @@ -650,9 +668,9 @@ machine(Directory, "Directory protocol") i_popIncomingRequestQueue; } - transition(O, DMA_READ, XI_U) { + transition(O, DMA_READ, O) { f_forwardRequest; // this will cause the data to go to DMA directly - g_sendInvalidations; // this will cause acks to be sent to the DMA + //g_sendInvalidations; // this will cause acks to be sent to the DMA i_popIncomingRequestQueue; } @@ -684,7 +702,7 @@ machine(Directory, "Directory protocol") } // no exclusive unblock will show up to the directory - transition(M, DMA_READ, XI_U) { + transition(M, DMA_READ, M) { f_forwardRequest; // this will cause the data to go to DMA directly i_popIncomingRequestQueue; } |