summaryrefslogtreecommitdiff
path: root/util/cpt_upgraders/dvfs-perflevel.py
diff options
context:
space:
mode:
authorNilay Vaish <nilay@cs.wisc.edu>2015-09-03 15:40:20 -0500
committerNilay Vaish <nilay@cs.wisc.edu>2015-09-03 15:40:20 -0500
commit80b911afd573ecda0cefb8f24b83d94b7faf4b7b (patch)
tree95aa2f9794fe70fa812c63583f9db6602457b69e /util/cpt_upgraders/dvfs-perflevel.py
parent2ab38ba13c6245480a08cd5b8651b5af8fce5a4b (diff)
parent87b9da2df4d4dc0028566a7803ee55159343d735 (diff)
downloadgem5-80b911afd573ecda0cefb8f24b83d94b7faf4b7b.tar.xz
merged with recent commits.
Diffstat (limited to 'util/cpt_upgraders/dvfs-perflevel.py')
-rw-r--r--util/cpt_upgraders/dvfs-perflevel.py15
1 files changed, 15 insertions, 0 deletions
diff --git a/util/cpt_upgraders/dvfs-perflevel.py b/util/cpt_upgraders/dvfs-perflevel.py
new file mode 100644
index 000000000..0dc15f351
--- /dev/null
+++ b/util/cpt_upgraders/dvfs-perflevel.py
@@ -0,0 +1,15 @@
+# Add the perfLevel variable in the clock domain and voltage domain simObjects
+def upgrader(cpt):
+ for sec in cpt.sections():
+ import re
+
+ if re.match('^.*sys.*[._]clk_domain$', sec):
+ # Make _perfLevel equal to 0 which means best performance
+ cpt.set(sec, '_perfLevel', ' '.join('0'))
+ elif re.match('^.*sys.*[._]voltage_domain$', sec):
+ # Make _perfLevel equal to 0 which means best performance
+ cpt.set(sec, '_perfLevel', ' '.join('0'))
+ else:
+ continue
+
+legacy_version = 11