Re: [PATCH 08/11] trace-cmd: Making start,extract,stream,profile separate funcs

2017-11-29 Thread Steven Rostedt
On Wed, 29 Nov 2017 12:03:14 +0200 Vladislav Valtchev wrote: > On Tue, 2017-11-28 at 14:35 -0500, Steven Rostedt wrote: > > > > Yes. Simply because we lost the fact that we can do it better. > > > > Hi Steven, > of course we can do better, if we make a step further than just > a mechanical r

Re: [PATCH 08/11] trace-cmd: Making start,extract,stream,profile separate funcs

2017-11-29 Thread Vladislav Valtchev
On Tue, 2017-11-28 at 14:35 -0500, Steven Rostedt wrote: > > Yes. Simply because we lost the fact that we can do it better. > Hi Steven, of course we can do better, if we make a step further than just a mechanical refactoring. I'm used to intentionally limit myself to do such kind of mechanical

Re: [PATCH 08/11] trace-cmd: Making start,extract,stream,profile separate funcs

2017-11-28 Thread Steven Rostedt
On Tue, 28 Nov 2017 20:34:22 +0200 Vladislav Valtchev wrote: > On Tue, 2017-11-28 at 12:14 -0500, Steven Rostedt wrote: > > As everything is doing both init_common_record_context() and > > parse_record_options() why not just move the > > init_common_record_context() into parse_record_option

Re: [PATCH 08/11] trace-cmd: Making start,extract,stream,profile separate funcs

2017-11-28 Thread Vladislav Valtchev
On Tue, 2017-11-28 at 12:14 -0500, Steven Rostedt wrote: > As everything is doing both init_common_record_context() and > parse_record_options() why not just move the > init_common_record_context() into parse_record_options(). If you need > to do something special (like set events = 1 for p

Re: [PATCH 08/11] trace-cmd: Making start,extract,stream,profile separate funcs

2017-11-28 Thread Steven Rostedt
On Thu, 23 Nov 2017 18:33:32 +0200 "Vladislav Valtchev (VMware)" wrote: > +static void init_common_record_context(struct common_record_context *ctx, > +enum trace_cmd curr_cmd) > +{ > + memset(ctx, 0, sizeof(*ctx)); > + ctx->instance = &top_instance; >

[PATCH 08/11] trace-cmd: Making start,extract,stream,profile separate funcs

2017-11-23 Thread Vladislav Valtchev (VMware)
This simple patch make the above-mentioned commands independent from 'record'. The point of doing so is to follow the convention of one entry-point per command that is followed by most of trace-cmd's code. Ultimately that aims to prevent the complexity to concentrate in a single point, making the c