Hello Tony Gutierrez,
I'd like you to do a code review. Please visit
https://gem5-review.googlesource.com/c/public/gem5/+/29963
to review the following change.
Change subject: gpu-compute: Don't track vector store insts in CU's
headTailMap
......................................................................
gpu-compute: Don't track vector store insts in CU's headTailMap
This change fixes a memory leak due to live GPUDynInstPtr references
to vector store insts being stored in the CU's headTailMap and never
released.
This happened because store insts are not supposed to have their
head-tail latencies tracked by the headTailMap; instead they use
timing information from the GPUCoalescer. When updating the
headTailLatency stat via the headTailMap, only loads were considered
and removed from the headTailMap, however when inserting into the
headTailMap loads and stores were considered, thus leading to the
memory leak.
This change fixes the issue by only adding loads to the headTailMap.
Change-Id: I8a8f5b79f55e00481ae5e82519a9ed627a7ecbd1
---
M src/gpu-compute/compute_unit.cc
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/src/gpu-compute/compute_unit.cc
b/src/gpu-compute/compute_unit.cc
index f3387a7..653c074 100644
--- a/src/gpu-compute/compute_unit.cc
+++ b/src/gpu-compute/compute_unit.cc
@@ -1389,9 +1389,11 @@
gpuDynInst->wfSlotId);
}
} else {
- if (!compute_unit->headTailMap.count(gpuDynInst)) {
- compute_unit->headTailMap.insert(
- std::make_pair(gpuDynInst, curTick()));
+ if (pkt->isRead()) {
+ if (!compute_unit->headTailMap.count(gpuDynInst)) {
+ compute_unit->headTailMap
+ .insert(std::make_pair(gpuDynInst, curTick()));
+ }
}
}
--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/29963
To unsubscribe, or for help writing mail filters, visit
https://gem5-review.googlesource.com/settings
Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I8a8f5b79f55e00481ae5e82519a9ed627a7ecbd1
Gerrit-Change-Number: 29963
Gerrit-PatchSet: 1
Gerrit-Owner: Anthony Gutierrez <[email protected]>
Gerrit-Reviewer: Tony Gutierrez <[email protected]>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s