Hi All,

I want to use MARSSx86+DramSim2 to count the row buffer hit ratio.

Several variables were added to class BankState as follows:

*class BankState*
*{*
* ostream &dramsim_log; *
*public:*
* //Fields*
*          ...*
* unsigned stateChangeCountdown;*
* /**
* * Added by SunnyBeike*
* * */*
* #ifdef CONFIG_SUNNY*
* unsigned lastOpenRow;*
*         unsigned long rowBufferAccessTimes;*
*         unsigned long rowBufferHitTimes;*
*         unsigned long rowBufferMissTimes;*
* #endif*
*
*
* /**
* * The End*
* * */*
* //Functions*
* BankState(ostream &dramsim_log_);*
* void print();*
*};*

lastOpenRow is the row accessed by the last memory request to this bank. If
it equals to the
row of current request to this bank, then row-buffer of this bank hits.
This judgement was carried
out in the following function:

*void Rank::receiveFromBus(BusPacket *packet)
*
*{*
*                ...*
*
*
* switch (packet->busPacketType) { *
*
*
* case READ:*
* /**
* Added by SunnyBeike*
* */*
* #ifdef CONFIG_SUNNY*
* ++bankStates[packet->bank].rowBufferAccessTimes;*
* *
* if(packet->row == bankStates[packet->bank].lastOpenRow)*
* ++bankStates[packet->bank].rowBufferHitTimes; *
* else *
* ++bankStates[packet->bank].rowBufferMissTimes;*
* *
* bankStates[packet->bank].lastOpenRow = packet->row;*
* #endif*
* /**
* The End*
* */*
*                    ...*
*          case WRITE:*
* /**
* Added by SunnyBeike*
* */*
* #ifdef CONFIG_SUNNY*
* ++bankStates[packet->bank].rowBufferAccessTimes;*
* *
* if(packet->row == bankStates[packet->bank].lastOpenRow)*
* ++bankStates[packet->bank].rowBufferHitTimes; *
* else *
* ++bankStates[packet->bank].rowBufferMissTimes;*
* *
* bankStates[packet->bank].lastOpenRow = packet->row;*
* #endif*
* /**
* The End*
* */*
*                   ...*
*
*
*             }*
*                ...*
*}*


Is this a correct way to collect the row-buffer hit ratio information in
DramSim2 ?
 Thanks...

Any reply is appreciated! Thanks...
_______________________________________________
http://www.marss86.org
Marss86-Devel mailing list
[email protected]
https://www.cs.binghamton.edu/mailman/listinfo/marss86-devel

Reply via email to