NSMBW-Decomp
A decompilation of New Super Mario Bros. Wii
Loading...
Searching...
No Matches
OSContext.h
1
// https://github.com/doldecomp/ogws/blob/0d988270c9009a2983b888c2b75b5430a35f23e4/include/revolution/OS/OSContext.h
2
3
#pragma once
4
5
#include <types.h>
6
#ifdef __cplusplus
7
extern
"C"
{
8
#endif
9
10
typedef
enum
{
11
OS_CONTEXT_STATE_FP_SAVED = (1 << 0),
12
} OSContextState;
13
14
typedef
struct
OSContext
{
15
u32 gprs[32];
// at 0x0
16
u32 cr;
// at 0x80
17
u32 lr;
// at 0x84
18
u32 ctr;
// at 0x88
19
u32 xer;
// at 0x8C
20
f64 fprs[32];
// at 0x90
21
u32 fpscr_pad;
// at 0x190
22
u32 fpscr;
// at 0x194
23
u32 srr0;
// at 0x198
24
u32 srr1;
// at 0x19C
25
u16 mode;
// at 0x1A0
26
u16 state;
// at 0x1A2
27
u32 gqrs[8];
// at 0x1A4
28
u32 psf_pad;
// at 0x1C4
29
f64 psfs[32];
// at 0x1C8
30
}
OSContext
;
31
32
void
OSSaveFPUContext(
OSContext
* ctx);
33
void
OSSetCurrentContext(
OSContext
* ctx);
34
OSContext
* OSGetCurrentContext(
void
);
35
BOOL OSSaveContext(
OSContext
* ctx);
36
void
OSLoadContext(
OSContext
* ctx);
37
void
* OSGetStackPointer(
void
);
38
void
OSSwitchFiber(
void
* func,
void
* stack);
39
void
OSSwitchFiberEx(u32 r3, u32 r4, u32 r5, u32 r6,
void
* func,
void
* stack);
40
void
OSClearContext(
OSContext
* ctx);
41
void
OSInitContext(
OSContext
* ctx,
void
* _srr0,
void
* stack);
42
void
OSDumpContext(
const
OSContext
* ctx);
43
void
__OSContextInit(
void
);
44
45
#ifdef __cplusplus
46
}
47
#endif
OSContext
Definition
OSContext.h:14
include
lib
rvl
os
OSContext.h
Made with ❤️ by
CLF78
and
RootCubed
. Logos by
Chasical
and
B1
. Website generated by
Doxygen
1.13.2