public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [Bug bpf/28285] New: Allow stapbpf backend to handle $arg1, $arg2, ...
@ 2021-08-27 19:50 wcohen at redhat dot com
  2021-09-02 19:23 ` [Bug bpf/28285] " wcohen at redhat dot com
  0 siblings, 1 reply; 2+ messages in thread
From: wcohen at redhat dot com @ 2021-08-27 19:50 UTC (permalink / raw)
  To: systemtap

https://sourceware.org/bugzilla/show_bug.cgi?id=28285

            Bug ID: 28285
           Summary: Allow stapbpf backend to handle $arg1, $arg2, ...
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: bpf
          Assignee: systemtap at sourceware dot org
          Reporter: wcohen at redhat dot com
  Target Milestone: ---

The stapbpf backend doesn't handle $argn (for example $arg2 in
gmalloc_watch.stp example below).  A number of the tapsets use $argn to access
values passed into functions.  The bpf backend should be able to access those
simple arguments also, but currently it fails.  This can be demonstrated with
some of the systemtap examples:

$ sudo dnf install glib2-devel
$ cd /usr/share/systemtap/testsuite/systemtap.examples/
$ sudo stap --bpf apps/gmalloc_watch.stp -T 1
semantic error: unhandled statement or expression type: identifier '$arg2' at
/usr/share/systemtap/tapset/x86_64/libglib-2.0.so.0.6800.4.stp:31:13
        source:   n_bytes = $arg2; 
                            ^

Pass 4: compilation failed.  [man error::pass4]
$ sudo stap  --bpf apps/stap_time.stp 
semantic error: unhandled statement or expression type: identifier '$arg1' at
/usr/share/systemtap/tapset/stap_staticmarkers.stp:18:12
        source:         session = $arg1
                                  ^

Pass 4: compilation failed.  [man error::pass4]


On the same machine the linux kernel module version things work fine:

$ sudo stap  apps/gmalloc_watch.stp -T 1
g_malloc: pid=2077 n_bytes=72
$ sudo stap  apps/stap_time.stp -T 1
$

-- 
You are receiving this mail because:
You are the assignee for the bug.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-09-02 19:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-27 19:50 [Bug bpf/28285] New: Allow stapbpf backend to handle $arg1, $arg2, wcohen at redhat dot com
2021-09-02 19:23 ` [Bug bpf/28285] " wcohen at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).