aboutsummaryrefslogtreecommitdiff
path: root/libs/utils/analysis_module.py
diff options
context:
space:
mode:
Diffstat (limited to 'libs/utils/analysis_module.py')
-rw-r--r--libs/utils/analysis_module.py23
1 files changed, 4 insertions, 19 deletions
diff --git a/libs/utils/analysis_module.py b/libs/utils/analysis_module.py
index 8544b13..87a02e9 100644
--- a/libs/utils/analysis_module.py
+++ b/libs/utils/analysis_module.py
@@ -34,7 +34,6 @@ class AnalysisModule(object):
self._trace = trace
self._platform = trace.platform
- self._tasks = trace.tasks
self._data_dir = trace.data_dir
self._dfg_trace_event = trace._dfg_trace_event
@@ -48,26 +47,12 @@ class AnalysisModule(object):
# By default assume SMP system
self._big_cap = 1024
self._little_cap = 1024
- nrg_model = self._platform.get('nrg_model', None)
- if nrg_model:
- try:
- self._big_cap = nrg_model['big']['cpu']['cap_max']
- self._little_cap = nrg_model['little']['cpu']['cap_max']
- except TypeError:
- self._log.debug('Failed parsing EM from platform data')
- else:
- self._log.debug('Platform data without Energy Model info')
-
- # By default assume SMP system
- self._big_cpus = []
+ self._big_cpus = range(self._platform['cpus_count'])
self._little_cpus = []
- if 'big' in self._platform['clusters']:
- self._log.debug('Parsing big.LITTLE system clusters')
+
+ if self._trace.has_big_little:
+ self._little_cap = self._platform['nrg_model']['little']['cpu']['cap_max']
self._big_cpus = self._platform['clusters']['big']
self._little_cpus = self._platform['clusters']['little']
- else:
- self._log.debug('Parsing SMP clusters')
- for cid in self._platform['clusters']:
- self._big_cpus.append(self._platform['clusters'][cid])
# vim :set tabstop=4 shiftwidth=4 expandtab