wut/include/coreinit/debug.h

71 lines
1.2 KiB
C
Raw Normal View History

2016-01-05 15:24:54 -08:00
#pragma once
2016-01-07 12:07:13 +00:00
#include <wut.h>
2016-01-05 15:24:54 -08:00
2016-01-07 16:02:54 +00:00
/**
* \defgroup coreinit_debug Debug
* \ingroup coreinit
* @{
*/
2016-01-07 14:09:43 +00:00
#ifdef __cplusplus
extern "C" {
#endif
2016-01-05 15:24:54 -08:00
2017-06-02 11:42:24 +01:00
typedef void (*DisassemblyPrintFn)(const char *fmt, ...);
typedef uint32_t (*DisassemblyFindSymbolFn)(uint32_t addr, char *symbolNameBuf, uint32_t symbolNameBufSize);
typedef enum DisassemblePPCFlags
{
DISASSEMBLE_PPC_FLAGS_NONE = 0,
} DisassemblePPCFlags;
2016-01-07 16:02:54 +00:00
2016-01-05 15:24:54 -08:00
void
2016-01-07 04:48:11 -08:00
OSConsoleWrite(const char *msg,
uint32_t size);
2016-01-05 15:24:54 -08:00
2016-01-07 16:02:54 +00:00
2016-01-05 15:24:54 -08:00
void
OSReport(const char *fmt, ...);
2016-01-07 16:02:54 +00:00
2016-01-05 15:24:54 -08:00
void
2016-01-07 04:48:11 -08:00
OSPanic(const char *file,
uint32_t line,
const char *fmt, ...);
2016-01-05 15:24:54 -08:00
2016-01-07 16:02:54 +00:00
2016-01-05 15:24:54 -08:00
void
OSFatal(const char *msg);
2016-01-07 16:02:54 +00:00
uint32_t
OSGetSymbolName(uint32_t addr,
char *symbolNameBuf,
uint32_t symbolNameBufSize);
uint32_t
OSGetUPID();
2019-01-10 09:42:48 +00:00
void
DisassemblePPCOpcode(uint32_t *opcode,
char *buffer,
uint32_t bufferSize,
DisassemblyFindSymbolFn findSymbolFn,
DisassemblePPCFlags flags);
2017-06-02 11:42:24 +01:00
void
DisassemblePPCRange(void *start,
void *end,
DisassemblyPrintFn printFn,
DisassemblyFindSymbolFn findSymbolFn,
DisassemblePPCFlags flags);
2016-01-07 14:09:43 +00:00
#ifdef __cplusplus
}
#endif
2016-01-07 16:02:54 +00:00
/** @} */