Hi
I am trying to change the clock frequencies of the different cores
dynamically.
I begin with boot up process in atomic mode and then at checkpoint restore
move to detailed mode. To implement dynamic frequency scaling, I added
function in /configs/common/Simulation.py that calls a pre-defined
switching function in src/python/simulate.py as shown below:
def switchcpufreq(root, system, f1, f2, num, do_drain=True):
from m5 import options
if do_drain:
drain(system)
system.cpu[0].clock= f1
system.cpu[1].clock= f2
if do_drain:
resume(system)
In simulation.py the calling function is :
if options.switch_freq:
m5.stats.dump()
m5.stats.reset()
#warmup instruction count may have already been set
if options.warmup_insts:
exit_event = m5.simulate()
else:
exit_event = m5.simulate(options.switch_freq)
print "Switching CPUfreq @ tick %s" % (m5.curTick())
m5.stats.dump()
m5.stats.reset()
m5.switchcpufreq(root, testsys, f1, f2, factor3, factor4, np)
So, the problem here is that it updates the clock frequencies in the
simulation.py file but does not reflect it in the simulation output
statistics (sim_seconds). I feel that the clock is not getting updated in
the C++ Object instantiation.
Kindly help.
Regards
Shivam Agarwal
_______________________________________________
gem5-users mailing list
[email protected]
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users