diff options
author | Nilay Vaish <nilay@cs.wisc.edu> | 2015-08-14 12:04:51 -0500 |
---|---|---|
committer | Nilay Vaish <nilay@cs.wisc.edu> | 2015-08-14 12:04:51 -0500 |
commit | 91a84c5b3cfb888794ac0245c066a4724b9a0871 (patch) | |
tree | 79a8b41aff56655dbd187934d2709fdd7488c6ed /src/mem/ruby/system/RubyPort.cc | |
parent | 9ea5d9cad9381e05004de28ef25309ebe94c3a79 (diff) | |
download | gem5-91a84c5b3cfb888794ac0245c066a4724b9a0871.tar.xz |
ruby: replace Address by Addr
This patch eliminates the type Address defined by the ruby memory system.
This memory system would now use the type Addr that is in use by the
rest of the system.
Diffstat (limited to 'src/mem/ruby/system/RubyPort.cc')
-rw-r--r-- | src/mem/ruby/system/RubyPort.cc | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/mem/ruby/system/RubyPort.cc b/src/mem/ruby/system/RubyPort.cc index 83be9337a..c13aed97e 100644 --- a/src/mem/ruby/system/RubyPort.cc +++ b/src/mem/ruby/system/RubyPort.cc @@ -249,7 +249,7 @@ RubyPort::MemSlavePort::recvTimingReq(PacketPtr pkt) return true; } - assert(Address(pkt->getAddr()).getOffset() + pkt->getSize() <= + assert(getOffset(pkt->getAddr()) + pkt->getSize() <= RubySystem::getBlockSizeBytes()); // Submit the ruby request @@ -299,8 +299,7 @@ RubyPort::MemSlavePort::recvFunctional(PacketPtr pkt) } assert(pkt->getAddr() + pkt->getSize() <= - line_address(Address(pkt->getAddr())).getAddress() + - RubySystem::getBlockSizeBytes()); + makeLineAddress(pkt->getAddr()) + RubySystem::getBlockSizeBytes()); if (access_backing_store) { // The attached physmem contains the official version of data. @@ -504,14 +503,13 @@ RubyPort::MemSlavePort::isPhysMemAddress(Addr addr) const } void -RubyPort::ruby_eviction_callback(const Address& address) +RubyPort::ruby_eviction_callback(Addr address) { DPRINTF(RubyPort, "Sending invalidations.\n"); // This request is deleted in the stack-allocated packet destructor // when this function exits // TODO: should this really be using funcMasterId? - RequestPtr req = - new Request(address.getAddress(), 0, 0, Request::funcMasterId); + RequestPtr req = new Request(address, 0, 0, Request::funcMasterId); // Use a single packet to signal all snooping ports of the invalidation. // This assumes that snooping ports do NOT modify the packet/request Packet pkt(req, MemCmd::InvalidateReq); |