Small bug fixes

This commit is contained in:
Matthias Jung
2021-08-30 10:45:31 +02:00
parent cae54bb879
commit 87d5be0696
3 changed files with 15 additions and 2 deletions

View File

@@ -78,6 +78,11 @@ void BankMachine::updateState(Command command)
case Command::REFA: case Command::REFB: case Command::REFSB: case Command::RFMAB:
sleeping = false;
blocked = false;
if(command == Command::RFMAB) {
blocked = false;
}
if(Configuration::getInstance().RFM == true) {
if (RFMCounter > Configuration::getInstance().memSpec->getRAADEC()) {
RFMCounter -= Configuration::getInstance().memSpec->getRAADEC();

View File

@@ -89,7 +89,7 @@ std::string Command::toString() const
"RFMSB", // 10
"PREA", // 11
"REFA", // 12
"RFMA", // 13
"RFMAB", // 13
"PDEA", // 14
"PDEP", // 15
"SREFEN", // 16

View File

@@ -30,6 +30,7 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* Author: Lukas Steiner
* Matthias Jung
*/
#include "RefreshManagerAllBank.h"
@@ -148,7 +149,14 @@ sc_time RefreshManagerAllBank::start()
}
else if (RFMRequired)
{
nextCommand = Command::RFMAB;
if (activatedBanks > 0)
nextCommand = Command::PREA;
else
nextCommand = Command::RFMAB;
for (auto it : bankMachinesOnRank)
it->block();
timeToSchedule = checker->timeToSatisfyConstraints(nextCommand, &refreshPayload);
return timeToSchedule;
}