Skip to content

lisa.trace: Add FtraceCollector(trace_clock='global', saved_cmdlines_…

Douglas Raillard requested to merge github/fork/douglas-raillard-arm/_pr398 into master

…nr=4096)

Allow changing the number of entries in the cmdlines/PID table created by the kernel while tracing. This is needed on systems generating a lot of tasks (Android), to avoid having placeholder task names such as "<...>".

Also allow changing the trace clock source, and default to the "global" monotonic shared clock so that timestamp between CPUs are consistent.

Depends on new devlib features:

Function tracer can be used with trappy PR: https://github.com/ARM-software/trappy/pull/299

Note that the functions are left as pointers rather than names, but that's the only way to get both entry and exit events. Dataframe sanitization will resolve the symbol names when parsed kallsyms from plat info is available. After sanitization, the dataframe looks like:

         __comm    __pid  __cpu  __line                  func  depth            func_name
Time                                                                                     
0.000000  <...>  2094921      2       0  18446744072324090592      0  select_task_rq_fair
0.000118  <...>  2094921      2       4  18446744072324090592      0  select_task_rq_fair
0.000318  <...>  2094920      7       8  18446744072324090592      0  select_task_rq_fair
0.001215  <...>  2094920      7      12  18446744072324090592      0  select_task_rq_fair
0.001521  <...>  2094918      0      18  18446744072324090592      0  select_task_rq_fair
...         ...      ...    ...     ...                   ...    ...                  ...
0.076765  <...>  2094947      4    1566  18446744072324090592      0  select_task_rq_fair
0.076771  <...>  2094947      4    1568  18446744072324090592      0  select_task_rq_fair
0.076892  <...>  2094948      6    1573  18446744072324090592      0  select_task_rq_fair
0.077026  <...>  2094948      6    1576  18446744072324090592      0  select_task_rq_fair
0.079242  <...>  2094948      6    1580  18446744072324090592      0  select_task_rq_fair

Merge request reports