mem-cache: Squash prefetch queue entries by block address.
Prefetch queue entries were being squashed by comparing the address of each queued prefetch against the block address of the demand access. Only prefetches that happen to fall on a cache-line block boundary would be squashed. This patch converts the prefetch addresses to block addresses before comparison. Change-Id: I3a80a1e3d752f925595e33edebf5359d2cc67182 Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
This commit is contained in:
4
src/mem/cache/prefetch/queued.cc
vendored
4
src/mem/cache/prefetch/queued.cc
vendored
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2014-2015, 2023 ARM Limited
|
||||
* Copyright (c) 2014-2015, 2022-2023 Arm Limited
|
||||
* All rights reserved
|
||||
*
|
||||
* The license below extends only to copyright in the software and shall
|
||||
@@ -180,7 +180,7 @@ Queued::notify(const CacheAccessProbeArg &acc, const PrefetchInfo &pfi)
|
||||
if (queueSquash) {
|
||||
auto itr = pfq.begin();
|
||||
while (itr != pfq.end()) {
|
||||
if (itr->pfInfo.getAddr() == blk_addr &&
|
||||
if (blockAddress(itr->pfInfo.getAddr()) == blk_addr &&
|
||||
itr->pfInfo.isSecure() == is_secure) {
|
||||
DPRINTF(HWPrefetch, "Removing pf candidate addr: %#x "
|
||||
"(cl: %#x), demand request going to the same addr\n",
|
||||
|
||||
Reference in New Issue
Block a user