foreach file [lsort [glob -nocomplain $srcdir/../examples/*.stp $srcdir/../examples/small_demos/*.stp]] {
    set test [file tail $file]
    switch $test {
        {iostat-scsi.stp} {set cmd "stap -p4 -g $file 5"}
        {sigmon.stp} {set cmd "stap -p4 -x 1234 $file SIGKILL"}
        {keyhack.stp} {set cmd "stap -p4 -g $file"}
        default {set cmd "stap -p4 $file"}
    }
    verbose -log "Running $cmd"
    set rc [catch {eval "exec $cmd"} baz]
    if {$rc} { fail $test; verbose -log $baz } else { pass $test }
}
