1
0
mirror of https://github.com/ARM-software/devlib.git synced 2025-01-31 02:00:45 +00:00

collector/perf: raise an error if report_options or report_sample_options are specified when not using perf/simpleperf record

This commit is contained in:
Javi Merino 2021-04-26 20:19:15 +01:00 committed by Marc Bonnici
parent fa595e1a3d
commit 34e51e7230

View File

@ -126,6 +126,10 @@ class PerfCollector(CollectorBase):
self.command = command
else:
raise ValueError('Unsupported perf command, must be stat or record')
if report_options and (command != 'record'):
raise ValueError('report_options specified, but command is not record')
if report_sample_options and (command != 'record'):
raise ValueError('report_sample_options specified, but command is not record')
self.binary = self.target.get_installed(self.perf_type)
if self.force_install or not self.binary: