From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27701 invoked by alias); 6 Jul 2016 20:38:24 -0000 Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org Received: (qmail 27617 invoked by uid 48); 6 Jul 2016 20:38:12 -0000 From: "dsmith at redhat dot com" To: systemtap@sourceware.org Subject: [Bug tapsets/20333] New: merge syscall and nd_syscall tapsets Date: Wed, 06 Jul 2016 20:38:00 -0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: systemtap X-Bugzilla-Component: tapsets X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: enhancement X-Bugzilla-Who: dsmith at redhat dot com X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: systemtap at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2016-q3/txt/msg00014.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=3D20333 Bug ID: 20333 Summary: merge syscall and nd_syscall tapsets Product: systemtap Version: unspecified Status: NEW Severity: enhancement Priority: P2 Component: tapsets Assignee: systemtap at sourceware dot org Reporter: dsmith at redhat dot com Target Milestone: --- It might be possible to merge the syscall and nd_syscall tapsets. Internall= y, it might look something like this: =3D=3D=3D=3D probe syscall.open =3D kernel.function("sys_open").call !,=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 kprobe.function("sys_open") ?=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 {=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20 name =3D "open"=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 if (@defined($filename) && @defined($flags) && @defined($mode))=20= =20=20=20=20=20=20=20=20 {=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 filename =3D user_string_quoted(__uint32($filename))=20=20= =20=20=20=20=20=20=20=20=20=20=20=20 flags =3D __int32($flags)=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20 mode =3D __uint32($mode)=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20 }=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 else=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 {=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 asmlinkage() filename =3D user_string_quoted(pointer_arg(1)) flags =3D int_arg(2) mode =3D uint_arg(3) } if (flags & @const("O_CREAT")) argstr =3D sprintf("%s, %s, %#o", filename, _sys_open_flag_str(flags), mode) else argstr =3D sprintf("%s, %s", filename, _sys_open_flag_str(flags)) } probe nd_syscall.open =3D syscall.open =3D=3D=3D=3D Note that the above code really isn't sufficient (or tested). The above code doesn't handle return probes, compat functions, and syscall nesting. There are some issues with this idea: - If you have debuginfo installed, there really isn't a way to specify you = want the non-debuginfo version of the probe. (Although why you'd really want to = do that I'm not so sure). The above code prefers the debuginfo version. - Perhaps the biggest problem with this idea is how users actually use sysc= all probes. I've seen user code (and I believe some of our examples) use a sysc= all probe, but then also use the 'raw' $FOO variables, which certainly wouldn't work correctly if no debuginfo was installed. --=20 You are receiving this mail because: You are the assignee for the bug.