changed small things for DRAMPower
This commit is contained in:
@@ -44,7 +44,8 @@ struct Dram: sc_module
|
||||
{
|
||||
MemorySpecification memSpec(MemorySpecification::getMemSpecFromXML(Configuration::getInstance().memspecUri));
|
||||
DRAMPower.getEnergy(memSpec);
|
||||
std::cout << "Total Energy" << "\t" << DRAMPower.mpm.energy.total_energy << endl;
|
||||
cout << "Total Energy" << "\t" << DRAMPower.mpm.energy.total_energy << endl;
|
||||
cout << "Average Power" << "\t" << DRAMPower.mpm.power.average_power << endl;
|
||||
}
|
||||
|
||||
virtual tlm::tlm_sync_enum nb_transport_fw(tlm::tlm_generic_payload& payload, tlm::tlm_phase& phase, sc_time& delay)
|
||||
@@ -99,11 +100,23 @@ struct Dram: sc_module
|
||||
//Powerdown phases have to be started and ended by the controller, because they do not have a fixed length
|
||||
else if (phase == BEGIN_PDNP)
|
||||
{
|
||||
DRAMPower.doCommand(MemCommand::PDN_S_PRE, bank, cycle);
|
||||
if(Configuration::getInstance().BankwiseLogic == false)
|
||||
{
|
||||
if(bank == 0)
|
||||
{
|
||||
DRAMPower.doCommand(MemCommand::PDN_S_PRE, bank, cycle);
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (phase == END_PDNP)
|
||||
{
|
||||
DRAMPower.doCommand(MemCommand::PUP_PRE, bank, cycle);
|
||||
if(Configuration::getInstance().BankwiseLogic == false)
|
||||
{
|
||||
if(bank == 0)
|
||||
{
|
||||
DRAMPower.doCommand(MemCommand::PUP_PRE, bank, cycle);
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (phase == BEGIN_PDNA)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user