MOESI_hammer: fixed bug with single cpu + flushes, then modified the regression teste...
authorBrad Beckmann <Brad.Beckmann@amd.com>
Fri, 6 Apr 2012 20:47:06 +0000 (13:47 -0700)
committerBrad Beckmann <Brad.Beckmann@amd.com>
Fri, 6 Apr 2012 20:47:06 +0000 (13:47 -0700)
src/mem/protocol/MOESI_hammer-dir.sm
tests/configs/rubytest-ruby.py

index dfb62e844285c54e12698796a72ddb6a8c1bd00b..24d64349e309b9d02b72874eb5d923badd13f78a 100644 (file)
@@ -493,7 +493,7 @@ machine(Directory, "AMD Hammer-like protocol")
 
   action(oc_sendBlockAck, "oc", desc="Send block ack to the owner") {
     peek(requestQueue_in, RequestMsg) {
-      if ((probe_filter_enabled || full_bit_dir_enabled) && (in_msg.Requestor == cache_entry.Owner)) {
+        if (((probe_filter_enabled || full_bit_dir_enabled) && (in_msg.Requestor == cache_entry.Owner)) || machineCount(MachineType:L1Cache) == 1) {
         enqueue(forwardNetwork_out, RequestMsg, latency=memory_controller_latency) {
           out_msg.Address := address;
           out_msg.Type := CoherenceRequestType:BLOCK_ACK;
@@ -1033,7 +1033,7 @@ machine(Directory, "AMD Hammer-like protocol")
   }
 
   action(nofc_forwardRequestConditionalOwner, "nofc", desc="Forward request to one or more nodes if the requestor is not the owner") {
-    assert(machineCount(MachineType:L1Cache) > 1);
+   if (machineCount(MachineType:L1Cache) > 1) {
 
      if (probe_filter_enabled || full_bit_dir_enabled) {
        peek(requestQueue_in, RequestMsg) {
@@ -1065,7 +1065,7 @@ machine(Directory, "AMD Hammer-like protocol")
         }
       }
      }
-
+   }
   }
 
   action(f_forwardWriteFromDma, "fw", desc="Forward requests") {
index 7bb7b90145b1adf7804d9e75d13813f4f15a6dc8..979295cf570f2d4d316c526273c21e91a6b60725 100644 (file)
@@ -65,10 +65,16 @@ options.l1i_assoc=2
 options.l2_assoc=2
 options.l3_assoc=2
 
+# Turn on flush check for the hammer protocol
+check_flush = False
+if buildEnv['PROTOCOL'] == 'MOESI_hammer':
+    check_flush = True
+
 #
 # create the tester and system, including ruby
 #
-tester = RubyTester(checks_to_complete = 100, wakeup_frequency = 10)
+tester = RubyTester(check_flush = check_flush, checks_to_complete = 100,
+                    wakeup_frequency = 10)
 
 system = System(tester = tester, physmem = SimpleMemory())