mirror of
https://github.com/zeldaret/oot.git
synced 2025-07-16 04:44:44 +00:00
Improve the state of handwritten assembly files (#865)
* Format all handwritten asm and document some * Use c preprocessor for constants * Fix * Fix PI_STATUS_ERROR, some label improvements * Avoid hi/lo for constants * Some more comments * Properly mark functions as functions and their sizes * Fix merge * Improvements * Review suggestions, rework procedure start/end macros to be more like libreultra * Move IPL3 symbol definitions into ipl3.s * Fix undefined_syms, add include and language guards to asm.h and fix the comment in gbi.h * Consistent hex capitalization, add some MIPS builtin defines to CC_CHECK to behave properly * Add -no-pad-sections assembler option and clean up alignment in gu files and bzero * Further suggestions and improvements * Matrix conversion function clarifications * Fix passing AVOID_UB to gcc * Suggestions * Suggestions, global interrupt mask improvements * Further suggestions, interrupt mask comments * Comments fixes, rdb.h * Switch from # comments to // comments, remove unnecesary .set gp=64 directives * Further review suggestions * Missed one
This commit is contained in:
parent
b9fded7b4e
commit
7334ffa373
62 changed files with 2758 additions and 2083 deletions
|
@ -1,10 +1,9 @@
|
|||
#ifndef ULTRA64_EXCEPTION_H
|
||||
#define ULTRA64_EXCEPTION_H
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// Interrupt masks
|
||||
#define OS_IM_NONE 0x00000001
|
||||
#define OS_IM_RCP 0x00000401
|
||||
#define OS_IM_SW1 0x00000501
|
||||
#define OS_IM_SW2 0x00000601
|
||||
#define OS_IM_CART 0x00000C01
|
||||
|
@ -24,6 +23,13 @@
|
|||
#define RCP_IMASK 0x003F0000
|
||||
#define RCP_IMASKSHIFT 16
|
||||
|
||||
// OSHWIntr values
|
||||
#define OS_INTR_CART 1
|
||||
|
||||
#ifdef _LANGUAGE_C
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef u32 OSIntMask;
|
||||
typedef u32 OSHWIntr;
|
||||
|
||||
|
@ -42,4 +48,15 @@ void __osResetGlobalIntMask(OSHWIntr mask);
|
|||
|
||||
extern __osHwInt __osHwIntTable[];
|
||||
|
||||
#else
|
||||
|
||||
// __osHwInt struct member offsets
|
||||
#define HWINT_CALLBACK 0x00
|
||||
#define HWINT_SP 0x04
|
||||
|
||||
// __osHwInt struct size
|
||||
#define HWINT_SIZE 0x8
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue