This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

/usr/share in XDG_DATA_DIRS breaks kprocess tapset


XDG_DATA_DIRS for my user is set to
/usr/share/kde-settings/kde-profile/default/share:/usr/local/share:/usr/share

The presence of /usr/share in XDG_DATA_DIRS causes the following problem
with the kprocess.stp tapset (as seen here using the forktracker.stp
example)

$ stap -p4 /usr/share/doc/systemtap-1.3/examples/process/forktracker.stp
/tmp/stapVVTQFz/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.c: In
function âprobe_3999â:
/tmp/stapVVTQFz/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.c:798: error:
âunion <anonymous>â has no member named âfunction__IS_ERRâ
/tmp/stapVVTQFz/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.c:799: error:
implicit declaration of function âfunction__IS_ERRâ
/tmp/stapVVTQFz/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.c:801: error:
âunion <anonymous>â has no member named âfunction__IS_ERRâ
make[1]: ***
[/tmp/stapVVTQFz/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.o] Error 1
make: *** [_module_/tmp/stapVVTQFz] Error 2
Pass 4: compilation failed.  Try again with another '--vp 0001' option.

Removing /usr/share from XDG_DATA_DIRS allows the script to run
properly. Looking at the issue with strace it the main difference
between the two scripts is the one with the bug is opening a lot of
extra files in /usr/share/systemtap/tapset/ that the successful run
isn't.

$ rm -rf ~/.systemtap;XDG_DATA_DIRS=/usr/share strace -eopen  stap
-p4 /usr/share/doc/systemtap-1.3/examples/process/forktracker.stp
>& /tmp/withbug
$ rm -rf ~/.systemtap;XDG_DATA_DIRS= strace -eopen  stap
-p4 /usr/share/doc/systemtap-1.3/examples/process/forktracker.stp
>& /tmp/nobug

I've attached the diff of the two straces and a diff of the two sets of
generated code, in both cases the working set is - and the broken is +

thanks,
Aaron
--- /tmp/nobug	2010-08-25 20:33:25.866206226 -0600
+++ /tmp/withbug	2010-08-25 20:32:51.963205458 -0600
@@ -154,6 +154,89 @@
 open("/usr/share/systemtap/tapset/udp.stp", O_RDONLY) = 3
 open("/usr/share/systemtap/tapset/utrace.stp", O_RDONLY) = 3
 open("/usr/share/systemtap/tapset/vfs.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/2.6.33.6-147.2.4.fc13.x86_64/x86_64", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
+open("/usr/share/systemtap/tapset/2.6.33.6-147.2.4.fc13.x86_64", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
+open("/usr/share/systemtap/tapset/2.6.33.6/x86_64", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
+open("/usr/share/systemtap/tapset/2.6.33.6", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
+open("/usr/share/systemtap/tapset/2.6.33/x86_64", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
+open("/usr/share/systemtap/tapset/2.6.33", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
+open("/usr/share/systemtap/tapset/2.6/x86_64", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
+open("/usr/share/systemtap/tapset/2.6", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
+open("/usr/share/systemtap/tapset/x86_64", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
+open("/usr/share/systemtap/tapset/x86_64/nd_syscalls.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/x86_64/registers.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/x86_64/syscalls.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
+open("/usr/share/systemtap/tapset/ansi.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/argv.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/atomic.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/aux_syscalls.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/context-symbols.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/context-unwind.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/context.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/conversions-guru.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/conversions.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/ctime.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/dentry.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/dev.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/endian.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/errno.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/indent-default.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/indent.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/inet.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/inet_sock.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/ioblock.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/ioscheduler.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/ip.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/ipmib-filter-default.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/ipmib.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/irq.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/kprocess.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/kretprobe.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/libpython2.6-64.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/linuxmib-filter-default.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/linuxmib.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/logging.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/memory.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/nd_syscalls.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/nd_syscalls2.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/networking.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/nfs.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/nfs_proc.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/nfsd.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/nfsderrno.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/null.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/perf.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/pn.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/proc_mem.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/queue_stats.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/random.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/rpc.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/scheduler.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/scsi.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/signal.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/socket.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/stap_staticmarkers.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/string.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/syscalls.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/syscalls2.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/syscalls_cfg_trunc.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/system.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/target_set.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/task.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/task_time.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/tcp.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/tcpmib-filter-default.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/tcpmib.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/timestamp.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/timestamp_gtod.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/tty.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/ucontext-symbols.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/ucontext-unwind.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/ucontext.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/udp.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/utrace.stp", O_RDONLY) = 3
+open("/usr/share/systemtap/tapset/vfs.stp", O_RDONLY) = 3
 open("/lib/modules/2.6.33.6-147.2.4.fc13.x86_64/debug.a", O_RDONLY) = -1 ENOENT (No such file or directory)
 open("/lib/modules/2.6.33.6-147.2.4.fc13.x86_64/debug.a", O_RDONLY) = -1 ENOENT (No such file or directory)
 open("/lib/modules/2.6.33.6-147.2.4.fc13.x86_64/.debug/debug.a", O_RDONLY) = -1 ENOENT (No such file or directory)
@@ -2931,12 +3014,12 @@
 open("/etc/localtime", O_RDONLY)        = 4
 open("/home/aluchko/.systemtap/cache/a6/typequery_a66b2c6ab5ad92a65503ac6de3ac0d7b_598_hash.log", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 4
 open("/home/aluchko/.systemtap/cache/a6/typequery_a66b2c6ab5ad92a65503ac6de3ac0d7b_598.ko", O_RDONLY) = -1 ENOENT (No such file or directory)
-open("/tmp/stapIFIiLS/typequery_kmod_1/Makefile", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 4
-open("/tmp/stapIFIiLS/typequery_kmod_1/typequery_kmod_1.c", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 4
+open("/tmp/staplZ5upJ/typequery_kmod_1/Makefile", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 4
+open("/tmp/staplZ5upJ/typequery_kmod_1/typequery_kmod_1.c", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 4
 --- SIGCHLD (Child exited) @ 0 (0) ---
-open("/tmp/stapIFIiLS/typequery_kmod_1/typequery_kmod_1.ko", O_RDONLY) = 4
-open("/home/aluchko/.systemtap/cache/a6/typequery_a66b2c6ab5ad92a65503ac6de3ac0d7b_598.ko.m7vdnV", O_RDWR|O_CREAT|O_EXCL, 0600) = 5
-open("/tmp/stapIFIiLS/typequery_kmod_1/typequery_kmod_1.ko", O_RDONLY) = 4
+open("/tmp/staplZ5upJ/typequery_kmod_1/typequery_kmod_1.ko", O_RDONLY) = 4
+open("/home/aluchko/.systemtap/cache/a6/typequery_a66b2c6ab5ad92a65503ac6de3ac0d7b_598.ko.XIsjRB", O_RDWR|O_CREAT|O_EXCL, 0600) = 5
+open("/tmp/staplZ5upJ/typequery_kmod_1/typequery_kmod_1.ko", O_RDONLY) = 4
 open("/lib/modules/2.6.33.6-147.2.4.fc13.x86_64/debug.a", O_RDONLY) = -1 ENOENT (No such file or directory)
 open("/lib/modules/2.6.33.6-147.2.4.fc13.x86_64/debug.a", O_RDONLY) = -1 ENOENT (No such file or directory)
 open("/lib/modules/2.6.33.6-147.2.4.fc13.x86_64/.debug/debug.a", O_RDONLY) = -1 ENOENT (No such file or directory)
@@ -9410,10 +9493,10 @@
 open("/home/aluchko/.systemtap/cache/a6/typequery_a66b2c6ab5ad92a65503ac6de3ac0d7b_598.ko", O_RDONLY) = 6
 open("/home/aluchko/.systemtap/cache/a6/typequery_a66b2c6ab5ad92a65503ac6de3ac0d7b_598_hash.log", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 6
 open("/home/aluchko/.systemtap/cache/a6/typequery_a66b2c6ab5ad92a65503ac6de3ac0d7b_598.ko", O_RDONLY) = 6
-open("/home/aluchko/.systemtap/cache/38/stap_3829792c612382c2af7d527a6e7a1ffd_7858_hash.log", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 3
-open("/home/aluchko/.systemtap/cache/38/stap_3829792c612382c2af7d527a6e7a1ffd_7858.ko", O_RDONLY) = -1 ENOENT (No such file or directory)
-open("/tmp/stapIFIiLS/stap_3829792c612382c2af7d527a6e7a1ffd_7858.c", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 3
-open("/tmp/stapIFIiLS/stap-symbols.h", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 4
+open("/home/aluchko/.systemtap/cache/8e/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891_hash.log", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 3
+open("/home/aluchko/.systemtap/cache/8e/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.ko", O_RDONLY) = -1 ENOENT (No such file or directory)
+open("/tmp/staplZ5upJ/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.c", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 3
+open("/tmp/staplZ5upJ/stap-symbols.h", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 4
 open("/lib/modules/2.6.33.6-147.2.4.fc13.x86_64/debug.a", O_RDONLY) = -1 ENOENT (No such file or directory)
 open("/lib/modules/2.6.33.6-147.2.4.fc13.x86_64/debug.a", O_RDONLY) = -1 ENOENT (No such file or directory)
 open("/lib/modules/2.6.33.6-147.2.4.fc13.x86_64/.debug/debug.a", O_RDONLY) = -1 ENOENT (No such file or directory)
@@ -12188,31 +12271,13 @@
 open("/lib/modules/2.6.33.6-147.2.4.fc13.x86_64/extra/VirtualBox-OSE", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 7
 open("/home/aluchko/.systemtap/cache/40/stapconf_4088388e3c479ba4f174d25e310a575c_577_hash.log", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 3
 open("/home/aluchko/.systemtap/cache/40/stapconf_4088388e3c479ba4f174d25e310a575c_577.h", O_RDONLY) = -1 ENOENT (No such file or directory)
-open("/tmp/stapIFIiLS/Makefile", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 3
+open("/tmp/staplZ5upJ/Makefile", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 3
+/tmp/staplZ5upJ/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.c: In function âprobe_3999â:
+/tmp/staplZ5upJ/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.c:798: error: âunion <anonymous>â has no member named âfunction__IS_ERRâ
+/tmp/staplZ5upJ/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.c:799: error: implicit declaration of function âfunction__IS_ERRâ
+/tmp/staplZ5upJ/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.c:801: error: âunion <anonymous>â has no member named âfunction__IS_ERRâ
+make[1]: *** [/tmp/staplZ5upJ/stap_8e1bcb59e9f4ec74857d1d7ac58f6669_8891.o] Error 1
+make: *** [_module_/tmp/staplZ5upJ] Error 2
 --- SIGCHLD (Child exited) @ 0 (0) ---
-/home/aluchko/.systemtap/cache/38/stap_3829792c612382c2af7d527a6e7a1ffd_7858.ko
-open("/home/aluchko/.systemtap/cache/cache_mb_limit", O_RDONLY) = -1 ENOENT (No such file or directory)
-open("/home/aluchko/.systemtap/cache/cache_mb_limit", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 3
-open("/home/aluchko/.systemtap/cache", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/a6", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/38", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/40", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/a6", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/38", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/40", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/a6", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/38", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/40", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/a6", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/38", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/home/aluchko/.systemtap/cache/40", O_RDONLY|O_NONBLOCK|O_DIRECTORY|O_CLOEXEC) = 3
-open("/tmp/stapIFIiLS/stap_3829792c612382c2af7d527a6e7a1ffd_7858.ko", O_RDONLY) = 3
-open("/home/aluchko/.systemtap/cache/38/stap_3829792c612382c2af7d527a6e7a1ffd_7858.ko.TFptww", O_RDWR|O_CREAT|O_EXCL, 0600) = 4
-open("/tmp/stapIFIiLS/stap_3829792c612382c2af7d527a6e7a1ffd_7858.c", O_RDONLY) = 3
-open("/home/aluchko/.systemtap/cache/38/stap_3829792c612382c2af7d527a6e7a1ffd_7858.c.pIPGG7", O_RDWR|O_CREAT|O_EXCL, 0600) = 4
-open("/tmp/stapIFIiLS/stapconf_4088388e3c479ba4f174d25e310a575c_577.h", O_RDONLY) = 3
-open("/home/aluchko/.systemtap/cache/40/stapconf_4088388e3c479ba4f174d25e310a575c_577.h.gID3QI", O_RDWR|O_CREAT|O_EXCL, 0600) = 4
+Pass 4: compilation failed.  Try again with another '--vp 0001' option.
 --- SIGCHLD (Child exited) @ 0 (0) ---
--- /tmp/stapR4khxE/stap_24993.c	2010-08-26 13:55:27.387893664 -0600
+++ /tmp/stapsAaxca/stap_24831.c	2010-08-26 13:55:18.256143908 -0600
@@ -114,7 +114,7 @@
   #endif
   struct uretprobe_instance *ri;
   union {
-    struct probe_2001_locals {
+    struct probe_3999_locals {
       int64_t task;
       int64_t new_pid;
       union {
@@ -136,8 +136,8 @@
           int64_t __tmp10;
         };
       };
-    } probe_2001;
-    struct probe_2003_locals {
+    } probe_3999;
+    struct probe_4003_locals {
       string_t filename;
       union {
         struct {
@@ -152,20 +152,16 @@
           string_t __tmp7;
         };
       };
-    } probe_2003;
+    } probe_4003;
   } probe_locals;
   union {
-    struct function__IS_ERR_locals {
-      int64_t ptr;
-      int64_t __retvalue;
-    } function__IS_ERR;
     struct function__dwarf_cast_get_cast_5_locals {
       int64_t pointer;
       int64_t __retvalue;
     } function__dwarf_cast_get_cast_5;
-    struct function__dwarf_tvar_get_filename_1_locals {
+    struct function__dwarf_tvar_get_filename_2_locals {
       int64_t __retvalue;
-    } function__dwarf_tvar_get_filename_1;
+    } function__dwarf_tvar_get_filename_2;
     struct function__dwarf_tvar_get_return_0_locals {
       int64_t __retvalue;
     } function__dwarf_tvar_get_return_0;
@@ -221,11 +217,9 @@
 
 
 
-static void function__IS_ERR (struct context * __restrict__ c);
-
 static void function__dwarf_cast_get_cast_5 (struct context * __restrict__ c);
 
-static void function__dwarf_tvar_get_filename_1 (struct context * __restrict__ c);
+static void function__dwarf_tvar_get_filename_2 (struct context * __restrict__ c);
 
 static void function__dwarf_tvar_get_return_0 (struct context * __restrict__ c);
 
@@ -243,35 +237,6 @@
 
 static void function_task_pid (struct context * __restrict__ c);
 
-static void function__IS_ERR (struct context* __restrict__ c) {
-  __label__ out;
-  struct function__IS_ERR_locals *  __restrict__ l = & c->locals[c->nesting+1].function__IS_ERR;
-  (void) l;
-  #define CONTEXT c
-  #define THIS l
-  c->last_stmt = "identifier '_IS_ERR' at /usr/share/systemtap/tapset/kprocess.stp:12:10";
-  if (unlikely (c->nesting+1 >= MAXNESTING)) {
-    c->last_error = "MAXNESTING exceeded";
-    return;
-  } else {
-    c->nesting ++;
-  }
-  l->__retvalue = 0;
-  #define return goto out
-  {
-     /* pure */
-    THIS->__retvalue = IS_ERR((const void *)(long)THIS->ptr);
-
-  }
-  #undef return
-out:
-  if (0) goto out;
-  c->nesting --;
-  #undef CONTEXT
-  #undef THIS
-}
-
-
 static void function__dwarf_cast_get_cast_5 (struct context* __restrict__ c) {
   __label__ out;
   struct function__dwarf_cast_get_cast_5_locals *  __restrict__ l = & c->locals[c->nesting+1].function__dwarf_cast_get_cast_5;
@@ -327,9 +292,9 @@
 }
 
 
-static void function__dwarf_tvar_get_filename_1 (struct context* __restrict__ c) {
+static void function__dwarf_tvar_get_filename_2 (struct context* __restrict__ c) {
   __label__ out;
-  struct function__dwarf_tvar_get_filename_1_locals *  __restrict__ l = & c->locals[c->nesting+1].function__dwarf_tvar_get_filename_1;
+  struct function__dwarf_tvar_get_filename_2_locals *  __restrict__ l = & c->locals[c->nesting+1].function__dwarf_tvar_get_filename_2;
   (void) l;
   #define CONTEXT c
   #define THIS l
@@ -789,11 +754,11 @@
 static __cacheline_aligned Stat time_probe_0;
 #endif
 
-static void probe_2001 (struct context * __restrict__ c) {
+static void probe_3999 (struct context * __restrict__ c) {
   __label__ out;
   static const struct stp_probe_lock locks[] = {
   };
-  struct probe_2001_locals * __restrict__ l = & c->probe_locals.probe_2001;
+  struct probe_3999_locals * __restrict__ l = & c->probe_locals.probe_3999;
   (void) l;
   #ifndef STP_PRIVILEGED
   #error Internal Error: Probe kernel.function("copy_process@kernel/fork.c:978").return generated in --unprivileged mode
@@ -907,11 +872,11 @@
 static __cacheline_aligned Stat time_probe_1;
 #endif
 
-static void probe_2003 (struct context * __restrict__ c) {
+static void probe_4003 (struct context * __restrict__ c) {
   __label__ out;
   static const struct stp_probe_lock locks[] = {
   };
-  struct probe_2003_locals * __restrict__ l = & c->probe_locals.probe_2003;
+  struct probe_4003_locals * __restrict__ l = & c->probe_locals.probe_4003;
   (void) l;
   #ifndef STP_PRIVILEGED
   #error Internal Error: Probe kernel.function("do_execve@fs/exec.c:1314") generated in --unprivileged mode
@@ -932,9 +897,9 @@
       ({
         l->__tmp2 = 
         ({
-          function__dwarf_tvar_get_filename_1 (c);
+          function__dwarf_tvar_get_filename_2 (c);
           if (unlikely(c->last_error)) goto out;
-          c->locals[c->nesting+1].function__dwarf_tvar_get_filename_1.__retvalue;
+          c->locals[c->nesting+1].function__dwarf_tvar_get_filename_2.__retvalue;
         });
         c->locals[c->nesting+1].function_kernel_string.addr = l->__tmp2;
         function_kernel_string (c);
@@ -1012,9 +977,9 @@
 static int enter_kprobe_probe (struct kprobe *inst, struct pt_regs *regs);
 static int enter_kretprobe_probe (struct kretprobe_instance *inst, struct pt_regs *regs);
 #if defined(STAPCONF_UNREGISTER_KPROBES)
-static void * stap_unreg_kprobes[3];
+static void * stap_unreg_kprobes[6];
 #endif
-static struct stap_dwarf_kprobe stap_dwarf_kprobes[3];
+static struct stap_dwarf_kprobe stap_dwarf_kprobes[6];
 static struct stap_dwarf_probe {
   const unsigned return_p:1;
   const unsigned maxactive_p:1;
@@ -1034,14 +999,17 @@
   const char *pathname;
   struct stap_task_finder_target finder;
 } stap_dwarf_probes[] = {
-  { .return_p=1, .address=(unsigned long)0x4904dULL, .module="kernel", .section="_stext", .probe=STAP_PROBE_INIT(&probe_2001, "kernel.function(\"copy_process@kernel/fork.c:978\").return", "kprocess.create"), .sdt_sem_offset=0, },
-  { .address=(unsigned long)0x1070eaULL, .module="kernel", .section="_stext", .probe=STAP_PROBE_INIT(&probe_2003, "kernel.function(\"do_execve@fs/exec.c:1314\")", "kprocess.exec"), .sdt_sem_offset=0, },
-  { .optional_p=1, .address=(unsigned long)0x134e56ULL, .module="kernel", .section="_stext", .probe=STAP_PROBE_INIT(&probe_2003, "kernel.function(\"compat_do_execve@fs/compat.c:1459\")?", "kprocess.exec"), .sdt_sem_offset=0, },
+  { .return_p=1, .address=(unsigned long)0x4904dULL, .module="kernel", .section="_stext", .probe=STAP_PROBE_INIT(&probe_3999, "kernel.function(\"copy_process@kernel/fork.c:978\").return", "kprocess.create"), .sdt_sem_offset=0, },
+  { .return_p=1, .address=(unsigned long)0x4904dULL, .module="kernel", .section="_stext", .probe=STAP_PROBE_INIT(&probe_3999, "kernel.function(\"copy_process@kernel/fork.c:978\").return", "kprocess.create"), .sdt_sem_offset=0, },
+  { .address=(unsigned long)0x1070eaULL, .module="kernel", .section="_stext", .probe=STAP_PROBE_INIT(&probe_4003, "kernel.function(\"do_execve@fs/exec.c:1314\")", "kprocess.exec"), .sdt_sem_offset=0, },
+  { .optional_p=1, .address=(unsigned long)0x134e56ULL, .module="kernel", .section="_stext", .probe=STAP_PROBE_INIT(&probe_4003, "kernel.function(\"compat_do_execve@fs/compat.c:1459\")?", "kprocess.exec"), .sdt_sem_offset=0, },
+  { .address=(unsigned long)0x1070eaULL, .module="kernel", .section="_stext", .probe=STAP_PROBE_INIT(&probe_4003, "kernel.function(\"do_execve@fs/exec.c:1314\")", "kprocess.exec"), .sdt_sem_offset=0, },
+  { .optional_p=1, .address=(unsigned long)0x134e56ULL, .module="kernel", .section="_stext", .probe=STAP_PROBE_INIT(&probe_4003, "kernel.function(\"compat_do_execve@fs/compat.c:1459\")?", "kprocess.exec"), .sdt_sem_offset=0, },
 };
 
 static int enter_kprobe_probe (struct kprobe *inst, struct pt_regs *regs) {
   int kprobe_idx = ((uintptr_t)inst-(uintptr_t)stap_dwarf_kprobes)/sizeof(struct stap_dwarf_kprobe);
-  struct stap_dwarf_probe *sdp = &stap_dwarf_probes[((kprobe_idx >= 0 && kprobe_idx < 3)?kprobe_idx:0)];
+  struct stap_dwarf_probe *sdp = &stap_dwarf_probes[((kprobe_idx >= 0 && kprobe_idx < 6)?kprobe_idx:0)];
   struct context* __restrict__ c;
   #if !INTERRUPTIBLE
   unsigned long flags;
@@ -1172,7 +1140,7 @@
 static int enter_kretprobe_common (struct kretprobe_instance *inst, struct pt_regs *regs, int entry) {
   struct kretprobe *krp = inst->rp;
   int kprobe_idx = ((uintptr_t)krp-(uintptr_t)stap_dwarf_kprobes)/sizeof(struct stap_dwarf_kprobe);
-  struct stap_dwarf_probe *sdp = &stap_dwarf_probes[((kprobe_idx >= 0 && kprobe_idx < 3)?kprobe_idx:0)];
+  struct stap_dwarf_probe *sdp = &stap_dwarf_probes[((kprobe_idx >= 0 && kprobe_idx < 6)?kprobe_idx:0)];
   struct context* __restrict__ c;
   #if !INTERRUPTIBLE
   unsigned long flags;
@@ -1355,8 +1323,8 @@
   time_probe_0 = _stp_stat_init (HIST_NONE);
   time_probe_1 = _stp_stat_init (HIST_NONE);
   #endif
-  _stp_print_kernel_info("1.3/0.148", (num_online_cpus() * sizeof(struct context)), 3);
-  for (i=0; i<3; i++) {
+  _stp_print_kernel_info("1.3/0.148", (num_online_cpus() * sizeof(struct context)), 6);
+  for (i=0; i<6; i++) {
     struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
     struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];
     unsigned long relocated_addr = _stp_kmodule_relocate (sdp->module, sdp->section, sdp->address);
@@ -1429,7 +1397,7 @@
   if (rc) {
     _stp_error ("probe %s registration error (rc %d)", probe_point, rc);
     atomic_set (&session_state, STAP_SESSION_ERROR);
-    for (i=0; i<3; i++) {
+    for (i=0; i<6; i++) {
       struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
       unsigned short sdt_semaphore = 0;
       if (sdp->sdt_sem_address && __access_process_vm_noflush (sdp->tsk, sdp->sdt_sem_address, &sdt_semaphore, sizeof (sdt_semaphore), 0)) {
@@ -1439,7 +1407,7 @@
     }
     #if defined(STAPCONF_UNREGISTER_KPROBES)
     j = 0;
-    for (i=0; i<3; i++) {
+    for (i=0; i<6; i++) {
       struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
       struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];
       if (! sdp->registered_p) continue;
@@ -1448,7 +1416,7 @@
     }
     unregister_kprobes((struct kprobe **)stap_unreg_kprobes, j);
     j = 0;
-    for (i=0; i<3; i++) {
+    for (i=0; i<6; i++) {
       struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
       struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];
       if (! sdp->registered_p) continue;
@@ -1458,7 +1426,7 @@
     unregister_kretprobes((struct kretprobe **)stap_unreg_kprobes, j);
     #ifdef __ia64__
     j = 0;
-    for (i=0; i<3; i++) {
+    for (i=0; i<6; i++) {
       struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
       struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];
       if (! sdp->registered_p) continue;
@@ -1467,7 +1435,7 @@
     unregister_kprobes((struct kprobe **)stap_unreg_kprobes, j);
     #endif
     #endif
-    for (i=0; i<3; i++) {
+    for (i=0; i<6; i++) {
       struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
       struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];
       if (! sdp->registered_p) continue;
@@ -1535,7 +1503,7 @@
   
   /* ---- task finder ---- */
   stap_stop_task_finder();
-  for (i=0; i<3; i++) {
+  for (i=0; i<6; i++) {
     struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
     unsigned short sdt_semaphore = 0;
     if (sdp->sdt_sem_address && __access_process_vm_noflush (sdp->tsk, sdp->sdt_sem_address, &sdt_semaphore, sizeof (sdt_semaphore), 0)) {
@@ -1545,7 +1513,7 @@
   }
   #if defined(STAPCONF_UNREGISTER_KPROBES)
   j = 0;
-  for (i=0; i<3; i++) {
+  for (i=0; i<6; i++) {
     struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
     struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];
     if (! sdp->registered_p) continue;
@@ -1554,7 +1522,7 @@
   }
   unregister_kprobes((struct kprobe **)stap_unreg_kprobes, j);
   j = 0;
-  for (i=0; i<3; i++) {
+  for (i=0; i<6; i++) {
     struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
     struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];
     if (! sdp->registered_p) continue;
@@ -1564,7 +1532,7 @@
   unregister_kretprobes((struct kretprobe **)stap_unreg_kprobes, j);
   #ifdef __ia64__
   j = 0;
-  for (i=0; i<3; i++) {
+  for (i=0; i<6; i++) {
     struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
     struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];
     if (! sdp->registered_p) continue;
@@ -1573,7 +1541,7 @@
   unregister_kprobes((struct kprobe **)stap_unreg_kprobes, j);
   #endif
   #endif
-  for (i=0; i<3; i++) {
+  for (i=0; i<6; i++) {
     struct stap_dwarf_probe *sdp = & stap_dwarf_probes[i];
     struct stap_dwarf_kprobe *kp = & stap_dwarf_kprobes[i];
     if (! sdp->registered_p) continue;

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]