Working on -e trace

haris iqbal haris.phnx at gmail.com
Thu Mar 10 20:30:10 UTC 2016


On Fri, Mar 11, 2016 at 1:26 AM, Dmitry V. Levin <ldv at altlinux.org> wrote:
> On Thu, Mar 10, 2016 at 11:42:24PM +0530, haris iqbal wrote:
>> On Thu, Mar 10, 2016 at 5:24 AM, Dmitry V. Levin wrote:
>> > On Wed, Mar 09, 2016 at 11:02:52AM +0530, haris iqbal wrote:
>> > [...]
>> >> Sorry for the multiple commits. My vim is giving trouble.
>> >
>> > Please don't send incremental commits, just amend and send the one you
>> > already have.
>>
>> I did not quite understand this. So, I make changes and send the older
>> commit log? How will the changes be seen by you guys then?
>
> Could you submit a patch implementing the change as a single commit,
> not as a series of commits, please?
>
>> >> >> --- a/syscall.c
>> >> >> +++ b/syscall.c
>> >> >> @@ -78,6 +78,7 @@
>> >> >>  #define TP TRACE_PROCESS
>> >> >>  #define TS TRACE_SIGNAL
>> >> >>  #define TM TRACE_MEMORY
>> >> >> +#define TSC TRACE_SCHED
>> >> >>  #define NF SYSCALL_NEVER_FAILS
>> >> >>  #define MA MAX_ARGS
>> >> >>  #define SI STACKTRACE_INVALIDATE_CACHE
>> >> >> @@ -500,6 +501,8 @@ lookup_class(const char *s)
>> >> >>          return TRACE_DESC;
>> >> >>      if (strcmp(s, "memory") == 0)
>> >> >>          return TRACE_MEMORY;
>> >> >> +    if (strcmp(s, "scheduler") == 0)
>> >> >> +        return TRACE_SCHED;
>> >> >>      return -1;
>> >> >>  }
>> >> >
>> >> > Please follow the indentation style.
>> >> > BTW, why "scheduler"?  Could you give a rationale for this name?
>> >>
>> >> I thought as all the system calls are one or the other related to the
>> >> scheduler. We can also consider the description "syscalls relate to
>> >> scheduling.
>> >
>> > There is a subtle difference between a scheduler (an actor) and a set
>> > of syscalls related to scheduling (an action) than might lead to confusion
>> > in the future.  That's why I still think that "%sched" would be better in
>> > long run than "scheduler" or "scheduling".
>>
>> True, but my concern was we cannot change the name of this new one to
>> "%sched", while the older ones are still following some other naming
>> convention. What can be done is, we can decide on the names for all
>> the existing options (for file, memory, ..) and then change all in one
>> commit.
>
> All currently supported names of syscall sets will remain supported no
> matter what kind of naming scheme will be used later.  So once we added
> "scheduler" to the user API, we would have to keep it.

So, lets say I use "%sched" for this new one, won't it look
inconsistent among other names of other options (like for memory, file
and all).

>
>> --- a/NEWS
>> +++ b/NEWS
>> @@ -12,6 +12,7 @@ Noteworthy changes in release ?.?? (????-??-??)
>>      spent in decoding socket details in -yy mode.
>>    * Implemented decoding of copy_file_range syscall.
>>    * Implemented dumping of vmsplice syscall.
>> +  * Added feature to trace scheduler related system calls with option -e.
>
> Please change the wording to follow the style.  You can use
> "-e trace=memory" in the same file as an example.
>
>> --- a/strace.1
>> +++ b/strace.1
>> @@ -423,6 +423,9 @@ Trace all file descriptor related system calls.
>>  .BR "\-e\ trace" = memory
>>  Trace all memory mapping related system calls.
>>  .TP
>> +.BR "\-e\ trace" = scheduler
>> +Trace all scheduler related system calls.
>> +.TP
>>  \fB\-e\ abbrev\fR=\,\fIset\fR
>>  Abbreviate the output from printing each member of large structures.
>>  The default is
>
> That's fine.
>
>
> --
> ldv
>
> ------------------------------------------------------------------------------
> Transform Data into Opportunity.
> Accelerate data analysis in your applications with
> Intel Data Analytics Acceleration Library.
> Click to learn more.
> http://pubads.g.doubleclick.net/gampad/clk?id=278785111&iu=/4140
> _______________________________________________
> Strace-devel mailing list
> Strace-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/strace-devel
>



-- 

With regards,

Md Haris Iqbal,
Placement Coordinator, MTech IT
NITK Surathkal,
Contact: +91 8861996962




More information about the Strace-devel mailing list