diff options
author | David Smith <dsmith@redhat.com> | 2009-05-21 16:57:04 -0500 |
---|---|---|
committer | David Smith <dsmith@redhat.com> | 2009-05-21 16:57:04 -0500 |
commit | c8e9eb18d8d13d099a4a177fe53de507c1d9ce8b (patch) | |
tree | ab2388afb795ed1a7ead2fbbf8b9d1b368a8231f /testsuite/buildok | |
parent | dd9a3bcbef65bde65491d959e9458bc641924811 (diff) | |
parent | 3863e7999255deeaa7f8f4bba7df893773812537 (diff) | |
download | systemtap-steved-c8e9eb18d8d13d099a4a177fe53de507c1d9ce8b.tar.gz systemtap-steved-c8e9eb18d8d13d099a4a177fe53de507c1d9ce8b.tar.xz systemtap-steved-c8e9eb18d8d13d099a4a177fe53de507c1d9ce8b.zip |
Merge commit 'origin/master' into pr7043
Conflicts:
runtime/print.c
runtime/transport/transport.c
runtime/transport/transport_msgs.h
Diffstat (limited to 'testsuite/buildok')
-rwxr-xr-x | testsuite/buildok/context_test.stp | 22 | ||||
-rwxr-xr-x | testsuite/buildok/maxactive01.stp | 2 | ||||
-rwxr-xr-x | testsuite/buildok/modname.stp | 8 | ||||
-rwxr-xr-x | testsuite/buildok/process-all-probes.stp | 12 | ||||
-rwxr-xr-x | testsuite/buildok/process_test.stp | 12 | ||||
-rwxr-xr-x | testsuite/buildok/seventeen.stp | 9 | ||||
-rwxr-xr-x | testsuite/buildok/symdata.stp | 8 | ||||
-rwxr-xr-x | testsuite/buildok/symname.stp | 8 | ||||
-rwxr-xr-x | testsuite/buildok/task-embedded.stp | 4 | ||||
-rwxr-xr-x | testsuite/buildok/task_test.stp | 2 | ||||
-rwxr-xr-x | testsuite/buildok/tcp_test.stp | 14 | ||||
-rwxr-xr-x | testsuite/buildok/thirteen.stp | 2 | ||||
-rwxr-xr-x | testsuite/buildok/thirty.stp | 49 | ||||
-rwxr-xr-x | testsuite/buildok/thirtyone.stp | 4 | ||||
-rwxr-xr-x | testsuite/buildok/twentysix.stp | 7 | ||||
-rwxr-xr-x | testsuite/buildok/uaddr.stp | 8 | ||||
-rwxr-xr-x | testsuite/buildok/ustack.stp | 10 | ||||
-rwxr-xr-x | testsuite/buildok/usymdata.stp | 8 | ||||
-rwxr-xr-x | testsuite/buildok/usymname.stp | 8 |
19 files changed, 148 insertions, 49 deletions
diff --git a/testsuite/buildok/context_test.stp b/testsuite/buildok/context_test.stp index 84f1cbf1..acc4ea07 100755 --- a/testsuite/buildok/context_test.stp +++ b/testsuite/buildok/context_test.stp @@ -1,6 +1,6 @@ #! stap -p4 -function print_stuff () { +probe begin { print_regs() print_backtrace() bt = backtrace() @@ -18,23 +18,5 @@ function print_stuff () { printf("gid is %d\n", gid()) printf("egid is %d\n", egid()) printf("pp is %s\n", pp()) -} - -probe kernel.function("uptime_read_proc") ? { - print("NOW IN UPTIME\n") - print_stuff () -} - -probe kernel.function("uptime_read_proc").return ? { - print("DONE WITH UPTIME\n") - print_stuff () - exit () -} - -probe begin { - print ("BEGIN\n") -} - -probe end { - print ("END\n") + printf("sid is %d\n", sid()) } diff --git a/testsuite/buildok/maxactive01.stp b/testsuite/buildok/maxactive01.stp index afdb2cea..1cf893ef 100755 --- a/testsuite/buildok/maxactive01.stp +++ b/testsuite/buildok/maxactive01.stp @@ -1,6 +1,6 @@ #! stap -p4 -probe kernel.function("sys_read").return.maxactive(3) +probe kernel.function("vfs_read").return.maxactive(3) { printf("."); } diff --git a/testsuite/buildok/modname.stp b/testsuite/buildok/modname.stp new file mode 100755 index 00000000..02229301 --- /dev/null +++ b/testsuite/buildok/modname.stp @@ -0,0 +1,8 @@ +#! stap -p4 +# +# Test the translatability for modname() +# +probe begin +{ + log(modname(0)) +} diff --git a/testsuite/buildok/process-all-probes.stp b/testsuite/buildok/process-all-probes.stp index 91a96514..c754462b 100755 --- a/testsuite/buildok/process-all-probes.stp +++ b/testsuite/buildok/process-all-probes.stp @@ -2,11 +2,11 @@ // Tests if all probes in the process tapset are resolvable. -probe process.create, - process.start, - process.exec, - process.exec_complete, - process.exit, - process.release +probe kprocess.create, + kprocess.start, + kprocess.exec, + kprocess.exec_complete, + kprocess.exit, + kprocess.release { } diff --git a/testsuite/buildok/process_test.stp b/testsuite/buildok/process_test.stp index 90de8b69..ba3fadf1 100755 --- a/testsuite/buildok/process_test.stp +++ b/testsuite/buildok/process_test.stp @@ -1,31 +1,31 @@ #! stap -p4 -probe process.create { +probe kprocess.create { log(pp()) log(sprint(task)) } -probe process.start { +probe kprocess.start { log(pp()) } -probe process.exec { +probe kprocess.exec { log(pp()) log(filename) } -probe process.exec_complete { +probe kprocess.exec_complete { log(pp()) log(sprint(errno)) log(sprint(success)) } -probe process.exit { +probe kprocess.exit { log(pp()) log(sprint(code)) } -probe process.release { +probe kprocess.release { log(pp()) log(sprint(task)) } diff --git a/testsuite/buildok/seventeen.stp b/testsuite/buildok/seventeen.stp index 126db1fb..4e0b07c4 100755 --- a/testsuite/buildok/seventeen.stp +++ b/testsuite/buildok/seventeen.stp @@ -11,3 +11,12 @@ probe kernel.function("pipe_write") printf("0x%x\n", $write_fifo_fops->llseek) %) } + +# PR10000: We're looking for *some* module function that has a nearby global variable in scope +# XXX: See PR4096 +probe module("nfs").function("nfs_create_client") !, module("nfs").function("nfs_init_client") !, + kernel.function("nfs_fsync_dir") { + println(kernel_string($nfs_program->name)) +} + +probe timer.s(5) { exit() } diff --git a/testsuite/buildok/symdata.stp b/testsuite/buildok/symdata.stp new file mode 100755 index 00000000..d7e803a9 --- /dev/null +++ b/testsuite/buildok/symdata.stp @@ -0,0 +1,8 @@ +#! stap -p4 +# +# Test the translatability for symdata() +# +probe begin +{ + log(symdata(0)) +} diff --git a/testsuite/buildok/symname.stp b/testsuite/buildok/symname.stp new file mode 100755 index 00000000..e082d1a5 --- /dev/null +++ b/testsuite/buildok/symname.stp @@ -0,0 +1,8 @@ +#! stap -p4 +# +# Test the translatability for symname() +# +probe begin +{ + log(symname(0)) +} diff --git a/testsuite/buildok/task-embedded.stp b/testsuite/buildok/task-embedded.stp index 4d1f5300..d35f3e0d 100755 --- a/testsuite/buildok/task-embedded.stp +++ b/testsuite/buildok/task-embedded.stp @@ -14,6 +14,8 @@ probe begin { task_nice (0) + task_cpu (0) + task_open_file_handles (0) + - task_max_file_handles (0)) + task_max_file_handles (0) + + pid2task(0)) print (task_execname (0)) + print (pid2execname (0)) } diff --git a/testsuite/buildok/task_test.stp b/testsuite/buildok/task_test.stp index c8da7da5..792f96ea 100755 --- a/testsuite/buildok/task_test.stp +++ b/testsuite/buildok/task_test.stp @@ -16,5 +16,7 @@ probe begin { log(sprint(task_cpu(c))) log(sprint(task_open_file_handles(c))) log(sprint(task_max_file_handles(c))) + log(sprint(pid2task(pid()))) + log(sprint(pid2execname(pid()))) exit() } diff --git a/testsuite/buildok/tcp_test.stp b/testsuite/buildok/tcp_test.stp index a262ab29..a5e3bafb 100755 --- a/testsuite/buildok/tcp_test.stp +++ b/testsuite/buildok/tcp_test.stp @@ -8,16 +8,16 @@ function print_report() } probe tcp.sendmsg { - ports = inet_get_local_port(sk) - src_ips = inet_get_ip_source(sk) - rtos = tcp_get_info_rto(sk) + ports = inet_get_local_port(sock) + src_ips = inet_get_ip_source(sock) + rtos = tcp_get_info_rto(sock) } probe tcp.recvmsg { - cwnd = tcp_get_info_snd_cwnd(sk) - mss = tcp_ts_get_info_rcv_mss(sk) - ssthresh = tcp_ts_get_info_snd_ssthresh(sk) - state = tcp_ts_get_info_state(sk) + cwnd = tcp_get_info_snd_cwnd(sock) + mss = tcp_ts_get_info_rcv_mss(sock) + ssthresh = tcp_ts_get_info_snd_ssthresh(sock) + state = tcp_ts_get_info_state(sock) } probe tcp.sendmsg.return { diff --git a/testsuite/buildok/thirteen.stp b/testsuite/buildok/thirteen.stp index 4dffc4b9..32228e79 100755 --- a/testsuite/buildok/thirteen.stp +++ b/testsuite/buildok/thirteen.stp @@ -1,6 +1,6 @@ #! stap -p4 -probe kernel.function("sys_read") +probe kernel.function("vfs_read") { printf ("count=%d\n", $count) } diff --git a/testsuite/buildok/thirty.stp b/testsuite/buildok/thirty.stp new file mode 100755 index 00000000..042bae56 --- /dev/null +++ b/testsuite/buildok/thirty.stp @@ -0,0 +1,49 @@ +#! stap -p4 + +# tests wide arrays +global a1, a2, a3, a4, a5, a6, a7, a8, a9 +global b1, b2, b3, b4, b5, b6, b7, b8, b9 +global c1, c2, c3, c4, c5, c6, c7, c8, c9 +global d1, d2, d3, d4, d5, d6, d7, d8, d9 + +probe begin { + a1[0]="a"; + a2[0,"a"]="a"; + a3[0,"a",0]="a"; + a4[0,"a",0,"a"]="a"; + a5[0,"a",0,"a",0]="a"; + a6[0,"a",0,"a",0,"a"]="a"; + a7[0,"a",0,"a",0,"a",0]="a"; + a8[0,"a",0,"a",0,"a",0,"a"]="a"; + a9[0,"a",0,"a",0,"a",0,"a",0]="a"; + + b1["b"]=0; + b2["b",0]=0; + b3["b",0,"b"]=0; + b4["b",0,"b",0]=0; + b5["b",0,"b",0,"b"]=0; + b6["b",0,"b",0,"b",0]=0; + b7["b",0,"b",0,"b",0,"b"]=0; + b8["b",0,"b",0,"b",0,"b",0]=0; + b9["b",0,"b",0,"b",0,"b",0,"b"]=0; + + c1[0]<<<0; + c2[0,"a"]<<<0; + c3[0,"a",0]<<<0; + c4[0,"a",0,"a"]<<<0; + c5[0,"a",0,"a",0]<<<0; + c6[0,"a",0,"a",0,"a"]<<<0; + c7[0,"a",0,"a",0,"a",0]<<<0; + c8[0,"a",0,"a",0,"a",0,"a"]<<<0; + c9[0,"a",0,"a",0,"a",0,"a",0]<<<0; + + d1["b"]<<<0; + d2["b",0]<<<0; + d3["b",0,"b"]<<<0; + d4["b",0,"b",0]<<<0; + d5["b",0,"b",0,"b"]<<<0; + d6["b",0,"b",0,"b",0]<<<0; + d7["b",0,"b",0,"b",0,"b"]<<<0; + d8["b",0,"b",0,"b",0,"b",0]<<<0; + d9["b",0,"b",0,"b",0,"b",0,"b"]<<<0; +} diff --git a/testsuite/buildok/thirtyone.stp b/testsuite/buildok/thirtyone.stp new file mode 100755 index 00000000..8a97d84f --- /dev/null +++ b/testsuite/buildok/thirtyone.stp @@ -0,0 +1,4 @@ +#! stap -p4 + +probe kprobe.function("sys_open") {} +probe kernel.function("sys_close") {} diff --git a/testsuite/buildok/twentysix.stp b/testsuite/buildok/twentysix.stp deleted file mode 100755 index 3fb7526f..00000000 --- a/testsuite/buildok/twentysix.stp +++ /dev/null @@ -1,7 +0,0 @@ -#! stap -up4 - -global a -probe begin -{ - a [1,2,3,4,5,6] = 0 -} diff --git a/testsuite/buildok/uaddr.stp b/testsuite/buildok/uaddr.stp new file mode 100755 index 00000000..8acfc495 --- /dev/null +++ b/testsuite/buildok/uaddr.stp @@ -0,0 +1,8 @@ +#! stap -p4 +# +# Test the translatability for uaddr() +# +probe begin +{ + printf("uaddr: 0x%x\n", uaddr()) +} diff --git a/testsuite/buildok/ustack.stp b/testsuite/buildok/ustack.stp new file mode 100755 index 00000000..23af0bff --- /dev/null +++ b/testsuite/buildok/ustack.stp @@ -0,0 +1,10 @@ +#! stap -p4 +# +# Test the translatability for ubacktrace(), print_ustack() +# and print_ubacktrace() +# +probe begin +{ + print_ustack(ubacktrace()); + print_ubacktrace(); +} diff --git a/testsuite/buildok/usymdata.stp b/testsuite/buildok/usymdata.stp new file mode 100755 index 00000000..48c1f36f --- /dev/null +++ b/testsuite/buildok/usymdata.stp @@ -0,0 +1,8 @@ +#! stap -p4 +# +# Test the translatability for usymdata() +# +probe begin +{ + log(usymdata(0)) +} diff --git a/testsuite/buildok/usymname.stp b/testsuite/buildok/usymname.stp new file mode 100755 index 00000000..57e3f9c2 --- /dev/null +++ b/testsuite/buildok/usymname.stp @@ -0,0 +1,8 @@ +#! stap -p4 +# +# Test the translatability for usymname() +# +probe begin +{ + log(usymname(0)) +} |