summaryrefslogtreecommitdiff
path: root/src/arch/x86/pagetable_walker.cc
diff options
context:
space:
mode:
authorBinh Pham <binhpham@cs.rutgers.edu>2014-06-21 10:39:44 -0700
committerBinh Pham <binhpham@cs.rutgers.edu>2014-06-21 10:39:44 -0700
commitb085db84afcbb4824d34b8755f4c09c1fcfefcee (patch)
tree624324e3628addbf4dbc1ea567021a16131ec324 /src/arch/x86/pagetable_walker.cc
parentb72c8798682d307adfe9c1c2a77ac5a6d6240c15 (diff)
downloadgem5-b085db84afcbb4824d34b8755f4c09c1fcfefcee.tar.xz
x86: fix table walker assertion
In a cycle, we could see a R and W requests corresponding to the same page walk being sent to the memory. During the cycle that assertion happens, we have 2 responses corresponding to the R and W above. We also have a 'read' variable to keep track of the inflight Read request, this gets reset to NULL right after we send out any R request; and gets set to the next R in the page walk when a response comes back. The issue we are seeing here is when we get a response for W request, assert(!read) fires because we got a response for R request right before this, hence we set 'read' to NOT NULL value, pointing to the next R request in the pagewalk! This work was done while Binh was an intern at AMD Research.
Diffstat (limited to 'src/arch/x86/pagetable_walker.cc')
-rw-r--r--src/arch/x86/pagetable_walker.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/arch/x86/pagetable_walker.cc b/src/arch/x86/pagetable_walker.cc
index 0c8dcd442..e75f2edc4 100644
--- a/src/arch/x86/pagetable_walker.cc
+++ b/src/arch/x86/pagetable_walker.cc
@@ -608,9 +608,11 @@ Walker::WalkerState::recvPacket(PacketPtr pkt)
assert(pkt->isResponse());
assert(inflight);
assert(state == Waiting);
- assert(!read);
inflight--;
if (pkt->isRead()) {
+ // should not have a pending read it we also had one outstanding
+ assert(!read);
+
// @todo someone should pay for this
pkt->busFirstWordDelay = pkt->busLastWordDelay = 0;