Romain Malmain 86d38fbfa7
Add pre/post cpu_run hooks + Refactoring (#82)
* Add cpu_run pre/post exec hooks, to hook the cpu just before / after it runs target code.
* Refactor hooks to separate them in different files
* Remove most extern variables
* Reduce the amount of extra code in QEMU
* Add clang-format script
2024-08-13 16:56:00 +02:00

20 lines
677 B
C

#pragma once
#include "qemu/error-report.h"
#define SYX_PRINTF(format, ...) \
fprintf(stderr, ("[QEMU-SYX] " format), ##__VA_ARGS__)
#ifdef CONFIG_DEBUG_SYX
#define SYX_DEBUG(format, ...) \
fprintf(stderr, ("[QEMU-SYX] DEBUG: " format), ##__VA_ARGS__)
#else
#define SYX_DEBUG(format, ...)
#endif
#define SYX_WARNING(format, ...) \
warn_report(("[QEMU-SYX] " format), ##__VA_ARGS__)
#define SYX_ERROR(format, ...) \
error_report(("[QEMU-SYX] " format), ##__VA_ARGS__)