3 /* This is needed to keep track of gquark for use in other probes.*/
4 probe process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("quark__new")
6 gquarks[pid(), $arg2] = user_string($arg1)
10 * probe glib.quark_new - Called when a #GQuark is initially created
11 * @quark: integer value for the quark
12 * @str: string form of the quark
14 probe glib.quark_new = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("quark__new")
16 str = user_string ($arg1);
18 probestr = sprintf("glib.quark_new(%s) -> %d", str, quark);
22 * probe glib.mem_alloc - Called when a malloc block is initially requested
23 * @mem: Raw memory pointer returned
24 * @n_bytes: number of bytes
25 * @zeroed: Boolean value, %TRUE if this block was filled with NUL bytes
26 * @failable: Boolean value, %TRUE if program execution can continue on allocation failure
28 probe glib.mem_alloc = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("mem__alloc")
34 probestr = sprintf("glib.mem_alloc(n_bytes=%d) -> %p", n_bytes, mem);
38 * probe glib.mem_free - Called when a malloc block freed
40 probe glib.mem_free = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("mem__free")
42 mem = $arg1; /* ARG: @mem: Raw memory pointer */
43 probestr = sprintf("glib.mem_free(mem=%p)", mem);
47 * probe glib.mem_realloc - Called when a malloc block is resized
48 * @mem: Raw memory pointer returned
49 * @old_mem: Original memory pointer
50 * @n_bytes: number of bytes
51 * @failable: Boolean value, %TRUE if program execution can continue on allocation failure
53 probe glib.mem_realloc = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("mem__realloc")
59 probestr = sprintf("glib.mem_realloc(old_mem=%p, n_bytes=%d) -> %p", old_mem, n_bytes, mem);
63 * probe glib.slice_alloc - Called when g_slice_alloc() is used
64 * @mem: Raw memory pointer returned
65 * @n_bytes: number of bytes
67 probe glib.slice_alloc = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("slice__alloc")
71 probestr = sprintf("glib.slice_alloc(n_bytes=%d) -> %p", n_bytes, mem);
75 * probe glib.slice_free - Called when memory slice is freed
76 * @mem: Raw memory pointer returned
77 * @n_bytes: Number of bytes
79 probe glib.slice_free = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("slice__free")
83 probestr = sprintf("glib.slice_free(n_bytes=%d) -> %p", n_bytes, mem);