# of it is treated as a regular expression. If $nlines_exp is not -1, then
# exactly $nlines_exp lines are expected.
proc stap_list {pp {exp ""} {nlines_exp 1} {arguments ""}} {
- global test TARGET_SUBTEST
+ global test TARGET_SUBTEST exefullpath sofullpath
set subtest "$test ($pp $arguments)"
+ set subtest [regsub -all $exefullpath $subtest EXEFULLPATH]
+ set subtest [regsub -all $sofullpath $subtest SOFULLPATH]
if {$TARGET_SUBTEST != ""} {
if {![string match $TARGET_SUBTEST $pp]} {
testing_probe {process.library(string).function(string)}
stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:54\"\\\)"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:55\"\\\)"
testing_probe {process.library(string).function(string).call}
stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo\").call" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:54\"\\\)\\\.call"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:55\"\\\)\\\.call"
if {[callee_probes_p]} {
testing_probe {process.library(string).function(string).callee(string)}
stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo\").callee(\"libbar\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:54\"\\\)\\\.callee\\\(\"libbar@\[^:\]+:47\"\\\)"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:55\"\\\)\\\.callee\\\(\"libbar@\[^:\]+:48\"\\\)"
testing_probe {process.library(string).function(string).callees}
stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo\").callees" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:54\"\\\)\\\.callee\\\(\"libbar@\[^:\]+:47\"\\\)"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:55\"\\\)\\\.callee\\\(\"libbar@\[^:\]+:48\"\\\)"
testing_probe {process.library(string).function(string).callees(number)}
stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo\").callees(1)" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:54\"\\\)\\\.callee\\\(\"libbar@\[^:\]+:47\"\\\)"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:55\"\\\)\\\.callee\\\(\"libbar@\[^:\]+:48\"\\\)"
stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo\").callees(2)" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"lib(foo|bar)@\[^:\]+:(54|47)\"\\\)\\\.callee\\\(\"(libbar|libinln)@\[^:\]+:(47|42)\"\\\)" {2}
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"lib(foo|bar)@\[^:\]+:(55|48)\"\\\)\\\.callee\\\(\"(libbar|libinln)@\[^:\]+:(48|43)\"\\\)" {2}
}
testing_probe {process.library(string).function(string).exported}
stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo\").exported" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:54\"\\\)\\\.exported"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:55\"\\\)\\\.exported"
testing_probe {process.library(string).function(string).inline}
stap_list_cmd_lib "process.library(\"sopath\").function(\"libinln\").inline" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libinln@\[^:\]+:42\"\\\)\\\.inline"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libinln@\[^:\]+:43\"\\\)\\\.inline"
testing_probe {process.library(string).function(string).label(string)}
stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo\").label(\"lib_label\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:57\"\\\)\\\.label\\\(\"lib_label\"\\\)"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:58\"\\\)\\\.label\\\(\"lib_label\"\\\)"
stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo\").label(\"lib_labe?\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:57\"\\\)\\\.label\\\(\"lib_label\"\\\)"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:58\"\\\)\\\.label\\\(\"lib_label\"\\\)"
- stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo@$test.c:57\").label(\"lib_label\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:57\"\\\)\\\.label\\\(\"lib_label\"\\\)"
+ stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo@$test.c:58\").label(\"lib_label\")" \
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:58\"\\\)\\\.label\\\(\"lib_label\"\\\)"
- stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo@$test.c:57\").label(\"lib_labe?\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:57\"\\\)\\\.label\\\(\"lib_label\"\\\)"
+ stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo@$test.c:58\").label(\"lib_labe?\")" \
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:58\"\\\)\\\.label\\\(\"lib_label\"\\\)"
testing_probe {process.library(string).function(string).return}
stap_list_cmd_lib "process.library(\"sopath\").function(\"libfoo\").return" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:54\"\\\)\\\.return"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.function\\\(\"libfoo@\[^:\]+:55\"\\\)\\\.return"
testing_probe {process.library(string).mark(string)}
testing_probe {process.library(string).statement(string)}
stap_list_cmd_lib "process.library(\"sopath\").statement(\"libinln\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libinln@\[^:\]+:42\"\\\)"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libinln@\[^:\]+:43\"\\\)"
stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:54\"\\\)"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:55\"\\\)"
stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:54\"\\\)"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:55\"\\\)"
- stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c:56\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:56\"\\\)"
+ stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c:57\")" \
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:57\"\\\)"
- stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfo?@$test.c:56\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:56\"\\\)"
+ stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfo?@$test.c:57\")" \
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:57\"\\\)"
stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c+2\")" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:56\"\\\)"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:57\"\\\)"
- stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c:54-56\")" \
+ stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c:55-56\")" \
"re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:\[0-9\]+\"\\\)" {-1}
- stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c:54,55-56\")" \
+ stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c:55,55-56\")" \
"re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:\[0-9\]+\"\\\)" {-1}
stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c:*\")" \
testing_probe {process.library(string).statement(string).nearest}
- stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c:57\").nearest" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:57\"\\\).nearest"
+ stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c:58\").nearest" \
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:58\"\\\).nearest"
stap_list_cmd_lib "process.library(\"sopath\").statement(\"libfoo@$test.c+3\").nearest" \
- "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:57\"\\\).nearest"
+ "re:process\\\(\"$exefullpath\"\\\)\\\.library\\\(\"$sofullpath\"\\\)\\\.statement\\\(\"libfoo@\[^:\]+:58\"\\\).nearest"
testing_probe {process.mark(string)}