Blame SOURCES/libruby.stp

d54c42
/* SystemTap tapset to make it easier to trace Ruby 2.0
d54c42
 *
d54c42
 * All probes provided by Ruby can be listed using following command
d54c42
 * (the path to the library must be adjuste appropriately):
d54c42
 *
d54c42
 * stap -L 'process("@LIBRARY_PATH@").mark("*")'
d54c42
 */
d54c42
d54c42
/**
d54c42
 * probe ruby.array.create - Allocation of new array.
d54c42
 *
d54c42
 * @size: Number of elements (an int)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.array.create =
d54c42
      process("@LIBRARY_PATH@").mark("array__create")
d54c42
{
d54c42
	size = $arg1
d54c42
	file = user_string($arg2)
d54c42
	line = $arg3
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.cmethod.entry - Fired just before a method implemented in C is entered.
d54c42
 *
d54c42
 * @classname: Name of the class (string)
d54c42
 * @methodname: The method about bo be executed (string)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.cmethod.entry =
d54c42
      process("@LIBRARY_PATH@").mark("cmethod__entry")
d54c42
{
d54c42
	classname  = user_string($arg1)
d54c42
	methodname = user_string($arg2)
d54c42
	file = user_string($arg3)
d54c42
	line = $arg4
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.cmethod.return - Fired just after a method implemented in C has returned.
d54c42
 *
d54c42
 * @classname: Name of the class (string)
d54c42
 * @methodname: The executed method (string)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.cmethod.return =
d54c42
      process("@LIBRARY_PATH@").mark("cmethod__return")
d54c42
{
d54c42
	classname  = user_string($arg1)
d54c42
	methodname = user_string($arg2)
d54c42
	file = user_string($arg3)
d54c42
	line = $arg4
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.find.require.entry - Fired when require starts to search load
d54c42
 * path for suitable file to require.
d54c42
 *
d54c42
 * @requiredfile: The name of the file to be required (string)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.find.require.entry =
d54c42
      process("@LIBRARY_PATH@").mark("find__require__entry")
d54c42
{
d54c42
	requiredfile = user_string($arg1)
d54c42
	file = user_string($arg2)
d54c42
	line = $arg3
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.find.require.return - Fired just after require has finished
d54c42
 * search of load path for suitable file to require.
d54c42
 *
d54c42
 * @requiredfile: The name of the file to be required (string)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.find.require.return =
d54c42
      process("@LIBRARY_PATH@").mark("find__require__return")
d54c42
{
d54c42
	requiredfile = user_string($arg1)
d54c42
	file = user_string($arg2)
d54c42
	line = $arg3
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.gc.mark.begin - Fired when a GC mark phase is about to start.
d54c42
 *
d54c42
 * It takes no arguments.
d54c42
 */
d54c42
probe ruby.gc.mark.begin =
d54c42
      process("@LIBRARY_PATH@").mark("gc__mark__begin")
d54c42
{
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.gc.mark.end - Fired when a GC mark phase has ended.
d54c42
 *
d54c42
 * It takes no arguments.
d54c42
 */
d54c42
probe ruby.gc.mark.end =
d54c42
      process("@LIBRARY_PATH@").mark("gc__mark__end")
d54c42
{
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.gc.sweep.begin - Fired when a GC sweep phase is about to start.
d54c42
 *
d54c42
 * It takes no arguments.
d54c42
 */
d54c42
probe ruby.gc.sweep.begin =
d54c42
      process("@LIBRARY_PATH@").mark("gc__sweep__begin")
d54c42
{
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.gc.sweep.end - Fired when a GC sweep phase has ended.
d54c42
 *
d54c42
 * It takes no arguments.
d54c42
 */
d54c42
probe ruby.gc.sweep.end =
d54c42
      process("@LIBRARY_PATH@").mark("gc__sweep__end")
d54c42
{
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.hash.create - Allocation of new hash.
d54c42
 *
d54c42
 * @size: Number of elements (int)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.hash.create =
d54c42
      process("@LIBRARY_PATH@").mark("hash__create")
d54c42
{
d54c42
	size = $arg1
d54c42
	file = user_string($arg2)
d54c42
	line = $arg3
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.load.entry - Fired when calls to "load" are made.
d54c42
 *
d54c42
 * @loadedfile: The name of the file to be loaded (string)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.load.entry =
d54c42
      process("@LIBRARY_PATH@").mark("load__entry")
d54c42
{
d54c42
	loadedfile = user_string($arg1)
d54c42
	file = user_string($arg2)
d54c42
	line = $arg3
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.load.return - Fired just after require has finished
d54c42
 * search of load path for suitable file to require.
d54c42
 *
d54c42
 * @loadedfile: The name of the file that was loaded (string)
d54c42
 */
d54c42
probe ruby.load.return =
d54c42
      process("@LIBRARY_PATH@").mark("load__return")
d54c42
{
d54c42
	loadedfile = user_string($arg1)
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.method.entry - Fired just before a method implemented in Ruby is entered.
d54c42
 *
d54c42
 * @classname: Name of the class (string)
d54c42
 * @methodname: The method about bo be executed (string)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.method.entry =
d54c42
      process("@LIBRARY_PATH@").mark("method__entry")
d54c42
{
d54c42
	classname  = user_string($arg1)
d54c42
	methodname = user_string($arg2)
d54c42
	file = user_string($arg3)
d54c42
	line = $arg4
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.method.return - Fired just after a method implemented in Ruby has returned.
d54c42
 *
d54c42
 * @classname: Name of the class (string)
d54c42
 * @methodname: The executed method (string)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.method.return =
d54c42
      process("@LIBRARY_PATH@").mark("method__return")
d54c42
{
d54c42
	classname  = user_string($arg1)
d54c42
	methodname = user_string($arg2)
d54c42
	file = user_string($arg3)
d54c42
	line = $arg4
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.object.create - Allocation of new object.
d54c42
 *
d54c42
 * @classname: Name of the class (string)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.object.create =
d54c42
      process("@LIBRARY_PATH@").mark("object__create")
d54c42
{
d54c42
	classname = user_string($arg1)
d54c42
	file = user_string($arg2)
d54c42
	line = $arg3
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.parse.begin - Fired just before a Ruby source file is parsed.
d54c42
 *
d54c42
 * @parsedfile: The name of the file to be parsed (string)
d54c42
 * @parsedline: The line number of beginning of parsing (int)
d54c42
 */
d54c42
probe ruby.parse.begin =
d54c42
      process("@LIBRARY_PATH@").mark("parse__begin")
d54c42
{
d54c42
	parsedfile = user_string($arg1)
d54c42
	parsedline = $arg2
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.parse.end - Fired just after a Ruby source file was parsed.
d54c42
 *
d54c42
 * @parsedfile: The name of parsed the file (string)
d54c42
 * @parsedline: The line number of beginning of parsing (int)
d54c42
 */
d54c42
probe ruby.parse.end =
d54c42
      process("@LIBRARY_PATH@").mark("parse__end")
d54c42
{
d54c42
	parsedfile = user_string($arg1)
d54c42
	parsedline = $arg2
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.raise - Fired when an exception is raised.
d54c42
 *
d54c42
 * @classname: The class name of the raised exception (string)
d54c42
 * @file: The name of the file where the exception was raised (string)
d54c42
 * @line: The line number in the file where the exception was raised (int)
d54c42
 */
d54c42
probe ruby.raise =
d54c42
      process("@LIBRARY_PATH@").mark("raise")
d54c42
{
d54c42
	classname  = user_string($arg1)
d54c42
	file = user_string($arg2)
d54c42
	line = $arg3
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.require.entry - Fired on calls to rb_require_safe (when a file
d54c42
 * is required).
d54c42
 *
d54c42
 * @requiredfile: The name of the file to be required (string)
d54c42
 * @file: The file that called "require" (string)
d54c42
 * @line: The line number where the call to require was made(int)
d54c42
 */
d54c42
probe ruby.require.entry =
d54c42
      process("@LIBRARY_PATH@").mark("require__entry")
d54c42
{
d54c42
	requiredfile = user_string($arg1)
d54c42
	file = user_string($arg2)
d54c42
	line = $arg3
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.require.return - Fired just after require has finished
d54c42
 * search of load path for suitable file to require.
d54c42
 *
d54c42
 * @requiredfile: The file that was required (string)
d54c42
 */
d54c42
probe ruby.require.return =
d54c42
      process("@LIBRARY_PATH@").mark("require__return")
d54c42
{
d54c42
	requiredfile = user_string($arg1)
d54c42
}
d54c42
d54c42
/**
d54c42
 * probe ruby.string.create - Allocation of new string.
d54c42
 *
d54c42
 * @size: Number of elements (an int)
d54c42
 * @file: The file name where the method is being called (string)
d54c42
 * @line: The line number where the method is being called (int)
d54c42
 */
d54c42
probe ruby.string.create =
d54c42
      process("@LIBRARY_PATH@").mark("string__create")
d54c42
{
d54c42
	size = $arg1
d54c42
	file = user_string($arg2)
d54c42
	line = $arg3
d54c42
}