#!/usr/bin/env stap # alias_suffixes.stp # Uses alias suffixes to track time intervals for a subset of kernel # functions. Based on func_time_stats.stp. global now_count =0; global old_count = 0; # We can apply a suffix to multiple probe points designated by one alias: probe miscellany = syscall.{open,close,read,write} { } probe miscellany { now_count = now_count +1; } probe timer.ms(1000){ new_count = now_count - old_count; printf("%d\n",new_count); old_count = now_count; }