Bump version to 5.23 (#11911)
[mono-project.git] / mono / profiler / aot.h
blobcf15398334aa5c3bde5e1cfdc240d777e8c88fb9
1 #ifndef __MONO_PROFILER_AOT_H__
2 #define __MONO_PROFILER_AOT_H__
4 #include <config.h>
6 /*
7 * File format:
8 * - magic (AOT_PROFILER_MAGIC)
9 * - int: major/minor version, e.g. 0x00010000 (AOT_PROFILER_MAJOR_VERSION, AOT_PROFILER_MINOR_VERSION)
10 * - sequence of records terminated by an AOTPROF_RECORD_NONE record
12 * Record format:
13 * - byte: record type (AotProfRecordType)
14 * - int: record id (unique across all record types in the file)
15 * - followed by record specific data (see below)
17 * Encoding rules:
18 * - int: 4 bytes little endian
19 * - string: int length followed by UTF-8 data (no null terminator)
22 typedef enum {
24 * Indicates EOF. No additional record data.
26 AOTPROF_RECORD_NONE,
28 * Contains info about a loaded image.
29 * - string: assembly name
30 * - string: module mvid
32 AOTPROF_RECORD_IMAGE,
34 * Contains info about a type referenced by other records.
35 * - byte: MONO_TYPE_CLASS
36 * - int: record id for the containing image (AOTPROF_RECORD_IMAGE)
37 * - int: record id for the generic instance or -1 if N/A (AOTPROF_RECORD_GINST)
38 * - string: type name
40 AOTPROF_RECORD_TYPE,
42 * Contains info about a generic instantiation of a type or method.
43 * - int: type argument count
44 * - for 0 .. type argument count:
45 * -- int: record id for the type argument (AOTPROF_RECORD_TYPE)
47 AOTPROF_RECORD_GINST,
49 * Contains info about a JITed method.
50 * - int: record id for the containing class (AOTPROF_RECORD_TYPE)
51 * - int: record id for the generic instance or -1 if N/A (AOTPROF_RECORD_GINST)
52 * - int: parameter count
53 * - string: method name
54 * - string: method signature
56 AOTPROF_RECORD_METHOD
57 } AotProfRecordType;
59 #define AOT_PROFILER_MAGIC "AOTPROFILE"
61 #define AOT_PROFILER_MAJOR_VERSION 1
62 #define AOT_PROFILER_MINOR_VERSION 0
64 #endif /* __MONO_PROFILER_AOT_H__ */