2003-11-03 Dave Brolley <brolley@redhat.com>
authorDave Brolley <brolley@redhat.com>
Mon, 3 Nov 2003 18:29:57 +0000 (18:29 +0000)
committerDave Brolley <brolley@redhat.com>
Mon, 3 Nov 2003 18:29:57 +0000 (18:29 +0000)
        * cache.c (address_interference): Check for higher priority requests
        in the same pipeline.

sim/frv/ChangeLog
sim/frv/cache.c

index 2589e0d0ef99aa3950a904c7c6a3731511c6cc02..efeb2bcd2e0d3af23ba170f5a7aee2b6d1535807 100644 (file)
@@ -1,3 +1,8 @@
+2003-11-03  Dave Brolley  <brolley@redhat.com>
+
+       * cache.c (address_interference): Check for higher priority requests
+       in the same pipeline.
+
 2003-10-31  Dave Brolley  <brolley@redhat.com>
 
        * frv-sim.h (LR_REGNUM): Removed.
index bfefa87d68e4216d87186f2d5866683b6c8dc29b..7b2635b6d266bd250f2a5d48f0faf18153399350 100644 (file)
@@ -1109,14 +1109,23 @@ address_interference (FRV_CACHE *cache, SI address, FRV_CACHE_REQUEST *req,
            return 1;
        }
       /* If this is not a WAR request, then yield to any WAR requests in
-        either pipeline.  */
+        either pipeline or to a higher priority request in the same pipeline.
+      */
       if (req->kind != req_WAR)
        {
          for (j = FIRST_STAGE; j < FRV_CACHE_STAGES; ++j)
            {
              other_req = cache->pipeline[i].stages[j].request;
-             if (other_req != NULL && other_req->kind == req_WAR)
-               return 1;
+             if (other_req != NULL)
+               {
+                 if (other_req->kind == req_WAR)
+                   return 1;
+                 if (i == pipe
+                     && (address == (other_req->address & line_mask) 
+                         || address == all_address)
+                     && priority > other_req->priority)
+                   return 1;
+               }
            }
        }
     }