diff --git a/cpu/simple/cpu.cc b/cpu/simple/cpu.cc index d352d8c03..a7f4fa499 100644 --- a/cpu/simple/cpu.cc +++ b/cpu/simple/cpu.cc @@ -382,6 +382,7 @@ SimpleCPU::copy(Addr dest) memReq->dest = dest_addr; memReq->size = 64; memReq->time = curTick; + memReq->flags &= ~INST_READ; dcacheInterface->access(memReq); } } @@ -412,6 +413,7 @@ SimpleCPU::read(Addr addr, T &data, unsigned flags) memReq->cmd = Read; memReq->completionEvent = NULL; memReq->time = curTick; + memReq->flags &= ~INST_READ; MemAccessResult result = dcacheInterface->access(memReq); // Ugly hack to get an event scheduled *only* if the access is @@ -500,6 +502,7 @@ SimpleCPU::write(T data, Addr addr, unsigned flags, uint64_t *res) memcpy(memReq->data,(uint8_t *)&data,memReq->size); memReq->completionEvent = NULL; memReq->time = curTick; + memReq->flags &= ~INST_READ; MemAccessResult result = dcacheInterface->access(memReq); // Ugly hack to get an event scheduled *only* if the access is @@ -714,6 +717,7 @@ SimpleCPU::tick() memReq->completionEvent = NULL; memReq->time = curTick; + memReq->flags |= INST_READ; MemAccessResult result = icacheInterface->access(memReq); // Ugly hack to get an event scheduled *only* if the access is