Deleted Added
sdiff udiff text old ( 9725:0d4ee33078bb ) new ( 10028:fb8c44de891a )
full compact
1/*
2 * Copyright (c) 2012 ARM Limited
3 * All rights reserved.
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software
9 * licensed hereunder. You may use the software subject to the license
10 * terms below provided that you ensure that this notice is replicated

--- 48 unchanged lines hidden (view full) ---

59#include "mem/cache/mshr.hh"
60#include "sim/core.hh"
61
62using namespace std;
63
64MSHR::MSHR() : readyTime(0), _isUncacheable(false), downstreamPending(false),
65 pendingDirty(false), postInvalidate(false),
66 postDowngrade(false), queue(NULL), order(0), addr(0), size(0),
67 inService(false), isForward(false), threadNum(InvalidThreadID),
68 data(NULL)
69{
70}
71
72
73MSHR::TargetList::TargetList()
74 : needsExclusive(false), hasUpgrade(false)
75{}
76

--- 119 unchanged lines hidden (view full) ---

196 }
197 ccprintf(os, "%s%s: ", prefix, s);
198 i->pkt->print(os, verbosity, "");
199 }
200}
201
202
203void
204MSHR::allocate(Addr _addr, int _size, PacketPtr target,
205 Tick whenReady, Counter _order)
206{
207 addr = _addr;
208 size = _size;
209 readyTime = whenReady;
210 order = _order;
211 assert(target);
212 isForward = false;
213 _isUncacheable = target->req->isUncacheable();
214 inService = false;
215 downstreamPending = false;
216 threadNum = 0;

--- 218 unchanged lines hidden (view full) ---

435
436bool
437MSHR::checkFunctional(PacketPtr pkt)
438{
439 // For printing, we treat the MSHR as a whole as single entity.
440 // For other requests, we iterate over the individual targets
441 // since that's where the actual data lies.
442 if (pkt->isPrint()) {
443 pkt->checkFunctional(this, addr, size, NULL);
444 return false;
445 } else {
446 return (targets.checkFunctional(pkt) ||
447 deferredTargets.checkFunctional(pkt));
448 }
449}
450
451
452void
453MSHR::print(std::ostream &os, int verbosity, const std::string &prefix) const
454{
455 ccprintf(os, "%s[%x:%x] %s %s %s state: %s %s %s %s %s\n",
456 prefix, addr, addr+size-1,
457 isForward ? "Forward" : "",
458 isForwardNoResponse() ? "ForwNoResp" : "",
459 needsExclusive() ? "Excl" : "",
460 _isUncacheable ? "Unc" : "",
461 inService ? "InSvc" : "",
462 downstreamPending ? "DwnPend" : "",
463 hasPostInvalidate() ? "PostInv" : "",
464 hasPostDowngrade() ? "PostDowngr" : "");

--- 16 unchanged lines hidden ---