WIP Removed all defined or auto undefined symbols (not matching)

This commit is contained in:
Mr-Wiseguy
2024-08-30 17:59:33 -04:00
parent 2514b28c12
commit b1b7605a5f
43 changed files with 212 additions and 205 deletions

View File

@@ -2,12 +2,7 @@
#include "functions.h"
#include "variables.h"
#ifndef CORE2_DATA_CRC2
#define CORE2_DATA_CRC2 0
#endif
extern s32 core2_D_803727F4;
extern s32 D_803727F4;
extern struct {
u8 pad0[4];
@@ -32,7 +27,7 @@ typedef struct {
f32 joystick[2];
}Struct_core1_10A00_1;
extern s32 D_80276574; // = CORE2_DATA_CRC2
extern s32 D_80276574;
/* .data */
s32 D_80275D30 = 0xC3A68832; //WHAT IS THIS?
@@ -73,7 +68,7 @@ f32 func_8024E420(s32 arg0, s32 arg1, s32 arg2) {
f32 phi_f2;
phi_f2 = 0.0125f;
if ((D_80379B90.unk4 != core2_D_803727F4) || (D_80379B90.unkC != D_80276574)) {
if ((D_80379B90.unk4 != D_803727F4) || (D_80379B90.unkC != D_80276574)) {
phi_f2 = 0.00625f;
}
if (arg0 > 0) {
@@ -341,6 +336,10 @@ void func_8024F1F0(void){
void func_8024F224(void){
s32 iCont, j;
// for(iCont = 0; iCont < 4; iCont++){
// D_80281250[iCont].unk0 = 0;
// }
for(iCont = 0; iCont < 4; iCont++){
D_80281250[iCont].unk0 = 0;
D_80281250[iCont].unk2 = 0;

View File

@@ -9,8 +9,9 @@ extern void func_8025F570(ALCSPlayer *, u8);
extern void func_8025F510(ALCSPlayer *, u8, u8);
extern void func_8025F5C0(ALCSPlayer *, u8);
extern ALBankFile D_EA3EB0;
extern ALWaveTable D_EADE60;
extern u8 soundfont2ctl_ROM_START[];
extern u8 soundfont2ctl_ROM_END[];
extern u8 soundfont2tbl_ROM_START[];
/* dependent functions */
void func_8024FA98(u8, enum comusic_e);
@@ -220,10 +221,10 @@ void musicInstruments_init(void){
s32 i;
f32 tmpf1;
size = (u8*)&D_EADE60 - (u8*)&D_EA3EB0;
size = soundfont2ctl_ROM_END - soundfont2ctl_ROM_START;
bnk_f = malloc(size);
osWriteBackDCacheAll();
osPiStartDma(func_802405D0(), 0, 0, &D_EA3EB0, bnk_f, size, func_802405C4());
osPiStartDma(func_802405D0(), 0, 0, (u32)soundfont2ctl_ROM_START, bnk_f, size, func_802405C4());
osRecvMesg(func_802405C4(), 0, 1); //osRecvMesg
D_80282104 = 0xAD;
D_802820E0 = (MusicTrack **) malloc(D_80282104 * sizeof(MusicTrack *));
@@ -242,7 +243,7 @@ void musicInstruments_init(void){
n_alCSPNew(&D_80281720[i].cseqp, &D_802820E8);
}
alBnkfNew(bnk_f, (u8 *)&D_EADE60);
alBnkfNew(bnk_f, soundfont2tbl_ROM_START);
D_80282108 = bnk_f->bankArray[0];
for(i = 0; i < 6; i++){
alCSPSetBank(&D_80281720[i].cseqp, D_80282108);

View File

@@ -9,7 +9,7 @@ f32 func_80263FF0(f32);
f32 cosf(f32);
#ifndef CORE2_DATA_CRC2
#define CORE2_DATA_CRC2 0
#define CORE2_DATA_CRC2 0x84D7B4F8
#endif
s32 D_80276570 = 0xFF62C2B8; //WHAT IS THIS?

View File

@@ -147,9 +147,9 @@ ALHeap D_8027CFF0;
u8 * D_8027D000;
s32 D_8027D004;
OSMesgQueue D_8027D008;
OSMesg D_8027D020;
OSMesg D_8027D020[50];
OSIoMesg D_8027D0E8;
Struct_core1_1D00_4 D_8027D100[58];
Struct_core1_1D00_4 D_8027D100[50];
struct {
u8 unk0;
Struct_1D00_3 *unk4;
@@ -297,7 +297,7 @@ void audioManager_create(void) {
int i;
f32 var_f0;
osCreateMesgQueue(&D_8027D008, &D_8027D020, 0x32);
osCreateMesgQueue(&D_8027D008, D_8027D020, 50);
osCreateMesgQueue(&audioManager.audioReplyMsgQ, audioManager.audioReplyMsgBuf, 8); //audioReplyMesgQueue
osCreateMesgQueue(&audioManager.audioFrameMsgQ, audioManager.audioFrameMsgBuf, 8);
var_f0 = 733.333313f;

View File

@@ -3,8 +3,10 @@
#include "variables.h"
OSIoMesg D_8027E090;
OSMesg D_8027E0A8;
OSMesgQueue D_8027E0AC;
struct {
OSMesg mesg;
OSMesgQueue queue;
} D_8027E0A8;
OSMesg D_8027E0C8[16]; //g_PimgrMesgBuffer
OSMesgQueue D_8027E108; //g_PimgrMesgQueue
@@ -19,20 +21,20 @@ void func_802405F0(u32 * arg0, s32 arg1, s32 size){
block_remainder = size % block_size;
for(i = 0; i < block_cnt; i++){
osPiStartDma(&D_8027E090, OS_MESG_PRI_NORMAL, OS_READ, arg1, arg0, 0x20000, &D_8027E0AC);
osRecvMesg(&D_8027E0AC, NULL, 1);
osPiStartDma(&D_8027E090, OS_MESG_PRI_NORMAL, OS_READ, arg1, arg0, 0x20000, &D_8027E0A8.queue);
osRecvMesg(&D_8027E0A8.queue, NULL, 1);
arg1 += 0x20000;
arg0 += 0x8000;
}
osPiStartDma(&D_8027E090, OS_MESG_PRI_NORMAL, OS_READ, arg1, arg0, block_remainder, &D_8027E0AC);
osRecvMesg(&D_8027E0AC, NULL, 1);
osPiStartDma(&D_8027E090, OS_MESG_PRI_NORMAL, OS_READ, arg1, arg0, block_remainder, &D_8027E0A8.queue);
osRecvMesg(&D_8027E0A8.queue, NULL, 1);
osInvalDCache(arg0, size);
}
void piMgr_create(void){
osCreateMesgQueue(&D_8027E0AC, &D_8027E0A8, 1);
osCreateMesgQueue(&D_8027E0A8.queue, &D_8027E0A8.mesg, 1);
osCreateMesgQueue(&D_8027E108, &D_8027E0C8[0], 16);
osCreatePiManager(OS_PRIORITY_PIMGR, &D_8027E108, &D_8027E0C8[0], 16);
}

View File

@@ -21,7 +21,7 @@ void func_80244978(s32 arg0, s16 type, s32 arg2);
N_ALSndPlayer D_8027EEC0;
s16 *D_8027EF14;
extern struct {
struct {
s32 volume[4];
}D_8027EF18;

View File

@@ -53,7 +53,7 @@ s32 D_80275768 = 6; //dbits
/* .data */
extern struct huft D_803FBE00;
struct huft *D_8027BF00;
u8 pad_8027BF00[0xC];
u8 pad_8027BF08[0x8];
u8 *D_8027BF10; //inbuf
u8 *D_8027BF14; //slide
u32 D_8027BF18; //inptr

View File

@@ -12,7 +12,6 @@ extern f32 func_8031C5D4(struct0*);
extern void func_8031C5AC(struct0 *, f32 *);
/* .bss */
u8 pad_D_8027EF20[0x10];
f32 D_8027EF30;
/* .code */

View File

@@ -61,7 +61,7 @@ s32 D_8027599C = 0;
/* .bss */
u64 D_8027EF40[OS_YIELD_DATA_SIZE / sizeof(u64)];
static u8 pad[0x28]; // 8027FB40
static u8 pad[0x20]; // 8027FB40
OSMesgQueue D_8027FB60;
OSMesg D_8027FB78[20];
OSMesgQueue D_8027FBC8;
@@ -74,7 +74,7 @@ s32 D_8027FC18;
s32 D_8027FC1C;
s32 D_8027FC20;
s32 D_8027FC24;
u8 D_8027FC28[2040]; //stack for thread D_80280428;
u8 D_8027FC28[2048]; //stack for thread D_80280428;
OSThread D_80280428;
Struct_Core1_8C50_s * D_802805D8[20];
volatile s32 D_80280628;
@@ -458,7 +458,7 @@ void func_80247560(void){
tmp_v0 = D_8027EF40;
while((u32)tmp_v0 % 0x10){((u32)tmp_v0)++;}
D_80275950.t.yield_data_ptr = tmp_v0;
osCreateThread(&D_80280428, 5, func_802473B4, NULL, &D_8027FC28[2040], 60);
osCreateThread(&D_80280428, 5, func_802473B4, NULL, &D_8027FC28[2048], 60);
osStartThread(&D_80280428);
}

View File

@@ -61,12 +61,16 @@ u32 D_80280724;
u32 D_80280728;
struct1 D_80280730[8];
OSMesgQueue D_80280770;
OSMesg D_80280788[10];
OSMesgQueue D_802807B0;
OSMesg D_802807C8[1];
OSMesgQueue D_802807D0;
OSMesg D_802807E8[60];
volatile s32 D_802808D8;
s32 D_802808DC;
OSThread D_802808E0;
u8 pad_80280970[0x520];
#define THREAD0_STACK_SIZE 0x400
u8 thread0_stack[THREAD0_STACK_SIZE];
extern u8 D_803A5D00[2][0x1ECC0]; //framebuffer
@@ -100,7 +104,6 @@ void func_8024BDAC(OSMesgQueue *mq, OSMesg msg){
}
void func_8024BE30(void){
extern s32 D_80280E90;
s32 i;
func_8024C428();
@@ -113,9 +116,9 @@ void func_8024BE30(void){
osViSetSpecialFeatures(OS_VI_DITHER_FILTER_ON);
osViSetSpecialFeatures(OS_VI_GAMMA_OFF);
osViSwapBuffer(&D_803A5D00);
osCreateMesgQueue(&D_80280770, (&D_80280770 + 1), 10);
osCreateMesgQueue(&D_802807B0, (&D_802807B0 + 1), 1);
osCreateMesgQueue(&D_802807D0, (&D_802807D0 + 1), 0x3C);
osCreateMesgQueue(&D_80280770, D_80280788, 10);
osCreateMesgQueue(&D_802807B0, D_802807C8, 1);
osCreateMesgQueue(&D_802807D0, D_802807E8, 60);
osViSetEvent(&D_80280770,NULL,1);
D_80280720 = 0;
D_80280724 = 1;
@@ -125,7 +128,7 @@ void func_8024BE30(void){
}
D_802808D8 = 0;
func_8024BF94(2);
osCreateThread(&D_802808E0,0,func_8024C2F8,NULL,&D_80280E90,0x50);
osCreateThread(&D_802808E0,0,func_8024C2F8,NULL,&thread0_stack[THREAD0_STACK_SIZE],80);
osStartThread(&D_802808E0);
}