Reformat to something more readable for me :3
Build libsm64 / Build libsm64 for linux (push) Successful in 30s
Build libsm64 / Build libsm64 for web (push) Successful in 30s
Build libsm64 / Build libsm64 for windows (push) Successful in 23s

This commit is contained in:
2026-05-24 11:31:35 -05:00
parent 4328104536
commit d3ea4e5e99
154 changed files with 30751 additions and 21008 deletions
+47 -20
View File
@@ -23,20 +23,31 @@ typedef s32 OSId;
typedef union
{
struct {f32 f_odd; f32 f_even;} f;
struct
{
f32 f_odd;
f32 f_even;
} f;
} __OSfp;
typedef struct
{
/* registers */
/*0x20*/ u64 at, v0, v1, a0, a1, a2, a3;
/*0x58*/ u64 t0, t1, t2, t3, t4, t5, t6, t7;
/*0x98*/ u64 s0, s1, s2, s3, s4, s5, s6, s7;
/*0xD8*/ u64 t8, t9, gp, sp, s8, ra;
/*0x108*/ u64 lo, hi;
/*0x118*/ u32 sr, pc, cause, badvaddr, rcp;
/*0x12C*/ u32 fpcsr;
__OSfp fp0, fp2, fp4, fp6, fp8, fp10, fp12, fp14;
/*0x20*/
u64 at, v0, v1, a0, a1, a2, a3;
/*0x58*/
u64 t0, t1, t2, t3, t4, t5, t6, t7;
/*0x98*/
u64 s0, s1, s2, s3, s4, s5, s6, s7;
/*0xD8*/
u64 t8, t9, gp, sp, s8, ra;
/*0x108*/
u64 lo, hi;
/*0x118*/
u32 sr, pc, cause, badvaddr, rcp;
/*0x12C*/
u32 fpcsr;
__OSfp fp0, fp2, fp4, fp6, fp8, fp10, fp12, fp14;
__OSfp fp16, fp18, fp20, fp22, fp24, fp26, fp28, fp30;
} __OSThreadContext;
@@ -49,27 +60,43 @@ typedef struct
typedef struct OSThread_s
{
/*0x00*/ struct OSThread_s *next;
/*0x04*/ OSPri priority;
/*0x08*/ struct OSThread_s **queue;
/*0x0C*/ struct OSThread_s *tlnext;
/*0x10*/ u16 state;
/*0x12*/ u16 flags;
/*0x14*/ OSId id;
/*0x18*/ int fp;
/*0x1C*/ __OSThreadprofile_s *thprof;
/*0x20*/ __OSThreadContext context;
/*0x00*/
struct OSThread_s *next;
/*0x04*/
OSPri priority;
/*0x08*/
struct OSThread_s **queue;
/*0x0C*/
struct OSThread_s *tlnext;
/*0x10*/
u16 state;
/*0x12*/
u16 flags;
/*0x14*/
OSId id;
/*0x18*/
int fp;
/*0x1C*/
__OSThreadprofile_s *thprof;
/*0x20*/
__OSThreadContext context;
} OSThread;
/* Functions */
void osCreateThread(OSThread *thread, OSId id, void (*entry)(void *),
void osCreateThread(
OSThread *thread, OSId id, void (*entry)(void *),
void *arg, void *sp, OSPri pri);
OSId osGetThreadId(OSThread *thread);
OSPri osGetThreadPri(OSThread *thread);
void osSetThreadPri(OSThread *thread, OSPri pri);
void osStartThread(OSThread *thread);
void osStopThread(OSThread *thread);
#endif