summaryrefslogtreecommitdiff
path: root/src/cpu/o3/fetch_impl.hh
diff options
context:
space:
mode:
authorRon Dreslinski <rdreslin@umich.edu>2006-07-11 15:42:31 -0400
committerRon Dreslinski <rdreslin@umich.edu>2006-07-11 15:42:31 -0400
commit6bcc65c1f866348f64a804a8bcc1f6dc06145afa (patch)
tree5a8cf877b7f882a83c9af18f86212d03dd8e5a5b /src/cpu/o3/fetch_impl.hh
parentad4374e0cd235ea98ddc2a4659f9d7c86e5b355b (diff)
downloadgem5-6bcc65c1f866348f64a804a8bcc1f6dc06145afa.tar.xz
Fix ordering issue with squashed Icache Fetches and Static data in packet.
Now hello world works with 2 levels of cache with O3 CPU(multiple outstanding requests). src/cpu/o3/fetch_impl.hh: Fix ordering issue with squashed Icache Fetches and Static data in packet. --HG-- extra : convert_revision : a6adb87540b007ead0b4982cb3f31da8199fb5ca
Diffstat (limited to 'src/cpu/o3/fetch_impl.hh')
-rw-r--r--src/cpu/o3/fetch_impl.hh4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/cpu/o3/fetch_impl.hh b/src/cpu/o3/fetch_impl.hh
index de883b5ba..39a13f9f8 100644
--- a/src/cpu/o3/fetch_impl.hh
+++ b/src/cpu/o3/fetch_impl.hh
@@ -357,6 +357,8 @@ DefaultFetch<Impl>::processCacheCompletion(PacketPtr pkt)
return;
}
+ memcpy(cacheData[tid], pkt->getPtr<uint8_t *>(), cacheBlkSize);
+
if (!drainPending) {
// Wake up the CPU (if it went to sleep and was waiting on
// this completion event).
@@ -548,7 +550,7 @@ DefaultFetch<Impl>::fetchCacheLine(Addr fetch_PC, Fault &ret_fault, unsigned tid
// Build packet here.
PacketPtr data_pkt = new Packet(mem_req,
Packet::ReadReq, Packet::Broadcast);
- data_pkt->dataStatic(cacheData[tid]);
+ data_pkt->dataDynamic(new uint8_t[cacheBlkSize]);
DPRINTF(Fetch, "Fetch: Doing instruction read.\n");