Added the tRAS timing constraint into the precharge checker

This commit is contained in:
Matthias Jung
2014-08-05 16:58:15 +02:00
parent fe9f9ad233
commit 609e568fbc

View File

@@ -14,6 +14,7 @@ void PrechargeChecker::delayToSatisfyConstraints(ScheduledCommand& command) cons
{
sc_assert(command.getCommand() == Command::Precharge);
ScheduledCommand lastCommand = state.getLastScheduledCommand(command.getBank());
if (lastCommand.isValidCommand())
@@ -34,6 +35,13 @@ void PrechargeChecker::delayToSatisfyConstraints(ScheduledCommand& command) cons
reportFatal("Precharge Checker", "Precharge can not follow " + commandToString(lastCommand.getCommand()));
}
ScheduledCommand lastActivate = state.getLastCommand(Command::Activate, command.getBank());
if (lastActivate.isValidCommand())
{
command.delayToMeetConstraint(lastActivate.getStart(), config.Timings.tRAS);
}
state.bus.moveCommandToNextFreeSlot(command);
}