Fix & tweak DPRINTFs for tracediff w/new cache code.
Note that we should *not* print pointer values in DPRINTFs as these needlessly clutter tracediff output. --HG-- extra : convert_revision : 25a448f1b3ac8d453a717a104ad6dc0112fb30bb
This commit is contained in:
parent
92bb9242fb
commit
7cd6c7ee05
6 changed files with 32 additions and 39 deletions
|
@ -453,7 +453,7 @@ TsunamiCChip::postRTC()
|
|||
if (!(cpumask & itint)) {
|
||||
itint |= cpumask;
|
||||
tsunami->intrctrl->post(i, TheISA::INTLEVEL_IRQ2, 0);
|
||||
DPRINTF(Tsunami, "Posting RTC interrupt to cpu=%d", i);
|
||||
DPRINTF(Tsunami, "Posting RTC interrupt to cpu=%d\n", i);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -103,8 +103,8 @@ DmaPort::recvTiming(PacketPtr pkt)
|
|||
|
||||
|
||||
if (pkt->result == Packet::Nacked) {
|
||||
DPRINTF(DMA, "Received nacked Pkt %#x with State: %#x Addr: %#x\n",
|
||||
pkt, pkt->senderState, pkt->getAddr());
|
||||
DPRINTF(DMA, "Received nacked %s addr %#x\n",
|
||||
pkt->cmdString(), pkt->getAddr());
|
||||
|
||||
if (backoffTime < device->minBackoffDelay)
|
||||
backoffTime = device->minBackoffDelay;
|
||||
|
@ -121,8 +121,8 @@ DmaPort::recvTiming(PacketPtr pkt)
|
|||
DmaReqState *state;
|
||||
backoffTime >>= 2;
|
||||
|
||||
DPRINTF(DMA, "Received response Pkt %#x with State: %#x Addr: %#x size: %#x\n",
|
||||
pkt, pkt->senderState, pkt->getAddr(), pkt->req->getSize());
|
||||
DPRINTF(DMA, "Received response %s addr %#x size %#x\n",
|
||||
pkt->cmdString(), pkt->getAddr(), pkt->req->getSize());
|
||||
state = dynamic_cast<DmaReqState*>(pkt->senderState);
|
||||
pendingCount--;
|
||||
|
||||
|
@ -184,8 +184,8 @@ DmaPort::recvRetry()
|
|||
PacketPtr pkt = transmitList.front();
|
||||
bool result = true;
|
||||
do {
|
||||
DPRINTF(DMA, "Retry on Packet %#x with senderState: %#x\n",
|
||||
pkt, pkt->senderState);
|
||||
DPRINTF(DMA, "Retry on %s addr %#x\n",
|
||||
pkt->cmdString(), pkt->getAddr());
|
||||
result = sendTiming(pkt);
|
||||
if (result) {
|
||||
DPRINTF(DMA, "-- Done\n");
|
||||
|
@ -269,8 +269,8 @@ DmaPort::sendDma()
|
|||
return;
|
||||
}
|
||||
|
||||
DPRINTF(DMA, "Attempting to send Packet %#x with addr: %#x\n",
|
||||
pkt, pkt->getAddr());
|
||||
DPRINTF(DMA, "Attempting to send %s addr %#x\n",
|
||||
pkt->cmdString(), pkt->getAddr());
|
||||
|
||||
bool result;
|
||||
do {
|
||||
|
|
|
@ -213,10 +213,7 @@ Bridge::BridgePort::queueForSendTiming(PacketPtr pkt)
|
|||
if (buf->expectResponse && pkt->result == Packet::Nacked)
|
||||
--outstandingResponses;
|
||||
|
||||
|
||||
DPRINTF(BusBridge, "restoring sender state: %#X, from packet buffer: %#X\n",
|
||||
pkt->senderState, buf);
|
||||
DPRINTF(BusBridge, " is response, new dest %d\n", pkt->getDest());
|
||||
DPRINTF(BusBridge, "response, new dest %d\n", pkt->getDest());
|
||||
delete buf;
|
||||
}
|
||||
|
||||
|
@ -229,8 +226,6 @@ Bridge::BridgePort::queueForSendTiming(PacketPtr pkt)
|
|||
|
||||
Tick readyTime = curTick + delay;
|
||||
PacketBuffer *buf = new PacketBuffer(pkt, readyTime);
|
||||
DPRINTF(BusBridge, "old sender state: %#X, new sender state: %#X\n",
|
||||
buf->origSenderState, buf);
|
||||
|
||||
// If we're about to put this packet at the head of the queue, we
|
||||
// need to schedule an event to do the transmit. Otherwise there
|
||||
|
|
|
@ -173,9 +173,8 @@ bool
|
|||
Bus::recvTiming(PacketPtr pkt)
|
||||
{
|
||||
Port *port;
|
||||
DPRINTF(Bus, "recvTiming: packet src %d dest %d addr 0x%x cmd %s result %d\n",
|
||||
pkt->getSrc(), pkt->getDest(), pkt->getAddr(), pkt->cmdString(),
|
||||
pkt->result);
|
||||
DPRINTF(Bus, "recvTiming: packet src %d dest %d addr 0x%x cmd %s\n",
|
||||
pkt->getSrc(), pkt->getDest(), pkt->getAddr(), pkt->cmdString());
|
||||
|
||||
BusPort *pktPort;
|
||||
if (pkt->getSrc() == defaultId)
|
||||
|
@ -261,7 +260,6 @@ Bus::recvTiming(PacketPtr pkt)
|
|||
void
|
||||
Bus::recvRetry(int id)
|
||||
{
|
||||
DPRINTF(Bus, "Received a retry from %s\n", id == -1 ? "self" : interfaces[id]->getPeer()->name());
|
||||
// If there's anything waiting, and the bus isn't busy...
|
||||
if (retryList.size() && curTick >= tickNextIdle) {
|
||||
//retryingPort = retryList.front();
|
||||
|
|
4
src/mem/cache/base_cache.cc
vendored
4
src/mem/cache/base_cache.cc
vendored
|
@ -162,7 +162,7 @@ BaseCache::CachePort::recvRetry()
|
|||
mshr->pkt = copyPkt;
|
||||
|
||||
bool success = sendTiming(pkt);
|
||||
DPRINTF(Cache, "Address %x was %s in sending the timing request\n",
|
||||
DPRINTF(CachePort, "Address %x was %s in sending the timing request\n",
|
||||
pkt->getAddr(), success ? "succesful" : "unsuccesful");
|
||||
|
||||
waitingOnRetry = !success;
|
||||
|
@ -272,7 +272,7 @@ BaseCache::RequestEvent::process()
|
|||
mshr->pkt = copyPkt;
|
||||
|
||||
bool success = cachePort->sendTiming(pkt);
|
||||
DPRINTF(Cache, "Address %x was %s in sending the timing request\n",
|
||||
DPRINTF(CachePort, "Address %x was %s in sending the timing request\n",
|
||||
pkt->getAddr(), success ? "succesful" : "unsuccesful");
|
||||
|
||||
cachePort->waitingOnRetry = !success;
|
||||
|
|
36
src/mem/cache/cache_impl.hh
vendored
36
src/mem/cache/cache_impl.hh
vendored
|
@ -631,8 +631,10 @@ Cache<TagStore,Coherence>::access(PacketPtr &pkt)
|
|||
delete wbPkt;
|
||||
}
|
||||
|
||||
DPRINTF(Cache, "%s %x %s\n", pkt->cmdString(), pkt->getAddr(),
|
||||
(blk) ? "hit" : "miss");
|
||||
if (!pkt->req->isUncacheable()) {
|
||||
DPRINTF(Cache, "%s %x %s\n", pkt->cmdString(), pkt->getAddr(),
|
||||
(blk) ? "hit" : "miss");
|
||||
}
|
||||
|
||||
if (blk) {
|
||||
// Hit
|
||||
|
@ -713,14 +715,14 @@ Cache<TagStore,Coherence>::sendResult(PacketPtr &pkt, MSHR* mshr,
|
|||
BlkType *blk = tags->findBlock(pkt->getAddr());
|
||||
CacheBlk::State old_state = (blk) ? blk->status : 0;
|
||||
CacheBlk::State new_state = coherence->getNewState(pkt,old_state);
|
||||
if (old_state != new_state)
|
||||
DPRINTF(Cache, "Block for blk addr %x moving from state "
|
||||
"%i to %i\n", pkt->getAddr(), old_state, new_state);
|
||||
//Set the state on the upgrade
|
||||
std::memcpy(pkt->getPtr<uint8_t>(), blk->data, blkSize);
|
||||
PacketList writebacks;
|
||||
handleFill(blk, mshr, new_state, writebacks, pkt);
|
||||
assert(writebacks.empty());
|
||||
if (old_state != new_state)
|
||||
DPRINTF(Cache, "Block addr %x moving from state "
|
||||
"%i to %i\n", pkt->getAddr(), old_state, new_state);
|
||||
missQueue->handleResponse(pkt, curTick + hitLatency);
|
||||
}
|
||||
} else if (pkt && !pkt->req->isUncacheable()) {
|
||||
|
@ -756,7 +758,7 @@ Cache<TagStore,Coherence>::handleResponse(PacketPtr &pkt)
|
|||
//Make the response a Bad address and send it
|
||||
}
|
||||
// MemDebug::cacheResponse(pkt);
|
||||
DPRINTF(Cache, "Handling reponse to %x\n", pkt->getAddr());
|
||||
DPRINTF(Cache, "Handling response to %x\n", pkt->getAddr());
|
||||
|
||||
if (pkt->isCacheFill() && !pkt->isNoAllocate()) {
|
||||
DPRINTF(Cache, "Block for addr %x being updated in Cache\n",
|
||||
|
@ -765,13 +767,11 @@ Cache<TagStore,Coherence>::handleResponse(PacketPtr &pkt)
|
|||
CacheBlk::State old_state = (blk) ? blk->status : 0;
|
||||
PacketList writebacks;
|
||||
CacheBlk::State new_state = coherence->getNewState(pkt,old_state);
|
||||
if (old_state != new_state)
|
||||
DPRINTF(Cache, "Block for blk addr %x moving from "
|
||||
"state %i to %i\n",
|
||||
pkt->getAddr(),
|
||||
old_state, new_state);
|
||||
blk = handleFill(blk, (MSHR*)pkt->senderState,
|
||||
new_state, writebacks, pkt);
|
||||
if (old_state != new_state)
|
||||
DPRINTF(Cache, "Block addr %x moving from state %i to %i\n",
|
||||
pkt->getAddr(), old_state, new_state);
|
||||
while (!writebacks.empty()) {
|
||||
PacketPtr wbPkt = writebacks.front();
|
||||
missQueue->doWriteback(wbPkt);
|
||||
|
@ -919,7 +919,7 @@ Cache<TagStore,Coherence>::snoop(PacketPtr &pkt)
|
|||
}
|
||||
|
||||
if (satisfy) {
|
||||
DPRINTF(Cache, "Cache snooped a %s request for addr %x and "
|
||||
DPRINTF(Cache, "snooped a %s request for addr %x and "
|
||||
"now supplying data, new state is %i\n",
|
||||
pkt->cmdString(), blk_addr, new_state);
|
||||
|
||||
|
@ -928,7 +928,7 @@ Cache<TagStore,Coherence>::snoop(PacketPtr &pkt)
|
|||
return;
|
||||
}
|
||||
if (blk)
|
||||
DPRINTF(Cache, "Cache snooped a %s request for addr %x, "
|
||||
DPRINTF(Cache, "snooped a %s request for addr %x, "
|
||||
"new state is %i\n", pkt->cmdString(), blk_addr, new_state);
|
||||
|
||||
handleSnoop(blk, new_state);
|
||||
|
@ -1070,11 +1070,11 @@ return 0;
|
|||
coherence->getNewState(busPkt, old_state);
|
||||
DPRINTF(Cache, "Receive response: %s for addr %x in state %i\n",
|
||||
busPkt->cmdString(), busPkt->getAddr(), old_state);
|
||||
if (old_state != new_state)
|
||||
DPRINTF(Cache, "Block for blk addr %x moving from state "
|
||||
"%i to %i\n", busPkt->getAddr(), old_state, new_state);
|
||||
|
||||
handleFill(blk, busPkt, new_state, writebacks, pkt);
|
||||
if (old_state != new_state)
|
||||
DPRINTF(Cache, "Block addr %x moving from state "
|
||||
"%i to %i\n", busPkt->getAddr(), old_state, new_state);
|
||||
//Free the packet
|
||||
delete busPkt;
|
||||
|
||||
|
@ -1127,8 +1127,8 @@ Cache<TagStore,Coherence>::snoopProbe(PacketPtr &pkt)
|
|||
CacheBlk::State new_state = 0;
|
||||
bool satisfy = coherence->handleBusRequest(pkt,blk,mshr, new_state);
|
||||
if (satisfy) {
|
||||
DPRINTF(Cache, "Cache snooped a %s request for addr %x and "
|
||||
"now supplying data, new state is %i\n",
|
||||
DPRINTF(Cache, "Cache snooped a %s request for addr %x, "
|
||||
"supplying data, new state is %i\n",
|
||||
pkt->cmdString(), blk_addr, new_state);
|
||||
|
||||
handleSnoop(blk, new_state, pkt);
|
||||
|
|
Loading…
Reference in a new issue