summaryrefslogtreecommitdiff
path: root/src/mem/simple_mem.cc
diff options
context:
space:
mode:
authorAndreas Hansson <andreas.hansson@arm.com>2015-03-19 04:06:11 -0400
committerAndreas Hansson <andreas.hansson@arm.com>2015-03-19 04:06:11 -0400
commit5275c9d740589abd631571cf48ac57d393d28093 (patch)
treeba07420117a6e353e2a24bdafc44db268a9554be /src/mem/simple_mem.cc
parent1d403960afec613f3aa9f1fc2ffc3287139e1d86 (diff)
downloadgem5-5275c9d740589abd631571cf48ac57d393d28093.tar.xz
mem: Use emplace front/back for deferred packets
Embrace C++11 for the deferred packets as we actually store the objects in the data structure, and not just pointers.
Diffstat (limited to 'src/mem/simple_mem.cc')
-rw-r--r--src/mem/simple_mem.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mem/simple_mem.cc b/src/mem/simple_mem.cc
index 52fd753c8..180339459 100644
--- a/src/mem/simple_mem.cc
+++ b/src/mem/simple_mem.cc
@@ -161,7 +161,7 @@ SimpleMemory::recvTimingReq(PacketPtr pkt)
// to keep things simple (and in order), we put the packet at
// the end even if the latency suggests it should be sent
// before the packet(s) before it
- packetQueue.push_back(DeferredPacket(pkt, curTick() + getLatency()));
+ packetQueue.emplace_back(DeferredPacket(pkt, curTick() + getLatency()));
if (!retryResp && !dequeueEvent.scheduled())
schedule(dequeueEvent, packetQueue.back().tick);
} else {