X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fmem%2Fcache%2Fmshr.hh;h=3e7b79ea0cd3c9331d35bf1461ae5e0e5b18bc24;hb=28059ffcdf50871b1be573c29a656da9473287d1;hp=b94dfb9c53721f412b7d777fa06f8f33666cab78;hpb=bf305c14c47c4bd228c0910ea3bb30ab4bc935e1;p=gem5.git diff --git a/src/mem/cache/mshr.hh b/src/mem/cache/mshr.hh index b94dfb9c5..3e7b79ea0 100644 --- a/src/mem/cache/mshr.hh +++ b/src/mem/cache/mshr.hh @@ -124,7 +124,7 @@ class MSHR : public QueueEntry, public Printable /** True if the entry is just a simple forward from an upper level */ bool isForward; - class Target { + class Target : public QueueEntry::Target { public: enum Source { @@ -133,10 +133,6 @@ class MSHR : public QueueEntry, public Printable FromPrefetcher }; - const Tick recvTime; //!< Time when request was received (for stats) - const Tick readyTime; //!< Time when request is ready to be serviced - const Counter order; //!< Global order (for memory consistency mgmt) - const PacketPtr pkt; //!< Pending request packet. const Source source; //!< Request from cpu, memory, or prefetcher? /** @@ -161,9 +157,8 @@ class MSHR : public QueueEntry, public Printable Target(PacketPtr _pkt, Tick _readyTime, Counter _order, Source _source, bool _markedPending, bool alloc_on_fill) - : recvTime(curTick()), readyTime(_readyTime), order(_order), - pkt(_pkt), source(_source), markedPending(_markedPending), - allocOnFill(alloc_on_fill) + : QueueEntry::Target(_pkt, _readyTime, _order), source(_source), + markedPending(_markedPending), allocOnFill(alloc_on_fill) {} }; @@ -357,7 +352,7 @@ class MSHR : public QueueEntry, public Printable assert(inService); return postDowngrade; } - bool sendPacket(BaseCache &cache); + bool sendPacket(BaseCache &cache) override; bool allocOnFill() const { return targets.allocOnFill; @@ -476,7 +471,7 @@ class MSHR : public QueueEntry, public Printable * Returns a reference to the first target. * @return A pointer to the first target. */ - Target *getTarget() + QueueEntry::Target *getTarget() override { assert(hasTargets()); return &targets.front(); @@ -528,7 +523,7 @@ class MSHR : public QueueEntry, public Printable */ void print(std::ostream &os, int verbosity = 0, - const std::string &prefix = "") const; + const std::string &prefix = "") const override; /** * A no-args wrapper of print(std::ostream...) meant to be * invoked from DPRINTFs avoiding string overheads in fast mode @@ -536,6 +531,10 @@ class MSHR : public QueueEntry, public Printable * @return string with mshr fields + [deferred]targets */ std::string print() const; + + bool matchBlockAddr(const Addr addr, const bool is_secure) const override; + bool matchBlockAddr(const PacketPtr pkt) const override; + bool conflictAddr(const QueueEntry* entry) const override; }; #endif // __MEM_CACHE_MSHR_HH__