Deleted Added
sdiff udiff text old ( 11448:8d94df4c9da4 ) new ( 11519:bf08fb8ccf4b )
full compact
1/*
2 * Copyright (c) 1999-2008 Mark D. Hill and David A. Wood
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

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

473 (type == RubyRequestType_IFETCH) ||
474 (type == RubyRequestType_RMW_Read) ||
475 (type == RubyRequestType_Locked_RMW_Read) ||
476 (type == RubyRequestType_Load_Linked)) {
477 memcpy(pkt->getPtr<uint8_t>(),
478 data.getData(getOffset(request_address), pkt->getSize()),
479 pkt->getSize());
480 DPRINTF(RubySequencer, "read data %s\n", data);
481 } else {
482 data.setData(pkt->getConstPtr<uint8_t>(),
483 getOffset(request_address), pkt->getSize());
484 DPRINTF(RubySequencer, "set data %s\n", data);
485 }
486 }
487
488 // If using the RubyTester, update the RubyTester sender state's

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

560 primary_type = RubyRequestType_Locked_RMW_Write;
561 } else {
562 DPRINTF(RubySequencer, "Issuing Locked RMW Read\n");
563 assert(pkt->isRead());
564 primary_type = RubyRequestType_Locked_RMW_Read;
565 }
566 secondary_type = RubyRequestType_ST;
567 } else {
568 if (pkt->isRead()) {
569 if (pkt->req->isInstFetch()) {
570 primary_type = secondary_type = RubyRequestType_IFETCH;
571 } else {
572 bool storeCheck = false;
573 // only X86 need the store check
574 if (system->getArch() == Arch::X86ISA) {
575 uint32_t flags = pkt->req->getFlags();
576 storeCheck = flags &
577 (X86ISA::StoreCheck << X86ISA::FlagShift);
578 }
579 if (storeCheck) {
580 primary_type = RubyRequestType_RMW_Read;
581 secondary_type = RubyRequestType_ST;
582 } else {
583 primary_type = secondary_type = RubyRequestType_LD;
584 }
585 }
586 } else if (pkt->isWrite()) {
587 //
588 // Note: M5 packets do not differentiate ST from RMW_Write
589 //
590 primary_type = secondary_type = RubyRequestType_ST;
591 } else if (pkt->isFlush()) {
592 primary_type = secondary_type = RubyRequestType_FLUSH;
593 } else {
594 panic("Unsupported ruby packet type\n");
595 }
596 }
597
598 RequestStatus status = insertRequest(pkt, primary_type);

--- 179 unchanged lines hidden ---