Tizen 2.1 base
[platform/upstream/glib2.0.git] / glib / glib.stp.in
1 global gquarks
2
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")
5 {
6   gquarks[pid(), $arg2] = user_string($arg1)
7 }
8
9 /**
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
13  */
14 probe glib.quark_new = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("quark__new")
15 {
16   str = user_string ($arg1); 
17   quark = $arg2; 
18   probestr = sprintf("glib.quark_new(%s) -> %d", str, quark);
19 }
20
21 /**
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
27  */
28 probe glib.mem_alloc = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("mem__alloc")
29 {
30   mem = $arg1; 
31   n_bytes = $arg2; 
32   zeroed = $arg3; 
33   failable = $arg4; 
34   probestr = sprintf("glib.mem_alloc(n_bytes=%d) -> %p", n_bytes, mem);
35 }
36
37 /**
38  * probe glib.mem_free - Called when a malloc block freed
39  */
40 probe glib.mem_free = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("mem__free")
41 {
42   mem = $arg1;  /* ARG: @mem: Raw memory pointer */
43   probestr = sprintf("glib.mem_free(mem=%p)", mem);
44 }
45
46 /**
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
52  */
53 probe glib.mem_realloc = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("mem__realloc")
54 {
55   mem = $arg1; 
56   old_mem = $arg2; 
57   n_bytes = $arg3;  
58   failable = $arg4; 
59   probestr = sprintf("glib.mem_realloc(old_mem=%p, n_bytes=%d) -> %p", old_mem, n_bytes, mem);
60 }
61
62 /**
63  * probe glib.slice_alloc - Called when g_slice_alloc() is used
64  * @mem: Raw memory pointer returned
65  * @n_bytes: number of bytes
66  */
67 probe glib.slice_alloc = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("slice__alloc")
68 {
69   mem = $arg1; 
70   n_bytes = $arg2; 
71   probestr = sprintf("glib.slice_alloc(n_bytes=%d) -> %p", n_bytes, mem);
72 }
73
74 /**
75  * probe glib.slice_free - Called when memory slice is freed
76  * @mem: Raw memory pointer returned
77  * @n_bytes: Number of bytes
78  */
79 probe glib.slice_free = process("@ABS_GLIB_RUNTIME_LIBDIR@/libglib-2.0.so.0.@LT_CURRENT@.@LT_REVISION@").mark("slice__free")
80 {
81   mem = $arg1; 
82   n_bytes = $arg2; 
83   probestr = sprintf("glib.slice_free(n_bytes=%d) -> %p", n_bytes, mem);
84 }