diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rwxr-xr-x | testsuite/parseok/nine.stp | 2 | ||||
-rwxr-xr-x | testsuite/semok/eleven.stp | 34 | ||||
-rwxr-xr-x | testsuite/semok/seven.stp | 7 | ||||
-rwxr-xr-x | testsuite/semok/seventeen.stp | 8 | ||||
-rwxr-xr-x | testsuite/semok/six.stp | 5 |
6 files changed, 37 insertions, 24 deletions
@@ -1,5 +1,10 @@ 2005-08-09 Graydon Hoare <graydon@redhat.com> + * testsuite/parseok/nine.stp: Update + * testsuite/semok/{six,seven,eleven,seventeen}.stp: Update. + +2005-08-09 Graydon Hoare <graydon@redhat.com> + * staptree.{cxx,h} (target_symbol): New struct. (*_visitor::visit_target_symbol): Support it. diff --git a/testsuite/parseok/nine.stp b/testsuite/parseok/nine.stp index 3582907a..60caf62e 100755 --- a/testsuite/parseok/nine.stp +++ b/testsuite/parseok/nine.stp @@ -9,7 +9,7 @@ probe two { a = b c = d - _e = $f(); + _e = $f; _g = h_; ; } diff --git a/testsuite/semok/eleven.stp b/testsuite/semok/eleven.stp index f7fc6914..e5e3c01c 100755 --- a/testsuite/semok/eleven.stp +++ b/testsuite/semok/eleven.stp @@ -7,26 +7,30 @@ function string (v) { return "" } function hexstring (v) { return "" } function trace (s) { return 0 } -probe begin /* kernel.syscall("read") */ { - $count=0 $timestamp=0 $fd=0 - - thread->entry_time = $timestamp # "macro" variable - thread->my_count = $count # function argument - thread->my_fd = $fd # function argument - trace ("my_count = " . string(thread->my_count) . - "my_fd = " . string(thread->my_fd)) +global tid + +probe begin /* kernel.function("read") */ { + count=0 timestamp=0 fd=0 + tid=1 + + entry_time[tid] = timestamp # "macro" variable + my_count[tid] = count # function argument + my_fd[tid] = fd # function argument + trace ("my_count = " . string(my_count[tid]) . + "my_fd = " . string(my_fd[tid])) } -probe end /* kernel.syscall("read").return */ { - $syscall_name="" $retvalue=0 +probe end /* kernel.function("read").return */ { + syscall_name="" retvalue=0 + tid=1 - if (thread->entry_time) { - read_times[$syscall_name] # variable from provider alias - += $timestamp - thread->entry_time + if (entry_time[tid]) { + read_times[syscall_name] # variable from provider alias + += timestamp - entry_time[tid] } - trace ("syscall " . $syscall_name . + trace ("syscall " . (syscall_name) . " return value = " . - hexstring ($retvalue)) # function pseudo-argument + hexstring (retvalue)) # function pseudo-argument } probe end { diff --git a/testsuite/semok/seven.stp b/testsuite/semok/seven.stp index 98d78f05..73264923 100755 --- a/testsuite/semok/seven.stp +++ b/testsuite/semok/seven.stp @@ -15,8 +15,11 @@ function search (key) probe begin /* syscall("zamboni") */ { - thread->ar2 = string ($tgid); - search ($pid) + tgid=0 + pid=0 + tid=0 + ar2[tid] = string (tgid); + search (pid) } probe end diff --git a/testsuite/semok/seventeen.stp b/testsuite/semok/seventeen.stp index 19ae854d..4ea03927 100755 --- a/testsuite/semok/seventeen.stp +++ b/testsuite/semok/seventeen.stp @@ -1,10 +1,10 @@ #! stap -p2 global foo -probe kernel.function("pipe_write") +probe kernel.function("pipe_writev") { - a = $filp + a = $nr_segs foo [a] = 1 - # $filp is not an lvalue here - foo [$filp] ++ + # $nr_segs is not an lvalue here + foo [$nr_segs] ++ } diff --git a/testsuite/semok/six.stp b/testsuite/semok/six.stp index f77baad8..39132fa3 100755 --- a/testsuite/semok/six.stp +++ b/testsuite/semok/six.stp @@ -4,6 +4,7 @@ global bar, baz probe begin { - thread->bar = 4; - process->baz = "5"; + tid=0 pid=0 + bar[tid] = 4; + baz[pid] = "5"; } |