2016-03-07 Md Haris Iqbal <haris.p...@gmail.com> * defs.h * + define TRACE_SCHED 04000 / Trace scheduler-related syscalls /
* syscall.c (lookup_class) * + if (strcmp(s, "scheduler") == 0) * + return TRACE_SCHED; * + define TSC TRACE_SCHED * All syscallent.h files * added TSC flag Tested with -e trace=scheduler On Thu, Mar 3, 2016 at 5:47 AM, Dmitry V. Levin <l...@altlinux.org> wrote: > On Wed, Mar 02, 2016 at 10:45:53AM +0530, haris iqbal wrote: > [...] >> A little help is needed here. I could understand that for the -e >> option, one uses the combination of sysent_vec[][].sys_flags and the >> macros TRACE_FILE and others, which sets the proper flag in qual_vec. >> Now that qual_vec is used by qual_flg in the tcb struct (correct me if >> something is wrong). >> >> But what I could not find is where those flag is used to print only >> the syscalls that are needed (like only file related). I searched and >> followed the flow of execution and found trace_syscall_entering() >> through trace_syscall() in trace(). There is a function calles >> get_scno(), I guess its where this syscall filtering is happening but >> not sure. Can someone please point me in the right direction. > > tcp->qual_flg is initialized from qual_flags[tcp->scno] in get_scno() > and later tested for QUAL_TRACE flag in trace_syscall_entering(). > >> NOTE: >> >> 1) I am looking at the -e option closely to come up with a POC for the >> idea "Fault injection for syscalls". >> >> 2) Waiting for a reply for the naming policy so that I can start >> working to add the sched_* and the *uid *gid ones to the -e option. > > You can start with some naming policy, e.g. %sched, %uid, and %gid. > I suppose a patch might attract more comments than a general discussion > on the subject. > > > -- > ldv > > ------------------------------------------------------------------------------ > Site24x7 APM Insight: Get Deep Visibility into Application Performance > APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month > Monitor end-to-end web transactions and take corrective actions now > Troubleshoot faster and improve end-user experience. Signup Now! > http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140 > _______________________________________________ > Strace-devel mailing list > Strace-devel@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 ------------------------------------------------------------------------------ Transform Data into Opportunity. Accelerate data analysis in your applications with Intel Data Analytics Acceleration Library. Click to learn more. http://makebettercode.com/inteldaal-eval _______________________________________________ Strace-devel mailing list Strace-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/strace-devel