sim: reset stats after startup
Currently statistics are reset after the initial / checkpoint state has been loaded. But ruby does some checkpoint processing in its startup() function. So the stats need to be reset after the startup() function has been called. This patch moves the class to stats.reset() to achieve this change in functionality.
This commit is contained in:
parent
5800e83223
commit
50d250f514
1 changed files with 3 additions and 3 deletions
|
@ -134,9 +134,6 @@ def instantiate(ckpt_dir=None):
|
|||
# a checkpoint, If so, this call will shift them to be at a valid time.
|
||||
updateStatEvents()
|
||||
|
||||
# Reset to put the stats in a consistent state.
|
||||
stats.reset()
|
||||
|
||||
need_resume = []
|
||||
need_startup = True
|
||||
def simulate(*args, **kwargs):
|
||||
|
@ -154,6 +151,9 @@ def simulate(*args, **kwargs):
|
|||
# register our C++ exit callback function with Python
|
||||
atexit.register(internal.core.doExitCleanup)
|
||||
|
||||
# Reset to put the stats in a consistent state.
|
||||
stats.reset()
|
||||
|
||||
for root in need_resume:
|
||||
resume(root)
|
||||
need_resume = []
|
||||
|
|
Loading…
Reference in a new issue