[0/3] tools lib traceevent: Fixing the API to be less policy driven
mbox series

Message ID 20190805204312.169565525@goodmis.org
Headers show
Series
  • tools lib traceevent: Fixing the API to be less policy driven
Related show

Message

Steven Rostedt Aug. 5, 2019, 8:43 p.m. UTC
Hi Arnaldo and Jiri,

We are still working on getting libtraceevent ready to be a stand alone
library. Part of that is to audit all the interfaces. We noticed
that the most the tep_print_*() interfaces define policy and limit
the way an application can display data. Instead of fixing this later
and being stuck with a limiting API that we must maintain for backward
compatibility, we removed and replaced most of it. perf was only affected
by a single function that was removed. These functions are replaced
by a more flexible one that allows the user to place what they want
where they want it (timestamps, event info, latency format, COMM, PID, etc).

The other noticeable perf change, is that we changed the location to
where the plugins are loaded from:

 ${HOME}/.traceevent/plugins

to

 ${HOME}/.local/lib/traceevent/plugins

As Patrick McLean (Gentoo package maintainer) informed us of the
XGD layout.

Should we have something the warns people if they have plugins in
the old directory. Should we move them on install? Currently, we
just ignore them.

Anyway, please add these patches to tip.

Thanks!

-- Steve


Tzvetomir Stoyanov (3):
      tools/lib/traceevent, tools/perf: Changes in tep_print_event_* APIs
      tools/lib/traceevent: Remove tep_register_trace_clock()
      tools/lib/traceevent: Change user's plugin directory

----
 tools/lib/traceevent/Makefile            |   6 +-
 tools/lib/traceevent/event-parse-api.c   |  40 ----
 tools/lib/traceevent/event-parse-local.h |   6 -
 tools/lib/traceevent/event-parse.c       | 333 +++++++++++++++++--------------
 tools/lib/traceevent/event-parse.h       |  30 +--
 tools/lib/traceevent/event-plugin.c      |   2 +-
 tools/perf/builtin-kmem.c                |   3 +-
 tools/perf/util/sort.c                   |   3 +-
 tools/perf/util/trace-event-parse.c      |   2 +-
 9 files changed, 207 insertions(+), 218 deletions(-)

Comments

Steven Rostedt Aug. 29, 2019, 6 p.m. UTC | #1
On Mon, 05 Aug 2019 16:43:12 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> Hi Arnaldo and Jiri,

Hi Arnaldo,

I think these fell through the cracks.

-- Steve

> 
> We are still working on getting libtraceevent ready to be a stand alone
> library. Part of that is to audit all the interfaces. We noticed
> that the most the tep_print_*() interfaces define policy and limit
> the way an application can display data. Instead of fixing this later
> and being stuck with a limiting API that we must maintain for backward
> compatibility, we removed and replaced most of it. perf was only affected
> by a single function that was removed. These functions are replaced
> by a more flexible one that allows the user to place what they want
> where they want it (timestamps, event info, latency format, COMM, PID, etc).
> 
> The other noticeable perf change, is that we changed the location to
> where the plugins are loaded from:
> 
>  ${HOME}/.traceevent/plugins
> 
> to
> 
>  ${HOME}/.local/lib/traceevent/plugins
> 
> As Patrick McLean (Gentoo package maintainer) informed us of the
> XGD layout.
> 
> Should we have something the warns people if they have plugins in
> the old directory. Should we move them on install? Currently, we
> just ignore them.
> 
> Anyway, please add these patches to tip.
> 
> Thanks!
> 
> -- Steve
> 
> 
> Tzvetomir Stoyanov (3):
>       tools/lib/traceevent, tools/perf: Changes in tep_print_event_* APIs
>       tools/lib/traceevent: Remove tep_register_trace_clock()
>       tools/lib/traceevent: Change user's plugin directory
> 
> ----
>  tools/lib/traceevent/Makefile            |   6 +-
>  tools/lib/traceevent/event-parse-api.c   |  40 ----
>  tools/lib/traceevent/event-parse-local.h |   6 -
>  tools/lib/traceevent/event-parse.c       | 333 +++++++++++++++++--------------
>  tools/lib/traceevent/event-parse.h       |  30 +--
>  tools/lib/traceevent/event-plugin.c      |   2 +-
>  tools/perf/builtin-kmem.c                |   3 +-
>  tools/perf/util/sort.c                   |   3 +-
>  tools/perf/util/trace-event-parse.c      |   2 +-
>  9 files changed, 207 insertions(+), 218 deletions(-)
Arnaldo Carvalho de Melo Aug. 29, 2019, 8:37 p.m. UTC | #2
Em Thu, Aug 29, 2019 at 02:00:10PM -0400, Steven Rostedt escreveu:
> On Mon, 05 Aug 2019 16:43:12 -0400
> Steven Rostedt <rostedt@goodmis.org> wrote:
> 
> > Hi Arnaldo and Jiri,
> 
> Hi Arnaldo,
> 
> I think these fell through the cracks.

Got it now, pushed to my perf/core branch, soon to be pushed upstream.

Thanks,

- Arnaldo
 
> -- Steve
> 
> > 
> > We are still working on getting libtraceevent ready to be a stand alone
> > library. Part of that is to audit all the interfaces. We noticed
> > that the most the tep_print_*() interfaces define policy and limit
> > the way an application can display data. Instead of fixing this later
> > and being stuck with a limiting API that we must maintain for backward
> > compatibility, we removed and replaced most of it. perf was only affected
> > by a single function that was removed. These functions are replaced
> > by a more flexible one that allows the user to place what they want
> > where they want it (timestamps, event info, latency format, COMM, PID, etc).
> > 
> > The other noticeable perf change, is that we changed the location to
> > where the plugins are loaded from:
> > 
> >  ${HOME}/.traceevent/plugins
> > 
> > to
> > 
> >  ${HOME}/.local/lib/traceevent/plugins
> > 
> > As Patrick McLean (Gentoo package maintainer) informed us of the
> > XGD layout.
> > 
> > Should we have something the warns people if they have plugins in
> > the old directory. Should we move them on install? Currently, we
> > just ignore them.
> > 
> > Anyway, please add these patches to tip.
> > 
> > Thanks!
> > 
> > -- Steve
> > 
> > 
> > Tzvetomir Stoyanov (3):
> >       tools/lib/traceevent, tools/perf: Changes in tep_print_event_* APIs
> >       tools/lib/traceevent: Remove tep_register_trace_clock()
> >       tools/lib/traceevent: Change user's plugin directory
> > 
> > ----
> >  tools/lib/traceevent/Makefile            |   6 +-
> >  tools/lib/traceevent/event-parse-api.c   |  40 ----
> >  tools/lib/traceevent/event-parse-local.h |   6 -
> >  tools/lib/traceevent/event-parse.c       | 333 +++++++++++++++++--------------
> >  tools/lib/traceevent/event-parse.h       |  30 +--
> >  tools/lib/traceevent/event-plugin.c      |   2 +-
> >  tools/perf/builtin-kmem.c                |   3 +-
> >  tools/perf/util/sort.c                   |   3 +-
> >  tools/perf/util/trace-event-parse.c      |   2 +-
> >  9 files changed, 207 insertions(+), 218 deletions(-)