0fce6c
/* Example tapset file.
0fce6c
 *
0fce6c
 * You can execute the tapset using following command (please adjust the path
0fce6c
 * prior running the command, if needed):
0fce6c
 * 
0fce6c
 * stap /usr/share/doc/ruby-2.0.0.0/ruby-exercise.stp -c "ruby -e \"puts 'test'\""
0fce6c
 */
0fce6c
0fce6c
probe ruby.cmethod.entry {
0fce6c
  printf("%d -> %s::%s %s:%d\n", tid(), classname, methodname, file, line);
0fce6c
}
0fce6c
0fce6c
probe ruby.cmethod.return {
0fce6c
  printf("%d <- %s::%s %s:%d\n", tid(), classname, methodname, file, line);
0fce6c
}
0fce6c
0fce6c
probe ruby.method.entry {
0fce6c
  printf("%d -> %s::%s %s:%d\n", tid(), classname, methodname, file, line);
0fce6c
}
0fce6c
0fce6c
probe ruby.method.return {
0fce6c
  printf("%d <- %s::%s %s:%d\n", tid(), classname, methodname, file, line);
0fce6c
}
0fce6c
0fce6c
probe ruby.gc.mark.begin { printf("%d gc.mark.begin\n", tid()); }
0fce6c
0fce6c
probe ruby.gc.mark.end { printf("%d gc.mark.end\n", tid()); }
0fce6c
0fce6c
probe ruby.gc.sweep.begin { printf("%d gc.sweep.begin\n", tid()); }
0fce6c
0fce6c
probe ruby.gc.sweep.end { printf("%d gc.sweep.end\n", tid()); }
0fce6c
0fce6c
probe ruby.object.create{
0fce6c
  printf("%d obj.create %s %s:%d\n", tid(), classname, file, line);
0fce6c
}
0fce6c
0fce6c
probe ruby.raise {
0fce6c
  printf("%d raise %s %s:%d\n", tid(), classname, file, line);
0fce6c
}