MOESI_AMD_Base-Region-dir.sm revision 14184
114184Sgabeblack@google.com/* 214184Sgabeblack@google.com * Copyright (c) 2010-2015 Advanced Micro Devices, Inc. 314184Sgabeblack@google.com * All rights reserved. 414184Sgabeblack@google.com * 514184Sgabeblack@google.com * For use for simulation and test purposes only 614184Sgabeblack@google.com * 714184Sgabeblack@google.com * Redistribution and use in source and binary forms, with or without 814184Sgabeblack@google.com * modification, are permitted provided that the following conditions are met: 914184Sgabeblack@google.com * 1014184Sgabeblack@google.com * 1. Redistributions of source code must retain the above copyright notice, 1114184Sgabeblack@google.com * this list of conditions and the following disclaimer. 1214184Sgabeblack@google.com * 1314184Sgabeblack@google.com * 2. Redistributions in binary form must reproduce the above copyright notice, 1414184Sgabeblack@google.com * this list of conditions and the following disclaimer in the documentation 1514184Sgabeblack@google.com * and/or other materials provided with the distribution. 1614184Sgabeblack@google.com * 1714184Sgabeblack@google.com * 3. Neither the name of the copyright holder nor the names of its 1814184Sgabeblack@google.com * contributors may be used to endorse or promote products derived from this 1914184Sgabeblack@google.com * software without specific prior written permission. 2014184Sgabeblack@google.com * 2114184Sgabeblack@google.com * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 2214184Sgabeblack@google.com * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 2314184Sgabeblack@google.com * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 2414184Sgabeblack@google.com * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE 2514184Sgabeblack@google.com * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 2614184Sgabeblack@google.com * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 2714184Sgabeblack@google.com * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 2814184Sgabeblack@google.com * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 2914184Sgabeblack@google.com * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 3014184Sgabeblack@google.com * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 3114184Sgabeblack@google.com * POSSIBILITY OF SUCH DAMAGE. 3214184Sgabeblack@google.com * 3314184Sgabeblack@google.com * Authors: Lisa Hsu 3414184Sgabeblack@google.com */ 3514184Sgabeblack@google.com 3614184Sgabeblack@google.commachine(MachineType:Directory, "AMD_Base-like protocol") 3714184Sgabeblack@google.com: DirectoryMemory * directory; 3814184Sgabeblack@google.com CacheMemory * L3CacheMemory; 3914184Sgabeblack@google.com Cycles response_latency := 5; 4014184Sgabeblack@google.com Cycles response_latency_regionDir := 1; 4114184Sgabeblack@google.com Cycles l3_hit_latency := 30; 4214184Sgabeblack@google.com bool useL3OnWT := "False"; 4314184Sgabeblack@google.com Cycles to_memory_controller_latency := 1; 4414184Sgabeblack@google.com 4514184Sgabeblack@google.com // From the Cores 4614184Sgabeblack@google.com MessageBuffer * requestFromCores, network="From", virtual_network="0", vnet_type="request"; 4714184Sgabeblack@google.com MessageBuffer * responseFromCores, network="From", virtual_network="2", vnet_type="response"; 4814184Sgabeblack@google.com MessageBuffer * unblockFromCores, network="From", virtual_network="4", vnet_type="unblock"; 4914184Sgabeblack@google.com 5014184Sgabeblack@google.com // To the Cores 5114184Sgabeblack@google.com MessageBuffer * probeToCore, network="To", virtual_network="0", vnet_type="request"; 5214184Sgabeblack@google.com MessageBuffer * responseToCore, network="To", virtual_network="2", vnet_type="response"; 5314184Sgabeblack@google.com 5414184Sgabeblack@google.com // From region buffer 5514184Sgabeblack@google.com MessageBuffer * reqFromRegBuf, network="From", virtual_network="7", vnet_type="request"; 5614184Sgabeblack@google.com 5714184Sgabeblack@google.com // To Region directory 5814184Sgabeblack@google.com MessageBuffer * reqToRegDir, network="To", virtual_network="5", vnet_type="request"; 5914184Sgabeblack@google.com MessageBuffer * reqFromRegDir, network="From", virtual_network="5", vnet_type="request"; 6014184Sgabeblack@google.com MessageBuffer * unblockToRegDir, network="To", virtual_network="4", vnet_type="unblock"; 6114184Sgabeblack@google.com 6214184Sgabeblack@google.com MessageBuffer * triggerQueue; 6314184Sgabeblack@google.com MessageBuffer * L3triggerQueue; 6414184Sgabeblack@google.com MessageBuffer * responseFromMemory; 6514184Sgabeblack@google.com{ 6614184Sgabeblack@google.com // STATES 6714184Sgabeblack@google.com state_declaration(State, desc="Directory states", default="Directory_State_U") { 6814184Sgabeblack@google.com U, AccessPermission:Backing_Store, desc="unblocked"; 6914184Sgabeblack@google.com BR, AccessPermission:Backing_Store, desc="got CPU read request, blocked while sent to L3"; 7014184Sgabeblack@google.com BW, AccessPermission:Backing_Store, desc="got CPU write request, blocked while sent to L3"; 7114184Sgabeblack@google.com BL, AccessPermission:Busy, desc="got L3 WB request"; 7214184Sgabeblack@google.com // BL is Busy because it's possible for the data only to be in the network 7314184Sgabeblack@google.com // in the WB, L3 has sent it and gone on with its business in possibly I 7414184Sgabeblack@google.com // state. 7514184Sgabeblack@google.com BI, AccessPermission:Backing_Store, desc="Blocked waiting for inv ack from core"; 7614184Sgabeblack@google.com BS_M, AccessPermission:Backing_Store, desc="blocked waiting for memory"; 7714184Sgabeblack@google.com BM_M, AccessPermission:Backing_Store, desc="blocked waiting for memory"; 7814184Sgabeblack@google.com B_M, AccessPermission:Backing_Store, desc="blocked waiting for memory"; 7914184Sgabeblack@google.com BP, AccessPermission:Backing_Store, desc="blocked waiting for probes, no need for memory"; 8014184Sgabeblack@google.com BS_PM, AccessPermission:Backing_Store, desc="blocked waiting for probes and Memory"; 8114184Sgabeblack@google.com BM_PM, AccessPermission:Backing_Store, desc="blocked waiting for probes and Memory"; 8214184Sgabeblack@google.com B_PM, AccessPermission:Backing_Store, desc="blocked waiting for probes and Memory"; 8314184Sgabeblack@google.com BS_Pm, AccessPermission:Backing_Store, desc="blocked waiting for probes, already got memory"; 8414184Sgabeblack@google.com BM_Pm, AccessPermission:Backing_Store, desc="blocked waiting for probes, already got memory"; 8514184Sgabeblack@google.com B_Pm, AccessPermission:Backing_Store, desc="blocked waiting for probes, already got memory"; 8614184Sgabeblack@google.com B, AccessPermission:Backing_Store, desc="sent response, Blocked til ack"; 8714184Sgabeblack@google.com 8814184Sgabeblack@google.com // These are needed for when a private requests was issued before an inv was received 8914184Sgabeblack@google.com // for writebacks 9014184Sgabeblack@google.com BS_Pm_BL, AccessPermission:Backing_Store, desc="blocked waiting for probes, already got memory"; 9114184Sgabeblack@google.com BM_Pm_BL, AccessPermission:Backing_Store, desc="blocked waiting for probes, already got memory"; 9214184Sgabeblack@google.com B_Pm_BL, AccessPermission:Backing_Store, desc="blocked waiting for probes, already got memory"; 9314184Sgabeblack@google.com BP_BL, AccessPermission:Backing_Store, desc="blocked waiting for probes, no need for memory"; 9414184Sgabeblack@google.com // for reads 9514184Sgabeblack@google.com BS_Pm_B, AccessPermission:Backing_Store, desc="blocked waiting for probes, already got memory"; 9614184Sgabeblack@google.com BM_Pm_B, AccessPermission:Backing_Store, desc="blocked waiting for probes, already got memory"; 9714184Sgabeblack@google.com B_Pm_B, AccessPermission:Backing_Store, desc="blocked waiting for probes, already got memory"; 9814184Sgabeblack@google.com BP_B, AccessPermission:Backing_Store, desc="blocked waiting for probes, no need for memory"; 9914184Sgabeblack@google.com } 10014184Sgabeblack@google.com 10114184Sgabeblack@google.com // Events 10214184Sgabeblack@google.com enumeration(Event, desc="Directory events") { 10314184Sgabeblack@google.com // CPU requests 10414184Sgabeblack@google.com RdBlkS, desc="..."; 10514184Sgabeblack@google.com RdBlkM, desc="..."; 10614184Sgabeblack@google.com RdBlk, desc="..."; 10714184Sgabeblack@google.com WriteThrough, desc="WriteThrough Message"; 10814184Sgabeblack@google.com Atomic, desc="Atomic Message"; 10914184Sgabeblack@google.com 11014184Sgabeblack@google.com RdBlkSP, desc="..."; 11114184Sgabeblack@google.com RdBlkMP, desc="..."; 11214184Sgabeblack@google.com RdBlkP, desc="..."; 11314184Sgabeblack@google.com VicDirtyP, desc="..."; 11414184Sgabeblack@google.com VicCleanP, desc="..."; 11514184Sgabeblack@google.com WriteThroughP, desc="WriteThrough Message"; 11614184Sgabeblack@google.com AtomicP, desc="Atomic Message"; 11714184Sgabeblack@google.com 11814184Sgabeblack@google.com // writebacks 11914184Sgabeblack@google.com VicDirty, desc="..."; 12014184Sgabeblack@google.com VicClean, desc="..."; 12114184Sgabeblack@google.com CPUData, desc="WB data from CPU"; 12214184Sgabeblack@google.com StaleWB, desc="WB response for a no longer valid request"; 12314184Sgabeblack@google.com 12414184Sgabeblack@google.com // probe responses 12514184Sgabeblack@google.com CPUPrbResp, desc="Probe Response Msg"; 12614184Sgabeblack@google.com LastCPUPrbResp, desc="Last Probe Response Msg"; 12714184Sgabeblack@google.com 12814184Sgabeblack@google.com ProbeAcksComplete, desc="Probe Acks Complete"; 12914184Sgabeblack@google.com 13014184Sgabeblack@google.com L3Hit, desc="Hit in L3 return data to core"; 13114184Sgabeblack@google.com 13214184Sgabeblack@google.com // Memory Controller 13314184Sgabeblack@google.com MemData, desc="Fetched data from memory arrives"; 13414184Sgabeblack@google.com WBAck, desc="Writeback Ack from memory arrives"; 13514184Sgabeblack@google.com 13614184Sgabeblack@google.com CoreUnblock, desc="Core received data, unblock"; 13714184Sgabeblack@google.com UnblockWriteThrough, desc="unblock, self triggered"; 13814184Sgabeblack@google.com 13914184Sgabeblack@google.com StaleVicDirty, desc="Core invalidated before VicDirty processed"; 14014184Sgabeblack@google.com StaleVicDirtyP, desc="Core invalidated before VicDirty processed"; 14114184Sgabeblack@google.com 14214184Sgabeblack@google.com // For region protocol 14314184Sgabeblack@google.com CPUReq, desc="Generic CPU request"; 14414184Sgabeblack@google.com Inv, desc="Region dir needs a block invalidated"; 14514184Sgabeblack@google.com Downgrade, desc="Region dir needs a block downgraded"; 14614184Sgabeblack@google.com 14714184Sgabeblack@google.com // For private accesses (bypassed reg-dir) 14814184Sgabeblack@google.com CPUReadP, desc="Initial req from core, sent to L3"; 14914184Sgabeblack@google.com CPUWriteP, desc="Initial req from core, sent to L3"; 15014184Sgabeblack@google.com } 15114184Sgabeblack@google.com 15214184Sgabeblack@google.com enumeration(RequestType, desc="To communicate stats from transitions to recordStats") { 15314184Sgabeblack@google.com L3DataArrayRead, desc="Read the data array"; 15414184Sgabeblack@google.com L3DataArrayWrite, desc="Write the data array"; 15514184Sgabeblack@google.com L3TagArrayRead, desc="Read the data array"; 15614184Sgabeblack@google.com L3TagArrayWrite, desc="Write the data array"; 15714184Sgabeblack@google.com } 15814184Sgabeblack@google.com 15914184Sgabeblack@google.com // TYPES 16014184Sgabeblack@google.com 16114184Sgabeblack@google.com // DirectoryEntry 16214184Sgabeblack@google.com structure(Entry, desc="...", interface="AbstractEntry") { 16314184Sgabeblack@google.com State DirectoryState, desc="Directory state"; 16414184Sgabeblack@google.com DataBlock DataBlk, desc="data for the block"; 16514184Sgabeblack@google.com NetDest VicDirtyIgnore, desc="VicDirty coming from whom to ignore"; 16614184Sgabeblack@google.com } 16714184Sgabeblack@google.com 16814184Sgabeblack@google.com structure(CacheEntry, desc="...", interface="AbstractCacheEntry") { 16914184Sgabeblack@google.com DataBlock DataBlk, desc="data for the block"; 17014184Sgabeblack@google.com MachineID LastSender, desc="Mach which this block came from"; 17114184Sgabeblack@google.com } 17214184Sgabeblack@google.com 17314184Sgabeblack@google.com structure(TBE, desc="...") { 17414184Sgabeblack@google.com State TBEState, desc="Transient state"; 17514184Sgabeblack@google.com DataBlock DataBlk, desc="data for the block"; 17614184Sgabeblack@google.com DataBlock DataBlkAux, desc="Auxiliary data for the block"; 17714184Sgabeblack@google.com bool Dirty, desc="Is the data dirty?"; 17814184Sgabeblack@google.com int NumPendingAcks, desc="num acks expected"; 17914184Sgabeblack@google.com MachineID OriginalRequestor, desc="Original Requestor"; 18014184Sgabeblack@google.com MachineID WTRequestor, desc="WT Requestor"; 18114184Sgabeblack@google.com bool Cached, desc="data hit in Cache"; 18214184Sgabeblack@google.com bool MemData, desc="Got MemData?",default="false"; 18314184Sgabeblack@google.com bool wtData, desc="Got write through data?",default="false"; 18414184Sgabeblack@google.com bool atomicData, desc="Got Atomic op?",default="false"; 18514184Sgabeblack@google.com Cycles InitialRequestTime, desc="..."; 18614184Sgabeblack@google.com Cycles ForwardRequestTime, desc="..."; 18714184Sgabeblack@google.com Cycles ProbeRequestStartTime, desc="..."; 18814184Sgabeblack@google.com bool DemandRequest, desc="for profiling"; 18914184Sgabeblack@google.com MachineID LastSender, desc="Mach which this block came from"; 19014184Sgabeblack@google.com bool L3Hit, default="false", desc="Was this an L3 hit?"; 19114184Sgabeblack@google.com bool TriggeredAcksComplete, default="false", desc="True if already triggered acks complete"; 19214184Sgabeblack@google.com WriteMask writeMask, desc="outstanding write through mask"; 19314184Sgabeblack@google.com } 19414184Sgabeblack@google.com 19514184Sgabeblack@google.com structure(TBETable, external="yes") { 19614184Sgabeblack@google.com TBE lookup(Addr); 19714184Sgabeblack@google.com void allocate(Addr); 19814184Sgabeblack@google.com void deallocate(Addr); 19914184Sgabeblack@google.com bool isPresent(Addr); 20014184Sgabeblack@google.com } 20114184Sgabeblack@google.com 20214184Sgabeblack@google.com TBETable TBEs, template="<Directory_TBE>", constructor="m_number_of_TBEs"; 20314184Sgabeblack@google.com 20414184Sgabeblack@google.com Tick clockEdge(); 20514184Sgabeblack@google.com Tick cyclesToTicks(Cycles c); 20614184Sgabeblack@google.com 20714184Sgabeblack@google.com void set_tbe(TBE a); 20814184Sgabeblack@google.com void unset_tbe(); 20914184Sgabeblack@google.com void wakeUpAllBuffers(); 21014184Sgabeblack@google.com void wakeUpBuffers(Addr a); 21114184Sgabeblack@google.com Cycles curCycle(); 21214184Sgabeblack@google.com 21314184Sgabeblack@google.com MachineID mapAddressToMachine(Addr addr, MachineType mtype); 21414184Sgabeblack@google.com 21514184Sgabeblack@google.com Entry getDirectoryEntry(Addr addr), return_by_pointer="yes" { 21614184Sgabeblack@google.com Entry dir_entry := static_cast(Entry, "pointer", directory.lookup(addr)); 21714184Sgabeblack@google.com 21814184Sgabeblack@google.com if (is_valid(dir_entry)) { 21914184Sgabeblack@google.com //DPRINTF(RubySlicc, "Getting entry %s: %s\n", addr, dir_entry.DataBlk); 22014184Sgabeblack@google.com return dir_entry; 22114184Sgabeblack@google.com } 22214184Sgabeblack@google.com 22314184Sgabeblack@google.com dir_entry := static_cast(Entry, "pointer", 22414184Sgabeblack@google.com directory.allocate(addr, new Entry)); 22514184Sgabeblack@google.com return dir_entry; 22614184Sgabeblack@google.com } 22714184Sgabeblack@google.com 22814184Sgabeblack@google.com DataBlock getDataBlock(Addr addr), return_by_ref="yes" { 22914184Sgabeblack@google.com TBE tbe := TBEs.lookup(addr); 23014184Sgabeblack@google.com if (is_valid(tbe) && tbe.MemData) { 23114184Sgabeblack@google.com DPRINTF(RubySlicc, "Returning DataBlk from TBE %s:%s\n", addr, tbe); 23214184Sgabeblack@google.com return tbe.DataBlk; 23314184Sgabeblack@google.com } 23414184Sgabeblack@google.com DPRINTF(RubySlicc, "Returning DataBlk from Dir %s:%s\n", addr, getDirectoryEntry(addr)); 23514184Sgabeblack@google.com return getDirectoryEntry(addr).DataBlk; 23614184Sgabeblack@google.com } 23714184Sgabeblack@google.com 23814184Sgabeblack@google.com State getState(TBE tbe, CacheEntry entry, Addr addr) { 23914184Sgabeblack@google.com return getDirectoryEntry(addr).DirectoryState; 24014184Sgabeblack@google.com } 24114184Sgabeblack@google.com 24214184Sgabeblack@google.com State getStateFromAddr(Addr addr) { 24314184Sgabeblack@google.com return getDirectoryEntry(addr).DirectoryState; 24414184Sgabeblack@google.com } 24514184Sgabeblack@google.com 24614184Sgabeblack@google.com void setState(TBE tbe, CacheEntry entry, Addr addr, State state) { 24714184Sgabeblack@google.com getDirectoryEntry(addr).DirectoryState := state; 24814184Sgabeblack@google.com } 24914184Sgabeblack@google.com 25014184Sgabeblack@google.com AccessPermission getAccessPermission(Addr addr) { 25114184Sgabeblack@google.com // For this Directory, all permissions are just tracked in Directory, since 25214184Sgabeblack@google.com // it's not possible to have something in TBE but not Dir, just keep track 25314184Sgabeblack@google.com // of state all in one place. 25414184Sgabeblack@google.com if(directory.isPresent(addr)) { 25514184Sgabeblack@google.com return Directory_State_to_permission(getDirectoryEntry(addr).DirectoryState); 25614184Sgabeblack@google.com } 25714184Sgabeblack@google.com 25814184Sgabeblack@google.com return AccessPermission:NotPresent; 25914184Sgabeblack@google.com } 26014184Sgabeblack@google.com 26114184Sgabeblack@google.com void functionalRead(Addr addr, Packet *pkt) { 26214184Sgabeblack@google.com TBE tbe := TBEs.lookup(addr); 26314184Sgabeblack@google.com if(is_valid(tbe)) { 26414184Sgabeblack@google.com testAndRead(addr, tbe.DataBlk, pkt); 26514184Sgabeblack@google.com } else { 26614184Sgabeblack@google.com functionalMemoryRead(pkt); 26714184Sgabeblack@google.com } 26814184Sgabeblack@google.com } 26914184Sgabeblack@google.com 27014184Sgabeblack@google.com int functionalWrite(Addr addr, Packet *pkt) { 27114184Sgabeblack@google.com int num_functional_writes := 0; 27214184Sgabeblack@google.com 27314184Sgabeblack@google.com TBE tbe := TBEs.lookup(addr); 27414184Sgabeblack@google.com if(is_valid(tbe)) { 27514184Sgabeblack@google.com num_functional_writes := num_functional_writes + 27614184Sgabeblack@google.com testAndWrite(addr, tbe.DataBlk, pkt); 27714184Sgabeblack@google.com } 27814184Sgabeblack@google.com 27914184Sgabeblack@google.com num_functional_writes := num_functional_writes + functionalMemoryWrite(pkt); 28014184Sgabeblack@google.com return num_functional_writes; 28114184Sgabeblack@google.com } 28214184Sgabeblack@google.com 28314184Sgabeblack@google.com void setAccessPermission(CacheEntry entry, Addr addr, State state) { 28414184Sgabeblack@google.com getDirectoryEntry(addr).changePermission(Directory_State_to_permission(state)); 28514184Sgabeblack@google.com } 28614184Sgabeblack@google.com 28714184Sgabeblack@google.com void recordRequestType(RequestType request_type, Addr addr) { 28814184Sgabeblack@google.com if (request_type == RequestType:L3DataArrayRead) { 28914184Sgabeblack@google.com L3CacheMemory.recordRequestType(CacheRequestType:DataArrayRead, addr); 29014184Sgabeblack@google.com } else if (request_type == RequestType:L3DataArrayWrite) { 29114184Sgabeblack@google.com L3CacheMemory.recordRequestType(CacheRequestType:DataArrayWrite, addr); 29214184Sgabeblack@google.com } else if (request_type == RequestType:L3TagArrayRead) { 29314184Sgabeblack@google.com L3CacheMemory.recordRequestType(CacheRequestType:TagArrayRead, addr); 29414184Sgabeblack@google.com } else if (request_type == RequestType:L3TagArrayWrite) { 29514184Sgabeblack@google.com L3CacheMemory.recordRequestType(CacheRequestType:TagArrayWrite, addr); 29614184Sgabeblack@google.com } 29714184Sgabeblack@google.com } 29814184Sgabeblack@google.com 29914184Sgabeblack@google.com bool checkResourceAvailable(RequestType request_type, Addr addr) { 30014184Sgabeblack@google.com if (request_type == RequestType:L3DataArrayRead) { 30114184Sgabeblack@google.com return L3CacheMemory.checkResourceAvailable(CacheResourceType:DataArray, addr); 30214184Sgabeblack@google.com } else if (request_type == RequestType:L3DataArrayWrite) { 30314184Sgabeblack@google.com return L3CacheMemory.checkResourceAvailable(CacheResourceType:DataArray, addr); 30414184Sgabeblack@google.com } else if (request_type == RequestType:L3TagArrayRead) { 30514184Sgabeblack@google.com return L3CacheMemory.checkResourceAvailable(CacheResourceType:TagArray, addr); 30614184Sgabeblack@google.com } else if (request_type == RequestType:L3TagArrayWrite) { 30714184Sgabeblack@google.com return L3CacheMemory.checkResourceAvailable(CacheResourceType:TagArray, addr); 30814184Sgabeblack@google.com } else { 30914184Sgabeblack@google.com error("Invalid RequestType type in checkResourceAvailable"); 31014184Sgabeblack@google.com return true; 31114184Sgabeblack@google.com } 31214184Sgabeblack@google.com } 31314184Sgabeblack@google.com 31414184Sgabeblack@google.com // ** OUT_PORTS ** 31514184Sgabeblack@google.com out_port(probeNetwork_out, NBProbeRequestMsg, probeToCore); 31614184Sgabeblack@google.com out_port(responseNetwork_out, ResponseMsg, responseToCore); 31714184Sgabeblack@google.com 31814184Sgabeblack@google.com out_port(requestNetworkReg_out, CPURequestMsg, reqToRegDir); 31914184Sgabeblack@google.com out_port(regAckNetwork_out, UnblockMsg, unblockToRegDir); 32014184Sgabeblack@google.com 32114184Sgabeblack@google.com out_port(triggerQueue_out, TriggerMsg, triggerQueue); 32214184Sgabeblack@google.com out_port(L3TriggerQueue_out, TriggerMsg, L3triggerQueue); 32314184Sgabeblack@google.com 32414184Sgabeblack@google.com // ** IN_PORTS ** 32514184Sgabeblack@google.com 32614184Sgabeblack@google.com // Trigger Queue 32714184Sgabeblack@google.com in_port(triggerQueue_in, TriggerMsg, triggerQueue, rank=7) { 32814184Sgabeblack@google.com if (triggerQueue_in.isReady(clockEdge())) { 32914184Sgabeblack@google.com peek(triggerQueue_in, TriggerMsg) { 33014184Sgabeblack@google.com TBE tbe := TBEs.lookup(in_msg.addr); 33114184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(in_msg.addr)); 33214184Sgabeblack@google.com if (in_msg.Type == TriggerType:AcksComplete) { 33314184Sgabeblack@google.com trigger(Event:ProbeAcksComplete, in_msg.addr, entry, tbe); 33414184Sgabeblack@google.com } else if (in_msg.Type == TriggerType:UnblockWriteThrough) { 33514184Sgabeblack@google.com trigger(Event:UnblockWriteThrough, in_msg.addr, entry, tbe); 33614184Sgabeblack@google.com } else { 33714184Sgabeblack@google.com error("Unknown trigger msg"); 33814184Sgabeblack@google.com } 33914184Sgabeblack@google.com } 34014184Sgabeblack@google.com } 34114184Sgabeblack@google.com } 34214184Sgabeblack@google.com 34314184Sgabeblack@google.com in_port(L3TriggerQueue_in, TriggerMsg, L3triggerQueue, rank=6) { 34414184Sgabeblack@google.com if (L3TriggerQueue_in.isReady(clockEdge())) { 34514184Sgabeblack@google.com peek(L3TriggerQueue_in, TriggerMsg) { 34614184Sgabeblack@google.com TBE tbe := TBEs.lookup(in_msg.addr); 34714184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(in_msg.addr)); 34814184Sgabeblack@google.com if (in_msg.Type == TriggerType:L3Hit) { 34914184Sgabeblack@google.com trigger(Event:L3Hit, in_msg.addr, entry, tbe); 35014184Sgabeblack@google.com } else { 35114184Sgabeblack@google.com error("Unknown trigger msg"); 35214184Sgabeblack@google.com } 35314184Sgabeblack@google.com } 35414184Sgabeblack@google.com } 35514184Sgabeblack@google.com } 35614184Sgabeblack@google.com 35714184Sgabeblack@google.com // Unblock Network 35814184Sgabeblack@google.com in_port(unblockNetwork_in, UnblockMsg, unblockFromCores, rank=5) { 35914184Sgabeblack@google.com if (unblockNetwork_in.isReady(clockEdge())) { 36014184Sgabeblack@google.com peek(unblockNetwork_in, UnblockMsg) { 36114184Sgabeblack@google.com TBE tbe := TBEs.lookup(in_msg.addr); 36214184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(in_msg.addr)); 36314184Sgabeblack@google.com trigger(Event:CoreUnblock, in_msg.addr, entry, tbe); 36414184Sgabeblack@google.com } 36514184Sgabeblack@google.com } 36614184Sgabeblack@google.com } 36714184Sgabeblack@google.com 36814184Sgabeblack@google.com // Core response network 36914184Sgabeblack@google.com in_port(responseNetwork_in, ResponseMsg, responseFromCores, rank=4) { 37014184Sgabeblack@google.com if (responseNetwork_in.isReady(clockEdge())) { 37114184Sgabeblack@google.com peek(responseNetwork_in, ResponseMsg) { 37214184Sgabeblack@google.com DPRINTF(RubySlicc, "core responses %s\n", in_msg); 37314184Sgabeblack@google.com TBE tbe := TBEs.lookup(in_msg.addr); 37414184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(in_msg.addr)); 37514184Sgabeblack@google.com if (in_msg.Type == CoherenceResponseType:CPUPrbResp) { 37614184Sgabeblack@google.com if (is_valid(tbe) && tbe.NumPendingAcks == 1 37714184Sgabeblack@google.com && tbe.TriggeredAcksComplete == false) { 37814184Sgabeblack@google.com trigger(Event:LastCPUPrbResp, in_msg.addr, entry, tbe); 37914184Sgabeblack@google.com } else { 38014184Sgabeblack@google.com trigger(Event:CPUPrbResp, in_msg.addr, entry, tbe); 38114184Sgabeblack@google.com } 38214184Sgabeblack@google.com } else if (in_msg.Type == CoherenceResponseType:CPUData) { 38314184Sgabeblack@google.com trigger(Event:CPUData, in_msg.addr, entry, tbe); 38414184Sgabeblack@google.com } else if (in_msg.Type == CoherenceResponseType:StaleNotif) { 38514184Sgabeblack@google.com trigger(Event:StaleWB, in_msg.addr, entry, tbe); 38614184Sgabeblack@google.com } else { 38714184Sgabeblack@google.com error("Unexpected response type"); 38814184Sgabeblack@google.com } 38914184Sgabeblack@google.com } 39014184Sgabeblack@google.com } 39114184Sgabeblack@google.com } 39214184Sgabeblack@google.com 39314184Sgabeblack@google.com // off-chip memory request/response is done 39414184Sgabeblack@google.com in_port(memQueue_in, MemoryMsg, responseFromMemory, rank=3) { 39514184Sgabeblack@google.com if (memQueue_in.isReady(clockEdge())) { 39614184Sgabeblack@google.com peek(memQueue_in, MemoryMsg) { 39714184Sgabeblack@google.com TBE tbe := TBEs.lookup(in_msg.addr); 39814184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(in_msg.addr)); 39914184Sgabeblack@google.com if (in_msg.Type == MemoryRequestType:MEMORY_READ) { 40014184Sgabeblack@google.com trigger(Event:MemData, in_msg.addr, entry, tbe); 40114184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", in_msg); 40214184Sgabeblack@google.com } else if (in_msg.Type == MemoryRequestType:MEMORY_WB) { 40314184Sgabeblack@google.com trigger(Event:WBAck, in_msg.addr, entry, tbe); // ignore WBAcks, don't care about them. 40414184Sgabeblack@google.com } else { 40514184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", in_msg.Type); 40614184Sgabeblack@google.com error("Invalid message"); 40714184Sgabeblack@google.com } 40814184Sgabeblack@google.com } 40914184Sgabeblack@google.com } 41014184Sgabeblack@google.com } 41114184Sgabeblack@google.com 41214184Sgabeblack@google.com in_port(regBuf_in, CPURequestMsg, reqFromRegBuf, rank=2) { 41314184Sgabeblack@google.com if (regBuf_in.isReady(clockEdge())) { 41414184Sgabeblack@google.com peek(regBuf_in, CPURequestMsg) { 41514184Sgabeblack@google.com TBE tbe := TBEs.lookup(in_msg.addr); 41614184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(in_msg.addr)); 41714184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:ForceInv) { 41814184Sgabeblack@google.com trigger(Event:Inv, in_msg.addr, entry, tbe); 41914184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:ForceDowngrade) { 42014184Sgabeblack@google.com trigger(Event:Downgrade, in_msg.addr, entry, tbe); 42114184Sgabeblack@google.com } else { 42214184Sgabeblack@google.com error("Bad request from region buffer"); 42314184Sgabeblack@google.com } 42414184Sgabeblack@google.com } 42514184Sgabeblack@google.com } 42614184Sgabeblack@google.com } 42714184Sgabeblack@google.com 42814184Sgabeblack@google.com in_port(regDir_in, CPURequestMsg, reqFromRegDir, rank=1) { 42914184Sgabeblack@google.com if (regDir_in.isReady(clockEdge())) { 43014184Sgabeblack@google.com peek(regDir_in, CPURequestMsg) { 43114184Sgabeblack@google.com TBE tbe := TBEs.lookup(in_msg.addr); 43214184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(in_msg.addr)); 43314184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:RdBlk) { 43414184Sgabeblack@google.com trigger(Event:RdBlk, in_msg.addr, entry, tbe); 43514184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:RdBlkS) { 43614184Sgabeblack@google.com trigger(Event:RdBlkS, in_msg.addr, entry, tbe); 43714184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:RdBlkM) { 43814184Sgabeblack@google.com trigger(Event:RdBlkM, in_msg.addr, entry, tbe); 43914184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:Atomic) { 44014184Sgabeblack@google.com trigger(Event:Atomic, in_msg.addr, entry, tbe); 44114184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:WriteThrough) { 44214184Sgabeblack@google.com trigger(Event:WriteThrough, in_msg.addr, entry, tbe); 44314184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:VicDirty) { 44414184Sgabeblack@google.com if (getDirectoryEntry(in_msg.addr).VicDirtyIgnore.isElement(in_msg.Requestor)) { 44514184Sgabeblack@google.com DPRINTF(RubySlicc, "Dropping VicDirty for address %s\n", in_msg.addr); 44614184Sgabeblack@google.com trigger(Event:StaleVicDirty, in_msg.addr, entry, tbe); 44714184Sgabeblack@google.com } else { 44814184Sgabeblack@google.com trigger(Event:VicDirty, in_msg.addr, entry, tbe); 44914184Sgabeblack@google.com } 45014184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:VicClean) { 45114184Sgabeblack@google.com if (getDirectoryEntry(in_msg.addr).VicDirtyIgnore.isElement(in_msg.Requestor)) { 45214184Sgabeblack@google.com DPRINTF(RubySlicc, "Dropping VicClean for address %s\n", in_msg.addr); 45314184Sgabeblack@google.com trigger(Event:StaleVicDirty, in_msg.addr, entry, tbe); 45414184Sgabeblack@google.com } else { 45514184Sgabeblack@google.com trigger(Event:VicClean, in_msg.addr, entry, tbe); 45614184Sgabeblack@google.com } 45714184Sgabeblack@google.com } else { 45814184Sgabeblack@google.com error("Bad message type fwded from Region Dir"); 45914184Sgabeblack@google.com } 46014184Sgabeblack@google.com } 46114184Sgabeblack@google.com } 46214184Sgabeblack@google.com } 46314184Sgabeblack@google.com 46414184Sgabeblack@google.com in_port(requestNetwork_in, CPURequestMsg, requestFromCores, rank=0) { 46514184Sgabeblack@google.com if (requestNetwork_in.isReady(clockEdge())) { 46614184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 46714184Sgabeblack@google.com TBE tbe := TBEs.lookup(in_msg.addr); 46814184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(in_msg.addr)); 46914184Sgabeblack@google.com if (in_msg.Private) { 47014184Sgabeblack@google.com // Bypass the region dir 47114184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:RdBlk) { 47214184Sgabeblack@google.com trigger(Event:RdBlkP, in_msg.addr, entry, tbe); 47314184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:RdBlkS) { 47414184Sgabeblack@google.com trigger(Event:RdBlkSP, in_msg.addr, entry, tbe); 47514184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:RdBlkM) { 47614184Sgabeblack@google.com trigger(Event:RdBlkMP, in_msg.addr, entry, tbe); 47714184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:Atomic) { 47814184Sgabeblack@google.com trigger(Event:AtomicP, in_msg.addr, entry, tbe); 47914184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:WriteThrough) { 48014184Sgabeblack@google.com trigger(Event:WriteThroughP, in_msg.addr, entry, tbe); 48114184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:VicDirty) { 48214184Sgabeblack@google.com if (getDirectoryEntry(in_msg.addr).VicDirtyIgnore.isElement(in_msg.Requestor)) { 48314184Sgabeblack@google.com DPRINTF(RubySlicc, "Dropping VicDirtyP for address %s\n", in_msg.addr); 48414184Sgabeblack@google.com trigger(Event:StaleVicDirtyP, in_msg.addr, entry, tbe); 48514184Sgabeblack@google.com } else { 48614184Sgabeblack@google.com DPRINTF(RubySlicc, "Got VicDirty from %s on %s\n", in_msg.Requestor, in_msg.addr); 48714184Sgabeblack@google.com trigger(Event:VicDirtyP, in_msg.addr, entry, tbe); 48814184Sgabeblack@google.com } 48914184Sgabeblack@google.com } else if (in_msg.Type == CoherenceRequestType:VicClean) { 49014184Sgabeblack@google.com if (getDirectoryEntry(in_msg.addr).VicDirtyIgnore.isElement(in_msg.Requestor)) { 49114184Sgabeblack@google.com DPRINTF(RubySlicc, "Dropping VicCleanP for address %s\n", in_msg.addr); 49214184Sgabeblack@google.com trigger(Event:StaleVicDirtyP, in_msg.addr, entry, tbe); 49314184Sgabeblack@google.com } else { 49414184Sgabeblack@google.com DPRINTF(RubySlicc, "Got VicClean from %s on %s\n", in_msg.Requestor, in_msg.addr); 49514184Sgabeblack@google.com trigger(Event:VicCleanP, in_msg.addr, entry, tbe); 49614184Sgabeblack@google.com } 49714184Sgabeblack@google.com } else { 49814184Sgabeblack@google.com error("Bad message type for private access"); 49914184Sgabeblack@google.com } 50014184Sgabeblack@google.com } else { 50114184Sgabeblack@google.com trigger(Event:CPUReq, in_msg.addr, entry, tbe); 50214184Sgabeblack@google.com } 50314184Sgabeblack@google.com } 50414184Sgabeblack@google.com } 50514184Sgabeblack@google.com } 50614184Sgabeblack@google.com 50714184Sgabeblack@google.com // Actions 50814184Sgabeblack@google.com action(s_sendResponseS, "s", desc="send Shared response") { 50914184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 51014184Sgabeblack@google.com out_msg.addr := address; 51114184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysResp; 51214184Sgabeblack@google.com if (tbe.L3Hit) { 51314184Sgabeblack@google.com out_msg.Sender := createMachineID(MachineType:L3Cache, intToID(0)); 51414184Sgabeblack@google.com } else { 51514184Sgabeblack@google.com out_msg.Sender := machineID; 51614184Sgabeblack@google.com } 51714184Sgabeblack@google.com out_msg.Destination.add(tbe.OriginalRequestor); 51814184Sgabeblack@google.com out_msg.DataBlk := tbe.DataBlk; 51914184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Data; 52014184Sgabeblack@google.com out_msg.Dirty := false; 52114184Sgabeblack@google.com out_msg.State := CoherenceState:Shared; 52214184Sgabeblack@google.com out_msg.InitialRequestTime := tbe.InitialRequestTime; 52314184Sgabeblack@google.com out_msg.ForwardRequestTime := tbe.ForwardRequestTime; 52414184Sgabeblack@google.com out_msg.ProbeRequestStartTime := tbe.ProbeRequestStartTime; 52514184Sgabeblack@google.com out_msg.OriginalResponder := tbe.LastSender; 52614184Sgabeblack@google.com out_msg.DemandRequest := tbe.DemandRequest; 52714184Sgabeblack@google.com out_msg.L3Hit := tbe.L3Hit; 52814184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 52914184Sgabeblack@google.com } 53014184Sgabeblack@google.com } 53114184Sgabeblack@google.com 53214184Sgabeblack@google.com action(es_sendResponseES, "es", desc="send Exclusive or Shared response") { 53314184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 53414184Sgabeblack@google.com out_msg.addr := address; 53514184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysResp; 53614184Sgabeblack@google.com if (tbe.L3Hit) { 53714184Sgabeblack@google.com out_msg.Sender := createMachineID(MachineType:L3Cache, intToID(0)); 53814184Sgabeblack@google.com } else { 53914184Sgabeblack@google.com out_msg.Sender := machineID; 54014184Sgabeblack@google.com } 54114184Sgabeblack@google.com out_msg.Destination.add(tbe.OriginalRequestor); 54214184Sgabeblack@google.com out_msg.DataBlk := tbe.DataBlk; 54314184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Data; 54414184Sgabeblack@google.com out_msg.Dirty := tbe.Dirty; 54514184Sgabeblack@google.com if (tbe.Cached) { 54614184Sgabeblack@google.com out_msg.State := CoherenceState:Shared; 54714184Sgabeblack@google.com } else { 54814184Sgabeblack@google.com out_msg.State := CoherenceState:Exclusive; 54914184Sgabeblack@google.com } 55014184Sgabeblack@google.com out_msg.InitialRequestTime := tbe.InitialRequestTime; 55114184Sgabeblack@google.com out_msg.ForwardRequestTime := tbe.ForwardRequestTime; 55214184Sgabeblack@google.com out_msg.ProbeRequestStartTime := tbe.ProbeRequestStartTime; 55314184Sgabeblack@google.com out_msg.OriginalResponder := tbe.LastSender; 55414184Sgabeblack@google.com out_msg.DemandRequest := tbe.DemandRequest; 55514184Sgabeblack@google.com out_msg.L3Hit := tbe.L3Hit; 55614184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 55714184Sgabeblack@google.com } 55814184Sgabeblack@google.com } 55914184Sgabeblack@google.com 56014184Sgabeblack@google.com action(m_sendResponseM, "m", desc="send Modified response") { 56114184Sgabeblack@google.com if (tbe.wtData) { 56214184Sgabeblack@google.com enqueue(triggerQueue_out, TriggerMsg, 1) { 56314184Sgabeblack@google.com out_msg.addr := address; 56414184Sgabeblack@google.com out_msg.Type := TriggerType:UnblockWriteThrough; 56514184Sgabeblack@google.com } 56614184Sgabeblack@google.com } else { 56714184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 56814184Sgabeblack@google.com out_msg.addr := address; 56914184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysResp; 57014184Sgabeblack@google.com if (tbe.L3Hit) { 57114184Sgabeblack@google.com out_msg.Sender := createMachineID(MachineType:L3Cache, intToID(0)); 57214184Sgabeblack@google.com } else { 57314184Sgabeblack@google.com out_msg.Sender := machineID; 57414184Sgabeblack@google.com } 57514184Sgabeblack@google.com out_msg.Destination.add(tbe.OriginalRequestor); 57614184Sgabeblack@google.com out_msg.DataBlk := tbe.DataBlk; 57714184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Data; 57814184Sgabeblack@google.com out_msg.Dirty := tbe.Dirty; 57914184Sgabeblack@google.com out_msg.State := CoherenceState:Modified; 58014184Sgabeblack@google.com out_msg.CtoD := false; 58114184Sgabeblack@google.com out_msg.InitialRequestTime := tbe.InitialRequestTime; 58214184Sgabeblack@google.com out_msg.ForwardRequestTime := tbe.ForwardRequestTime; 58314184Sgabeblack@google.com out_msg.ProbeRequestStartTime := tbe.ProbeRequestStartTime; 58414184Sgabeblack@google.com out_msg.OriginalResponder := tbe.LastSender; 58514184Sgabeblack@google.com out_msg.DemandRequest := tbe.DemandRequest; 58614184Sgabeblack@google.com out_msg.L3Hit := tbe.L3Hit; 58714184Sgabeblack@google.com if (tbe.atomicData) { 58814184Sgabeblack@google.com out_msg.WTRequestor := tbe.WTRequestor; 58914184Sgabeblack@google.com } 59014184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 59114184Sgabeblack@google.com } 59214184Sgabeblack@google.com if (tbe.atomicData) { 59314184Sgabeblack@google.com enqueue(triggerQueue_out, TriggerMsg, 1) { 59414184Sgabeblack@google.com out_msg.addr := address; 59514184Sgabeblack@google.com out_msg.Type := TriggerType:UnblockWriteThrough; 59614184Sgabeblack@google.com } 59714184Sgabeblack@google.com } 59814184Sgabeblack@google.com } 59914184Sgabeblack@google.com } 60014184Sgabeblack@google.com 60114184Sgabeblack@google.com action(sb_sendResponseSBypass, "sb", desc="send Shared response") { 60214184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 60314184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 60414184Sgabeblack@google.com out_msg.addr := address; 60514184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysResp; 60614184Sgabeblack@google.com if (tbe.L3Hit) { 60714184Sgabeblack@google.com out_msg.Sender := createMachineID(MachineType:L3Cache, intToID(0)); 60814184Sgabeblack@google.com } else { 60914184Sgabeblack@google.com out_msg.Sender := machineID; 61014184Sgabeblack@google.com } 61114184Sgabeblack@google.com out_msg.Destination.add(in_msg.Requestor); 61214184Sgabeblack@google.com out_msg.DataBlk := tbe.DataBlk; 61314184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Data; 61414184Sgabeblack@google.com out_msg.Dirty := false; 61514184Sgabeblack@google.com out_msg.State := CoherenceState:Shared; 61614184Sgabeblack@google.com out_msg.InitialRequestTime := in_msg.InitialRequestTime; 61714184Sgabeblack@google.com out_msg.ForwardRequestTime := curCycle(); 61814184Sgabeblack@google.com out_msg.ProbeRequestStartTime := in_msg.ProbeRequestStartTime; 61914184Sgabeblack@google.com out_msg.OriginalResponder := tbe.LastSender; 62014184Sgabeblack@google.com out_msg.DemandRequest := false; 62114184Sgabeblack@google.com out_msg.L3Hit := tbe.L3Hit; 62214184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 62314184Sgabeblack@google.com } 62414184Sgabeblack@google.com } 62514184Sgabeblack@google.com } 62614184Sgabeblack@google.com 62714184Sgabeblack@google.com action(esb_sendResponseESBypass, "esb", desc="send Exclusive or Shared response") { 62814184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 62914184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 63014184Sgabeblack@google.com out_msg.addr := address; 63114184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysResp; 63214184Sgabeblack@google.com if (tbe.L3Hit) { 63314184Sgabeblack@google.com out_msg.Sender := createMachineID(MachineType:L3Cache, intToID(0)); 63414184Sgabeblack@google.com } else { 63514184Sgabeblack@google.com out_msg.Sender := machineID; 63614184Sgabeblack@google.com } 63714184Sgabeblack@google.com out_msg.Destination.add(in_msg.Requestor); 63814184Sgabeblack@google.com out_msg.DataBlk := tbe.DataBlk; 63914184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Data; 64014184Sgabeblack@google.com out_msg.Dirty := tbe.Dirty; 64114184Sgabeblack@google.com if (tbe.Cached || in_msg.ForceShared) { 64214184Sgabeblack@google.com out_msg.State := CoherenceState:Shared; 64314184Sgabeblack@google.com } else { 64414184Sgabeblack@google.com out_msg.State := CoherenceState:Exclusive; 64514184Sgabeblack@google.com } 64614184Sgabeblack@google.com out_msg.InitialRequestTime := in_msg.InitialRequestTime; 64714184Sgabeblack@google.com out_msg.ForwardRequestTime := curCycle(); 64814184Sgabeblack@google.com out_msg.ProbeRequestStartTime := in_msg.ProbeRequestStartTime; 64914184Sgabeblack@google.com out_msg.OriginalResponder := tbe.LastSender; 65014184Sgabeblack@google.com out_msg.DemandRequest := false; 65114184Sgabeblack@google.com out_msg.L3Hit := tbe.L3Hit; 65214184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 65314184Sgabeblack@google.com } 65414184Sgabeblack@google.com } 65514184Sgabeblack@google.com } 65614184Sgabeblack@google.com 65714184Sgabeblack@google.com action(mbwt_sendResponseWriteThroughBypass, "mbwt", desc="send write through response") { 65814184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 65914184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:WriteThrough) { 66014184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 66114184Sgabeblack@google.com out_msg.addr := address; 66214184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysWBAck; 66314184Sgabeblack@google.com out_msg.Destination.add(in_msg.Requestor); 66414184Sgabeblack@google.com out_msg.WTRequestor := in_msg.WTRequestor; 66514184Sgabeblack@google.com out_msg.Sender := machineID; 66614184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Writeback_Control; 66714184Sgabeblack@google.com out_msg.InitialRequestTime := in_msg.InitialRequestTime; 66814184Sgabeblack@google.com out_msg.ForwardRequestTime := curCycle(); 66914184Sgabeblack@google.com out_msg.ProbeRequestStartTime := in_msg.ProbeRequestStartTime; 67014184Sgabeblack@google.com out_msg.DemandRequest := false; 67114184Sgabeblack@google.com } 67214184Sgabeblack@google.com } else { 67314184Sgabeblack@google.com assert(in_msg.Type == CoherenceRequestType:Atomic); 67414184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 67514184Sgabeblack@google.com out_msg.addr := address; 67614184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysResp; 67714184Sgabeblack@google.com if (tbe.L3Hit) { 67814184Sgabeblack@google.com out_msg.Sender := createMachineID(MachineType:L3Cache, intToID(0)); 67914184Sgabeblack@google.com } else { 68014184Sgabeblack@google.com out_msg.Sender := machineID; 68114184Sgabeblack@google.com } 68214184Sgabeblack@google.com out_msg.Destination.add(in_msg.Requestor); 68314184Sgabeblack@google.com out_msg.DataBlk := getDirectoryEntry(address).DataBlk; 68414184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Data; 68514184Sgabeblack@google.com out_msg.Dirty := in_msg.Dirty; 68614184Sgabeblack@google.com out_msg.State := CoherenceState:Modified; 68714184Sgabeblack@google.com out_msg.CtoD := false; 68814184Sgabeblack@google.com out_msg.InitialRequestTime := in_msg.InitialRequestTime; 68914184Sgabeblack@google.com out_msg.ForwardRequestTime := curCycle(); 69014184Sgabeblack@google.com out_msg.ProbeRequestStartTime := in_msg.ProbeRequestStartTime; 69114184Sgabeblack@google.com out_msg.OriginalResponder := tbe.LastSender; 69214184Sgabeblack@google.com out_msg.DemandRequest := false; 69314184Sgabeblack@google.com out_msg.L3Hit := tbe.L3Hit; 69414184Sgabeblack@google.com out_msg.WTRequestor := in_msg.WTRequestor; 69514184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 69614184Sgabeblack@google.com } 69714184Sgabeblack@google.com } 69814184Sgabeblack@google.com enqueue(triggerQueue_out, TriggerMsg, 1) { 69914184Sgabeblack@google.com out_msg.addr := address; 70014184Sgabeblack@google.com out_msg.Type := TriggerType:UnblockWriteThrough; 70114184Sgabeblack@google.com } 70214184Sgabeblack@google.com } 70314184Sgabeblack@google.com } 70414184Sgabeblack@google.com 70514184Sgabeblack@google.com action(mb_sendResponseMBypass, "mb", desc="send Modified response") { 70614184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 70714184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 70814184Sgabeblack@google.com out_msg.addr := address; 70914184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysResp; 71014184Sgabeblack@google.com if (tbe.L3Hit) { 71114184Sgabeblack@google.com out_msg.Sender := createMachineID(MachineType:L3Cache, intToID(0)); 71214184Sgabeblack@google.com } else { 71314184Sgabeblack@google.com out_msg.Sender := machineID; 71414184Sgabeblack@google.com } 71514184Sgabeblack@google.com out_msg.Destination.add(in_msg.Requestor); 71614184Sgabeblack@google.com out_msg.DataBlk := tbe.DataBlk; 71714184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Data; 71814184Sgabeblack@google.com out_msg.Dirty := tbe.Dirty; 71914184Sgabeblack@google.com out_msg.State := CoherenceState:Modified; 72014184Sgabeblack@google.com out_msg.CtoD := false; 72114184Sgabeblack@google.com out_msg.InitialRequestTime := in_msg.InitialRequestTime; 72214184Sgabeblack@google.com out_msg.ForwardRequestTime := curCycle(); 72314184Sgabeblack@google.com out_msg.ProbeRequestStartTime := in_msg.ProbeRequestStartTime; 72414184Sgabeblack@google.com out_msg.OriginalResponder := tbe.LastSender; 72514184Sgabeblack@google.com out_msg.DemandRequest := false; 72614184Sgabeblack@google.com out_msg.L3Hit := tbe.L3Hit; 72714184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 72814184Sgabeblack@google.com } 72914184Sgabeblack@google.com } 73014184Sgabeblack@google.com } 73114184Sgabeblack@google.com 73214184Sgabeblack@google.com action(c_sendResponseCtoD, "c", desc="send CtoD Ack") { 73314184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 73414184Sgabeblack@google.com out_msg.addr := address; 73514184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysResp; 73614184Sgabeblack@google.com out_msg.Sender := machineID; 73714184Sgabeblack@google.com out_msg.Destination.add(tbe.OriginalRequestor); 73814184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Control; 73914184Sgabeblack@google.com out_msg.Dirty := false; 74014184Sgabeblack@google.com out_msg.State := CoherenceState:Modified; 74114184Sgabeblack@google.com out_msg.CtoD := true; 74214184Sgabeblack@google.com out_msg.InitialRequestTime := tbe.InitialRequestTime; 74314184Sgabeblack@google.com out_msg.ForwardRequestTime := curCycle(); 74414184Sgabeblack@google.com out_msg.ProbeRequestStartTime := tbe.ProbeRequestStartTime; 74514184Sgabeblack@google.com out_msg.DemandRequest := tbe.DemandRequest; 74614184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 74714184Sgabeblack@google.com } 74814184Sgabeblack@google.com } 74914184Sgabeblack@google.com 75014184Sgabeblack@google.com action(cp_sendResponseCtoDP, "cp", desc="send CtoD Ack") { 75114184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 75214184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 75314184Sgabeblack@google.com out_msg.addr := address; 75414184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysResp; 75514184Sgabeblack@google.com out_msg.Sender := machineID; 75614184Sgabeblack@google.com out_msg.Destination.add(in_msg.Requestor); 75714184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Control; 75814184Sgabeblack@google.com out_msg.Dirty := false; 75914184Sgabeblack@google.com out_msg.State := CoherenceState:Modified; 76014184Sgabeblack@google.com out_msg.CtoD := true; 76114184Sgabeblack@google.com out_msg.InitialRequestTime := in_msg.InitialRequestTime; 76214184Sgabeblack@google.com out_msg.ForwardRequestTime := curCycle(); 76314184Sgabeblack@google.com out_msg.ProbeRequestStartTime := in_msg.ProbeRequestStartTime; 76414184Sgabeblack@google.com out_msg.DemandRequest := false; 76514184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 76614184Sgabeblack@google.com } 76714184Sgabeblack@google.com } 76814184Sgabeblack@google.com } 76914184Sgabeblack@google.com 77014184Sgabeblack@google.com action(w_sendResponseWBAck, "w", desc="send WB Ack") { 77114184Sgabeblack@google.com peek(regDir_in, CPURequestMsg) { 77214184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 77314184Sgabeblack@google.com out_msg.addr := address; 77414184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysWBAck; 77514184Sgabeblack@google.com out_msg.Destination.add(in_msg.Requestor); 77614184Sgabeblack@google.com out_msg.WTRequestor := in_msg.WTRequestor; 77714184Sgabeblack@google.com out_msg.Sender := machineID; 77814184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Writeback_Control; 77914184Sgabeblack@google.com out_msg.InitialRequestTime := in_msg.InitialRequestTime; 78014184Sgabeblack@google.com out_msg.ForwardRequestTime := in_msg.ForwardRequestTime; 78114184Sgabeblack@google.com out_msg.ProbeRequestStartTime := in_msg.ProbeRequestStartTime; 78214184Sgabeblack@google.com out_msg.DemandRequest := false; 78314184Sgabeblack@google.com } 78414184Sgabeblack@google.com } 78514184Sgabeblack@google.com } 78614184Sgabeblack@google.com 78714184Sgabeblack@google.com action(wp_sendResponseWBAckP, "wp", desc="send WB Ack") { 78814184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 78914184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 79014184Sgabeblack@google.com out_msg.addr := address; 79114184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysWBAck; 79214184Sgabeblack@google.com out_msg.Destination.add(in_msg.Requestor); 79314184Sgabeblack@google.com out_msg.WTRequestor := in_msg.WTRequestor; 79414184Sgabeblack@google.com out_msg.Sender := machineID; 79514184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Writeback_Control; 79614184Sgabeblack@google.com out_msg.InitialRequestTime := in_msg.InitialRequestTime; 79714184Sgabeblack@google.com out_msg.ForwardRequestTime := curCycle(); 79814184Sgabeblack@google.com out_msg.ProbeRequestStartTime := in_msg.ProbeRequestStartTime; 79914184Sgabeblack@google.com out_msg.DemandRequest := false; 80014184Sgabeblack@google.com } 80114184Sgabeblack@google.com } 80214184Sgabeblack@google.com } 80314184Sgabeblack@google.com 80414184Sgabeblack@google.com action(wc_sendResponseWBAck, "wc", desc="send WB Ack for cancel") { 80514184Sgabeblack@google.com peek(responseNetwork_in, ResponseMsg) { 80614184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency) { 80714184Sgabeblack@google.com out_msg.addr := address; 80814184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:NBSysWBAck; 80914184Sgabeblack@google.com out_msg.Destination.add(in_msg.Sender); 81014184Sgabeblack@google.com out_msg.Sender := machineID; 81114184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Writeback_Control; 81214184Sgabeblack@google.com } 81314184Sgabeblack@google.com } 81414184Sgabeblack@google.com } 81514184Sgabeblack@google.com 81614184Sgabeblack@google.com action(ra_ackRegionDir, "ra", desc="Ack region dir") { 81714184Sgabeblack@google.com peek(regDir_in, CPURequestMsg) { 81814184Sgabeblack@google.com if (in_msg.NoAckNeeded == false) { 81914184Sgabeblack@google.com enqueue(responseNetwork_out, ResponseMsg, response_latency_regionDir) { 82014184Sgabeblack@google.com out_msg.addr := address; 82114184Sgabeblack@google.com out_msg.Type := CoherenceResponseType:DirReadyAck; 82214184Sgabeblack@google.com out_msg.Destination.add(mapAddressToMachine(address, MachineType:RegionDir)); 82314184Sgabeblack@google.com out_msg.Sender := machineID; 82414184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Writeback_Control; 82514184Sgabeblack@google.com } 82614184Sgabeblack@google.com } 82714184Sgabeblack@google.com } 82814184Sgabeblack@google.com } 82914184Sgabeblack@google.com 83014184Sgabeblack@google.com action(l_queueMemRdReq, "lr", desc="Read data from memory") { 83114184Sgabeblack@google.com peek(regDir_in, CPURequestMsg) { 83214184Sgabeblack@google.com if (L3CacheMemory.isTagPresent(address)) { 83314184Sgabeblack@google.com enqueue(L3TriggerQueue_out, TriggerMsg, l3_hit_latency) { 83414184Sgabeblack@google.com out_msg.addr := address; 83514184Sgabeblack@google.com out_msg.Type := TriggerType:L3Hit; 83614184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 83714184Sgabeblack@google.com } 83814184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(address)); 83914184Sgabeblack@google.com tbe.DataBlk := entry.DataBlk; 84014184Sgabeblack@google.com tbe.LastSender := entry.LastSender; 84114184Sgabeblack@google.com tbe.L3Hit := true; 84214184Sgabeblack@google.com tbe.MemData := true; 84314184Sgabeblack@google.com DPRINTF(RubySlicc, "L3 data is %s\n", entry.DataBlk); 84414184Sgabeblack@google.com L3CacheMemory.deallocate(address); 84514184Sgabeblack@google.com } else { 84614184Sgabeblack@google.com queueMemoryRead(machineID, address, to_memory_controller_latency); 84714184Sgabeblack@google.com } 84814184Sgabeblack@google.com } 84914184Sgabeblack@google.com } 85014184Sgabeblack@google.com 85114184Sgabeblack@google.com action(lrp_queueMemRdReqP, "lrp", desc="Read data from memory") { 85214184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 85314184Sgabeblack@google.com if (L3CacheMemory.isTagPresent(address)) { 85414184Sgabeblack@google.com enqueue(L3TriggerQueue_out, TriggerMsg, l3_hit_latency) { 85514184Sgabeblack@google.com out_msg.addr := address; 85614184Sgabeblack@google.com out_msg.Type := TriggerType:L3Hit; 85714184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 85814184Sgabeblack@google.com } 85914184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(address)); 86014184Sgabeblack@google.com tbe.DataBlk := entry.DataBlk; 86114184Sgabeblack@google.com tbe.LastSender := entry.LastSender; 86214184Sgabeblack@google.com tbe.L3Hit := true; 86314184Sgabeblack@google.com tbe.MemData := true; 86414184Sgabeblack@google.com DPRINTF(RubySlicc, "L3 data is %s\n", entry.DataBlk); 86514184Sgabeblack@google.com L3CacheMemory.deallocate(address); 86614184Sgabeblack@google.com } else { 86714184Sgabeblack@google.com queueMemoryRead(machineID, address, to_memory_controller_latency); 86814184Sgabeblack@google.com } 86914184Sgabeblack@google.com } 87014184Sgabeblack@google.com } 87114184Sgabeblack@google.com 87214184Sgabeblack@google.com action(dcr_probeInvCoreData, "dcr", desc="probe inv cores, return data") { 87314184Sgabeblack@google.com peek(regBuf_in, CPURequestMsg) { 87414184Sgabeblack@google.com enqueue(probeNetwork_out, NBProbeRequestMsg, response_latency) { 87514184Sgabeblack@google.com out_msg.addr := address; 87614184Sgabeblack@google.com out_msg.Type := ProbeRequestType:PrbInv; 87714184Sgabeblack@google.com out_msg.ReturnData := true; 87814184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Control; 87914184Sgabeblack@google.com out_msg.Destination := in_msg.Sharers; 88014184Sgabeblack@google.com tbe.NumPendingAcks := tbe.NumPendingAcks + in_msg.Sharers.count(); 88114184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 88214184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" dcr: Acks remaining: "); 88314184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(tbe.NumPendingAcks); 88414184Sgabeblack@google.com tbe.ProbeRequestStartTime := curCycle(); 88514184Sgabeblack@google.com } 88614184Sgabeblack@google.com } 88714184Sgabeblack@google.com } 88814184Sgabeblack@google.com 88914184Sgabeblack@google.com action(ddr_probeDownCoreData, "ddr", desc="probe inv cores, return data") { 89014184Sgabeblack@google.com peek(regBuf_in, CPURequestMsg) { 89114184Sgabeblack@google.com enqueue(probeNetwork_out, NBProbeRequestMsg, response_latency) { 89214184Sgabeblack@google.com out_msg.addr := address; 89314184Sgabeblack@google.com out_msg.Type := ProbeRequestType:PrbDowngrade; 89414184Sgabeblack@google.com out_msg.ReturnData := true; 89514184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Control; 89614184Sgabeblack@google.com out_msg.Destination := in_msg.Sharers; 89714184Sgabeblack@google.com tbe.NumPendingAcks := tbe.NumPendingAcks + in_msg.Sharers.count(); 89814184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 89914184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" dcr: Acks remaining: "); 90014184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(tbe.NumPendingAcks); 90114184Sgabeblack@google.com tbe.ProbeRequestStartTime := curCycle(); 90214184Sgabeblack@google.com } 90314184Sgabeblack@google.com } 90414184Sgabeblack@google.com } 90514184Sgabeblack@google.com 90614184Sgabeblack@google.com action(sc_probeShrCoreData, "sc", desc="probe shared cores, return data") { 90714184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { // not the right network? 90814184Sgabeblack@google.com enqueue(probeNetwork_out, NBProbeRequestMsg, response_latency) { 90914184Sgabeblack@google.com out_msg.addr := address; 91014184Sgabeblack@google.com out_msg.Type := ProbeRequestType:PrbDowngrade; 91114184Sgabeblack@google.com out_msg.ReturnData := true; 91214184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Control; 91314184Sgabeblack@google.com out_msg.Destination.broadcast(MachineType:CorePair); // won't be realistic for multisocket 91414184Sgabeblack@google.com tbe.NumPendingAcks := tbe.NumPendingAcks +machineCount(MachineType:CorePair) - 1; 91514184Sgabeblack@google.com out_msg.Destination.broadcast(MachineType:TCP); 91614184Sgabeblack@google.com tbe.NumPendingAcks := tbe.NumPendingAcks + machineCount(MachineType:TCP); 91714184Sgabeblack@google.com out_msg.Destination.broadcast(MachineType:SQC); 91814184Sgabeblack@google.com tbe.NumPendingAcks := tbe.NumPendingAcks + machineCount(MachineType:SQC); 91914184Sgabeblack@google.com out_msg.Destination.remove(in_msg.Requestor); 92014184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", (out_msg)); 92114184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" sc: Acks remaining: "); 92214184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(tbe.NumPendingAcks); 92314184Sgabeblack@google.com tbe.ProbeRequestStartTime := curCycle(); 92414184Sgabeblack@google.com } 92514184Sgabeblack@google.com } 92614184Sgabeblack@google.com } 92714184Sgabeblack@google.com 92814184Sgabeblack@google.com action(ic_probeInvCore, "ic", desc="probe invalidate core, no return data needed") { 92914184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { // not the right network? 93014184Sgabeblack@google.com enqueue(probeNetwork_out, NBProbeRequestMsg, response_latency) { 93114184Sgabeblack@google.com out_msg.addr := address; 93214184Sgabeblack@google.com out_msg.Type := ProbeRequestType:PrbInv; 93314184Sgabeblack@google.com out_msg.ReturnData := false; 93414184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Control; 93514184Sgabeblack@google.com out_msg.Destination.broadcast(MachineType:CorePair); // won't be realistic for multisocket 93614184Sgabeblack@google.com tbe.NumPendingAcks := tbe.NumPendingAcks +machineCount(MachineType:CorePair) - 1; 93714184Sgabeblack@google.com out_msg.Destination.broadcast(MachineType:TCP); 93814184Sgabeblack@google.com tbe.NumPendingAcks := tbe.NumPendingAcks + machineCount(MachineType:TCP); 93914184Sgabeblack@google.com out_msg.Destination.broadcast(MachineType:SQC); 94014184Sgabeblack@google.com tbe.NumPendingAcks := tbe.NumPendingAcks + machineCount(MachineType:SQC); 94114184Sgabeblack@google.com out_msg.Destination.remove(in_msg.Requestor); 94214184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" ic: Acks remaining: "); 94314184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(tbe.NumPendingAcks); 94414184Sgabeblack@google.com DPRINTF(RubySlicc, "%s\n", out_msg); 94514184Sgabeblack@google.com tbe.ProbeRequestStartTime := curCycle(); 94614184Sgabeblack@google.com } 94714184Sgabeblack@google.com } 94814184Sgabeblack@google.com } 94914184Sgabeblack@google.com 95014184Sgabeblack@google.com action(d_writeDataToMemory, "d", desc="Write data to memory") { 95114184Sgabeblack@google.com peek(responseNetwork_in, ResponseMsg) { 95214184Sgabeblack@google.com getDirectoryEntry(address).DataBlk := in_msg.DataBlk; 95314184Sgabeblack@google.com DPRINTF(RubySlicc, "Writing Data: %s to address %s\n", in_msg.DataBlk, 95414184Sgabeblack@google.com in_msg.addr); 95514184Sgabeblack@google.com } 95614184Sgabeblack@google.com } 95714184Sgabeblack@google.com 95814184Sgabeblack@google.com action(t_allocateTBE, "t", desc="allocate TBE Entry") { 95914184Sgabeblack@google.com check_allocate(TBEs); 96014184Sgabeblack@google.com peek(regDir_in, CPURequestMsg) { 96114184Sgabeblack@google.com TBEs.allocate(address); 96214184Sgabeblack@google.com set_tbe(TBEs.lookup(address)); 96314184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:WriteThrough) { 96414184Sgabeblack@google.com tbe.writeMask.clear(); 96514184Sgabeblack@google.com tbe.writeMask.orMask(in_msg.writeMask); 96614184Sgabeblack@google.com tbe.wtData := true; 96714184Sgabeblack@google.com tbe.WTRequestor := in_msg.WTRequestor; 96814184Sgabeblack@google.com tbe.LastSender := in_msg.Requestor; 96914184Sgabeblack@google.com } 97014184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:Atomic) { 97114184Sgabeblack@google.com tbe.writeMask.clear(); 97214184Sgabeblack@google.com tbe.writeMask.orMask(in_msg.writeMask); 97314184Sgabeblack@google.com tbe.atomicData := true; 97414184Sgabeblack@google.com tbe.WTRequestor := in_msg.WTRequestor; 97514184Sgabeblack@google.com tbe.LastSender := in_msg.Requestor; 97614184Sgabeblack@google.com } 97714184Sgabeblack@google.com tbe.DataBlk := getDirectoryEntry(address).DataBlk; // Data only for WBs 97814184Sgabeblack@google.com tbe.Dirty := false; 97914184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:WriteThrough) { 98014184Sgabeblack@google.com tbe.DataBlk.copyPartial(in_msg.DataBlk,tbe.writeMask); 98114184Sgabeblack@google.com tbe.Dirty := false; 98214184Sgabeblack@google.com } 98314184Sgabeblack@google.com tbe.OriginalRequestor := in_msg.Requestor; 98414184Sgabeblack@google.com tbe.NumPendingAcks := 0; 98514184Sgabeblack@google.com tbe.Cached := in_msg.ForceShared; 98614184Sgabeblack@google.com tbe.InitialRequestTime := in_msg.InitialRequestTime; 98714184Sgabeblack@google.com tbe.ForwardRequestTime := curCycle(); 98814184Sgabeblack@google.com tbe.ProbeRequestStartTime := in_msg.ProbeRequestStartTime; 98914184Sgabeblack@google.com tbe.DemandRequest := in_msg.DemandRequest; 99014184Sgabeblack@google.com } 99114184Sgabeblack@google.com } 99214184Sgabeblack@google.com 99314184Sgabeblack@google.com action(tp_allocateTBEP, "tp", desc="allocate TBE Entry") { 99414184Sgabeblack@google.com check_allocate(TBEs); 99514184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 99614184Sgabeblack@google.com TBEs.allocate(address); 99714184Sgabeblack@google.com set_tbe(TBEs.lookup(address)); 99814184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:WriteThrough) { 99914184Sgabeblack@google.com tbe.writeMask.clear(); 100014184Sgabeblack@google.com tbe.writeMask.orMask(in_msg.writeMask); 100114184Sgabeblack@google.com tbe.wtData := true; 100214184Sgabeblack@google.com tbe.WTRequestor := in_msg.WTRequestor; 100314184Sgabeblack@google.com tbe.LastSender := in_msg.Requestor; 100414184Sgabeblack@google.com } 100514184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:Atomic) { 100614184Sgabeblack@google.com tbe.writeMask.clear(); 100714184Sgabeblack@google.com tbe.writeMask.orMask(in_msg.writeMask); 100814184Sgabeblack@google.com tbe.atomicData := true; 100914184Sgabeblack@google.com tbe.WTRequestor := in_msg.WTRequestor; 101014184Sgabeblack@google.com tbe.LastSender := in_msg.Requestor; 101114184Sgabeblack@google.com } 101214184Sgabeblack@google.com tbe.DataBlk := getDirectoryEntry(address).DataBlk; // Data only for WBs 101314184Sgabeblack@google.com tbe.Dirty := false; 101414184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:WriteThrough) { 101514184Sgabeblack@google.com tbe.DataBlk.copyPartial(in_msg.DataBlk,tbe.writeMask); 101614184Sgabeblack@google.com tbe.Dirty := false; 101714184Sgabeblack@google.com } 101814184Sgabeblack@google.com tbe.OriginalRequestor := in_msg.Requestor; 101914184Sgabeblack@google.com tbe.NumPendingAcks := 0; 102014184Sgabeblack@google.com tbe.Cached := in_msg.ForceShared; 102114184Sgabeblack@google.com tbe.InitialRequestTime := in_msg.InitialRequestTime; 102214184Sgabeblack@google.com tbe.ForwardRequestTime := curCycle(); 102314184Sgabeblack@google.com tbe.ProbeRequestStartTime := in_msg.ProbeRequestStartTime; 102414184Sgabeblack@google.com tbe.DemandRequest := false; 102514184Sgabeblack@google.com } 102614184Sgabeblack@google.com } 102714184Sgabeblack@google.com 102814184Sgabeblack@google.com action(sa_setAcks, "sa", desc="setAcks") { 102914184Sgabeblack@google.com peek(regDir_in, CPURequestMsg) { 103014184Sgabeblack@google.com tbe.NumPendingAcks := in_msg.Acks; 103114184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" waiting for acks "); 103214184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(tbe.NumPendingAcks); 103314184Sgabeblack@google.com } 103414184Sgabeblack@google.com } 103514184Sgabeblack@google.com 103614184Sgabeblack@google.com action(tr_allocateTBE, "tr", desc="allocate TBE Entry for Region inv") { 103714184Sgabeblack@google.com check_allocate(TBEs); 103814184Sgabeblack@google.com TBEs.allocate(address); 103914184Sgabeblack@google.com set_tbe(TBEs.lookup(address)); 104014184Sgabeblack@google.com tbe.NumPendingAcks := 0; 104114184Sgabeblack@google.com } 104214184Sgabeblack@google.com 104314184Sgabeblack@google.com action(dt_deallocateTBE, "dt", desc="deallocate TBE Entry") { 104414184Sgabeblack@google.com TBEs.deallocate(address); 104514184Sgabeblack@google.com unset_tbe(); 104614184Sgabeblack@google.com } 104714184Sgabeblack@google.com 104814184Sgabeblack@google.com action(wdp_writeBackDataPrivate, "wdp", desc="Write back data if needed") { 104914184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 105014184Sgabeblack@google.com if (in_msg.Type == CoherenceRequestType:WriteThrough) { 105114184Sgabeblack@google.com tbe.DataBlkAux := getDirectoryEntry(address).DataBlk; 105214184Sgabeblack@google.com tbe.DataBlkAux.copyPartial(in_msg.DataBlk,in_msg.writeMask); 105314184Sgabeblack@google.com getDirectoryEntry(address).DataBlk := tbe.DataBlkAux; 105414184Sgabeblack@google.com } else{ 105514184Sgabeblack@google.com assert(in_msg.Type == CoherenceRequestType:Atomic); 105614184Sgabeblack@google.com tbe.DataBlkAux.atomicPartial(getDirectoryEntry(address).DataBlk,in_msg.writeMask); 105714184Sgabeblack@google.com getDirectoryEntry(address).DataBlk := tbe.DataBlkAux; 105814184Sgabeblack@google.com } 105914184Sgabeblack@google.com } 106014184Sgabeblack@google.com } 106114184Sgabeblack@google.com 106214184Sgabeblack@google.com action(wd_writeBackData, "wd", desc="Write back data if needed") { 106314184Sgabeblack@google.com if (tbe.wtData) { 106414184Sgabeblack@google.com DataBlock tmp := getDirectoryEntry(address).DataBlk; 106514184Sgabeblack@google.com tmp.copyPartial(tbe.DataBlk,tbe.writeMask); 106614184Sgabeblack@google.com tbe.DataBlk := tmp; 106714184Sgabeblack@google.com getDirectoryEntry(address).DataBlk := tbe.DataBlk; 106814184Sgabeblack@google.com } else if (tbe.atomicData) { 106914184Sgabeblack@google.com tbe.DataBlk.atomicPartial(getDirectoryEntry(address).DataBlk,tbe.writeMask); 107014184Sgabeblack@google.com getDirectoryEntry(address).DataBlk := tbe.DataBlk; 107114184Sgabeblack@google.com } else if (tbe.Dirty == true) { 107214184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" Wrote data back "); 107314184Sgabeblack@google.com getDirectoryEntry(address).DataBlk := tbe.DataBlk; 107414184Sgabeblack@google.com } 107514184Sgabeblack@google.com } 107614184Sgabeblack@google.com 107714184Sgabeblack@google.com action(wdi_writeBackDataInv, "wdi", desc="Write back inv data if needed") { 107814184Sgabeblack@google.com // Kind of opposite from above...? 107914184Sgabeblack@google.com if (tbe.Dirty == true) { 108014184Sgabeblack@google.com getDirectoryEntry(address).DataBlk := tbe.DataBlk; 108114184Sgabeblack@google.com APPEND_TRANSITION_COMMENT("Writing dirty data to dir"); 108214184Sgabeblack@google.com DPRINTF(RubySlicc, "Data %s: %s\n", address, tbe.DataBlk); 108314184Sgabeblack@google.com } else { 108414184Sgabeblack@google.com APPEND_TRANSITION_COMMENT("NOT!!! Writing dirty data to dir"); 108514184Sgabeblack@google.com } 108614184Sgabeblack@google.com } 108714184Sgabeblack@google.com 108814184Sgabeblack@google.com action(wdt_writeBackDataInvNoTBE, "wdt", desc="Write back inv data if needed no TBE") { 108914184Sgabeblack@google.com // Kind of opposite from above...? 109014184Sgabeblack@google.com peek(responseNetwork_in, ResponseMsg) { 109114184Sgabeblack@google.com if (in_msg.Dirty == true) { 109214184Sgabeblack@google.com getDirectoryEntry(address).DataBlk := in_msg.DataBlk; 109314184Sgabeblack@google.com APPEND_TRANSITION_COMMENT("Writing dirty data to dir"); 109414184Sgabeblack@google.com DPRINTF(RubySlicc, "Data %s: %s\n", address, in_msg.DataBlk); 109514184Sgabeblack@google.com } else { 109614184Sgabeblack@google.com APPEND_TRANSITION_COMMENT("NOT!!! Writing dirty data to dir"); 109714184Sgabeblack@google.com } 109814184Sgabeblack@google.com } 109914184Sgabeblack@google.com } 110014184Sgabeblack@google.com 110114184Sgabeblack@google.com action(mt_writeMemDataToTBE, "mt", desc="write Mem data to TBE") { 110214184Sgabeblack@google.com peek(memQueue_in, MemoryMsg) { 110314184Sgabeblack@google.com if (tbe.Dirty == false) { 110414184Sgabeblack@google.com tbe.DataBlk := getDirectoryEntry(address).DataBlk; 110514184Sgabeblack@google.com } 110614184Sgabeblack@google.com tbe.MemData := true; 110714184Sgabeblack@google.com } 110814184Sgabeblack@google.com } 110914184Sgabeblack@google.com 111014184Sgabeblack@google.com action(ml_writeL3DataToTBE, "ml", desc="write L3 data to TBE") { 111114184Sgabeblack@google.com assert(tbe.Dirty == false); 111214184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(address)); 111314184Sgabeblack@google.com tbe.DataBlk := entry.DataBlk; 111414184Sgabeblack@google.com tbe.LastSender := entry.LastSender; 111514184Sgabeblack@google.com tbe.L3Hit := true; 111614184Sgabeblack@google.com tbe.MemData := true; 111714184Sgabeblack@google.com } 111814184Sgabeblack@google.com 111914184Sgabeblack@google.com action(y_writeProbeDataToTBE, "y", desc="write Probe Data to TBE") { 112014184Sgabeblack@google.com peek(responseNetwork_in, ResponseMsg) { 112114184Sgabeblack@google.com if (in_msg.Dirty) { 112214184Sgabeblack@google.com DPRINTF(RubySlicc, "Got dirty data for %s from %s\n", address, in_msg.Sender); 112314184Sgabeblack@google.com DPRINTF(RubySlicc, "Data is %s\n", in_msg.DataBlk); 112414184Sgabeblack@google.com if (tbe.wtData) { 112514184Sgabeblack@google.com DataBlock tmp := in_msg.DataBlk; 112614184Sgabeblack@google.com tmp.copyPartial(tbe.DataBlk,tbe.writeMask); 112714184Sgabeblack@google.com tbe.DataBlk := tmp; 112814184Sgabeblack@google.com } else if (tbe.Dirty) { 112914184Sgabeblack@google.com if(tbe.atomicData == false && tbe.wtData == false) { 113014184Sgabeblack@google.com DPRINTF(RubySlicc, "Got double data for %s from %s\n", address, in_msg.Sender); 113114184Sgabeblack@google.com assert(tbe.DataBlk == in_msg.DataBlk); // in case of double data 113214184Sgabeblack@google.com } 113314184Sgabeblack@google.com } else { 113414184Sgabeblack@google.com tbe.DataBlk := in_msg.DataBlk; 113514184Sgabeblack@google.com tbe.Dirty := in_msg.Dirty; 113614184Sgabeblack@google.com tbe.LastSender := in_msg.Sender; 113714184Sgabeblack@google.com } 113814184Sgabeblack@google.com } 113914184Sgabeblack@google.com if (in_msg.Hit) { 114014184Sgabeblack@google.com tbe.Cached := true; 114114184Sgabeblack@google.com } 114214184Sgabeblack@google.com } 114314184Sgabeblack@google.com } 114414184Sgabeblack@google.com 114514184Sgabeblack@google.com action(yc_writeCPUDataToTBE, "yc", desc="write CPU Data to TBE") { 114614184Sgabeblack@google.com peek(responseNetwork_in, ResponseMsg) { 114714184Sgabeblack@google.com if (in_msg.Dirty) { 114814184Sgabeblack@google.com DPRINTF(RubySlicc, "Got dirty data for %s from %s\n", address, in_msg.Sender); 114914184Sgabeblack@google.com DPRINTF(RubySlicc, "Data is %s\n", in_msg.DataBlk); 115014184Sgabeblack@google.com if (tbe.Dirty) { 115114184Sgabeblack@google.com DPRINTF(RubySlicc, "Got double data for %s from %s\n", address, in_msg.Sender); 115214184Sgabeblack@google.com assert(tbe.DataBlk == in_msg.DataBlk); // in case of double data 115314184Sgabeblack@google.com } 115414184Sgabeblack@google.com tbe.DataBlk := in_msg.DataBlk; 115514184Sgabeblack@google.com tbe.Dirty := false; 115614184Sgabeblack@google.com tbe.LastSender := in_msg.Sender; 115714184Sgabeblack@google.com } 115814184Sgabeblack@google.com } 115914184Sgabeblack@google.com } 116014184Sgabeblack@google.com 116114184Sgabeblack@google.com action(x_decrementAcks, "x", desc="decrement Acks pending") { 116214184Sgabeblack@google.com if (tbe.NumPendingAcks > 0) { 116314184Sgabeblack@google.com tbe.NumPendingAcks := tbe.NumPendingAcks - 1; 116414184Sgabeblack@google.com } else { 116514184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" Double ack! "); 116614184Sgabeblack@google.com } 116714184Sgabeblack@google.com assert(tbe.NumPendingAcks >= 0); 116814184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" Acks remaining: "); 116914184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(tbe.NumPendingAcks); 117014184Sgabeblack@google.com } 117114184Sgabeblack@google.com 117214184Sgabeblack@google.com action(o_checkForCompletion, "o", desc="check for ack completion") { 117314184Sgabeblack@google.com if (tbe.NumPendingAcks == 0 && tbe.TriggeredAcksComplete == false) { 117414184Sgabeblack@google.com enqueue(triggerQueue_out, TriggerMsg, 1) { 117514184Sgabeblack@google.com out_msg.addr := address; 117614184Sgabeblack@google.com out_msg.Type := TriggerType:AcksComplete; 117714184Sgabeblack@google.com } 117814184Sgabeblack@google.com tbe.TriggeredAcksComplete := true; 117914184Sgabeblack@google.com } 118014184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" Check: Acks remaining: "); 118114184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(tbe.NumPendingAcks); 118214184Sgabeblack@google.com } 118314184Sgabeblack@google.com 118414184Sgabeblack@google.com action(ont_checkForCompletionNoTrigger, "ont", desc="check for ack completion, no trigger") { 118514184Sgabeblack@google.com if (tbe.NumPendingAcks == 0 && tbe.TriggeredAcksComplete == false) { 118614184Sgabeblack@google.com tbe.TriggeredAcksComplete := true; 118714184Sgabeblack@google.com } 118814184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" Check: Acks remaining: "); 118914184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(tbe.NumPendingAcks); 119014184Sgabeblack@google.com } 119114184Sgabeblack@google.com 119214184Sgabeblack@google.com action(rvp_removeVicDirtyIgnore, "rvp", desc="Remove ignored core") { 119314184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 119414184Sgabeblack@google.com getDirectoryEntry(address).VicDirtyIgnore.remove(in_msg.Requestor); 119514184Sgabeblack@google.com } 119614184Sgabeblack@google.com } 119714184Sgabeblack@google.com 119814184Sgabeblack@google.com action(rv_removeVicDirtyIgnore, "rv", desc="Remove ignored core") { 119914184Sgabeblack@google.com peek(regDir_in, CPURequestMsg) { 120014184Sgabeblack@google.com getDirectoryEntry(address).VicDirtyIgnore.remove(in_msg.Requestor); 120114184Sgabeblack@google.com } 120214184Sgabeblack@google.com } 120314184Sgabeblack@google.com 120414184Sgabeblack@google.com action(r_sendRequestToRegionDir, "r", desc="send request to Region Directory") { 120514184Sgabeblack@google.com peek(requestNetwork_in, CPURequestMsg) { 120614184Sgabeblack@google.com enqueue(requestNetworkReg_out, CPURequestMsg, 1) { 120714184Sgabeblack@google.com out_msg.addr := address; 120814184Sgabeblack@google.com out_msg.Type := in_msg.Type; 120914184Sgabeblack@google.com out_msg.Requestor := in_msg.Requestor; 121014184Sgabeblack@google.com out_msg.Destination.add(mapAddressToMachine(address, MachineType:RegionDir)); 121114184Sgabeblack@google.com out_msg.Shared := in_msg.Shared; 121214184Sgabeblack@google.com out_msg.MessageSize := in_msg.MessageSize; 121314184Sgabeblack@google.com DPRINTF(RubySlicc, "out dest: %s\n", mapAddressToMachine(address, MachineType:RegionDir)); 121414184Sgabeblack@google.com } 121514184Sgabeblack@google.com } 121614184Sgabeblack@google.com } 121714184Sgabeblack@google.com 121814184Sgabeblack@google.com action(ai_ackInvalidate, "ai", desc="Ack to let the reg-dir know that the inv is ordered") { 121914184Sgabeblack@google.com peek(regBuf_in, CPURequestMsg) { 122014184Sgabeblack@google.com enqueue(regAckNetwork_out, UnblockMsg, 1) { 122114184Sgabeblack@google.com out_msg.addr := address; 122214184Sgabeblack@google.com out_msg.Destination.add(in_msg.Requestor); 122314184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Control; 122414184Sgabeblack@google.com DPRINTF(RubySlicc, "ai out_msg: %s\n", out_msg); 122514184Sgabeblack@google.com } 122614184Sgabeblack@google.com } 122714184Sgabeblack@google.com } 122814184Sgabeblack@google.com 122914184Sgabeblack@google.com action(aic_ackInvalidate, "aic", desc="Ack to let the reg-dir know that the inv is ordered") { 123014184Sgabeblack@google.com peek(responseNetwork_in, ResponseMsg) { 123114184Sgabeblack@google.com if (in_msg.NoAckNeeded == false) { 123214184Sgabeblack@google.com enqueue(regAckNetwork_out, UnblockMsg, 1) { 123314184Sgabeblack@google.com out_msg.addr := address; 123414184Sgabeblack@google.com if (machineIDToMachineType(in_msg.Sender) == MachineType:CorePair) { 123514184Sgabeblack@google.com out_msg.Destination.add(createMachineID(MachineType:RegionBuffer, intToID(0))); 123614184Sgabeblack@google.com } else { 123714184Sgabeblack@google.com out_msg.Destination.add(createMachineID(MachineType:RegionBuffer, intToID(1))); 123814184Sgabeblack@google.com } 123914184Sgabeblack@google.com out_msg.MessageSize := MessageSizeType:Response_Control; 124014184Sgabeblack@google.com DPRINTF(RubySlicc, "ai out_msg: %s\n", out_msg); 124114184Sgabeblack@google.com out_msg.wasValid := in_msg.isValid; 124214184Sgabeblack@google.com } 124314184Sgabeblack@google.com } 124414184Sgabeblack@google.com } 124514184Sgabeblack@google.com } 124614184Sgabeblack@google.com 124714184Sgabeblack@google.com action(al_allocateL3Block, "al", desc="allocate the L3 block on WB") { 124814184Sgabeblack@google.com peek(responseNetwork_in, ResponseMsg) { 124914184Sgabeblack@google.com if (L3CacheMemory.isTagPresent(address)) { 125014184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(address)); 125114184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" al wrote data to L3 (hit) "); 125214184Sgabeblack@google.com entry.DataBlk := in_msg.DataBlk; 125314184Sgabeblack@google.com entry.LastSender := in_msg.Sender; 125414184Sgabeblack@google.com } else { 125514184Sgabeblack@google.com if (L3CacheMemory.cacheAvail(address) == false) { 125614184Sgabeblack@google.com Addr victim := L3CacheMemory.cacheProbe(address); 125714184Sgabeblack@google.com CacheEntry victim_entry := static_cast(CacheEntry, "pointer", 125814184Sgabeblack@google.com L3CacheMemory.lookup(victim)); 125914184Sgabeblack@google.com queueMemoryWrite(machineID, victim, to_memory_controller_latency, 126014184Sgabeblack@google.com victim_entry.DataBlk); 126114184Sgabeblack@google.com L3CacheMemory.deallocate(victim); 126214184Sgabeblack@google.com } 126314184Sgabeblack@google.com assert(L3CacheMemory.cacheAvail(address)); 126414184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.allocate(address, new CacheEntry)); 126514184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" al wrote data to L3 "); 126614184Sgabeblack@google.com entry.DataBlk := in_msg.DataBlk; 126714184Sgabeblack@google.com entry.LastSender := in_msg.Sender; 126814184Sgabeblack@google.com } 126914184Sgabeblack@google.com } 127014184Sgabeblack@google.com } 127114184Sgabeblack@google.com 127214184Sgabeblack@google.com action(alwt_allocateL3BlockOnWT, "alwt", desc="allocate the L3 block on WT") { 127314184Sgabeblack@google.com if ((tbe.wtData || tbe.atomicData) && useL3OnWT) { 127414184Sgabeblack@google.com if (L3CacheMemory.isTagPresent(address)) { 127514184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(address)); 127614184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" al wrote data to L3 (hit) "); 127714184Sgabeblack@google.com entry.DataBlk := tbe.DataBlk; 127814184Sgabeblack@google.com entry.LastSender := tbe.LastSender; 127914184Sgabeblack@google.com } else { 128014184Sgabeblack@google.com if (L3CacheMemory.cacheAvail(address) == false) { 128114184Sgabeblack@google.com Addr victim := L3CacheMemory.cacheProbe(address); 128214184Sgabeblack@google.com CacheEntry victim_entry := static_cast(CacheEntry, "pointer", 128314184Sgabeblack@google.com L3CacheMemory.lookup(victim)); 128414184Sgabeblack@google.com queueMemoryWrite(machineID, victim, to_memory_controller_latency, 128514184Sgabeblack@google.com victim_entry.DataBlk); 128614184Sgabeblack@google.com L3CacheMemory.deallocate(victim); 128714184Sgabeblack@google.com } 128814184Sgabeblack@google.com assert(L3CacheMemory.cacheAvail(address)); 128914184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.allocate(address, new CacheEntry)); 129014184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" al wrote data to L3 "); 129114184Sgabeblack@google.com entry.DataBlk := tbe.DataBlk; 129214184Sgabeblack@google.com entry.LastSender := tbe.LastSender; 129314184Sgabeblack@google.com } 129414184Sgabeblack@google.com } 129514184Sgabeblack@google.com } 129614184Sgabeblack@google.com 129714184Sgabeblack@google.com action(ali_allocateL3Block, "ali", desc="allocate the L3 block on ForceInv") { 129814184Sgabeblack@google.com if (tbe.Dirty == true) { 129914184Sgabeblack@google.com if (L3CacheMemory.isTagPresent(address)) { 130014184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(address)); 130114184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" al wrote data to L3 (hit) "); 130214184Sgabeblack@google.com entry.DataBlk := tbe.DataBlk; 130314184Sgabeblack@google.com entry.LastSender := tbe.LastSender; 130414184Sgabeblack@google.com } else { 130514184Sgabeblack@google.com if (L3CacheMemory.cacheAvail(address) == false) { 130614184Sgabeblack@google.com Addr victim := L3CacheMemory.cacheProbe(address); 130714184Sgabeblack@google.com CacheEntry victim_entry := static_cast(CacheEntry, "pointer", 130814184Sgabeblack@google.com L3CacheMemory.lookup(victim)); 130914184Sgabeblack@google.com queueMemoryWrite(machineID, victim, to_memory_controller_latency, 131014184Sgabeblack@google.com victim_entry.DataBlk); 131114184Sgabeblack@google.com L3CacheMemory.deallocate(victim); 131214184Sgabeblack@google.com } 131314184Sgabeblack@google.com assert(L3CacheMemory.cacheAvail(address)); 131414184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.allocate(address, new CacheEntry)); 131514184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" al wrote data to L3 "); 131614184Sgabeblack@google.com entry.DataBlk := tbe.DataBlk; 131714184Sgabeblack@google.com entry.LastSender := tbe.LastSender; 131814184Sgabeblack@google.com } 131914184Sgabeblack@google.com } 132014184Sgabeblack@google.com } 132114184Sgabeblack@google.com 132214184Sgabeblack@google.com action(ali_allocateL3BlockNoTBE, "alt", desc="allocate the L3 block on ForceInv no TBE") { 132314184Sgabeblack@google.com peek(responseNetwork_in, ResponseMsg) { 132414184Sgabeblack@google.com if (in_msg.Dirty) { 132514184Sgabeblack@google.com if (L3CacheMemory.isTagPresent(address)) { 132614184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.lookup(address)); 132714184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" ali wrote data to L3 (hit) "); 132814184Sgabeblack@google.com entry.DataBlk := in_msg.DataBlk; 132914184Sgabeblack@google.com entry.LastSender := in_msg.Sender; 133014184Sgabeblack@google.com } else { 133114184Sgabeblack@google.com if (L3CacheMemory.cacheAvail(address) == false) { 133214184Sgabeblack@google.com Addr victim := L3CacheMemory.cacheProbe(address); 133314184Sgabeblack@google.com CacheEntry victim_entry := static_cast(CacheEntry, "pointer", 133414184Sgabeblack@google.com L3CacheMemory.lookup(victim)); 133514184Sgabeblack@google.com queueMemoryWrite(machineID, victim, to_memory_controller_latency, 133614184Sgabeblack@google.com victim_entry.DataBlk); 133714184Sgabeblack@google.com L3CacheMemory.deallocate(victim); 133814184Sgabeblack@google.com } 133914184Sgabeblack@google.com assert(L3CacheMemory.cacheAvail(address)); 134014184Sgabeblack@google.com CacheEntry entry := static_cast(CacheEntry, "pointer", L3CacheMemory.allocate(address, new CacheEntry)); 134114184Sgabeblack@google.com APPEND_TRANSITION_COMMENT(" ali wrote data to L3 "); 134214184Sgabeblack@google.com entry.DataBlk := in_msg.DataBlk; 134314184Sgabeblack@google.com entry.LastSender := in_msg.Sender; 134414184Sgabeblack@google.com } 134514184Sgabeblack@google.com } 134614184Sgabeblack@google.com } 134714184Sgabeblack@google.com } 134814184Sgabeblack@google.com 134914184Sgabeblack@google.com action(dl_deallocateL3, "dl", desc="deallocate the L3 block") { 135014184Sgabeblack@google.com L3CacheMemory.deallocate(address); 135114184Sgabeblack@google.com } 135214184Sgabeblack@google.com 135314184Sgabeblack@google.com action(p_popRequestQueue, "p", desc="pop request queue") { 135414184Sgabeblack@google.com requestNetwork_in.dequeue(clockEdge()); 135514184Sgabeblack@google.com } 135614184Sgabeblack@google.com 135714184Sgabeblack@google.com action(prd_popRegionQueue, "prd", desc="pop request queue") { 135814184Sgabeblack@google.com regDir_in.dequeue(clockEdge()); 135914184Sgabeblack@google.com } 136014184Sgabeblack@google.com 136114184Sgabeblack@google.com action(prb_popRegionBufQueue, "prb", desc="pop request queue") { 136214184Sgabeblack@google.com regBuf_in.dequeue(clockEdge()); 136314184Sgabeblack@google.com } 136414184Sgabeblack@google.com 136514184Sgabeblack@google.com action(pr_popResponseQueue, "pr", desc="pop response queue") { 136614184Sgabeblack@google.com responseNetwork_in.dequeue(clockEdge()); 136714184Sgabeblack@google.com } 136814184Sgabeblack@google.com 136914184Sgabeblack@google.com action(pm_popMemQueue, "pm", desc="pop mem queue") { 137014184Sgabeblack@google.com memQueue_in.dequeue(clockEdge()); 137114184Sgabeblack@google.com } 137214184Sgabeblack@google.com 137314184Sgabeblack@google.com action(pt_popTriggerQueue, "pt", desc="pop trigger queue") { 137414184Sgabeblack@google.com triggerQueue_in.dequeue(clockEdge()); 137514184Sgabeblack@google.com } 137614184Sgabeblack@google.com 137714184Sgabeblack@google.com action(ptl_popTriggerQueue, "ptl", desc="pop L3 trigger queue") { 137814184Sgabeblack@google.com L3TriggerQueue_in.dequeue(clockEdge()); 137914184Sgabeblack@google.com } 138014184Sgabeblack@google.com 138114184Sgabeblack@google.com action(pu_popUnblockQueue, "pu", desc="pop unblock queue") { 138214184Sgabeblack@google.com unblockNetwork_in.dequeue(clockEdge()); 138314184Sgabeblack@google.com } 138414184Sgabeblack@google.com 138514184Sgabeblack@google.com action(yy_recycleResponseQueue, "yy", desc="recycle response queue") { 138614184Sgabeblack@google.com responseNetwork_in.recycle(clockEdge(), cyclesToTicks(recycle_latency)); 138714184Sgabeblack@google.com } 138814184Sgabeblack@google.com 138914184Sgabeblack@google.com action(ww_stallAndWaitRegRequestQueue, "ww", desc="recycle region dir request queue") { 139014184Sgabeblack@google.com stall_and_wait(regDir_in, address); 139114184Sgabeblack@google.com } 139214184Sgabeblack@google.com 139314184Sgabeblack@google.com action(st_stallAndWaitRequest, "st", desc="Stall and wait on the address") { 139414184Sgabeblack@google.com stall_and_wait(requestNetwork_in, address); 139514184Sgabeblack@google.com } 139614184Sgabeblack@google.com 139714184Sgabeblack@google.com action(wa_wakeUpDependents, "wa", desc="Wake up any requests waiting for this address") { 139814184Sgabeblack@google.com wakeUpBuffers(address); 139914184Sgabeblack@google.com } 140014184Sgabeblack@google.com 140114184Sgabeblack@google.com action(wa_wakeUpAllDependents, "waa", desc="Wake up any requests waiting for this region") { 140214184Sgabeblack@google.com wakeUpAllBuffers(); 140314184Sgabeblack@google.com } 140414184Sgabeblack@google.com 140514184Sgabeblack@google.com action(z_stall, "z", desc="...") { 140614184Sgabeblack@google.com } 140714184Sgabeblack@google.com 140814184Sgabeblack@google.com // TRANSITIONS 140914184Sgabeblack@google.com 141014184Sgabeblack@google.com // transitions from U 141114184Sgabeblack@google.com 141214184Sgabeblack@google.com transition({BR, BW, BL, BI, BS_M, BM_M, B_M, BP, BS_PM, BM_PM, B_PM, BS_Pm, BM_Pm, B_Pm, B}, {Inv, Downgrade}) { 141314184Sgabeblack@google.com ww_stallAndWaitRegRequestQueue; 141414184Sgabeblack@google.com } 141514184Sgabeblack@google.com 141614184Sgabeblack@google.com transition(U, Inv, BI){L3TagArrayRead} { 141714184Sgabeblack@google.com tr_allocateTBE; 141814184Sgabeblack@google.com dcr_probeInvCoreData; // only need to invalidate sharers 141914184Sgabeblack@google.com ai_ackInvalidate; 142014184Sgabeblack@google.com prb_popRegionBufQueue; 142114184Sgabeblack@google.com } 142214184Sgabeblack@google.com 142314184Sgabeblack@google.com transition(U, Downgrade, BI){L3TagArrayRead} { 142414184Sgabeblack@google.com tr_allocateTBE; 142514184Sgabeblack@google.com ddr_probeDownCoreData; // only need to invalidate sharers 142614184Sgabeblack@google.com ai_ackInvalidate; 142714184Sgabeblack@google.com prb_popRegionBufQueue; 142814184Sgabeblack@google.com } 142914184Sgabeblack@google.com 143014184Sgabeblack@google.com // The next 2 transistions are needed in the event that an invalidation 143114184Sgabeblack@google.com // is waiting for its ack from the core, but the event makes it through 143214184Sgabeblack@google.com // the region directory before the acks. This wouldn't be needed if 143314184Sgabeblack@google.com // we waited to ack the region dir until the directory got all the acks 143414184Sgabeblack@google.com transition({BR, BW, BI, BL, BS_M, BM_M, B_M, BP, BS_PM, BM_PM, B_PM, BS_Pm, BM_Pm, B_Pm, B}, {RdBlkS, RdBlkM, RdBlk, WriteThrough, Atomic}) { 143514184Sgabeblack@google.com ww_stallAndWaitRegRequestQueue; 143614184Sgabeblack@google.com } 143714184Sgabeblack@google.com 143814184Sgabeblack@google.com transition({BR, BW, BI, BL, BS_M, BM_M, B_M, BS_PM, BM_PM, B_PM, B, BS_Pm_BL, BM_Pm_BL, B_Pm_BL, BP_BL, BS_Pm_B, BM_Pm_B, B_Pm_B, BP_B}, {RdBlkSP, RdBlkMP, RdBlkP}) { 143914184Sgabeblack@google.com st_stallAndWaitRequest; 144014184Sgabeblack@google.com } 144114184Sgabeblack@google.com 144214184Sgabeblack@google.com transition({BR, BW, BI, BL, BS_M, BM_M, B_M, BS_PM, BM_PM, B_PM, B, BS_Pm_BL, BM_Pm_BL, B_Pm_BL, BP_BL, BS_Pm_B, BM_Pm_B, B_Pm_B, BP_B}, {WriteThroughP,AtomicP}) { 144314184Sgabeblack@google.com st_stallAndWaitRequest; 144414184Sgabeblack@google.com } 144514184Sgabeblack@google.com 144614184Sgabeblack@google.com transition(U, {RdBlkS}, BS_PM) {L3TagArrayRead} { 144714184Sgabeblack@google.com t_allocateTBE; 144814184Sgabeblack@google.com l_queueMemRdReq; 144914184Sgabeblack@google.com sa_setAcks; 145014184Sgabeblack@google.com o_checkForCompletion; 145114184Sgabeblack@google.com ra_ackRegionDir; 145214184Sgabeblack@google.com prd_popRegionQueue; 145314184Sgabeblack@google.com } 145414184Sgabeblack@google.com 145514184Sgabeblack@google.com transition(U, WriteThrough, BM_PM){L3TagArrayRead} { 145614184Sgabeblack@google.com t_allocateTBE; 145714184Sgabeblack@google.com w_sendResponseWBAck; 145814184Sgabeblack@google.com l_queueMemRdReq; 145914184Sgabeblack@google.com sa_setAcks; 146014184Sgabeblack@google.com o_checkForCompletion; 146114184Sgabeblack@google.com ra_ackRegionDir; 146214184Sgabeblack@google.com prd_popRegionQueue; 146314184Sgabeblack@google.com } 146414184Sgabeblack@google.com 146514184Sgabeblack@google.com transition(U, {RdBlkM,Atomic}, BM_PM){L3TagArrayRead} { 146614184Sgabeblack@google.com t_allocateTBE; 146714184Sgabeblack@google.com l_queueMemRdReq; 146814184Sgabeblack@google.com sa_setAcks; 146914184Sgabeblack@google.com o_checkForCompletion; 147014184Sgabeblack@google.com ra_ackRegionDir; 147114184Sgabeblack@google.com prd_popRegionQueue; 147214184Sgabeblack@google.com } 147314184Sgabeblack@google.com 147414184Sgabeblack@google.com transition(U, RdBlk, B_PM){L3TagArrayRead} { 147514184Sgabeblack@google.com t_allocateTBE; 147614184Sgabeblack@google.com l_queueMemRdReq; 147714184Sgabeblack@google.com sa_setAcks; 147814184Sgabeblack@google.com o_checkForCompletion; 147914184Sgabeblack@google.com ra_ackRegionDir; 148014184Sgabeblack@google.com prd_popRegionQueue; 148114184Sgabeblack@google.com } 148214184Sgabeblack@google.com 148314184Sgabeblack@google.com transition(U, {RdBlkSP}, BS_M) {L3TagArrayRead} { 148414184Sgabeblack@google.com tp_allocateTBEP; 148514184Sgabeblack@google.com lrp_queueMemRdReqP; 148614184Sgabeblack@google.com p_popRequestQueue; 148714184Sgabeblack@google.com } 148814184Sgabeblack@google.com 148914184Sgabeblack@google.com transition(U, WriteThroughP, BM_M) {L3TagArrayRead} { 149014184Sgabeblack@google.com tp_allocateTBEP; 149114184Sgabeblack@google.com wp_sendResponseWBAckP; 149214184Sgabeblack@google.com lrp_queueMemRdReqP; 149314184Sgabeblack@google.com p_popRequestQueue; 149414184Sgabeblack@google.com } 149514184Sgabeblack@google.com 149614184Sgabeblack@google.com transition(U, {RdBlkMP,AtomicP}, BM_M) {L3TagArrayRead} { 149714184Sgabeblack@google.com tp_allocateTBEP; 149814184Sgabeblack@google.com lrp_queueMemRdReqP; 149914184Sgabeblack@google.com p_popRequestQueue; 150014184Sgabeblack@google.com } 150114184Sgabeblack@google.com 150214184Sgabeblack@google.com transition(U, RdBlkP, B_M) {L3TagArrayRead} { 150314184Sgabeblack@google.com tp_allocateTBEP; 150414184Sgabeblack@google.com lrp_queueMemRdReqP; 150514184Sgabeblack@google.com p_popRequestQueue; 150614184Sgabeblack@google.com } 150714184Sgabeblack@google.com 150814184Sgabeblack@google.com transition(U, VicDirtyP, BL) {L3TagArrayRead} { 150914184Sgabeblack@google.com tp_allocateTBEP; 151014184Sgabeblack@google.com wp_sendResponseWBAckP; 151114184Sgabeblack@google.com p_popRequestQueue; 151214184Sgabeblack@google.com } 151314184Sgabeblack@google.com 151414184Sgabeblack@google.com transition(U, VicCleanP, BL) {L3TagArrayRead} { 151514184Sgabeblack@google.com tp_allocateTBEP; 151614184Sgabeblack@google.com wp_sendResponseWBAckP; 151714184Sgabeblack@google.com p_popRequestQueue; 151814184Sgabeblack@google.com } 151914184Sgabeblack@google.com 152014184Sgabeblack@google.com transition(BM_Pm, RdBlkSP, BM_Pm_B) {L3DataArrayWrite} { 152114184Sgabeblack@google.com sb_sendResponseSBypass; 152214184Sgabeblack@google.com p_popRequestQueue; 152314184Sgabeblack@google.com } 152414184Sgabeblack@google.com 152514184Sgabeblack@google.com transition(BS_Pm, RdBlkSP, BS_Pm_B) {L3DataArrayWrite} { 152614184Sgabeblack@google.com sb_sendResponseSBypass; 152714184Sgabeblack@google.com p_popRequestQueue; 152814184Sgabeblack@google.com } 152914184Sgabeblack@google.com 153014184Sgabeblack@google.com transition(B_Pm, RdBlkSP, B_Pm_B) {L3DataArrayWrite} { 153114184Sgabeblack@google.com sb_sendResponseSBypass; 153214184Sgabeblack@google.com p_popRequestQueue; 153314184Sgabeblack@google.com } 153414184Sgabeblack@google.com 153514184Sgabeblack@google.com transition(BP, RdBlkSP, BP_B) {L3DataArrayWrite} { 153614184Sgabeblack@google.com sb_sendResponseSBypass; 153714184Sgabeblack@google.com p_popRequestQueue; 153814184Sgabeblack@google.com } 153914184Sgabeblack@google.com 154014184Sgabeblack@google.com transition(BM_Pm, RdBlkMP, BM_Pm_B) {L3DataArrayWrite} { 154114184Sgabeblack@google.com mb_sendResponseMBypass; 154214184Sgabeblack@google.com p_popRequestQueue; 154314184Sgabeblack@google.com } 154414184Sgabeblack@google.com 154514184Sgabeblack@google.com transition(BS_Pm, RdBlkMP, BS_Pm_B) {L3DataArrayWrite} { 154614184Sgabeblack@google.com mb_sendResponseMBypass; 154714184Sgabeblack@google.com p_popRequestQueue; 154814184Sgabeblack@google.com } 154914184Sgabeblack@google.com 155014184Sgabeblack@google.com transition(B_Pm, RdBlkMP, B_Pm_B) {L3DataArrayWrite} { 155114184Sgabeblack@google.com mb_sendResponseMBypass; 155214184Sgabeblack@google.com p_popRequestQueue; 155314184Sgabeblack@google.com } 155414184Sgabeblack@google.com 155514184Sgabeblack@google.com transition(BP, RdBlkMP, BP_B) {L3DataArrayWrite} { 155614184Sgabeblack@google.com mb_sendResponseMBypass; 155714184Sgabeblack@google.com p_popRequestQueue; 155814184Sgabeblack@google.com } 155914184Sgabeblack@google.com 156014184Sgabeblack@google.com transition(BM_Pm, {WriteThroughP,AtomicP}, BM_Pm_B) {L3DataArrayWrite} { 156114184Sgabeblack@google.com wdp_writeBackDataPrivate; 156214184Sgabeblack@google.com mbwt_sendResponseWriteThroughBypass; 156314184Sgabeblack@google.com p_popRequestQueue; 156414184Sgabeblack@google.com } 156514184Sgabeblack@google.com 156614184Sgabeblack@google.com transition(BS_Pm, {WriteThroughP,AtomicP}, BS_Pm_B) {L3DataArrayWrite} { 156714184Sgabeblack@google.com wdp_writeBackDataPrivate; 156814184Sgabeblack@google.com mbwt_sendResponseWriteThroughBypass; 156914184Sgabeblack@google.com p_popRequestQueue; 157014184Sgabeblack@google.com } 157114184Sgabeblack@google.com 157214184Sgabeblack@google.com transition(B_Pm, {WriteThroughP,AtomicP}, B_Pm_B) {L3DataArrayWrite} { 157314184Sgabeblack@google.com wdp_writeBackDataPrivate; 157414184Sgabeblack@google.com mbwt_sendResponseWriteThroughBypass; 157514184Sgabeblack@google.com p_popRequestQueue; 157614184Sgabeblack@google.com } 157714184Sgabeblack@google.com 157814184Sgabeblack@google.com transition(BP, {WriteThroughP,AtomicP}, BP_B) {L3DataArrayWrite} { 157914184Sgabeblack@google.com wdp_writeBackDataPrivate; 158014184Sgabeblack@google.com mbwt_sendResponseWriteThroughBypass; 158114184Sgabeblack@google.com p_popRequestQueue; 158214184Sgabeblack@google.com } 158314184Sgabeblack@google.com 158414184Sgabeblack@google.com transition(BM_Pm, RdBlkP, BM_Pm_B) {L3DataArrayWrite} { 158514184Sgabeblack@google.com esb_sendResponseESBypass; 158614184Sgabeblack@google.com p_popRequestQueue; 158714184Sgabeblack@google.com } 158814184Sgabeblack@google.com 158914184Sgabeblack@google.com transition(BS_Pm, RdBlkP, BS_Pm_B) {L3DataArrayWrite} { 159014184Sgabeblack@google.com esb_sendResponseESBypass; 159114184Sgabeblack@google.com p_popRequestQueue; 159214184Sgabeblack@google.com } 159314184Sgabeblack@google.com 159414184Sgabeblack@google.com transition(B_Pm, RdBlkP, B_Pm_B) {L3DataArrayWrite}{ 159514184Sgabeblack@google.com esb_sendResponseESBypass; 159614184Sgabeblack@google.com p_popRequestQueue; 159714184Sgabeblack@google.com } 159814184Sgabeblack@google.com 159914184Sgabeblack@google.com transition(BP, RdBlkP, BP_B) {L3DataArrayWrite}{ 160014184Sgabeblack@google.com esb_sendResponseESBypass; 160114184Sgabeblack@google.com p_popRequestQueue; 160214184Sgabeblack@google.com } 160314184Sgabeblack@google.com 160414184Sgabeblack@google.com transition(BM_Pm_B, CoreUnblock, BM_Pm) { 160514184Sgabeblack@google.com wa_wakeUpDependents; 160614184Sgabeblack@google.com pu_popUnblockQueue; 160714184Sgabeblack@google.com } 160814184Sgabeblack@google.com 160914184Sgabeblack@google.com transition(BS_Pm_B, CoreUnblock, BS_Pm) { 161014184Sgabeblack@google.com wa_wakeUpDependents; 161114184Sgabeblack@google.com pu_popUnblockQueue; 161214184Sgabeblack@google.com } 161314184Sgabeblack@google.com 161414184Sgabeblack@google.com transition(B_Pm_B, CoreUnblock, B_Pm) { 161514184Sgabeblack@google.com wa_wakeUpDependents; 161614184Sgabeblack@google.com pu_popUnblockQueue; 161714184Sgabeblack@google.com } 161814184Sgabeblack@google.com 161914184Sgabeblack@google.com transition(BP_B, CoreUnblock, BP) { 162014184Sgabeblack@google.com wa_wakeUpDependents; 162114184Sgabeblack@google.com pu_popUnblockQueue; 162214184Sgabeblack@google.com } 162314184Sgabeblack@google.com 162414184Sgabeblack@google.com transition(BM_Pm_B, UnblockWriteThrough, BM_Pm) { 162514184Sgabeblack@google.com wa_wakeUpDependents; 162614184Sgabeblack@google.com pt_popTriggerQueue; 162714184Sgabeblack@google.com } 162814184Sgabeblack@google.com 162914184Sgabeblack@google.com transition(BS_Pm_B, UnblockWriteThrough, BS_Pm) { 163014184Sgabeblack@google.com wa_wakeUpDependents; 163114184Sgabeblack@google.com pt_popTriggerQueue; 163214184Sgabeblack@google.com } 163314184Sgabeblack@google.com 163414184Sgabeblack@google.com transition(B_Pm_B, UnblockWriteThrough, B_Pm) { 163514184Sgabeblack@google.com wa_wakeUpDependents; 163614184Sgabeblack@google.com pt_popTriggerQueue; 163714184Sgabeblack@google.com } 163814184Sgabeblack@google.com 163914184Sgabeblack@google.com transition(BP_B, UnblockWriteThrough, BP) { 164014184Sgabeblack@google.com wa_wakeUpDependents; 164114184Sgabeblack@google.com pt_popTriggerQueue; 164214184Sgabeblack@google.com } 164314184Sgabeblack@google.com 164414184Sgabeblack@google.com transition(BM_Pm, VicDirtyP, BM_Pm_BL) { 164514184Sgabeblack@google.com wp_sendResponseWBAckP; 164614184Sgabeblack@google.com p_popRequestQueue; 164714184Sgabeblack@google.com } 164814184Sgabeblack@google.com 164914184Sgabeblack@google.com transition(BS_Pm, VicDirtyP, BS_Pm_BL) { 165014184Sgabeblack@google.com wp_sendResponseWBAckP; 165114184Sgabeblack@google.com p_popRequestQueue; 165214184Sgabeblack@google.com } 165314184Sgabeblack@google.com 165414184Sgabeblack@google.com transition(B_Pm, VicDirtyP, B_Pm_BL) { 165514184Sgabeblack@google.com wp_sendResponseWBAckP; 165614184Sgabeblack@google.com p_popRequestQueue; 165714184Sgabeblack@google.com } 165814184Sgabeblack@google.com 165914184Sgabeblack@google.com transition(BP, VicDirtyP, BP_BL) { 166014184Sgabeblack@google.com wp_sendResponseWBAckP; 166114184Sgabeblack@google.com p_popRequestQueue; 166214184Sgabeblack@google.com } 166314184Sgabeblack@google.com 166414184Sgabeblack@google.com transition(BM_Pm, VicCleanP, BM_Pm_BL) { 166514184Sgabeblack@google.com wp_sendResponseWBAckP; 166614184Sgabeblack@google.com p_popRequestQueue; 166714184Sgabeblack@google.com } 166814184Sgabeblack@google.com 166914184Sgabeblack@google.com transition(BS_Pm, VicCleanP, BS_Pm_BL) { 167014184Sgabeblack@google.com wp_sendResponseWBAckP; 167114184Sgabeblack@google.com p_popRequestQueue; 167214184Sgabeblack@google.com } 167314184Sgabeblack@google.com 167414184Sgabeblack@google.com transition(B_Pm, VicCleanP, B_Pm_BL) { 167514184Sgabeblack@google.com wp_sendResponseWBAckP; 167614184Sgabeblack@google.com p_popRequestQueue; 167714184Sgabeblack@google.com } 167814184Sgabeblack@google.com 167914184Sgabeblack@google.com transition(BP, VicCleanP, BP_BL) { 168014184Sgabeblack@google.com wp_sendResponseWBAckP; 168114184Sgabeblack@google.com p_popRequestQueue; 168214184Sgabeblack@google.com } 168314184Sgabeblack@google.com 168414184Sgabeblack@google.com transition(BM_Pm_BL, CPUData, BM_Pm) { 168514184Sgabeblack@google.com yc_writeCPUDataToTBE; 168614184Sgabeblack@google.com d_writeDataToMemory; 168714184Sgabeblack@google.com wa_wakeUpDependents; 168814184Sgabeblack@google.com pr_popResponseQueue; 168914184Sgabeblack@google.com } 169014184Sgabeblack@google.com 169114184Sgabeblack@google.com transition(BS_Pm_BL, CPUData, BS_Pm) { 169214184Sgabeblack@google.com yc_writeCPUDataToTBE; 169314184Sgabeblack@google.com d_writeDataToMemory; 169414184Sgabeblack@google.com wa_wakeUpDependents; 169514184Sgabeblack@google.com pr_popResponseQueue; 169614184Sgabeblack@google.com } 169714184Sgabeblack@google.com 169814184Sgabeblack@google.com transition(B_Pm_BL, CPUData, B_Pm) { 169914184Sgabeblack@google.com yc_writeCPUDataToTBE; 170014184Sgabeblack@google.com d_writeDataToMemory; 170114184Sgabeblack@google.com wa_wakeUpDependents; 170214184Sgabeblack@google.com pr_popResponseQueue; 170314184Sgabeblack@google.com } 170414184Sgabeblack@google.com 170514184Sgabeblack@google.com transition(BP_BL, CPUData, BP) { 170614184Sgabeblack@google.com yc_writeCPUDataToTBE; 170714184Sgabeblack@google.com d_writeDataToMemory; 170814184Sgabeblack@google.com wa_wakeUpDependents; 170914184Sgabeblack@google.com pr_popResponseQueue; 171014184Sgabeblack@google.com } 171114184Sgabeblack@google.com 171214184Sgabeblack@google.com transition({BR, BW, BL}, {VicDirtyP, VicCleanP}) { 171314184Sgabeblack@google.com st_stallAndWaitRequest; 171414184Sgabeblack@google.com } 171514184Sgabeblack@google.com 171614184Sgabeblack@google.com transition({BR, BW, BL}, {VicDirty, VicClean}) { 171714184Sgabeblack@google.com ww_stallAndWaitRegRequestQueue; 171814184Sgabeblack@google.com } 171914184Sgabeblack@google.com 172014184Sgabeblack@google.com transition(BL, CPUData, U) {L3TagArrayWrite, L3DataArrayWrite} { 172114184Sgabeblack@google.com dt_deallocateTBE; 172214184Sgabeblack@google.com d_writeDataToMemory; 172314184Sgabeblack@google.com al_allocateL3Block; 172414184Sgabeblack@google.com wa_wakeUpDependents; 172514184Sgabeblack@google.com pr_popResponseQueue; 172614184Sgabeblack@google.com } 172714184Sgabeblack@google.com 172814184Sgabeblack@google.com transition(BL, StaleWB, U) {L3TagArrayWrite} { 172914184Sgabeblack@google.com dt_deallocateTBE; 173014184Sgabeblack@google.com wa_wakeUpAllDependents; 173114184Sgabeblack@google.com pr_popResponseQueue; 173214184Sgabeblack@google.com } 173314184Sgabeblack@google.com 173414184Sgabeblack@google.com transition({BI, B, BS_M, BM_M, B_M, BP, BS_PM, BM_PM, B_PM, BS_Pm, BM_Pm, B_Pm, BS_Pm_BL, BM_Pm_BL, B_Pm_BL, BP_BL, BS_Pm_B, BM_Pm_B, B_Pm_B, BP_B}, {VicDirty, VicClean}) { 173514184Sgabeblack@google.com ww_stallAndWaitRegRequestQueue; 173614184Sgabeblack@google.com } 173714184Sgabeblack@google.com 173814184Sgabeblack@google.com transition({BI, B, BS_M, BM_M, B_M, BS_PM, BM_PM, B_PM, BS_Pm_BL, BM_Pm_BL, B_Pm_BL, BP_BL, BS_Pm_B, BM_Pm_B, B_Pm_B, BP_B}, {VicDirtyP, VicCleanP}) { 173914184Sgabeblack@google.com st_stallAndWaitRequest; 174014184Sgabeblack@google.com } 174114184Sgabeblack@google.com 174214184Sgabeblack@google.com transition({U, BR, BW, BL, BI, BS_M, BM_M, B_M, BP, BS_PM, BM_PM, B_PM, BS_Pm, BM_Pm, B_Pm, B, BS_Pm_BL, BM_Pm_BL, B_Pm_BL, BP_BL, BS_Pm_B, BM_Pm_B, B_Pm_B, BP_B}, WBAck) { 174314184Sgabeblack@google.com pm_popMemQueue; 174414184Sgabeblack@google.com } 174514184Sgabeblack@google.com 174614184Sgabeblack@google.com transition({U, BR, BW, BL, BI, BS_M, BM_M, B_M, BP, BS_PM, BM_PM, B_PM, BS_Pm, BM_Pm, B_Pm, B, BS_Pm_BL, BM_Pm_BL, B_Pm_BL, BP_BL, BS_Pm_B, BM_Pm_B, B_Pm_B, BP_B}, StaleVicDirtyP) { 174714184Sgabeblack@google.com rvp_removeVicDirtyIgnore; 174814184Sgabeblack@google.com wp_sendResponseWBAckP; 174914184Sgabeblack@google.com p_popRequestQueue; 175014184Sgabeblack@google.com } 175114184Sgabeblack@google.com 175214184Sgabeblack@google.com transition({U, BR, BW, BL, BI, BS_M, BM_M, B_M, BP, BS_PM, BM_PM, B_PM, BS_Pm, BM_Pm, B_Pm, B, BS_Pm_BL, BM_Pm_BL, B_Pm_BL, BP_BL, BS_Pm_B, BM_Pm_B, B_Pm_B, BP_B}, StaleVicDirty) { 175314184Sgabeblack@google.com rv_removeVicDirtyIgnore; 175414184Sgabeblack@google.com w_sendResponseWBAck; 175514184Sgabeblack@google.com prd_popRegionQueue; 175614184Sgabeblack@google.com } 175714184Sgabeblack@google.com 175814184Sgabeblack@google.com transition(U, VicDirty, BL) {L3TagArrayRead} { 175914184Sgabeblack@google.com t_allocateTBE; 176014184Sgabeblack@google.com ra_ackRegionDir; 176114184Sgabeblack@google.com w_sendResponseWBAck; 176214184Sgabeblack@google.com prd_popRegionQueue; 176314184Sgabeblack@google.com } 176414184Sgabeblack@google.com 176514184Sgabeblack@google.com transition(U, VicClean, BL) {L3TagArrayRead} { 176614184Sgabeblack@google.com t_allocateTBE; 176714184Sgabeblack@google.com ra_ackRegionDir; 176814184Sgabeblack@google.com w_sendResponseWBAck; 176914184Sgabeblack@google.com prd_popRegionQueue; 177014184Sgabeblack@google.com } 177114184Sgabeblack@google.com 177214184Sgabeblack@google.com transition({B, BR}, CoreUnblock, U) { 177314184Sgabeblack@google.com wa_wakeUpDependents; 177414184Sgabeblack@google.com pu_popUnblockQueue; 177514184Sgabeblack@google.com } 177614184Sgabeblack@google.com 177714184Sgabeblack@google.com transition({B, BR}, UnblockWriteThrough, U) { 177814184Sgabeblack@google.com wa_wakeUpDependents; 177914184Sgabeblack@google.com pt_popTriggerQueue; 178014184Sgabeblack@google.com } 178114184Sgabeblack@google.com 178214184Sgabeblack@google.com transition(BS_M, MemData, B) {L3TagArrayWrite, L3DataArrayWrite} { 178314184Sgabeblack@google.com mt_writeMemDataToTBE; 178414184Sgabeblack@google.com s_sendResponseS; 178514184Sgabeblack@google.com wd_writeBackData; 178614184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 178714184Sgabeblack@google.com dt_deallocateTBE; 178814184Sgabeblack@google.com pm_popMemQueue; 178914184Sgabeblack@google.com } 179014184Sgabeblack@google.com 179114184Sgabeblack@google.com transition(BM_M, MemData, B){L3TagArrayWrite, L3DataArrayWrite} { 179214184Sgabeblack@google.com mt_writeMemDataToTBE; 179314184Sgabeblack@google.com m_sendResponseM; 179414184Sgabeblack@google.com wd_writeBackData; 179514184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 179614184Sgabeblack@google.com dt_deallocateTBE; 179714184Sgabeblack@google.com pm_popMemQueue; 179814184Sgabeblack@google.com } 179914184Sgabeblack@google.com 180014184Sgabeblack@google.com transition(B_M, MemData, B){L3TagArrayWrite, L3DataArrayWrite} { 180114184Sgabeblack@google.com mt_writeMemDataToTBE; 180214184Sgabeblack@google.com es_sendResponseES; 180314184Sgabeblack@google.com wd_writeBackData; 180414184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 180514184Sgabeblack@google.com dt_deallocateTBE; 180614184Sgabeblack@google.com pm_popMemQueue; 180714184Sgabeblack@google.com } 180814184Sgabeblack@google.com 180914184Sgabeblack@google.com transition(BS_PM, MemData, BS_Pm) {} { 181014184Sgabeblack@google.com mt_writeMemDataToTBE; 181114184Sgabeblack@google.com wa_wakeUpDependents; 181214184Sgabeblack@google.com pm_popMemQueue; 181314184Sgabeblack@google.com } 181414184Sgabeblack@google.com 181514184Sgabeblack@google.com transition(BM_PM, MemData, BM_Pm){} { 181614184Sgabeblack@google.com mt_writeMemDataToTBE; 181714184Sgabeblack@google.com wa_wakeUpDependents; 181814184Sgabeblack@google.com pm_popMemQueue; 181914184Sgabeblack@google.com } 182014184Sgabeblack@google.com 182114184Sgabeblack@google.com transition(B_PM, MemData, B_Pm){} { 182214184Sgabeblack@google.com mt_writeMemDataToTBE; 182314184Sgabeblack@google.com wa_wakeUpDependents; 182414184Sgabeblack@google.com pm_popMemQueue; 182514184Sgabeblack@google.com } 182614184Sgabeblack@google.com 182714184Sgabeblack@google.com transition(BS_M, L3Hit, B) {L3TagArrayWrite, L3DataArrayWrite} { 182814184Sgabeblack@google.com s_sendResponseS; 182914184Sgabeblack@google.com wd_writeBackData; 183014184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 183114184Sgabeblack@google.com dt_deallocateTBE; 183214184Sgabeblack@google.com ptl_popTriggerQueue; 183314184Sgabeblack@google.com } 183414184Sgabeblack@google.com 183514184Sgabeblack@google.com transition(BM_M, L3Hit, B) {L3TagArrayWrite, L3DataArrayWrite} { 183614184Sgabeblack@google.com m_sendResponseM; 183714184Sgabeblack@google.com wd_writeBackData; 183814184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 183914184Sgabeblack@google.com dt_deallocateTBE; 184014184Sgabeblack@google.com ptl_popTriggerQueue; 184114184Sgabeblack@google.com } 184214184Sgabeblack@google.com 184314184Sgabeblack@google.com transition(B_M, L3Hit, B) {L3TagArrayWrite, L3DataArrayWrite} { 184414184Sgabeblack@google.com es_sendResponseES; 184514184Sgabeblack@google.com wd_writeBackData; 184614184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 184714184Sgabeblack@google.com dt_deallocateTBE; 184814184Sgabeblack@google.com ptl_popTriggerQueue; 184914184Sgabeblack@google.com } 185014184Sgabeblack@google.com 185114184Sgabeblack@google.com transition(BS_PM, L3Hit, BS_Pm) { 185214184Sgabeblack@google.com wa_wakeUpDependents; 185314184Sgabeblack@google.com ptl_popTriggerQueue; 185414184Sgabeblack@google.com } 185514184Sgabeblack@google.com 185614184Sgabeblack@google.com transition(BM_PM, L3Hit, BM_Pm) { 185714184Sgabeblack@google.com wa_wakeUpDependents; 185814184Sgabeblack@google.com ptl_popTriggerQueue; 185914184Sgabeblack@google.com } 186014184Sgabeblack@google.com 186114184Sgabeblack@google.com transition(B_PM, L3Hit, B_Pm) { 186214184Sgabeblack@google.com wa_wakeUpDependents; 186314184Sgabeblack@google.com ptl_popTriggerQueue; 186414184Sgabeblack@google.com } 186514184Sgabeblack@google.com 186614184Sgabeblack@google.com transition({BS_PM, BM_PM, B_PM, BS_Pm, BM_Pm, B_Pm, BP, BI}, CPUPrbResp) { 186714184Sgabeblack@google.com aic_ackInvalidate; 186814184Sgabeblack@google.com y_writeProbeDataToTBE; 186914184Sgabeblack@google.com x_decrementAcks; 187014184Sgabeblack@google.com ont_checkForCompletionNoTrigger; 187114184Sgabeblack@google.com pr_popResponseQueue; 187214184Sgabeblack@google.com } 187314184Sgabeblack@google.com 187414184Sgabeblack@google.com transition({B, B_M, BS_M, BM_M}, {CPUPrbResp, LastCPUPrbResp}) { 187514184Sgabeblack@google.com z_stall; 187614184Sgabeblack@google.com } 187714184Sgabeblack@google.com 187814184Sgabeblack@google.com transition({BS_Pm_BL, BM_Pm_BL, B_Pm_BL, BP_BL, BS_Pm_B, BM_Pm_B, B_Pm_B, BP_B}, {CPUPrbResp, LastCPUPrbResp}) { 187914184Sgabeblack@google.com // recycling because PrbResponse and data come on the same network 188014184Sgabeblack@google.com yy_recycleResponseQueue; 188114184Sgabeblack@google.com } 188214184Sgabeblack@google.com 188314184Sgabeblack@google.com transition(U, {CPUPrbResp, LastCPUPrbResp}) {L3TagArrayRead, L3DataArrayWrite} { 188414184Sgabeblack@google.com aic_ackInvalidate; 188514184Sgabeblack@google.com wdt_writeBackDataInvNoTBE; 188614184Sgabeblack@google.com ali_allocateL3BlockNoTBE; 188714184Sgabeblack@google.com pr_popResponseQueue; 188814184Sgabeblack@google.com } 188914184Sgabeblack@google.com 189014184Sgabeblack@google.com transition(BL, {CPUPrbResp, LastCPUPrbResp}) {} { 189114184Sgabeblack@google.com aic_ackInvalidate; 189214184Sgabeblack@google.com y_writeProbeDataToTBE; 189314184Sgabeblack@google.com wdi_writeBackDataInv; 189414184Sgabeblack@google.com ali_allocateL3Block; 189514184Sgabeblack@google.com pr_popResponseQueue; 189614184Sgabeblack@google.com } 189714184Sgabeblack@google.com 189814184Sgabeblack@google.com transition(BS_PM, LastCPUPrbResp, BS_M) { 189914184Sgabeblack@google.com aic_ackInvalidate; 190014184Sgabeblack@google.com y_writeProbeDataToTBE; 190114184Sgabeblack@google.com x_decrementAcks; 190214184Sgabeblack@google.com ont_checkForCompletionNoTrigger; 190314184Sgabeblack@google.com pr_popResponseQueue; 190414184Sgabeblack@google.com } 190514184Sgabeblack@google.com 190614184Sgabeblack@google.com transition(BS_PM, ProbeAcksComplete, BS_M) {} { 190714184Sgabeblack@google.com pt_popTriggerQueue; 190814184Sgabeblack@google.com } 190914184Sgabeblack@google.com 191014184Sgabeblack@google.com transition(BM_PM, LastCPUPrbResp, BM_M) { 191114184Sgabeblack@google.com aic_ackInvalidate; 191214184Sgabeblack@google.com y_writeProbeDataToTBE; 191314184Sgabeblack@google.com x_decrementAcks; 191414184Sgabeblack@google.com ont_checkForCompletionNoTrigger; 191514184Sgabeblack@google.com pr_popResponseQueue; 191614184Sgabeblack@google.com } 191714184Sgabeblack@google.com 191814184Sgabeblack@google.com transition(BM_PM, ProbeAcksComplete, BM_M) {} { 191914184Sgabeblack@google.com pt_popTriggerQueue; 192014184Sgabeblack@google.com } 192114184Sgabeblack@google.com 192214184Sgabeblack@google.com transition(B_PM, LastCPUPrbResp, B_M) { 192314184Sgabeblack@google.com aic_ackInvalidate; 192414184Sgabeblack@google.com y_writeProbeDataToTBE; 192514184Sgabeblack@google.com x_decrementAcks; 192614184Sgabeblack@google.com ont_checkForCompletionNoTrigger; 192714184Sgabeblack@google.com pr_popResponseQueue; 192814184Sgabeblack@google.com } 192914184Sgabeblack@google.com 193014184Sgabeblack@google.com transition(B_PM, ProbeAcksComplete, B_M){} { 193114184Sgabeblack@google.com pt_popTriggerQueue; 193214184Sgabeblack@google.com } 193314184Sgabeblack@google.com 193414184Sgabeblack@google.com transition(BS_Pm, LastCPUPrbResp, B) { 193514184Sgabeblack@google.com aic_ackInvalidate; 193614184Sgabeblack@google.com y_writeProbeDataToTBE; 193714184Sgabeblack@google.com x_decrementAcks; 193814184Sgabeblack@google.com ont_checkForCompletionNoTrigger; 193914184Sgabeblack@google.com s_sendResponseS; 194014184Sgabeblack@google.com wd_writeBackData; 194114184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 194214184Sgabeblack@google.com ali_allocateL3Block; 194314184Sgabeblack@google.com dt_deallocateTBE; 194414184Sgabeblack@google.com pr_popResponseQueue; 194514184Sgabeblack@google.com } 194614184Sgabeblack@google.com 194714184Sgabeblack@google.com transition(BS_Pm, ProbeAcksComplete, B){L3DataArrayWrite, L3TagArrayWrite} { 194814184Sgabeblack@google.com s_sendResponseS; 194914184Sgabeblack@google.com wd_writeBackData; 195014184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 195114184Sgabeblack@google.com ali_allocateL3Block; 195214184Sgabeblack@google.com dt_deallocateTBE; 195314184Sgabeblack@google.com pt_popTriggerQueue; 195414184Sgabeblack@google.com } 195514184Sgabeblack@google.com 195614184Sgabeblack@google.com transition(BM_Pm, LastCPUPrbResp, B) { 195714184Sgabeblack@google.com aic_ackInvalidate; 195814184Sgabeblack@google.com y_writeProbeDataToTBE; 195914184Sgabeblack@google.com x_decrementAcks; 196014184Sgabeblack@google.com ont_checkForCompletionNoTrigger; 196114184Sgabeblack@google.com m_sendResponseM; 196214184Sgabeblack@google.com wd_writeBackData; 196314184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 196414184Sgabeblack@google.com ali_allocateL3Block; 196514184Sgabeblack@google.com dt_deallocateTBE; 196614184Sgabeblack@google.com pr_popResponseQueue; 196714184Sgabeblack@google.com } 196814184Sgabeblack@google.com 196914184Sgabeblack@google.com transition(BM_Pm, ProbeAcksComplete, B){L3DataArrayWrite, L3TagArrayWrite} { 197014184Sgabeblack@google.com m_sendResponseM; 197114184Sgabeblack@google.com wd_writeBackData; 197214184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 197314184Sgabeblack@google.com ali_allocateL3Block; 197414184Sgabeblack@google.com dt_deallocateTBE; 197514184Sgabeblack@google.com pt_popTriggerQueue; 197614184Sgabeblack@google.com } 197714184Sgabeblack@google.com 197814184Sgabeblack@google.com transition(B_Pm, LastCPUPrbResp, B) { 197914184Sgabeblack@google.com aic_ackInvalidate; 198014184Sgabeblack@google.com y_writeProbeDataToTBE; 198114184Sgabeblack@google.com x_decrementAcks; 198214184Sgabeblack@google.com ont_checkForCompletionNoTrigger; 198314184Sgabeblack@google.com es_sendResponseES; 198414184Sgabeblack@google.com wd_writeBackData; 198514184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 198614184Sgabeblack@google.com ali_allocateL3Block; 198714184Sgabeblack@google.com dt_deallocateTBE; 198814184Sgabeblack@google.com pr_popResponseQueue; 198914184Sgabeblack@google.com } 199014184Sgabeblack@google.com 199114184Sgabeblack@google.com transition(B_Pm, ProbeAcksComplete, B){L3DataArrayWrite, L3TagArrayWrite} { 199214184Sgabeblack@google.com es_sendResponseES; 199314184Sgabeblack@google.com wd_writeBackData; 199414184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 199514184Sgabeblack@google.com ali_allocateL3Block; 199614184Sgabeblack@google.com dt_deallocateTBE; 199714184Sgabeblack@google.com pt_popTriggerQueue; 199814184Sgabeblack@google.com } 199914184Sgabeblack@google.com 200014184Sgabeblack@google.com transition(BP, LastCPUPrbResp, B) { 200114184Sgabeblack@google.com aic_ackInvalidate; 200214184Sgabeblack@google.com y_writeProbeDataToTBE; 200314184Sgabeblack@google.com x_decrementAcks; 200414184Sgabeblack@google.com ont_checkForCompletionNoTrigger; 200514184Sgabeblack@google.com c_sendResponseCtoD; 200614184Sgabeblack@google.com wd_writeBackData; 200714184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 200814184Sgabeblack@google.com dt_deallocateTBE; 200914184Sgabeblack@google.com pr_popResponseQueue; 201014184Sgabeblack@google.com } 201114184Sgabeblack@google.com 201214184Sgabeblack@google.com transition(BP, ProbeAcksComplete, B){L3TagArrayWrite, L3TagArrayWrite} { 201314184Sgabeblack@google.com c_sendResponseCtoD; 201414184Sgabeblack@google.com wd_writeBackData; 201514184Sgabeblack@google.com alwt_allocateL3BlockOnWT; 201614184Sgabeblack@google.com dt_deallocateTBE; 201714184Sgabeblack@google.com pt_popTriggerQueue; 201814184Sgabeblack@google.com } 201914184Sgabeblack@google.com 202014184Sgabeblack@google.com transition(BI, LastCPUPrbResp, B) { 202114184Sgabeblack@google.com aic_ackInvalidate; 202214184Sgabeblack@google.com y_writeProbeDataToTBE; 202314184Sgabeblack@google.com x_decrementAcks; 202414184Sgabeblack@google.com ont_checkForCompletionNoTrigger; 202514184Sgabeblack@google.com wa_wakeUpDependents; 202614184Sgabeblack@google.com wdi_writeBackDataInv; 202714184Sgabeblack@google.com ali_allocateL3Block; 202814184Sgabeblack@google.com dt_deallocateTBE; 202914184Sgabeblack@google.com pr_popResponseQueue; 203014184Sgabeblack@google.com } 203114184Sgabeblack@google.com 203214184Sgabeblack@google.com transition(BI, ProbeAcksComplete, U) {L3TagArrayWrite, L3DataArrayWrite}{ 203314184Sgabeblack@google.com wa_wakeUpDependents; 203414184Sgabeblack@google.com wdi_writeBackDataInv; 203514184Sgabeblack@google.com ali_allocateL3Block; 203614184Sgabeblack@google.com dt_deallocateTBE; 203714184Sgabeblack@google.com pt_popTriggerQueue; 203814184Sgabeblack@google.com } 203914184Sgabeblack@google.com 204014184Sgabeblack@google.com} 2041