wut  v1.7.0
Wii U Toolchain
debug.h
Go to the documentation of this file.
1 #pragma once
2 #include <wut.h>
3 
10 #ifdef __cplusplus
11 extern "C" {
12 #endif
13 
14 typedef void (*DisassemblyPrintFn)(const char *fmt, ...);
15 
16 typedef uint32_t (*DisassemblyFindSymbolFn)(uint32_t addr, char *symbolNameBuf, uint32_t symbolNameBufSize);
17 
18 typedef enum DisassemblePPCFlags
19 {
22 
23 
24 void
25 OSConsoleWrite(const char *msg,
26  uint32_t size);
27 
28 void
29 __OSConsoleWrite(const char *msg,
30  uint32_t size);
31 
32 void
33 OSReport(const char *fmt, ...);
34 
35 
36 void
37 OSReportVerbose(const char *fmt, ...);
38 
39 
40 void
41 OSReportInfo(const char *fmt, ...);
42 
43 
44 void
45 OSReportWarn(const char *fmt, ...);
46 
47 
48 void
49 OSPanic(const char *file,
50  uint32_t line,
51  const char *fmt, ...);
52 
53 
54 void
55 OSFatal(const char *msg);
56 
57 
58 uint32_t
59 OSGetSymbolName(uint32_t addr,
60  char *symbolNameBuf,
61  uint32_t symbolNameBufSize);
62 
63 
64 uint32_t
66 
67 BOOL
69 
70 BOOL
72 
73 BOOL
75 
76 BOOL
78 
79 void
80 __OSSetCrashRecovery(uint32_t crashRecovery);
81 
82 uint32_t
84 
85 BOOL
86 DisassemblePPCOpcode(uint32_t *opcode,
87  char *buffer,
88  uint32_t bufferSize,
89  DisassemblyFindSymbolFn findSymbolFn,
90  DisassemblePPCFlags flags);
91 
92 void
93 DisassemblePPCRange(void *start,
94  void *end,
95  DisassemblyPrintFn printFn,
96  DisassemblyFindSymbolFn findSymbolFn,
97  DisassemblePPCFlags flags);
98 
99 #ifdef __cplusplus
100 }
101 #endif
102 
void __OSSetCrashRecovery(uint32_t crashRecovery)
uint32_t(* DisassemblyFindSymbolFn)(uint32_t addr, char *symbolNameBuf, uint32_t symbolNameBufSize)
Definition: debug.h:16
void OSPanic(const char *file, uint32_t line, const char *fmt,...)
void OSReportWarn(const char *fmt,...)
uint32_t OSGetUPID()
uint32_t OSGetSymbolName(uint32_t addr, char *symbolNameBuf, uint32_t symbolNameBufSize)
BOOL OSIsECOBoot()
BOOL OSIsDebuggerInitialized()
BOOL OSIsECOMode()
void(* DisassemblyPrintFn)(const char *fmt,...)
Definition: debug.h:14
void DisassemblePPCRange(void *start, void *end, DisassemblyPrintFn printFn, DisassemblyFindSymbolFn findSymbolFn, DisassemblePPCFlags flags)
void OSReport(const char *fmt,...)
DisassemblePPCFlags
Definition: debug.h:19
void OSConsoleWrite(const char *msg, uint32_t size)
void OSFatal(const char *msg)
void OSReportInfo(const char *fmt,...)
BOOL OSIsDebuggerPresent()
BOOL DisassemblePPCOpcode(uint32_t *opcode, char *buffer, uint32_t bufferSize, DisassemblyFindSymbolFn findSymbolFn, DisassemblePPCFlags flags)
void __OSConsoleWrite(const char *msg, uint32_t size)
uint32_t __OSGetCrashRecovery()
void OSReportVerbose(const char *fmt,...)
@ DISASSEMBLE_PPC_FLAGS_NONE
Definition: debug.h:20
int32_t BOOL
Definition: wut_types.h:7