Deleted Added
sdiff udiff text old ( 11177:524c44cf8278 ) new ( 11197:f8fdd931e674 )
full compact
1/*
2 * Copyright (c) 2012-2013, 2015 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

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

61
62using namespace std;
63
64MSHR::MSHR() : readyTime(0), _isUncacheable(false), downstreamPending(false),
65 pendingDirty(false),
66 postInvalidate(false), postDowngrade(false),
67 queue(NULL), order(0), blkAddr(0),
68 blkSize(0), isSecure(false), inService(false),
69 isForward(false), threadNum(InvalidThreadID), data(NULL)
70{
71}
72
73
74MSHR::TargetList::TargetList()
75 : needsExclusive(false), hasUpgrade(false)
76{}
77

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

197 ccprintf(os, "%s%s: ", prefix, s);
198 t.pkt->print(os, verbosity, "");
199 }
200}
201
202
203void
204MSHR::allocate(Addr blk_addr, unsigned blk_size, PacketPtr target,
205 Tick when_ready, Counter _order)
206{
207 blkAddr = blk_addr;
208 blkSize = blk_size;
209 isSecure = target->isSecure();
210 readyTime = when_ready;
211 order = _order;
212 assert(target);
213 isForward = false;
214 _isUncacheable = target->req->isUncacheable();
215 inService = false;
216 downstreamPending = false;
217 threadNum = 0;
218 assert(targets.isReset());
219 // Don't know of a case where we would allocate a new MSHR for a
220 // snoop (mem-side request), so set source according to request here
221 Target::Source source = (target->cmd == MemCmd::HardPFReq) ?

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

269 assert(deferredTargets.isReset());
270 inService = false;
271}
272
273/*
274 * Adds a target to an MSHR
275 */
276void
277MSHR::allocateTarget(PacketPtr pkt, Tick whenReady, Counter _order)
278{
279 // assume we'd never issue a prefetch when we've got an
280 // outstanding miss
281 assert(pkt->cmd != MemCmd::HardPFReq);
282
283 // uncacheable accesses always allocate a new MSHR, and cacheable
284 // accesses ignore any uncacheable MSHRs, thus we should never
285 // have targets addded if originally allocated uncacheable
286 assert(!_isUncacheable);
287
288 // if there's a request already in service for this MSHR, we will
289 // have to defer the new target until after the response if any of
290 // the following are true:
291 // - there are other targets already deferred
292 // - there's a pending invalidate to be applied after the response
293 // comes back (but before this target is processed)
294 // - this target requires an exclusive block and either we're not
295 // getting an exclusive block back or we have already snooped

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

473
474void
475MSHR::print(std::ostream &os, int verbosity, const std::string &prefix) const
476{
477 ccprintf(os, "%s[%#llx:%#llx](%s) %s %s %s state: %s %s %s %s %s\n",
478 prefix, blkAddr, blkAddr + blkSize - 1,
479 isSecure ? "s" : "ns",
480 isForward ? "Forward" : "",
481 isForwardNoResponse() ? "ForwNoResp" : "",
482 needsExclusive() ? "Excl" : "",
483 _isUncacheable ? "Unc" : "",
484 inService ? "InSvc" : "",
485 downstreamPending ? "DwnPend" : "",
486 hasPostInvalidate() ? "PostInv" : "",
487 hasPostDowngrade() ? "PostDowngr" : "");
488

--- 15 unchanged lines hidden ---