mem: Add PacketInfo to be used for packet probe points
Review Request #3140 - Created Sept. 25, 2015 and submitted
| Information | |
|---|---|
| Andreas Hansson | |
| gem5 | |
| default | |
| Reviewers | |
| Default | |
Changeset 11139:33043178935c --------------------------- mem: Add PacketInfo to be used for packet probe points This patch fixes a use-after-delete issue in the packet probe points by adding a PacketInfo struct to retain the key fields before passing the packet onwards. We want to probe the packet after it is successfully sent, but by that time the fields may be modified, and the packet may even be deleted. Amazingly enough the issue has gone undetected for months, and only recently popped up in our regressions.
Affected regressions now pass
Posted (Sept. 25, 2015, 7:47 a.m.)
I'd like to get this patch shipped today or tomorrow if possible. It turns out there is a use-after-delete bug in the packet probing, and it would be good to get it fixed ASAP.
THe fix looks fine to me (though I just skimmed it, obviously).
From a longer-term perspective: we've discussed reference-counting Packet and Request objects before, haven't we? I don't recall where that discussion ended up though. Did it turn out to cause a performance issue?
