Age | Commit message (Collapse) | Author |
|
When the sched_switch event is added to the parser the constructor is
not called so we never set the parse_raw flag. Ensure there is a class
variable to hold the correct value and use it in the constructor.
We use the raw file to extract the events since we actually do construct
one of these objects during parsing.
Signed-off-by: Chris Redpath <chris.redpath@arm.com>
Reviewed-by: KP Singh <kpsingh@google.com>
|
|
|
|
The EAS patchset includes an enhancement of sched_migrate_task that
includes a enum field printed with __print_symbolic that only gets
parsed in the trace.txt and not in the trace.raw.txt.
Remove the instances of sched_migrate_task from the trace_empty file to
keep the tests testing a trace that is "empty", that is, no event in it
is parsed.
|
|
sched_migrate_task has been in the kernel since v2.6.28. Let's add it
to the events in the sched scope.
|
|
For trace-cmd traces, we use the raw trace to parse sched_switch.
That's not possible for SysTrace traces, we don't have access to the raw
data. Luckily SysTrace doesn't mangle the data as much as trace-cmd's
plugin, so a simple string replace is enough to get rid of a stray
"==>".
|
|
Most registration of base events in trappy were being done with
FTrace.register_parser() which introduces unnecessary noise when
refactoring. Use register_ftrace_parser() instead as it is what we
recommend for external classes and it simplifies refactoring.
|
|
Some recent version of trace-cmd prints sched_wakeup and sched_wakeup_new
events using a format string. Thus, when this events are required we must
parse them from the raw trace.
Since these events are already available mainline, this patch pre-register
them dynamically as raw events. This allows to parse these events (when
required) using the proper trace.
The patch adds also a test case by using the original formatted trace as
a source for the raw trace to use.
Signed-off-by: Patrick Bellasi <patrick.bellasi@arm.com>
|
|
|
|
Now that we can have traces coming from sources other than ftrace,
rename register_dynamic() and register_class() to
register_dynamic_ftrace() and register_ftrace_parser() to make it clear
that they are only available for traces coming from ftrace.
|
|
Run is a very generic and inappropriate name for an object that parses
the result of ftrace into a form consumable by python. Rename it to
FTrace in preparation for its generalization.
|
|
A number of trace classes are called as the trace event they parse.
Unsurprisingly, the unique_word *is* the trace event name. Instead of
repeating the same thing over and over, let register_class() assign a
name to a class it's registering based on the unique_word if it doesn't
have a name.
This needs to be a class variable that's set before the class is
instantiated (Run.register_class() needs it). So you can't set it in
Base's constructor. You can't set it in DynamicTypeFactory either
because not every Base class uses that. This looks like a good
compromise and remove some redundant code.
Change-Id: I6389c9ac072f6571b4faf8dacdee4cd77775a1f8
|
|
When using Run(events=["cpu_capacity"]), we end up on re-using the
pre-defined sched::SchedCpuCapacity class, which is registered as
"sched_cpu_capacity", so it appears as run.sched_cpu_capacity. This
misalignment is confusing for the user and should be avoided.
Rename all the pre-registered sched related events to match the
eventually user defined name.
|
|
Now that unique_word is required to be a class variable of all
classes derived from Base there is no pass it to the constructor. Base
can already pick it up.
Thanks to this we can remove all the repeated code in the dummy
constructors.
|
|
This patch adds pivot values to the pre-registered scheduler
events
Signed-off-by: Kapileshwar Singh <kapileshwar.singh@arm.com>
|
|
CPU Frequency and Capacity trace events report the actual "frequency" and
"capacity" using an anonymous "state" column. Plots generated using Plotter
use that columns name in the legend, thus making a bit confusing the plot,
even worst when we want to plot both frequency and capacity.
This patch assigns some more meaningful name to the "state" report by
these two trace events.
Signed-off-by: Patrick Bellasi <patrick.bellasi@arm.com>
|
|
To plot the sched_cpu_capacity events pivoted on the CPU number, we need
to rename the 'cpu_id' column to read as 'cpu'. Otherwise we cannot
'mix and match' with other classes.
Signed-off-by: Patrick Bellasi <patrick.bellasi@arm.com>
|
|
Signed-off-by: Kapileshwar Singh <kapileshwar.singh@arm.com>
|
|
Change-Id: I7e0e34c9f5565e34629683bb29ab25cf5e737088
|