diff options
author | Rekai Gonzalez Alberquilla <Rekai.GonzalezAlberquilla@arm.com> | 2016-04-07 11:32:38 -0500 |
---|---|---|
committer | Rekai Gonzalez Alberquilla <Rekai.GonzalezAlberquilla@arm.com> | 2016-04-07 11:32:38 -0500 |
commit | af27586fbc75480725fbef0564775fe5aa8cc8d8 (patch) | |
tree | 172bc90811714896da278d16d97edbbb1f3fe4e2 /src/mem/cache/prefetch/tagged.cc | |
parent | dad7d9277b571305ee248cd761a7dbb9400b3681 (diff) | |
download | gem5-af27586fbc75480725fbef0564775fe5aa8cc8d8.tar.xz |
mem: Add priority to QueuedPrefetcher
Queued prefetcher entries now count with a priority field. The idea is to
add packets ordered by priority and then by age.
For the existing algorithms in which priority doesn't make sense, it is set
to 0 for all deferred packets in the queue.
Diffstat (limited to 'src/mem/cache/prefetch/tagged.cc')
-rw-r--r-- | src/mem/cache/prefetch/tagged.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mem/cache/prefetch/tagged.cc b/src/mem/cache/prefetch/tagged.cc index 59c489a28..32a5b47f8 100644 --- a/src/mem/cache/prefetch/tagged.cc +++ b/src/mem/cache/prefetch/tagged.cc @@ -43,7 +43,7 @@ TaggedPrefetcher::TaggedPrefetcher(const TaggedPrefetcherParams *p) void TaggedPrefetcher::calculatePrefetch(const PacketPtr &pkt, - std::vector<Addr> &addresses) + std::vector<AddrPriority> &addresses) { Addr blkAddr = pkt->getAddr() & ~(Addr)(blkSize-1); @@ -54,7 +54,7 @@ TaggedPrefetcher::calculatePrefetch(const PacketPtr &pkt, pfSpanPage += degree - d + 1; return; } else { - addresses.push_back(newAddr); + addresses.push_back(AddrPriority(newAddr,0)); } } } |