mshr.cc (9543:a373b2e664ff) mshr.cc (9663:45df88079f04)
1/*
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
11 * unmodified and in its entirety in all distributions of the software,
12 * modified or unmodified, in source code or in binary form.
13 *
2 * Copyright (c) 2002-2005 The Regents of The University of Michigan
3 * Copyright (c) 2010 Advanced Micro Devices, Inc.
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions are
8 * met: redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer;

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

298 }
299
300 ++ntargets;
301}
302
303bool
304MSHR::handleSnoop(PacketPtr pkt, Counter _order)
305{
14 * Copyright (c) 2002-2005 The Regents of The University of Michigan
15 * Copyright (c) 2010 Advanced Micro Devices, Inc.
16 * All rights reserved.
17 *
18 * Redistribution and use in source and binary forms, with or without
19 * modification, are permitted provided that the following conditions are
20 * met: redistributions of source code must retain the above copyright
21 * notice, this list of conditions and the following disclaimer;

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

310 }
311
312 ++ntargets;
313}
314
315bool
316MSHR::handleSnoop(PacketPtr pkt, Counter _order)
317{
318 DPRINTF(Cache, "%s for %s address %x size %d\n", __func__,
319 pkt->cmdString(), pkt->getAddr(), pkt->getSize());
306 if (!inService || (pkt->isExpressSnoop() && downstreamPending)) {
307 // Request has not been issued yet, or it's been issued
308 // locally but is buffered unissued at some downstream cache
309 // which is forwarding us this snoop. Either way, the packet
310 // we're snooping logically precedes this MSHR's request, so
311 // the snoop has no impact on the MSHR, but must be processed
312 // in the standard way by the cache. The only exception is
313 // that if we're an L2+ cache buffering an UpgradeReq from a

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

462 ccprintf(os, "%s Targets:\n", prefix);
463 targets->print(os, verbosity, prefix + " ");
464 if (!deferredTargets->empty()) {
465 ccprintf(os, "%s Deferred Targets:\n", prefix);
466 deferredTargets->print(os, verbosity, prefix + " ");
467 }
468}
469
320 if (!inService || (pkt->isExpressSnoop() && downstreamPending)) {
321 // Request has not been issued yet, or it's been issued
322 // locally but is buffered unissued at some downstream cache
323 // which is forwarding us this snoop. Either way, the packet
324 // we're snooping logically precedes this MSHR's request, so
325 // the snoop has no impact on the MSHR, but must be processed
326 // in the standard way by the cache. The only exception is
327 // that if we're an L2+ cache buffering an UpgradeReq from a

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

476 ccprintf(os, "%s Targets:\n", prefix);
477 targets->print(os, verbosity, prefix + " ");
478 if (!deferredTargets->empty()) {
479 ccprintf(os, "%s Deferred Targets:\n", prefix);
480 deferredTargets->print(os, verbosity, prefix + " ");
481 }
482}
483
484std::string
485MSHR::print() const
486{
487 ostringstream str;
488 print(str);
489 return str.str();
490}
491
470MSHR::~MSHR()
471{
472 delete[] targets;
473 delete[] deferredTargets;
474}
492MSHR::~MSHR()
493{
494 delete[] targets;
495 delete[] deferredTargets;
496}