qapi: allow unions to contain further unions
[qemu/armbru.git] / accel / tcg / perf.h
blobf92dd52c6994e2b23fc25f6ab2b6d9a91e607593
1 /*
2 * Linux perf perf-<pid>.map and jit-<pid>.dump integration.
4 * SPDX-License-Identifier: GPL-2.0-or-later
5 */
7 #ifndef ACCEL_TCG_PERF_H
8 #define ACCEL_TCG_PERF_H
10 #if defined(CONFIG_TCG) && defined(CONFIG_LINUX)
11 /* Start writing perf-<pid>.map. */
12 void perf_enable_perfmap(void);
14 /* Start writing jit-<pid>.dump. */
15 void perf_enable_jitdump(void);
17 /* Add information about TCG prologue to profiler maps. */
18 void perf_report_prologue(const void *start, size_t size);
20 /* Add information about JITted guest code to profiler maps. */
21 void perf_report_code(uint64_t guest_pc, TranslationBlock *tb,
22 const void *start);
24 /* Stop writing perf-<pid>.map and/or jit-<pid>.dump. */
25 void perf_exit(void);
26 #else
27 static inline void perf_enable_perfmap(void)
31 static inline void perf_enable_jitdump(void)
35 static inline void perf_report_prologue(const void *start, size_t size)
39 static inline void perf_report_code(uint64_t guest_pc, TranslationBlock *tb,
40 const void *start)
44 static inline void perf_exit(void)
47 #endif
49 #endif