MSL_C fully matched / some SSystem cleanup/ obj_rgate OK (#2011)

* cleanup SSystem files

* MSL_C fully matched

* fix build

* remove asm

* reorganize MSL_C/Runtime libs into more accurate setup

* little more cleanup

* cleanup some MSL headers

* obj_rgate OK

* remove asm

* some rgate documentation
This commit is contained in:
TakaRikka
2023-12-25 07:31:05 -08:00
committed by GitHub
parent 54e5104f56
commit 8b3a582278
399 changed files with 5321 additions and 12620 deletions
+36 -50
View File
@@ -1,53 +1,48 @@
//
// Generated By: dol2asm
// Translation Unit: c_phase
//
/**
* c_phase.cpp
*
*/
#include "SSystem/SComponent/c_phase.h"
#include "dolphin/types.h"
//
// Declarations:
//
/* 80266624-80266630 000C+00 s=1 e=2 z=0 None .text
* cPhs_Reset__FP30request_of_phase_process_class */
void cPhs_Reset(request_of_phase_process_class* pPhase) {
pPhase->id = cPhs_INIT_e;
void cPhs_Reset(request_of_phase_process_class* phase) {
phase->id = cPhs_INIT_e;
}
/* 80266630-80266640 0010+00 s=0 e=3 z=0 None .text
* cPhs_Set__FP30request_of_phase_process_classPPFPv_i */
void cPhs_Set(request_of_phase_process_class* pPhase, cPhs__Handler* pHandlerTable) {
pPhase->mpHandlerTable = pHandlerTable;
pPhase->id = cPhs_INIT_e;
void cPhs_Set(request_of_phase_process_class* phase, cPhs__Handler* handlerTbl) {
phase->mpHandlerTable = handlerTbl;
phase->id = cPhs_INIT_e;
}
/* 80266640-80266668 0028+00 s=1 e=0 z=0 None .text
* cPhs_UnCompleate__FP30request_of_phase_process_class */
void cPhs_UnCompleate(request_of_phase_process_class* pPhase) {
pPhase->mpHandlerTable = NULL;
cPhs_Reset(pPhase);
void cPhs_UnCompleate(request_of_phase_process_class* phase) {
phase->mpHandlerTable = NULL;
cPhs_Reset(phase);
}
/* 80266668-80266678 0010+00 s=2 e=0 z=0 None .text
* cPhs_Compleate__FP30request_of_phase_process_class */
int cPhs_Compleate(request_of_phase_process_class* pPhase) {
pPhase->mpHandlerTable = NULL;
int cPhs_Compleate(request_of_phase_process_class* phase) {
phase->mpHandlerTable = NULL;
return cPhs_COMPLEATE_e;
}
/* 80266678-802666D8 0060+00 s=1 e=0 z=0 None .text cPhs_Next__FP30request_of_phase_process_class
*/
int cPhs_Next(request_of_phase_process_class* pPhase) {
if (const cPhs__Handler* handlerTable = pPhase->mpHandlerTable) {
pPhase->id++;
cPhs__Handler handler = handlerTable[pPhase->id];
int cPhs_Next(request_of_phase_process_class* phase) {
if (const cPhs__Handler* handlerTable = phase->mpHandlerTable) {
phase->id++;
cPhs__Handler handler = handlerTable[phase->id];
// Double null check here actually matters for emitted assembly.
// Wee old compilers.
if (handler == NULL || handler == NULL) {
return cPhs_Compleate(pPhase);
return cPhs_Compleate(phase);
} else {
return cPhs_LOADING_e;
}
@@ -58,47 +53,38 @@ int cPhs_Next(request_of_phase_process_class* pPhase) {
/* 802666D8-802667AC 00D4+00 s=1 e=3 z=0 None .text cPhs_Do__FP30request_of_phase_process_classPv
*/
#ifdef NONMATCHING
// pUserData loading in too early
int cPhs_Do(request_of_phase_process_class* pPhase, void* pUserData) {
if (pPhase->mpHandlerTable) {
int newStep = pPhase->mpHandlerTable[pPhase->id](pUserData);
int cPhs_Do(request_of_phase_process_class* phase, void* data) {
cPhs__Handler* handler = phase->mpHandlerTable;
if (handler) {
handler += phase->id;
int newStep = (*handler)(data);
switch (newStep) {
case cPhs_LOADING_e:
return cPhs_Next(pPhase);
return cPhs_Next(phase);
case cPhs_NEXT_e:
return cPhs_Next(pPhase) == cPhs_LOADING_e ? cPhs_NEXT_e : cPhs_COMPLEATE_e;
return cPhs_Next(phase) == cPhs_LOADING_e ? cPhs_NEXT_e : cPhs_COMPLEATE_e;
case cPhs_COMPLEATE_e:
return cPhs_Compleate(pPhase);
return cPhs_Compleate(phase);
case cPhs_UNK3_e:
cPhs_UnCompleate(pPhase);
cPhs_UnCompleate(phase);
return cPhs_UNK3_e;
case cPhs_ERROR_e:
cPhs_UnCompleate(pPhase);
cPhs_UnCompleate(phase);
return cPhs_ERROR_e;
case cPhs_INIT_e:
default:
return newStep;
}
}
return cPhs_Compleate(pPhase);
return cPhs_Compleate(phase);
}
#else
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm int cPhs_Do(request_of_phase_process_class* param_0, void* param_1) {
nofralloc
#include "asm/SSystem/SComponent/c_phase/cPhs_Do__FP30request_of_phase_process_classPv.s"
}
#pragma pop
#endif
/* 802667AC-802667D4 0028+00 s=0 e=2 z=0 None .text
* cPhs_Handler__FP30request_of_phase_process_classPPFPv_iPv */
int cPhs_Handler(request_of_phase_process_class* pPhase, cPhs__Handler* pHandlerTable,
void* pUserData) {
pPhase->mpHandlerTable = pHandlerTable;
return cPhs_Do(pPhase, pUserData);
int cPhs_Handler(request_of_phase_process_class* phase, cPhs__Handler* handlerTbl, void* data) {
phase->mpHandlerTable = handlerTbl;
return cPhs_Do(phase, data);
}