gem5  v20.1.0.0
mem_interface.hh
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2012-2020 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  *
14  * Copyright (c) 2013 Amin Farmahini-Farahani
15  * All rights reserved.
16  *
17  * Redistribution and use in source and binary forms, with or without
18  * modification, are permitted provided that the following conditions are
19  * met: redistributions of source code must retain the above copyright
20  * notice, this list of conditions and the following disclaimer;
21  * redistributions in binary form must reproduce the above copyright
22  * notice, this list of conditions and the following disclaimer in the
23  * documentation and/or other materials provided with the distribution;
24  * neither the name of the copyright holders nor the names of its
25  * contributors may be used to endorse or promote products derived from
26  * this software without specific prior written permission.
27  *
28  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
29  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
30  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
31  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
32  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
33  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
34  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
35  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
36  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
37  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
38  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
39  */
40 
46 #ifndef __MEM_INTERFACE_HH__
47 #define __MEM_INTERFACE_HH__
48 
49 #include <deque>
50 #include <string>
51 #include <unordered_set>
52 #include <utility>
53 #include <vector>
54 
55 #include "base/statistics.hh"
56 #include "enums/AddrMap.hh"
57 #include "enums/PageManage.hh"
58 #include "mem/abstract_mem.hh"
59 #include "mem/drampower.hh"
60 #include "mem/mem_ctrl.hh"
61 #include "params/DRAMInterface.hh"
62 #include "params/MemInterface.hh"
63 #include "params/NVMInterface.hh"
64 #include "sim/eventq.hh"
65 
71 {
72  protected:
82  class Bank
83  {
84 
85  public:
86  static const uint32_t NO_ROW = -1;
87 
88  uint32_t openRow;
89  uint8_t bank;
90  uint8_t bankgr;
91 
96 
97  uint32_t rowAccesses;
98  uint32_t bytesAccessed;
99 
100  Bank() :
101  openRow(NO_ROW), bank(0), bankgr(0),
104  { }
105  };
106 
111 
116  unsigned int maxCommandsPerWindow;
117 
122  Enums::AddrMap addrMapping;
123 
129  const uint32_t burstSize;
130  const uint32_t deviceSize;
131  const uint32_t deviceRowBufferSize;
132  const uint32_t devicesPerRank;
133  const uint32_t rowBufferSize;
134  const uint32_t burstsPerRowBuffer;
135  const uint32_t burstsPerStripe;
136  const uint32_t ranksPerChannel;
137  const uint32_t banksPerRank;
138  uint32_t rowsPerBank;
139 
144  const Tick tCS;
145  const Tick tBURST;
146  const Tick tRTW;
147  const Tick tWTR;
148 
149  /*
150  * @return delay between write and read commands
151  */
152  virtual Tick writeToReadDelay() const { return tBURST + tWTR; }
153 
154  /*
155  * @return delay between write and read commands
156  */
157  Tick readToWriteDelay() const { return tBURST + tRTW; }
158 
159  /*
160  * @return delay between accesses to different ranks
161  */
162  Tick rankToRankDelay() const { return tBURST + tCS; }
163 
164 
165  public:
166 
173  const uint32_t readBufferSize;
174  const uint32_t writeBufferSize;
175 
182  void setCtrl(MemCtrl* _ctrl, unsigned int command_window);
183 
194 
201  virtual void setupRank(const uint8_t rank, const bool is_read) = 0;
202 
209  virtual bool allRanksDrained() const = 0;
210 
223  chooseNextFRFCFS(MemPacketQueue& queue, Tick min_col_at) const = 0;
224 
225  /*
226  * Function to calulate unloaded latency
227  */
228  virtual Tick accessLatency() const = 0;
229 
233  uint32_t bytesPerBurst() const { return burstSize; }
234 
235  /*
236  * @return time to offset next command
237  */
238  virtual Tick commandOffset() const = 0;
239 
245  virtual bool burstReady(MemPacket* pkt) const = 0;
246 
252  Tick rankDelay() const { return tCS; }
253 
258  Tick minReadToWriteDataGap() const { return std::min(tRTW, tCS); }
259 
264  Tick minWriteToReadDataGap() const { return std::min(tWTR, tCS); }
265 
279  MemPacket* decodePacket(const PacketPtr pkt, Addr pkt_addr,
280  unsigned int size, bool is_read, bool is_dram);
281 
289  virtual void addRankToRankDelay(Tick cmd_at) = 0;
290 
291  typedef MemInterfaceParams Params;
292  MemInterface(const Params* _p);
293 };
294 
302 {
303  private:
308  struct Command
309  {
310  Data::MemCommand::cmds type;
311  uint8_t bank;
313 
314  constexpr Command(Data::MemCommand::cmds _type, uint8_t _bank,
315  Tick time_stamp)
316  : type(_type), bank(_bank), timeStamp(time_stamp)
317  { }
318  };
319 
348  {
349  PWR_IDLE = 0,
355  };
356 
388  {
389  REF_IDLE = 0,
396  };
397 
398  class Rank;
399  struct RankStats : public Stats::Group
400  {
401  RankStats(DRAMInterface &dram, Rank &rank);
402 
403  void regStats() override;
404  void resetStats() override;
405  void preDumpStats() override;
406 
408 
409  /*
410  * Command energies
411  */
417 
418  /*
419  * Active Background Energy
420  */
422 
423  /*
424  * Precharge Background Energy
425  */
427 
428  /*
429  * Active Power-Down Energy
430  */
432 
433  /*
434  * Precharge Power-Down Energy
435  */
437 
438  /*
439  * self Refresh Energy
440  */
442 
445 
451 
456  };
457 
465  class Rank : public EventManager
466  {
467  private:
468 
473 
479 
484 
489 
494 
498  void updatePowerStats();
499 
507  void schedulePowerEvent(PowerState pwr_state, Tick tick);
508 
509  public:
510 
515 
520 
525 
529  uint8_t rank;
530 
534  uint32_t readEntries;
535 
539  uint32_t writeEntries;
540 
547 
552 
557 
565 
571 
576  unsigned int numBanksActive;
577 
580 
585 
586  Rank(const DRAMInterfaceParams* _p, int _rank,
587  DRAMInterface& _dram);
588 
589  const std::string name() const { return csprintf("%d", rank); }
590 
597  void startup(Tick ref_tick);
598 
602  void suspend();
603 
610  bool inRefIdleState() const { return refreshState == REF_IDLE; }
611 
619  bool inPwrIdleState() const { return pwrState == PWR_IDLE; }
620 
631  bool forceSelfRefreshExit() const;
632 
639  bool isQueueEmpty() const;
640 
645  void checkDrainDone();
646 
653  void flushCmdList();
654 
658  void computeStats();
659 
663  void resetStats();
664 
671  void powerDownSleep(PowerState pwr_state, Tick tick);
672 
680  void scheduleWakeUpEvent(Tick exit_delay);
681 
682  void processWriteDoneEvent();
684 
685  void processActivateEvent();
687 
688  void processPrechargeEvent();
690 
691  void processRefreshEvent();
693 
694  void processPowerEvent();
696 
697  void processWakeUpEvent();
699 
700  protected:
702  };
703 
711  static bool
712  sortTime(const Command& cmd, const Command& cmd_next)
713  {
714  return cmd.timeStamp < cmd_next.timeStamp;
715  }
716 
720  const uint32_t bankGroupsPerRank;
721  const bool bankGroupArch;
722 
726  const Tick tCL;
730  const Tick tCCD_L;
731  const Tick tRCD;
732  const Tick tRP;
733  const Tick tRAS;
734  const Tick tWR;
735  const Tick tRTP;
736  const Tick tRFC;
737  const Tick tREFI;
738  const Tick tRRD;
739  const Tick tRRD_L;
740  const Tick tPPD;
741  const Tick tAAD;
742  const Tick tXAW;
743  const Tick tXP;
744  const Tick tXS;
746  const bool dataClockSync;
747  const bool burstInterleave;
748  const uint8_t twoCycleActivate;
749  const uint32_t activationLimit;
752 
753 
754  Enums::PageManage pageMgmt;
759  const uint32_t maxAccessesPerRow;
760 
761  // timestamp offset
762  uint64_t timeStampOffset;
763 
764  // Holds the value of the DRAM rank of burst issued
765  uint8_t activeRank;
766 
769 
772 
784  void activateBank(Rank& rank_ref, Bank& bank_ref, Tick act_tick,
785  uint32_t row);
786 
798  void prechargeBank(Rank& rank_ref, Bank& bank_ref,
799  Tick pre_tick, bool auto_or_preall = false,
800  bool trace = true);
801 
802  struct DRAMStats : public Stats::Group
803  {
805 
806  void regStats() override;
807  void resetStats() override;
808 
810 
814 
818 
819  // Latencies summed over all requests
823 
824  // Average latencies per request
828 
829  // Row hit count and rate
835  // Number of bytes transferred to/from DRAM
838 
839  // Average bandwidth
843  // bus utilization
848  };
849 
851 
856 
857  /*
858  * @return delay between write and read commands
859  */
860  Tick writeToReadDelay() const override { return tBURST + tWTR + tCL; }
861 
873  minBankPrep(const MemPacketQueue& queue, Tick min_col_at) const;
874 
875  /*
876  * @return time to send a burst of data without gaps
877  */
878  Tick
879  burstDelay() const
880  {
881  return (burstInterleave ? tBURST_MAX / 2 : tBURST);
882  }
883 
884  public:
888  void init() override;
889 
893  void startup() override;
894 
901  void setupRank(const uint8_t rank, const bool is_read) override;
902 
906  void drainRanks();
907 
917  bool allRanksDrained() const override;
918 
922  void suspend();
923 
924  /*
925  * @return time to offset next command
926  */
927  Tick commandOffset() const override { return (tRP + tRCD); }
928 
929  /*
930  * Function to calulate unloaded, closed bank access latency
931  */
932  Tick accessLatency() const override { return (tRP + tRCD + tCL); }
933 
943  chooseNextFRFCFS(MemPacketQueue& queue, Tick min_col_at) const override;
944 
960  doBurstAccess(MemPacket* mem_pkt, Tick next_burst_at,
961  const std::vector<MemPacketQueue>& queue);
962 
970  bool
971  burstReady(MemPacket* pkt) const override
972  {
973  return ranks[pkt->rank]->inRefIdleState();
974  }
975 
984  bool isBusy();
985 
993  void addRankToRankDelay(Tick cmd_at) override;
994 
1002  void respondEvent(uint8_t rank);
1003 
1010  void checkRefreshState(uint8_t rank);
1011 
1012  DRAMInterface(const DRAMInterfaceParams* _p);
1013 };
1014 
1022 {
1023  private:
1027  class Rank : public EventManager
1028  {
1029  public:
1030 
1034  uint8_t rank;
1035 
1041 
1042  Rank(const NVMInterfaceParams* _p, int _rank,
1043  NVMInterface& _nvm);
1044  };
1045 
1049  const uint32_t maxPendingWrites;
1050  const uint32_t maxPendingReads;
1051  const bool twoCycleRdWr;
1052 
1056  const Tick tREAD;
1057  const Tick tWRITE;
1058  const Tick tSEND;
1059 
1060  struct NVMStats : public Stats::Group
1061  {
1063 
1064  void regStats() override;
1065 
1067 
1071 
1074 
1075  // Latencies summed over all requests
1079 
1080  // Average latencies per request
1084 
1087 
1088  // Average bandwidth
1095 
1100  };
1102 
1103  void processWriteRespondEvent();
1105 
1106  void processReadReadyEvent();
1108 
1113 
1123 
1125 
1131  bool writeRespQueueEmpty() const { return writeRespQueue.empty(); }
1132 
1137 
1138  // keep track of reads that have issued for which data is either
1139  // not yet ready or has not yet been transferred to the ctrl
1142 
1143  public:
1144  // keep track of the number of reads that have yet to be issued
1146 
1147  // number of writes in the writeQueue for the NVM interface
1149 
1153  void init() override;
1154 
1161  void setupRank(const uint8_t rank, const bool is_read) override;
1162 
1169  bool allRanksDrained() const override { return writeRespQueueEmpty(); }
1170 
1171  /*
1172  * @return time to offset next command
1173  */
1174  Tick commandOffset() const override { return tBURST; }
1175 
1184  bool burstReady(MemPacket* pkt) const override;
1185 
1197  bool isBusy(bool read_queue_empty, bool all_writes_nvm);
1208  chooseNextFRFCFS(MemPacketQueue& queue, Tick min_col_at) const override;
1209 
1217  void addRankToRankDelay(Tick cmd_at) override;
1218 
1219 
1223  void chooseRead(MemPacketQueue& queue);
1224 
1225  /*
1226  * Function to calulate unloaded access latency
1227  */
1228  Tick accessLatency() const override { return (tREAD + tSEND); }
1229 
1235  bool
1237  {
1238  return writeRespQueue.size() == maxPendingWrites;
1239  }
1240 
1241  bool
1243  {
1244  return ((numReadsToIssue != 0) &&
1246  }
1247 
1257  doBurstAccess(MemPacket* pkt, Tick next_burst_at);
1258 
1259  NVMInterface(const NVMInterfaceParams* _p);
1260 };
1261 
1262 #endif //__MEM_INTERFACE_HH__
MemPacket::rank
const uint8_t rank
Will be populated by address decoder.
Definition: mem_ctrl.hh:113
MemInterface::accessLatency
virtual Tick accessLatency() const =0
DRAMInterface::Rank::updatePowerStats
void updatePowerStats()
Function to update Power Stats.
Definition: mem_interface.cc:1777
DRAMInterface::DRAMInterface
DRAMInterface(const DRAMInterfaceParams *_p)
Definition: mem_interface.cc:733
MemInterface::setupRank
virtual void setupRank(const uint8_t rank, const bool is_read)=0
Setup the rank based on packet received.
DRAMInterface::Rank::pwrStateTick
Tick pwrStateTick
Track when we transitioned to the current power state.
Definition: mem_interface.hh:488
MemInterface::burstReady
virtual bool burstReady(MemPacket *pkt) const =0
Check if a burst operation can be issued to the interface.
NVMInterface::Rank::rank
uint8_t rank
Current Rank index.
Definition: mem_interface.hh:1034
DRAMInterface::Rank::suspend
void suspend()
Stop the refresh events.
Definition: mem_interface.cc:1178
DRAMInterface::tRTP
const Tick tRTP
Definition: mem_interface.hh:735
NVMInterface::NVMStats::bytesPerBank
Stats::Histogram bytesPerBank
Definition: mem_interface.hh:1099
MemInterface::banksPerRank
const uint32_t banksPerRank
Definition: mem_interface.hh:137
DRAMInterface::RankStats::actPowerDownEnergy
Stats::Scalar actPowerDownEnergy
Definition: mem_interface.hh:431
DRAMInterface::Rank::processWriteDoneEvent
void processWriteDoneEvent()
Definition: mem_interface.cc:1285
DRAMInterface::DRAMStats::perBankWrBursts
Stats::Vector perBankWrBursts
Definition: mem_interface.hh:817
NVMInterface::numWritesQueued
uint32_t numWritesQueued
Definition: mem_interface.hh:1148
DRAMInterface::bankGroupArch
const bool bankGroupArch
Definition: mem_interface.hh:721
NVMInterface::NVMStats::totQLat
Stats::Scalar totQLat
Definition: mem_interface.hh:1076
MemInterface::Bank::Bank
Bank()
Definition: mem_interface.hh:100
MemInterface::writeToReadDelay
virtual Tick writeToReadDelay() const
Definition: mem_interface.hh:152
DRAMInterface::Rank::lastBurstTick
Tick lastBurstTick
Track when we issued the last read/write burst.
Definition: mem_interface.hh:584
MemInterface::minWriteToReadDataGap
Tick minWriteToReadDataGap() const
Definition: mem_interface.hh:264
NVMInterface::NVMStats::perBankRdBursts
Stats::Vector perBankRdBursts
Definition: mem_interface.hh:1072
DRAMInterface::doBurstAccess
std::pair< Tick, Tick > doBurstAccess(MemPacket *mem_pkt, Tick next_burst_at, const std::vector< MemPacketQueue > &queue)
Actually do the burst - figure out the latency it will take to service the req based on bank state,...
Definition: mem_interface.cc:456
DRAMInterface::prechargeBank
void prechargeBank(Rank &rank_ref, Bank &bank_ref, Tick pre_tick, bool auto_or_preall=false, bool trace=true)
Precharge a given bank and also update when the precharge is done.
Definition: mem_interface.cc:393
DRAMInterface::RankStats::regStats
void regStats() override
Callback to set stat parameters.
Definition: mem_interface.cc:1969
NVMInterface::maxPendingReads
const uint32_t maxPendingReads
Definition: mem_interface.hh:1050
DRAMInterface::Rank::powerEvent
EventFunctionWrapper powerEvent
Definition: mem_interface.hh:695
DRAMInterface::REF_START
@ REF_START
Definition: mem_interface.hh:394
MemInterface::chooseNextFRFCFS
virtual std::pair< MemPacketQueue::iterator, Tick > chooseNextFRFCFS(MemPacketQueue &queue, Tick min_col_at) const =0
For FR-FCFS policy, find first command that can issue Function will be overriden by interface to sele...
MemInterface::Bank::actAllowedAt
Tick actAllowedAt
Definition: mem_interface.hh:95
drampower.hh
abstract_mem.hh
DRAMInterface::REF_IDLE
@ REF_IDLE
Definition: mem_interface.hh:389
DRAMInterface::Rank::pwrState
PowerState pwrState
Current power state.
Definition: mem_interface.hh:514
NVMInterface::NVMStats::perBankWrBursts
Stats::Vector perBankWrBursts
Definition: mem_interface.hh:1073
DRAMInterface::RankStats::resetStats
void resetStats() override
Callback to reset stats.
Definition: mem_interface.cc:1984
DRAMInterface::RankStats
Definition: mem_interface.hh:399
DRAMInterface::DRAMStats::avgRdBW
Stats::Formula avgRdBW
Definition: mem_interface.hh:840
NVMInterface::twoCycleRdWr
const bool twoCycleRdWr
Definition: mem_interface.hh:1051
DRAMInterface::Rank::banks
std::vector< Bank > banks
Vector of Banks.
Definition: mem_interface.hh:570
MemInterface::MemInterface
MemInterface(const Params *_p)
Definition: mem_interface.cc:54
DRAMInterface::RankStats::writeEnergy
Stats::Scalar writeEnergy
Definition: mem_interface.hh:415
NVMInterface::NVMStats::readBursts
Stats::Scalar readBursts
NVM stats.
Definition: mem_interface.hh:1069
MemInterface::Bank::preAllowedAt
Tick preAllowedAt
Definition: mem_interface.hh:94
MemInterface::Bank::openRow
uint32_t openRow
Definition: mem_interface.hh:88
MemInterface::Bank::rowAccesses
uint32_t rowAccesses
Definition: mem_interface.hh:97
NVMInterface::chooseNextFRFCFS
std::pair< MemPacketQueue::iterator, Tick > chooseNextFRFCFS(MemPacketQueue &queue, Tick min_col_at) const override
For FR-FCFS policy, find first NVM command that can issue default to first command to prepped region.
Definition: mem_interface.cc:2073
DRAMInterface::Rank::processWakeUpEvent
void processWakeUpEvent()
Definition: mem_interface.cc:1626
DRAMInterface::tRAS
const Tick tRAS
Definition: mem_interface.hh:733
DRAMInterface
Interface to DRAM devices with media specific parameters, statistics, and functions.
Definition: mem_interface.hh:301
Clocked::tick
Tick tick
Definition: clocked_object.hh:65
DRAMInterface::respondEvent
void respondEvent(uint8_t rank)
Complete response process for DRAM when read burst is complete This will update the counters and chec...
Definition: mem_interface.cc:940
NVMInterface::NVMStats::writeBursts
Stats::Scalar writeBursts
Definition: mem_interface.hh:1070
DRAMInterface::RankStats::prePowerDownEnergy
Stats::Scalar prePowerDownEnergy
Definition: mem_interface.hh:436
DRAMInterface::Rank::wakeUpEvent
EventFunctionWrapper wakeUpEvent
Definition: mem_interface.hh:698
DRAMInterface::Rank::prechargeEvent
EventFunctionWrapper prechargeEvent
Definition: mem_interface.hh:689
NVMInterface::NVMStats::peakBW
Stats::Formula peakBW
Definition: mem_interface.hh:1091
Tick
uint64_t Tick
Tick count type.
Definition: types.hh:63
DRAMInterface::Rank::name
const std::string name() const
Definition: mem_interface.hh:589
DRAMInterface::Rank::resetStats
void resetStats()
Reset stats on a stats event.
Definition: mem_interface.cc:1833
DRAMInterface::isBusy
bool isBusy()
This function checks if ranks are actively refreshing and therefore busy.
Definition: mem_interface.cc:892
DRAMInterface::setupRank
void setupRank(const uint8_t rank, const bool is_read) override
Setup the rank based on packet received.
Definition: mem_interface.cc:929
DRAMInterface::PWR_PRE_PDN
@ PWR_PRE_PDN
Definition: mem_interface.hh:352
NVMInterface::tSEND
const Tick tSEND
Definition: mem_interface.hh:1058
DRAMInterface::tAAD
const Tick tAAD
Definition: mem_interface.hh:741
DRAMInterface::Rank::inPwrIdleState
bool inPwrIdleState() const
Check if the current rank has all banks closed and is not in a low power state.
Definition: mem_interface.hh:619
DRAMInterface::DRAMStats::readRowHitRate
Stats::Formula readRowHitRate
Definition: mem_interface.hh:832
AddrRange::getOffset
Addr getOffset(const Addr &a) const
Determine the offset of an address within the range.
Definition: addr_range.hh:559
MemInterface::tCK
const Tick M5_CLASS_VAR_USED tCK
General timing requirements.
Definition: mem_interface.hh:143
DRAMInterface::writeToReadDelay
Tick writeToReadDelay() const override
Definition: mem_interface.hh:860
DRAMInterface::burstDelay
Tick burstDelay() const
Definition: mem_interface.hh:879
DRAMInterface::Rank::isQueueEmpty
bool isQueueEmpty() const
Check if the command queue of current rank is idle.
Definition: mem_interface.cc:1190
DRAMInterface::clkResyncDelay
const Tick clkResyncDelay
Definition: mem_interface.hh:745
MemInterface::tBURST
const Tick tBURST
Definition: mem_interface.hh:145
std::vector
STL vector class.
Definition: stl.hh:37
DRAMInterface::Command::type
Data::MemCommand::cmds type
Definition: mem_interface.hh:310
DRAMInterface::tXAW
const Tick tXAW
Definition: mem_interface.hh:742
NVMInterface::init
void init() override
Initialize the NVM interface and verify parameters.
Definition: mem_interface.cc:2056
DRAMInterface::Rank::actTicks
std::deque< Tick > actTicks
List to keep track of activate ticks.
Definition: mem_interface.hh:579
NVMInterface::NVMStats::busUtil
Stats::Formula busUtil
Definition: mem_interface.hh:1092
DRAMInterface::Rank::scheduleWakeUpEvent
void scheduleWakeUpEvent(Tick exit_delay)
schedule and event to wake-up from power-down or self-refresh and update bank timing parameters
Definition: mem_interface.cc:1574
NVMInterface::NVMInterface
NVMInterface(const NVMInterfaceParams *_p)
Definition: mem_interface.cc:1999
Stats::Vector
A vector of scalar stats.
Definition: statistics.hh:2575
DRAMInterface::bankGroupsPerRank
const uint32_t bankGroupsPerRank
DRAM specific device characteristics.
Definition: mem_interface.hh:720
MemInterface::Bank::bankgr
uint8_t bankgr
Definition: mem_interface.hh:90
DRAMInterface::Rank::Rank
Rank(const DRAMInterfaceParams *_p, int _rank, DRAMInterface &_dram)
Definition: mem_interface.cc:1127
NVMInterface::accessLatency
Tick accessLatency() const override
Definition: mem_interface.hh:1228
DRAMInterface::Rank::forceSelfRefreshExit
bool forceSelfRefreshExit() const
Trigger a self-refresh exit if there are entries enqueued Exit if there are any read entries regardle...
Definition: mem_interface.cc:1843
MemInterface::tCS
const Tick tCS
Definition: mem_interface.hh:144
DRAMInterface::DRAMStats::busUtilRead
Stats::Formula busUtilRead
Definition: mem_interface.hh:845
DRAMInterface::RankStats::RankStats
RankStats(DRAMInterface &dram, Rank &rank)
Definition: mem_interface.cc:1943
MemInterface::maxCommandsPerWindow
unsigned int maxCommandsPerWindow
Number of commands that can issue in the defined controller command window, used to verify command ba...
Definition: mem_interface.hh:116
DRAMInterface::PWR_IDLE
@ PWR_IDLE
Definition: mem_interface.hh:349
DRAMInterface::DRAMStats::avgQLat
Stats::Formula avgQLat
Definition: mem_interface.hh:825
EventFunctionWrapper
Definition: eventq.hh:1101
Stats::Histogram
A simple histogram stat.
Definition: statistics.hh:2654
DRAMInterface::REF_DRAIN
@ REF_DRAIN
Definition: mem_interface.hh:390
DRAMInterface::Rank::writeDoneEvent
EventFunctionWrapper writeDoneEvent
Definition: mem_interface.hh:683
DRAMInterface::Rank::inRefIdleState
bool inRefIdleState() const
Check if there is no refresh and no preparation of refresh ongoing i.e.
Definition: mem_interface.hh:610
NVMInterface::setupRank
void setupRank(const uint8_t rank, const bool is_read) override
Setup the rank based on packet received.
Definition: mem_interface.cc:2061
DRAMInterface::Rank::flushCmdList
void flushCmdList()
Push command out of cmdList queue that are scheduled at or before curTick() to DRAMPower library All ...
Definition: mem_interface.cc:1216
Stats::Scalar
This is a simple scalar statistic, like a counter.
Definition: statistics.hh:2533
AbstractMemory
An abstract memory represents a contiguous block of physical memory, with an associated address range...
Definition: abstract_mem.hh:104
NVMInterface::allRanksDrained
bool allRanksDrained() const override
Check drain state of NVM interface.
Definition: mem_interface.hh:1169
NVMInterface::writeRespQueueFull
bool writeRespQueueFull() const
Check if the write response queue has reached defined threshold.
Definition: mem_interface.hh:1236
NVMInterface::NVMStats::bytesWritten
Stats::Scalar bytesWritten
Definition: mem_interface.hh:1086
M5_CLASS_VAR_USED
#define M5_CLASS_VAR_USED
Definition: compiler.hh:64
DRAMInterface::tXP
const Tick tXP
Definition: mem_interface.hh:743
DRAMInterface::Rank::computeStats
void computeStats()
Computes stats just prior to dump event.
Definition: mem_interface.cc:1820
NVMInterface
Interface to NVM devices with media specific parameters, statistics, and functions.
Definition: mem_interface.hh:1021
NVMInterface::NVMStats::nvm
NVMInterface & nvm
Definition: mem_interface.hh:1066
NVMInterface::NVMStats
Definition: mem_interface.hh:1060
DRAMInterface::tREFI
const Tick tREFI
Definition: mem_interface.hh:737
DRAMInterface::minBankPrep
std::pair< std::vector< uint32_t >, bool > minBankPrep(const MemPacketQueue &queue, Tick min_col_at) const
Find which are the earliest banks ready to issue an activate for the enqueued requests.
Definition: mem_interface.cc:1037
DRAMInterface::tXS
const Tick tXS
Definition: mem_interface.hh:744
NVMInterface::maxPendingWrites
const uint32_t maxPendingWrites
NVM specific device and channel characteristics.
Definition: mem_interface.hh:1049
MemInterface::readToWriteDelay
Tick readToWriteDelay() const
Definition: mem_interface.hh:157
DRAMInterface::activateBank
void activateBank(Rank &rank_ref, Bank &bank_ref, Tick act_tick, uint32_t row)
Keep track of when row activations happen, in order to enforce the maximum number of activations in t...
Definition: mem_interface.cc:284
DRAMInterface::maxAccessesPerRow
const uint32_t maxAccessesPerRow
Max column accesses (read and write) per row, before forefully closing it.
Definition: mem_interface.hh:759
DRAMInterface::Rank::cmdList
std::vector< Command > cmdList
List of commands issued, to be sent to DRAMPpower at refresh and stats dump.
Definition: mem_interface.hh:564
DRAMInterface::sortTime
static bool sortTime(const Command &cmd, const Command &cmd_next)
Function for sorting Command structures based on timeStamp.
Definition: mem_interface.hh:712
NVMInterface::Rank::Rank
Rank(const NVMInterfaceParams *_p, int _rank, NVMInterface &_nvm)
Definition: mem_interface.cc:2044
DRAMInterface::burstReady
bool burstReady(MemPacket *pkt) const override
Check if a burst operation can be issued to the DRAM.
Definition: mem_interface.hh:971
NVMInterface::NVMStats::avgMemAccLat
Stats::Formula avgMemAccLat
Definition: mem_interface.hh:1083
NVMInterface::NVMStats::avgRdBW
Stats::Formula avgRdBW
Definition: mem_interface.hh:1089
AbstractMemory::size
uint64_t size() const
Get the memory size.
Definition: abstract_mem.hh:285
DRAMInterface::DRAMStats::busUtilWrite
Stats::Formula busUtilWrite
Definition: mem_interface.hh:846
DRAMInterface::checkRefreshState
void checkRefreshState(uint8_t rank)
Check the refresh state to determine if refresh needs to be kicked back into action after a read resp...
Definition: mem_interface.cc:987
DRAMInterface::RankStats::readEnergy
Stats::Scalar readEnergy
Definition: mem_interface.hh:414
MemInterface::addRankToRankDelay
virtual void addRankToRankDelay(Tick cmd_at)=0
Add rank to rank delay to bus timing to all banks in all ranks when access to an alternate interface ...
DRAMInterface::tWR
const Tick tWR
Definition: mem_interface.hh:734
MemInterface::Bank::NO_ROW
static const uint32_t NO_ROW
Definition: mem_interface.hh:86
DRAMInterface::DRAMStats::resetStats
void resetStats() override
Callback to reset stats.
Definition: mem_interface.cc:1849
NVMInterface::writeRespQueue
std::list< Tick > writeRespQueue
Holding queue for non-deterministic write commands, which maintains writes that have been issued but ...
Definition: mem_interface.hh:1122
DRAMInterface::ranks
std::vector< Rank * > ranks
Vector of dram ranks.
Definition: mem_interface.hh:855
DRAMInterface::DRAMStats::totQLat
Stats::Scalar totQLat
Definition: mem_interface.hh:820
MemInterface::rankDelay
Tick rankDelay() const
Determine the required delay for an access to a different rank.
Definition: mem_interface.hh:252
DRAMInterface::RankStats::selfRefreshEnergy
Stats::Scalar selfRefreshEnergy
Definition: mem_interface.hh:441
MemInterface::Bank::bank
uint8_t bank
Definition: mem_interface.hh:89
NVMInterface::nextReadAt
Tick nextReadAt
Till when must we wait before issuing next read command?
Definition: mem_interface.hh:1136
NVMInterface::writeRespQueueEmpty
bool writeRespQueueEmpty() const
Check if the write response queue is empty.
Definition: mem_interface.hh:1131
statistics.hh
DRAMInterface::DRAMStats::avgWrBW
Stats::Formula avgWrBW
Definition: mem_interface.hh:841
PowerState
Helper class for objects that have power states.
Definition: power_state.hh:61
DRAMInterface::RankStats::averagePower
Stats::Scalar averagePower
Definition: mem_interface.hh:444
DRAMInterface::DRAMStats::bytesWritten
Stats::Scalar bytesWritten
Definition: mem_interface.hh:837
DRAMInterface::activeRank
uint8_t activeRank
Definition: mem_interface.hh:765
DRAMInterface::DRAMStats::pageHitRate
Stats::Formula pageHitRate
Definition: mem_interface.hh:847
DRAMInterface::REF_RUN
@ REF_RUN
Definition: mem_interface.hh:395
DRAMInterface::DRAMStats::writeRowHitRate
Stats::Formula writeRowHitRate
Definition: mem_interface.hh:833
DRAMInterface::Rank::refreshDueAt
Tick refreshDueAt
Keep track of when a refresh is due.
Definition: mem_interface.hh:493
DRAMInterface::Rank::wakeUpAllowedAt
Tick wakeUpAllowedAt
delay low-power exit until this requirement is met
Definition: mem_interface.hh:551
DRAMInterface::commandOffset
Tick commandOffset() const override
Definition: mem_interface.hh:927
DRAMInterface::REF_SREF_EXIT
@ REF_SREF_EXIT
Definition: mem_interface.hh:392
MemInterface::ranksPerChannel
const uint32_t ranksPerChannel
Definition: mem_interface.hh:136
DRAMInterface::Rank::stats
RankStats stats
Definition: mem_interface.hh:701
DRAMInterface::PWR_REF
@ PWR_REF
Definition: mem_interface.hh:350
NVMInterface::commandOffset
Tick commandOffset() const override
Definition: mem_interface.hh:1174
DRAMInterface::DRAMStats::regStats
void regStats() override
Callback to set stat parameters.
Definition: mem_interface.cc:1896
DRAMInterface::DRAMStats::readRowHits
Stats::Scalar readRowHits
Definition: mem_interface.hh:830
DRAMInterface::DRAMStats::bytesRead
Stats::Scalar bytesRead
Definition: mem_interface.hh:836
NVMInterface::NVMStats::busUtilWrite
Stats::Formula busUtilWrite
Definition: mem_interface.hh:1094
MemInterface::Bank::bytesAccessed
uint32_t bytesAccessed
Definition: mem_interface.hh:98
MemPacket
A memory packet stores packets along with the timestamp of when the packet entered the queue,...
Definition: mem_ctrl.hh:91
MemInterface::getCtrlAddr
Addr getCtrlAddr(Addr addr)
Get an address in a dense range which starts from 0.
Definition: mem_interface.hh:193
NVMInterface::isBusy
bool isBusy(bool read_queue_empty, bool all_writes_nvm)
This function checks if ranks are busy.
Definition: mem_interface.cc:2469
DRAMInterface::RefreshState
RefreshState
The refresh state is used to control the progress of the refresh scheduling.
Definition: mem_interface.hh:387
mem_ctrl.hh
MemInterface::setCtrl
void setCtrl(MemCtrl *_ctrl, unsigned int command_window)
Set a pointer to the controller and initialize interface based on controller parameters.
Definition: mem_interface.cc:76
DRAMInterface::DRAMStats::bytesPerActivate
Stats::Histogram bytesPerActivate
Definition: mem_interface.hh:834
NVMInterface::NVMStats::avgBusLat
Stats::Formula avgBusLat
Definition: mem_interface.hh:1082
DRAMInterface::Command
Simple structure to hold the values needed to keep track of commands for DRAMPower.
Definition: mem_interface.hh:308
NVMInterface::NVMStats::regStats
void regStats() override
Callback to set stat parameters.
Definition: mem_interface.cc:2524
NVMInterface::readReadyQueue
std::deque< Tick > readReadyQueue
Definition: mem_interface.hh:1124
std::pair
STL pair class.
Definition: stl.hh:58
MemInterface::tWTR
const Tick tWTR
Definition: mem_interface.hh:147
DRAMInterface::startup
void startup() override
Iterate through dram ranks and instantiate per rank startup routine.
Definition: mem_interface.cc:879
MemInterface::burstsPerRowBuffer
const uint32_t burstsPerRowBuffer
Definition: mem_interface.hh:134
DRAMInterface::timeStampOffset
uint64_t timeStampOffset
Definition: mem_interface.hh:762
DRAMInterface::DRAMStats::perBankRdBursts
Stats::Vector perBankRdBursts
DRAM per bank stats.
Definition: mem_interface.hh:816
NVMInterface::numReadsToIssue
uint16_t numReadsToIssue
Definition: mem_interface.hh:1145
DRAMInterface::rdToWrDlySameBG
const Tick rdToWrDlySameBG
Definition: mem_interface.hh:751
NVMInterface::Rank::banks
std::vector< Bank > banks
Vector of NVM banks.
Definition: mem_interface.hh:1040
NVMInterface::NVMStats::pendingReads
Stats::Histogram pendingReads
NVM stats.
Definition: mem_interface.hh:1097
DRAMInterface::twoCycleActivate
const uint8_t twoCycleActivate
Definition: mem_interface.hh:748
DRAMInterface::Rank::power
DRAMPower power
One DRAMPower instance per rank.
Definition: mem_interface.hh:556
Addr
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
Definition: types.hh:142
DRAMInterface::Rank::rank
uint8_t rank
Current Rank index.
Definition: mem_interface.hh:529
DRAMInterface::Rank::inLowPowerState
bool inLowPowerState
rank is in or transitioning to power-down or self-refresh
Definition: mem_interface.hh:524
DRAMInterface::allRanksDrained
bool allRanksDrained() const override
Return true once refresh is complete for all ranks and there are no additional commands enqueued.
Definition: mem_interface.cc:1014
MemInterface::addrMapping
Enums::AddrMap addrMapping
Memory controller configuration initialized based on parameter values.
Definition: mem_interface.hh:122
DRAMInterface::PWR_SREF
@ PWR_SREF
Definition: mem_interface.hh:351
DRAMInterface::tCCD_L
const Tick tCCD_L
Definition: mem_interface.hh:730
DRAMInterface::DRAMStats::writeBursts
Stats::Scalar writeBursts
Definition: mem_interface.hh:813
MemInterface::rowBufferSize
const uint32_t rowBufferSize
Definition: mem_interface.hh:133
NVMInterface::NVMStats::totMemAccLat
Stats::Scalar totMemAccLat
Definition: mem_interface.hh:1078
NVMInterface::NVMStats::bytesRead
Stats::Scalar bytesRead
Definition: mem_interface.hh:1085
MemInterface::readBufferSize
const uint32_t readBufferSize
Buffer sizes for read and write queues in the controller These are passed to the controller on instan...
Definition: mem_interface.hh:173
DRAMInterface::tRFC
const Tick tRFC
Definition: mem_interface.hh:736
MemInterface::burstsPerStripe
const uint32_t burstsPerStripe
Definition: mem_interface.hh:135
AbstractMemory::range
AddrRange range
Definition: abstract_mem.hh:109
NVMInterface::processWriteRespondEvent
void processWriteRespondEvent()
Definition: mem_interface.cc:2423
DRAMInterface::Rank::startup
void startup(Tick ref_tick)
Kick off accounting for power and refresh states and schedule initial refresh.
Definition: mem_interface.cc:1166
DRAMInterface::Rank::readEntries
uint32_t readEntries
Track number of packets in read queue going to this rank.
Definition: mem_interface.hh:534
DRAMInterface::REF_PD_EXIT
@ REF_PD_EXIT
Definition: mem_interface.hh:391
DRAMInterface::RankStats::totalEnergy
Stats::Scalar totalEnergy
Definition: mem_interface.hh:443
DRAMInterface::Command::timeStamp
Tick timeStamp
Definition: mem_interface.hh:312
DRAMInterface::addRankToRankDelay
void addRankToRankDelay(Tick cmd_at) override
Add rank to rank delay to bus timing to all DRAM banks in alli ranks when access to an alternate inte...
Definition: mem_interface.cc:717
DRAMInterface::RankStats::actEnergy
Stats::Scalar actEnergy
Definition: mem_interface.hh:412
NVMInterface::numPendingReads
uint16_t numPendingReads
Definition: mem_interface.hh:1140
DRAMInterface::wrToRdDlySameBG
const Tick wrToRdDlySameBG
Definition: mem_interface.hh:750
DRAMInterface::pageMgmt
Enums::PageManage pageMgmt
Definition: mem_interface.hh:754
MemCtrl
The memory controller is a single-channel memory controller capturing the most important timing const...
Definition: mem_ctrl.hh:236
NVMInterface::tREAD
const Tick tREAD
NVM specific timing requirements.
Definition: mem_interface.hh:1056
MemInterface::bytesPerBurst
uint32_t bytesPerBurst() const
Definition: mem_interface.hh:233
NVMInterface::processReadReadyEvent
void processReadReadyEvent()
Definition: mem_interface.cc:2224
MemInterface::writeBufferSize
const uint32_t writeBufferSize
Definition: mem_interface.hh:174
DRAMInterface::DRAMStats
Definition: mem_interface.hh:802
DRAMInterface::DRAMStats::peakBW
Stats::Formula peakBW
Definition: mem_interface.hh:842
NVMInterface::readReadyEvent
EventFunctionWrapper readReadyEvent
Definition: mem_interface.hh:1107
NVMInterface::addRankToRankDelay
void addRankToRankDelay(Tick cmd_at) override
Add rank to rank delay to bus timing to all NVM banks in alli ranks when access to an alternate inter...
Definition: mem_interface.cc:2452
NVMInterface::NVMStats::NVMStats
NVMStats(NVMInterface &nvm)
Definition: mem_interface.cc:2487
DRAMInterface::Rank::schedulePowerEvent
void schedulePowerEvent(PowerState pwr_state, Tick tick)
Schedule a power state transition in the future, and potentially override an already scheduled transi...
Definition: mem_interface.cc:1502
MemInterface::allRanksDrained
virtual bool allRanksDrained() const =0
Check drain state of interface.
NVMInterface::Rank
NVM rank class simply includes a vector of banks.
Definition: mem_interface.hh:1027
DRAMInterface::tCL
const Tick tCL
DRAM specific timing requirements.
Definition: mem_interface.hh:726
Stats::Formula
A formula for statistics that is calculated when printed.
Definition: statistics.hh:3037
DRAMInterface::tBURST_MAX
const Tick tBURST_MAX
Definition: mem_interface.hh:728
Packet
A Packet is used to encapsulate a transfer between two objects in the memory system (e....
Definition: packet.hh:257
DRAMInterface::Rank::outstandingEvents
uint8_t outstandingEvents
Number of ACT, RD, and WR events currently scheduled Incremented when a refresh event is started as w...
Definition: mem_interface.hh:546
MemInterface::minReadToWriteDataGap
Tick minReadToWriteDataGap() const
Definition: mem_interface.hh:258
MemInterface::burstSize
const uint32_t burstSize
General device and channel characteristics The rowsPerBank is determined based on the capacity,...
Definition: mem_interface.hh:129
std::deque< MemPacket * >
MemInterface::Bank
A basic class to track the bank state, i.e.
Definition: mem_interface.hh:82
DRAMInterface::DRAMStats::avgBusLat
Stats::Formula avgBusLat
Definition: mem_interface.hh:826
Stats::Group
Statistics container.
Definition: group.hh:83
DRAMInterface::chooseNextFRFCFS
std::pair< MemPacketQueue::iterator, Tick > chooseNextFRFCFS(MemPacketQueue &queue, Tick min_col_at) const override
For FR-FCFS policy, find first DRAM command that can issue.
Definition: mem_interface.cc:169
addr
ip6_addr_t addr
Definition: inet.hh:423
NVMInterface::numReadDataReady
uint16_t numReadDataReady
Definition: mem_interface.hh:1141
DRAMInterface::REF_PRE
@ REF_PRE
Definition: mem_interface.hh:393
DRAMInterface::Rank::writeEntries
uint32_t writeEntries
Track number of packets in write queue going to this rank.
Definition: mem_interface.hh:539
DRAMInterface::Rank::processRefreshEvent
void processRefreshEvent()
Definition: mem_interface.cc:1296
DRAMInterface::RankStats::actBackEnergy
Stats::Scalar actBackEnergy
Definition: mem_interface.hh:421
NVMInterface::ranks
std::vector< Rank * > ranks
Vector of nvm ranks.
Definition: mem_interface.hh:1112
NVMInterface::NVMStats::totBusLat
Stats::Scalar totBusLat
Definition: mem_interface.hh:1077
DRAMInterface::Command::bank
uint8_t bank
Definition: mem_interface.hh:311
DRAMInterface::dataClockSync
const bool dataClockSync
Definition: mem_interface.hh:746
DRAMInterface::DRAMStats::busUtil
Stats::Formula busUtil
Definition: mem_interface.hh:844
MemInterface::deviceRowBufferSize
const uint32_t deviceRowBufferSize
Definition: mem_interface.hh:131
DRAMInterface::init
void init() override
Initialize the DRAM interface and verify parameters.
Definition: mem_interface.cc:837
MemInterface::rowsPerBank
uint32_t rowsPerBank
Definition: mem_interface.hh:138
DRAMInterface::tRCD
const Tick tRCD
Definition: mem_interface.hh:731
NVMInterface::writeRespondEvent
EventFunctionWrapper writeRespondEvent
Definition: mem_interface.hh:1104
DRAMInterface::DRAMStats::totBusLat
Stats::Scalar totBusLat
Definition: mem_interface.hh:821
AbstractMemory::Params
AbstractMemoryParams Params
Definition: abstract_mem.hh:207
EventManager
Definition: eventq.hh:973
MemInterface::Bank::rdAllowedAt
Tick rdAllowedAt
Definition: mem_interface.hh:92
DRAMInterface::Rank::refreshState
RefreshState refreshState
current refresh state
Definition: mem_interface.hh:519
DRAMInterface::RankStats::preDumpStats
void preDumpStats() override
Callback before stats are dumped.
Definition: mem_interface.cc:1992
NVMInterface::NVMStats::avgWrBW
Stats::Formula avgWrBW
Definition: mem_interface.hh:1090
MemInterface::ctrl
MemCtrl * ctrl
A pointer to the parent MemCtrl instance.
Definition: mem_interface.hh:110
DRAMInterface::DRAMStats::DRAMStats
DRAMStats(DRAMInterface &dram)
Definition: mem_interface.cc:1854
DRAMInterface::Rank::checkDrainDone
void checkDrainDone()
Let the rank check if it was waiting for requests to drain to allow it to transition states.
Definition: mem_interface.cc:1201
DRAMInterface::tRP
const Tick tRP
Definition: mem_interface.hh:732
DRAMInterface::drainRanks
void drainRanks()
Iterate through dram ranks to exit self-refresh in order to drain.
Definition: mem_interface.cc:1000
DRAMInterface::Rank::refreshEvent
EventFunctionWrapper refreshEvent
Definition: mem_interface.hh:692
DRAMInterface::RankStats::preEnergy
Stats::Scalar preEnergy
Definition: mem_interface.hh:413
DRAMInterface::DRAMStats::dram
DRAMInterface & dram
Definition: mem_interface.hh:809
DRAMInterface::Rank::processPowerEvent
void processPowerEvent()
Definition: mem_interface.cc:1644
DRAMInterface::Rank::pwrStatePostRefresh
PowerState pwrStatePostRefresh
Previous low-power state, which will be re-entered after refresh.
Definition: mem_interface.hh:483
std::list< Tick >
DRAMInterface::PWR_ACT
@ PWR_ACT
Definition: mem_interface.hh:353
DRAMInterface::RankStats::refreshEnergy
Stats::Scalar refreshEnergy
Definition: mem_interface.hh:416
MemInterface::deviceSize
const uint32_t deviceSize
Definition: mem_interface.hh:130
MemInterface::Bank::wrAllowedAt
Tick wrAllowedAt
Definition: mem_interface.hh:93
DRAMInterface::RankStats::rank
Rank & rank
Definition: mem_interface.hh:407
MemInterface::tRTW
const Tick tRTW
Definition: mem_interface.hh:146
NVMInterface::chooseRead
void chooseRead(MemPacketQueue &queue)
Select read command to issue asynchronously.
Definition: mem_interface.cc:2129
DRAMInterface::Rank
Rank class includes a vector of banks.
Definition: mem_interface.hh:465
DRAMInterface::accessLatency
Tick accessLatency() const override
Definition: mem_interface.hh:932
DRAMInterface::tBURST_MIN
const Tick tBURST_MIN
Definition: mem_interface.hh:727
DRAMInterface::enableDRAMPowerdown
bool enableDRAMPowerdown
Enable or disable DRAM powerdown states.
Definition: mem_interface.hh:768
MemInterface::devicesPerRank
const uint32_t devicesPerRank
Definition: mem_interface.hh:132
DRAMInterface::Rank::processActivateEvent
void processActivateEvent()
Definition: mem_interface.cc:1244
DRAMInterface::activationLimit
const uint32_t activationLimit
Definition: mem_interface.hh:749
MemInterface::commandOffset
virtual Tick commandOffset() const =0
DRAMInterface::Rank::dram
DRAMInterface & dram
A reference to the parent DRAMInterface instance.
Definition: mem_interface.hh:472
DRAMInterface::RankStats::pwrStateTime
Stats::Vector pwrStateTime
Track time spent in each power state.
Definition: mem_interface.hh:455
DRAMInterface::PWR_ACT_PDN
@ PWR_ACT_PDN
Definition: mem_interface.hh:354
DRAMInterface::RankStats::preBackEnergy
Stats::Scalar preBackEnergy
Definition: mem_interface.hh:426
DRAMInterface::Rank::activateEvent
EventFunctionWrapper activateEvent
Definition: mem_interface.hh:686
MemInterface::decodePacket
MemPacket * decodePacket(const PacketPtr pkt, Addr pkt_addr, unsigned int size, bool is_read, bool is_dram)
Address decoder to figure out physical mapping onto ranks, banks, and rows.
Definition: mem_interface.cc:83
NVMInterface::NVMStats::busUtilRead
Stats::Formula busUtilRead
Definition: mem_interface.hh:1093
DRAMInterface::suspend
void suspend()
Iterate through DRAM ranks and suspend them.
Definition: mem_interface.cc:1029
DRAMInterface::Rank::powerDownSleep
void powerDownSleep(PowerState pwr_state, Tick tick)
Schedule a transition to power-down (sleep)
Definition: mem_interface.cc:1523
DRAMInterface::DRAMStats::readBursts
Stats::Scalar readBursts
total number of DRAM bursts serviced
Definition: mem_interface.hh:812
DRAMInterface::Rank::pwrStateTrans
PowerState pwrStateTrans
Since we are taking decisions out of order, we need to keep track of what power transition is happeni...
Definition: mem_interface.hh:478
csprintf
std::string csprintf(const char *format, const Args &...args)
Definition: cprintf.hh:158
DRAMInterface::tCCD_L_WR
const Tick tCCD_L_WR
Definition: mem_interface.hh:729
NVMInterface::readsWaitingToIssue
bool readsWaitingToIssue() const
Definition: mem_interface.hh:1242
MemInterface::rankToRankDelay
Tick rankToRankDelay() const
Definition: mem_interface.hh:162
DRAMInterface::Rank::numBanksActive
unsigned int numBanksActive
To track number of banks which are currently active for this rank.
Definition: mem_interface.hh:576
DRAMInterface::Rank::processPrechargeEvent
void processPrechargeEvent()
Definition: mem_interface.cc:1254
DRAMInterface::DRAMStats::avgMemAccLat
Stats::Formula avgMemAccLat
Definition: mem_interface.hh:827
DRAMInterface::DRAMStats::totMemAccLat
Stats::Scalar totMemAccLat
Definition: mem_interface.hh:822
DRAMPower
DRAMPower is a standalone tool which calculates the power consumed by a DRAM in the system.
Definition: drampower.hh:53
NVMInterface::tWRITE
const Tick tWRITE
Definition: mem_interface.hh:1057
NVMInterface::doBurstAccess
std::pair< Tick, Tick > doBurstAccess(MemPacket *pkt, Tick next_burst_at)
Actually do the burst and update stats.
Definition: mem_interface.cc:2278
DRAMInterface::burstInterleave
const bool burstInterleave
Definition: mem_interface.hh:747
DRAMInterface::tRRD
const Tick tRRD
Definition: mem_interface.hh:738
NVMInterface::NVMStats::pendingWrites
Stats::Histogram pendingWrites
Definition: mem_interface.hh:1098
MemInterface::Params
MemInterfaceParams Params
Definition: mem_interface.hh:291
DRAMInterface::tPPD
const Tick tPPD
Definition: mem_interface.hh:740
NVMInterface::burstReady
bool burstReady(MemPacket *pkt) const override
Check if a burst operation can be issued to the NVM.
Definition: mem_interface.cc:2269
NVMInterface::NVMStats::avgQLat
Stats::Formula avgQLat
Definition: mem_interface.hh:1081
DRAMInterface::Command::Command
constexpr Command(Data::MemCommand::cmds _type, uint8_t _bank, Tick time_stamp)
Definition: mem_interface.hh:314
DRAMInterface::DRAMStats::writeRowHits
Stats::Scalar writeRowHits
Definition: mem_interface.hh:831
NVMInterface::stats
NVMStats stats
Definition: mem_interface.hh:1101
DRAMInterface::stats
DRAMStats stats
Definition: mem_interface.hh:850
DRAMInterface::RankStats::totalIdleTime
Stats::Scalar totalIdleTime
Stat to track total DRAM idle time.
Definition: mem_interface.hh:450
DRAMInterface::tRRD_L
const Tick tRRD_L
Definition: mem_interface.hh:739
DRAMInterface::lastStatsResetTick
Tick lastStatsResetTick
The time when stats were last reset used to calculate average power.
Definition: mem_interface.hh:771
eventq.hh
MemInterface
General interface to memory device Includes functions and parameters shared across media types.
Definition: mem_interface.hh:70

Generated on Wed Sep 30 2020 14:02:13 for gem5 by doxygen 1.8.17