mirror of
https://github.com/zeldaret/oot.git
synced 2024-11-10 19:20:13 +00:00
Import fault bss under NON_MATCHING (#1484)
* Import fault bss under NON_MATCHING * Fix comments in data files * Fix variable name
This commit is contained in:
parent
e37b993483
commit
e77b83cf1b
5 changed files with 27 additions and 4 deletions
|
@ -7,6 +7,8 @@
|
||||||
|
|
||||||
.section .bss
|
.section .bss
|
||||||
|
|
||||||
|
# Note: This file is only included in the MATCHING build, the data is imported for non-matching
|
||||||
|
|
||||||
.balign 16
|
.balign 16
|
||||||
|
|
||||||
glabel sFaultInstance
|
glabel sFaultInstance
|
||||||
|
|
|
@ -7,10 +7,12 @@
|
||||||
|
|
||||||
.section .bss
|
.section .bss
|
||||||
|
|
||||||
|
# Note: This file is only included in the MATCHING build, the data is imported for non-matching
|
||||||
|
|
||||||
.balign 16
|
.balign 16
|
||||||
|
|
||||||
glabel sFaultDrawer
|
glabel sFaultDrawer
|
||||||
.space 0x3C
|
.space 0x3C
|
||||||
|
|
||||||
glabel D_8016B6C0
|
glabel D_8016B6BC
|
||||||
.space 0x20
|
.space 0x24
|
||||||
|
|
4
spec
4
spec
|
@ -409,9 +409,11 @@ beginseg
|
||||||
include "build/src/code/irqmgr.o"
|
include "build/src/code/irqmgr.o"
|
||||||
include "build/src/code/debug_malloc.o"
|
include "build/src/code/debug_malloc.o"
|
||||||
include "build/src/code/fault.o"
|
include "build/src/code/fault.o"
|
||||||
include "build/data/fault.bss.o"
|
|
||||||
include "build/src/code/fault_drawer.o"
|
include "build/src/code/fault_drawer.o"
|
||||||
|
#ifndef NON_MATCHING
|
||||||
|
include "build/data/fault.bss.o"
|
||||||
include "build/data/fault_drawer.bss.o"
|
include "build/data/fault_drawer.bss.o"
|
||||||
|
#endif
|
||||||
include "build/src/code/kanread.o"
|
include "build/src/code/kanread.o"
|
||||||
include "build/src/code/ucode_disas.o"
|
include "build/src/code/ucode_disas.o"
|
||||||
pad_text // audio library aligned to 32 bytes?
|
pad_text // audio library aligned to 32 bytes?
|
||||||
|
|
|
@ -76,12 +76,21 @@ const char* sFpExceptionNames[] = {
|
||||||
"Unimplemented operation", "Invalid operation", "Division by zero", "Overflow", "Underflow", "Inexact operation",
|
"Unimplemented operation", "Invalid operation", "Division by zero", "Overflow", "Underflow", "Inexact operation",
|
||||||
};
|
};
|
||||||
|
|
||||||
// TODO: import .bss (has reordering issues)
|
#ifndef NON_MATCHING
|
||||||
|
// TODO: match .bss (has reordering issues)
|
||||||
extern FaultMgr* sFaultInstance;
|
extern FaultMgr* sFaultInstance;
|
||||||
extern u8 sFaultAwaitingInput;
|
extern u8 sFaultAwaitingInput;
|
||||||
extern STACK(sFaultStack, 0x600);
|
extern STACK(sFaultStack, 0x600);
|
||||||
extern StackEntry sFaultThreadInfo;
|
extern StackEntry sFaultThreadInfo;
|
||||||
extern FaultMgr gFaultMgr;
|
extern FaultMgr gFaultMgr;
|
||||||
|
#else
|
||||||
|
// Non-matching version for struct shiftability
|
||||||
|
FaultMgr* sFaultInstance;
|
||||||
|
u8 sFaultAwaitingInput;
|
||||||
|
STACK(sFaultStack, 0x600);
|
||||||
|
StackEntry sFaultThreadInfo;
|
||||||
|
FaultMgr gFaultMgr;
|
||||||
|
#endif
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
/* 0x00 */ s32 (*callback)(void*, void*);
|
/* 0x00 */ s32 (*callback)(void*, void*);
|
||||||
|
|
|
@ -99,7 +99,15 @@ FaultDrawer sFaultDrawerDefault = {
|
||||||
NULL,
|
NULL,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifndef NON_MATCHING
|
||||||
|
// TODO: match .bss (has reordering issues)
|
||||||
extern FaultDrawer sFaultDrawer;
|
extern FaultDrawer sFaultDrawer;
|
||||||
|
extern char D_8016B6BC[0x24];
|
||||||
|
#else
|
||||||
|
// Non-matching version for struct shiftability
|
||||||
|
FaultDrawer sFaultDrawer;
|
||||||
|
char D_8016B6BC[0x24];
|
||||||
|
#endif
|
||||||
|
|
||||||
void FaultDrawer_SetOsSyncPrintfEnabled(u32 enabled) {
|
void FaultDrawer_SetOsSyncPrintfEnabled(u32 enabled) {
|
||||||
sFaultDrawer.osSyncPrintfEnabled = enabled;
|
sFaultDrawer.osSyncPrintfEnabled = enabled;
|
||||||
|
|
Loading…
Reference in a new issue