changeset 35cb92cbd50c in /z/repo/m5
details: http://repo.m5sim.org/m5?cmd=changeset;node=35cb92cbd50c
description:
        ruby: Removed the unnecessary MachineType message fields

diffstat:

3 files changed, 3 insertions(+), 55 deletions(-)
src/mem/protocol/MOESI_CMP_token-L1cache.sm |   26 +++-----------------------
src/mem/protocol/MOESI_CMP_token-L2cache.sm |   20 --------------------
src/mem/protocol/MOESI_CMP_token-dir.sm     |   12 ------------

diffs (truncated from 435 to 300 lines):

diff -r 9f938aea1942 -r 35cb92cbd50c src/mem/protocol/MOESI_CMP_token-L1cache.sm
--- a/src/mem/protocol/MOESI_CMP_token-L1cache.sm       Sun Mar 21 21:22:22 
2010 -0700
+++ b/src/mem/protocol/MOESI_CMP_token-L1cache.sm       Sun Mar 21 21:22:22 
2010 -0700
@@ -516,7 +516,7 @@
         assert(in_msg.Destination.isElement(machineID));
 
         // Mark TBE flag if response received off-chip.  Use this to update 
average latency estimate
-        if ( in_msg.SenderMachine == MachineType:L2Cache ) {
+        if ( machineIDToMachineType(in_msg.Sender) == MachineType:L2Cache ) {
 
           if (in_msg.Sender == mapAddressToRange(in_msg.Address,
                                                  MachineType:L2Cache,
@@ -532,12 +532,12 @@
           else {
                // profile_onchipL2_response(in_msg.Address );
           }
-        } else if ( in_msg.SenderMachine == MachineType:Directory ) {
+        } else if ( machineIDToMachineType(in_msg.Sender) == 
MachineType:Directory ) {
           if (L1_TBEs.isPresent(in_msg.Address)) {
             L1_TBEs[in_msg.Address].ExternalResponse := true;
             // profile_memory_response( in_msg.Address);
           }
-        } else if ( in_msg.SenderMachine == MachineType:L1Cache) {
+        } else if ( machineIDToMachineType(in_msg.Sender) == 
MachineType:L1Cache) {
           //if (isLocalProcessor(machineID, in_msg.Sender) == false) {
             //if (L1_TBEs.isPresent(in_msg.Address)) {
                // L1_TBEs[in_msg.Address].ExternalResponse := true;
@@ -697,7 +697,6 @@
           out_msg.Address := address;
           out_msg.Type := CoherenceRequestType:GETS;
           out_msg.Requestor := machineID;
-
           out_msg.Destination.add(mapAddressToRange(address,
                                                     MachineType:L2Cache,
                                                     l2_select_low_bit,
@@ -718,7 +717,6 @@
           out_msg.Address := address;
           out_msg.Type := CoherenceRequestType:GETS;
           out_msg.Requestor := machineID;
-
           //
           // Since only one chip, assuming all L1 caches are local
           //
@@ -766,7 +764,6 @@
             out_msg.Address := address;
             out_msg.Type := PersistentRequestType:GETX_PERSISTENT;
             out_msg.Requestor := machineID;
-            out_msg.RequestorMachine := MachineType:L1Cache;
             out_msg.Destination.broadcast(MachineType:L1Cache);
 
             //
@@ -821,7 +818,6 @@
           out_msg.Address := address;
           out_msg.Type := CoherenceRequestType:GETX;
           out_msg.Requestor := machineID;
-          out_msg.RequestorMachine := MachineType:L1Cache;
 
           out_msg.Destination.add(mapAddressToRange(address,
                                                     MachineType:L2Cache,
@@ -885,7 +881,6 @@
         out_msg.Address := address;
         out_msg.Type := in_msg.Type;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L1Cache;
         out_msg.Destination.add(map_Address_to_Directory(address));
         out_msg.Tokens := in_msg.Tokens;
         out_msg.MessageSize := in_msg.MessageSize;
@@ -899,7 +894,6 @@
     enqueue(responseNetwork_out, ResponseMsg, latency = l1_response_latency) {
       out_msg.Address := address;
       out_msg.Sender := machineID;
-      out_msg.SenderMachine := MachineType:L1Cache;
 
       out_msg.Destination.add(mapAddressToRange(address,
                                                 MachineType:L2Cache,
@@ -924,7 +918,6 @@
       enqueue(responseNetwork_out, ResponseMsg, latency = l1_response_latency) 
{
         out_msg.Address := address;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L1Cache;
 
         out_msg.Destination.add(mapAddressToRange(address,
                                                   MachineType:L2Cache,
@@ -956,7 +949,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:DATA_SHARED;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L1Cache;
         out_msg.Destination.add(in_msg.Requestor);
         out_msg.Tokens := 1;
         out_msg.DataBlk := getCacheEntry(address).DataBlk;
@@ -980,7 +972,6 @@
           out_msg.Address := address;
           out_msg.Type := CoherenceResponseType:DATA_SHARED;
           out_msg.Sender := machineID;
-          out_msg.SenderMachine := MachineType:L1Cache;
           out_msg.Destination.add(in_msg.Requestor);
           out_msg.Tokens := N_tokens;
           out_msg.DataBlk := getCacheEntry(address).DataBlk;
@@ -999,7 +990,6 @@
           out_msg.Address := address;
           out_msg.Type := CoherenceResponseType:DATA_SHARED;
           out_msg.Sender := machineID;
-          out_msg.SenderMachine := MachineType:L1Cache;
           out_msg.Destination.add(in_msg.Requestor);
           out_msg.Tokens := 1;
           out_msg.DataBlk := getCacheEntry(address).DataBlk;
@@ -1023,7 +1013,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:DATA_OWNER;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L1Cache;
         out_msg.Destination.add(in_msg.Requestor);
         assert(getCacheEntry(address).Tokens >= 1);
         out_msg.Tokens := getCacheEntry(address).Tokens;
@@ -1046,7 +1035,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:ACK;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L1Cache;
         out_msg.Destination.add(persistentTable.findSmallest(address));
         assert(getCacheEntry(address).Tokens >= 1);
         out_msg.Tokens := getCacheEntry(address).Tokens;
@@ -1063,7 +1051,6 @@
       out_msg.Address := address;
       out_msg.Type := CoherenceResponseType:DATA_OWNER;
       out_msg.Sender := machineID;
-      out_msg.SenderMachine := MachineType:L1Cache;
       out_msg.Destination.add(persistentTable.findSmallest(address));
       assert(getCacheEntry(address).Tokens >= 1);
       out_msg.Tokens := getCacheEntry(address).Tokens;
@@ -1082,7 +1069,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:ACK;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L1Cache;
         out_msg.Destination.add(persistentTable.findSmallest(address));
         assert(getCacheEntry(address).Tokens >= 1);
         if (getCacheEntry(address).Tokens > N_tokens) {
@@ -1108,7 +1094,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:DATA_OWNER;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L1Cache;
         out_msg.Destination.add(persistentTable.findSmallest(address));
         assert(getCacheEntry(address).Tokens >= 1);
         if (getCacheEntry(address).Tokens > N_tokens) {
@@ -1138,7 +1123,6 @@
         out_msg.Address := address;
         out_msg.Type := in_msg.Type;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L1Cache;
         out_msg.Destination.add(persistentTable.findSmallest(address));
         out_msg.Tokens := in_msg.Tokens;
         out_msg.DataBlk := in_msg.DataBlk;
@@ -1236,8 +1220,6 @@
        out_msg.Type := CoherenceResponseType:INV;
        out_msg.Tokens := 0;
        out_msg.Sender := machineID;
-       out_msg.SenderMachine := MachineType:L1Cache;
-       out_msg.DestMachine := MachineType:L2Cache;
 
        out_msg.Destination.add(mapAddressToRange(address,
                                                  MachineType:L2Cache,
@@ -1273,7 +1255,6 @@
         out_msg.Address := address;
         out_msg.Type := PersistentRequestType:DEACTIVATE_PERSISTENT;
         out_msg.Requestor := machineID;
-        out_msg.RequestorMachine := MachineType:L1Cache;
         out_msg.Destination.broadcast(MachineType:L1Cache);
 
         //
@@ -1320,7 +1301,6 @@
           out_msg.Address := address;
           out_msg.Type := CoherenceResponseType:ACK;
           out_msg.Sender := machineID;
-          out_msg.SenderMachine := MachineType:L1Cache;
           out_msg.Destination.add(in_msg.Requestor);
           assert(getCacheEntry(address).Tokens >= 1);
           out_msg.Tokens := getCacheEntry(address).Tokens;
diff -r 9f938aea1942 -r 35cb92cbd50c src/mem/protocol/MOESI_CMP_token-L2cache.sm
--- a/src/mem/protocol/MOESI_CMP_token-L2cache.sm       Sun Mar 21 21:22:22 
2010 -0700
+++ b/src/mem/protocol/MOESI_CMP_token-L2cache.sm       Sun Mar 21 21:22:22 
2010 -0700
@@ -477,7 +477,6 @@
            out_msg.Address := in_msg.Address;
            out_msg.Type := in_msg.Type;
            out_msg.Requestor := in_msg.Requestor;
-           out_msg.RequestorMachine := in_msg.RequestorMachine;
            out_msg.RetryNum := in_msg.RetryNum;
 
            //
@@ -507,7 +506,6 @@
         out_msg.Address := address;
         out_msg.Type := in_msg.Type;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L2Cache;
         out_msg.Destination.add(map_Address_to_Directory(address));
         out_msg.Tokens := in_msg.Tokens;
         out_msg.MessageSize := in_msg.MessageSize;
@@ -523,7 +521,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:ACK;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L2Cache;
         out_msg.Destination.add(map_Address_to_Directory(address));
         out_msg.Tokens := getL2CacheEntry(address).Tokens;
         out_msg.MessageSize := MessageSizeType:Writeback_Control;
@@ -536,7 +533,6 @@
     enqueue(responseNetwork_out, ResponseMsg, latency=l2_response_latency) {
       out_msg.Address := address;
       out_msg.Sender := machineID;
-      out_msg.SenderMachine := MachineType:L2Cache;
       out_msg.Destination.add(map_Address_to_Directory(address));
       out_msg.Tokens := getL2CacheEntry(address).Tokens;
       out_msg.DataBlk := getL2CacheEntry(address).DataBlk;
@@ -560,7 +556,6 @@
           out_msg.Address := address;
           out_msg.Type := CoherenceResponseType:DATA_SHARED;
           out_msg.Sender := machineID;
-          out_msg.SenderMachine := MachineType:L2Cache;
           out_msg.Destination.add(in_msg.Requestor);
           out_msg.Tokens := N_tokens;
           out_msg.DataBlk := getL2CacheEntry(address).DataBlk;
@@ -574,7 +569,6 @@
           out_msg.Address := address;
           out_msg.Type := CoherenceResponseType:DATA_SHARED;
           out_msg.Sender := machineID;
-          out_msg.SenderMachine := MachineType:L2Cache;
           out_msg.Destination.add(in_msg.Requestor);
           out_msg.Tokens := 1;
           out_msg.DataBlk := getL2CacheEntry(address).DataBlk;
@@ -592,7 +586,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:DATA_OWNER;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L2Cache;
         out_msg.Destination.add(in_msg.Requestor);
         assert(getL2CacheEntry(address).Tokens >= 1);
         out_msg.Tokens := getL2CacheEntry(address).Tokens;
@@ -610,7 +603,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:ACK;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L2Cache;
         out_msg.Destination.add(persistentTable.findSmallest(address));
         assert(getL2CacheEntry(address).Tokens >= 1);
         out_msg.Tokens := getL2CacheEntry(address).Tokens;
@@ -625,7 +617,6 @@
       out_msg.Address := address;
       out_msg.Type := CoherenceResponseType:DATA_OWNER;
       out_msg.Sender := machineID;
-      out_msg.SenderMachine := MachineType:L2Cache;
       out_msg.Destination.add(persistentTable.findSmallest(address));
       assert(getL2CacheEntry(address).Tokens >= 1);
       out_msg.Tokens := getL2CacheEntry(address).Tokens;
@@ -644,7 +635,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:ACK;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L2Cache;
         out_msg.Destination.add(persistentTable.findSmallest(address));
         assert(getL2CacheEntry(address).Tokens >= 1);
         out_msg.Tokens := getL2CacheEntry(address).Tokens - 1;
@@ -662,7 +652,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:DATA_OWNER;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L2Cache;
         out_msg.Destination.add(persistentTable.findSmallest(address));
         assert(getL2CacheEntry(address).Tokens >= 1);
         out_msg.Tokens := getL2CacheEntry(address).Tokens - 1;
@@ -684,7 +673,6 @@
         out_msg.Address := address;
         out_msg.Type := in_msg.Type;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L2Cache;
         out_msg.Destination.add(persistentTable.findSmallest(address));
         out_msg.Tokens := in_msg.Tokens;
         out_msg.DataBlk := in_msg.DataBlk;
@@ -706,7 +694,6 @@
           out_msg.Type := CoherenceResponseType:ACK;
         }
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L2Cache;
         out_msg.Destination.add(persistentTable.findSmallest(address));
         out_msg.Tokens := in_msg.Tokens;
         out_msg.DataBlk := in_msg.DataBlk;
@@ -724,7 +711,6 @@
         out_msg.Address := address;
         out_msg.Type := CoherenceResponseType:DATA_OWNER;
         out_msg.Sender := machineID;
-        out_msg.SenderMachine := MachineType:L2Cache;
         out_msg.Destination.add(persistentTable.findSmallest(address));
         out_msg.Tokens := in_msg.Tokens;
         out_msg.DataBlk := in_msg.DataBlk;
@@ -752,7 +738,6 @@
         enqueue(localRequestNetwork_out, RequestMsg, 
latency=l2_response_latency ) {
            out_msg.Address := in_msg.Address;
            out_msg.Requestor := in_msg.Requestor;
-           out_msg.RequestorMachine := in_msg.RequestorMachine;
_______________________________________________
m5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/m5-dev

Reply via email to