1
0
mirror of https://github.com/ARM-software/workload-automation.git synced 2025-01-19 12:24:32 +00:00

19 Commits

Author SHA1 Message Date
Sergei Trofimov
6da0550b98 utils/trace_cmd: expect ': ' in task name
': ' is used as the delimiter for the different parts of of the event
line; unfortunately, it is also a valid character sequence to appear in
a task name.

This change attempts to perform the event line split correctly by
ensuring that the cpu id is present in the first part.
2017-07-24 09:31:31 +01:00
Sergei Trofimov
7f8e7fed4b utils/trace_cmd: fix event parsing
Make event preamble parsing more robust in cases there are multiple
instances of ' [' (e.g. as part of thread name) by splitting exactly
once from the right. The right-most columns are the timestamp and the
cpu id, and much more restricted (and therefore predictable) in their
formatting.
2017-07-20 15:52:31 +01:00
Sergei Trofimov
33874a8f71 utils/trace_cmd: reduce regex use
Do not attempt to regex match each line for dropped events/preamble. Use
substring search to detect them first, and only use regex on relevant
lines.
2017-07-20 11:12:54 +01:00
Sergei Trofimov
93dba8b35d utils/trace_cmd: optimize event parsing
Use string searching and splitting instead of regex matching to parse
trace events. This significantly speeds up trace parsing.
2017-07-20 11:12:53 +01:00
Sergei Trofimov
6f629601be utils/trace_cmd: lazy evaluation of event fields
Parsing if a trace events body text into fields is potentially
expensive, so only do it if the fields are being accessed.
2017-07-20 11:12:53 +01:00
Sergei Trofimov
c86ce64408 utils/trace_cmd: add parsers for more sched events
Added parsers for sched_wakeup(_new) and sched_stat_* events that have
non-standard text.
2017-05-31 10:42:55 +01:00
Sebastian Goscik
9707aa6237 Pylint fixes
Pylint now checks for trailing new lines, this commit fixes them.
2016-07-21 16:40:26 +01:00
Sebastian Goscik
f276d4e39f cpustates: Added the ability to configure how a missing start marker is handled.
cpustates can now handle the lack of a start marker in three ways:

 - try: If the start marker is present only the correct section of the trace
        will be used, if its not the whole trace will be used.
 - error: An error will be raised if the start marker is missing
 - ignore: The markers are ignored and the whole trace is always used.
2016-06-06 17:09:48 +01:00
Sergei Trofimov
107e8414bb trace-cmd: set a minimum bound on trace pull timeout
The timeout for the pulling the trace file after the run is being set
based on the time for which the trace was collected. For workloads with
short execution time, but large number of events, the resulting timeout
might be too short. To deal with this, do not let the timout be shorter
than 1 minute.
2016-03-24 16:49:42 +00:00
Sergei Trofimov
4f8b7e9f59 trace-cmd: updating sched_switch parser to handle both formats.
Depending on the kernel, sched_switch events may be formatted one of two
different ways in the text output. Previously, we've only handled the
"old" format. This commit updates the parser to handle the new format as
well.
2016-03-24 16:33:29 +00:00
Brendan Jackman
2ae8c6073f doc: Apply it's/its grammar pedantry 2016-01-25 13:34:24 +00:00
Sergei Trofimov
b84f97a902 trace_cmd: updated to handle empty CPUs.
Updated trace-cmd parser to handle messages that the trace for a CPU is
empty.
2016-01-12 10:12:00 +00:00
Sergei Trofimov
0f60e9600f trace_cmd: parser for sched_switch events and fixes
- Compiled regular expressions in EVENT_PARSER_MAP now get handled
  correctly.
- regex_body_parser now attemts to convert field values to ints,
  bringing it inline with the default parser behavior.
- There is now a regex for sched_switch events.
2015-12-10 13:41:24 +00:00
Sergei Trofimov
7546232c10 trace_cmd: fix parser to oportunistically convert parsed values to ints
This was done previosly but was broken by commit

1c146e3ce78de44889712b58f293a859b9df8321
2015-10-16 17:08:09 +01:00
Sergei Trofimov
1c146e3ce7 trace_cmd: more robust event fields parsing
The default paraser can now handle spaces in field values (but not field
names).
2015-10-08 17:13:48 +01:00
Sergei Trofimov
95c3f049fb trace_cmd: handle trace headers and thread names with spaces 2015-08-17 12:37:58 +01:00
Sergei Trofimov
3b4dc137d2 cpustate: check if trace marker is present and disable marker filtering if it is not. 2015-06-29 17:33:28 +01:00
Sergei Trofimov
02af02f0cb Adding cpustates result processor (and script) 2015-06-03 16:20:48 +01:00
Sergei Trofimov
e9b21e2ef3 Adding a generic trace-cmd paraser. 2015-06-03 16:20:48 +01:00