[profiler] log profiler: limit method instrumentation to selected methods (#5517)
[mono.git] / mono / profiler / log.h
index d8182d90ee27dfc7d3b266e31124bd7f3dae2baa..e381d8975471a34d1895b98bb0f05b07a54db502 100644 (file)
@@ -4,6 +4,7 @@
 #include <glib.h>
 #define MONO_PROFILER_UNSTABLE_GC_ROOTS
 #include <mono/metadata/profiler.h>
+#include <mono/metadata/callspec.h>
 
 #define BUF_ID 0x4D504C01
 #define LOG_HEADER_ID 0x4D505A01
@@ -70,6 +71,7 @@
                class unload events no longer exist (they were never emitted)
                removed type field from TYPE_SAMPLE_HIT
                removed MONO_GC_EVENT_{MARK,RECLAIM}_{START,END}
+               reverted the root_type field back to uleb128
  */
 
 /*
  *     [num_roots: uleb128] number of root references
  *     [num_gc: uleb128] number of major gcs
  *     [object: sleb128] the object as a difference from obj_base
- *     [root_type: byte] the root_type: MonoProfileGCRootType (profiler.h)
+ *     [root_type: uleb128] the root_type: MonoProfileGCRootType (profiler.h)
  *     [extra_info: uleb128] the extra_info value
  *     object, root_type and extra_info are repeated num_roots times
  *
@@ -536,6 +538,9 @@ typedef struct {
 
        // Sample mode. Only used at startup.
        MonoProfilerSampleMode sampling_mode;
+
+       // Callspec config - which methods are to be instrumented
+       MonoCallSpec callspec;
 } ProfilerConfig;
 
 void proflog_parse_args (ProfilerConfig *config, const char *desc);