diff --git a/.gitignore b/.gitignore index b7b097c..04ea0be 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,8 @@ assets/ bin/ build/ disks/ +include/*.inc +include/include_asm.h sym_export.*.txt undefined_funcs_auto.*.txt undefined_syms_auto.*.txt diff --git a/config/main.us.yaml b/config/main.us.yaml index e694bd9..39450c5 100644 --- a/config/main.us.yaml +++ b/config/main.us.yaml @@ -28,6 +28,7 @@ options: - ".data" - ".bss" ld_generate_symbol_per_data_segment: true + include_asm_macro_style: maspsx_hack sha1: a95e8b16b97071203b953bb81a33980509262f30 segments: - [0x800, header] diff --git a/include/common.h b/include/common.h index 44dc901..e58515a 100644 --- a/include/common.h +++ b/include/common.h @@ -5,21 +5,7 @@ #define NULL 0 #endif -#ifdef USE_INCLUDE_ASM -__asm__(".include \"macro.inc\"\n"); -#define INCLUDE_ASM(FOLDER, NAME) \ - void __maspsx_include_asm_hack_##NAME() { \ - __asm__(".text # maspsx-keep \n" \ - "\t.align\t2 # maspsx-keep\n" \ - "\t.set noreorder # maspsx-keep\n" \ - "\t.set noat # maspsx-keep\n" \ - ".include \"" FOLDER "/" #NAME ".s\" # maspsx-keep\n" \ - "\t.set reorder # maspsx-keep\n" \ - "\t.set at # maspsx-keep\n"); \ - } -#else -#define INCLUDE_ASM(FOLDER, NAME) -#endif +#include "include_asm.h" typedef signed char s8; typedef unsigned char u8; diff --git a/include/macro.inc b/include/macro.inc deleted file mode 100644 index 3078253..0000000 --- a/include/macro.inc +++ /dev/null @@ -1,19 +0,0 @@ -.ifndef .L_MACRO_INC -.L_MACRO_INC: - -.macro jlabel label - glabel \label -.endm - -.macro glabel label - .global \label - \label: -.endm - -.macro .def # -.endm - - -.include "gte.inc" - -.endif diff --git a/requirements.txt b/requirements.txt index 56e9cb7..78c4a94 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,6 +1,6 @@ -splat64==0.34.3 -spimdisasm==1.35.0 -rabbitizer +splat64==0.36.3 +spimdisasm==1.39.0 +rabbitizer==1.14.3 colorama watchdog levenshtein diff --git a/tools/symbols.py b/tools/symbols.py index d2a9b32..95c4988 100755 --- a/tools/symbols.py +++ b/tools/symbols.py @@ -57,7 +57,11 @@ def filter_functions( symbol_list: list[tuple[str, str, str]], ) -> list[tuple[str, str, str]]: return [ - symbol for symbol in symbol_list if symbol[1] == "T" and is_function(symbol[2]) + symbol + for symbol in symbol_list + if symbol[1] == "T" + and is_function(symbol[2]) + and not symbol[2].endswith(".NON_MATCHING") ]