From 19206f91f98eea819c632ae311b756e2fbbd222e Mon Sep 17 00:00:00 2001 From: Phillip Stephens Date: Wed, 6 Apr 2022 01:17:53 -0700 Subject: [PATCH] Move asm/Runtime/PPCEABI/H code into asm/Runtime --- asm/Runtime/{PPCEABI/H => }/CPlusLibPPC.s | 0 asm/Runtime/{PPCEABI/H => }/FILE_POS.s | 0 .../{PPCEABI/H => }/Gecko_ExceptionPPC.s | 0 asm/Runtime/{PPCEABI/H => }/NMWException.s | 0 .../{PPCEABI/H => }/__init_cpp_exceptions.s | 0 asm/Runtime/{PPCEABI/H => }/__mem.s | 0 asm/Runtime/{PPCEABI/H => }/__va_arg.s | 0 asm/Runtime/{PPCEABI/H => }/abort_exit.s | 0 asm/Runtime/{PPCEABI/H => }/alloc.s | 0 asm/Runtime/{PPCEABI/H => }/ansi_files.s | 0 asm/Runtime/{PPCEABI/H => }/ansi_fp.s | 0 asm/Runtime/{PPCEABI/H => }/arith.s | 0 asm/Runtime/{PPCEABI/H => }/buffer_io.s | 0 asm/Runtime/{PPCEABI/H => }/ctype.s | 0 asm/Runtime/{PPCEABI/H => }/direct_io.s | 0 asm/Runtime/{PPCEABI/H => }/e_acos.s | 0 asm/Runtime/{PPCEABI/H => }/e_asin.s | 0 asm/Runtime/{PPCEABI/H => }/e_atan2.s | 0 asm/Runtime/{PPCEABI/H => }/e_exp.s | 0 asm/Runtime/{PPCEABI/H => }/e_fmod.s | 0 asm/Runtime/{PPCEABI/H => }/e_log.s | 0 asm/Runtime/{PPCEABI/H => }/e_pow.s | 0 asm/Runtime/{PPCEABI/H => }/e_rem_pio2.s | 0 asm/Runtime/{PPCEABI/H => }/file_io.s | 0 .../{PPCEABI/H => }/global_destructor_chain.s | 0 asm/Runtime/{PPCEABI/H => }/k_cos.s | 0 asm/Runtime/{PPCEABI/H => }/k_rem_pio2.s | 0 asm/Runtime/{PPCEABI/H => }/k_sin.s | 0 asm/Runtime/{PPCEABI/H => }/k_tan.s | 0 asm/Runtime/{PPCEABI/H => }/mbstring.s | 0 asm/Runtime/{PPCEABI/H => }/mem.s | 0 asm/Runtime/{PPCEABI/H => }/mem_funcs.s | 0 asm/Runtime/{PPCEABI/H => }/misc_io.s | 0 asm/Runtime/{PPCEABI/H => }/printf.s | 0 asm/Runtime/{PPCEABI/H => }/ptmf.s | 0 asm/Runtime/{PPCEABI/H => }/qsort.s | 0 asm/Runtime/{PPCEABI/H => }/rand.s | 0 asm/Runtime/{PPCEABI/H => }/runtime.s | 0 asm/Runtime/{PPCEABI/H => }/s_acos.s | 0 asm/Runtime/{PPCEABI/H => }/s_asin.s | 0 asm/Runtime/{PPCEABI/H => }/s_atan.s | 0 asm/Runtime/{PPCEABI/H => }/s_atan2.s | 0 asm/Runtime/{PPCEABI/H => }/s_copysign.s | 0 asm/Runtime/{PPCEABI/H => }/s_cos.s | 0 asm/Runtime/{PPCEABI/H => }/s_cosf.s | 0 asm/Runtime/{PPCEABI/H => }/s_exp.s | 0 asm/Runtime/{PPCEABI/H => }/s_floor.s | 0 asm/Runtime/{PPCEABI/H => }/s_fmod.s | 0 asm/Runtime/{PPCEABI/H => }/s_frexp.s | 0 asm/Runtime/{PPCEABI/H => }/s_ldexp.s | 0 asm/Runtime/{PPCEABI/H => }/s_log.s | 0 asm/Runtime/{PPCEABI/H => }/s_modf.s | 0 asm/Runtime/{PPCEABI/H => }/s_nextafter.s | 0 asm/Runtime/{PPCEABI/H => }/s_pow.s | 0 asm/Runtime/{PPCEABI/H => }/s_sin.s | 0 asm/Runtime/{PPCEABI/H => }/s_tan.s | 0 asm/Runtime/{PPCEABI/H => }/sbss.s | 0 asm/Runtime/{PPCEABI/H => }/sscanf.s | 0 asm/Runtime/{PPCEABI/H => }/string.s | 0 asm/Runtime/{PPCEABI/H => }/strtold.s | 0 asm/Runtime/{PPCEABI/H => }/uart_console_io.s | 0 asm/Runtime/{PPCEABI/H => }/widechar_io.s | 0 asm/extab.s | 2 +- asm/extabindex.s | 2 +- asm/rodata.s | 1 + asm/sbss.s | 1 + asm/sdata.s | 1 + asm/sdata2.s | 1 + ldscript.lcf | 6 +- ldscript.ld | 8 +- obj_files.mk | 124 +++++++++--------- src/musyx/iram_image.c | 12 +- src/musyx/iram_image.h | 12 ++ 73 files changed, 97 insertions(+), 73 deletions(-) rename asm/Runtime/{PPCEABI/H => }/CPlusLibPPC.s (100%) rename asm/Runtime/{PPCEABI/H => }/FILE_POS.s (100%) rename asm/Runtime/{PPCEABI/H => }/Gecko_ExceptionPPC.s (100%) rename asm/Runtime/{PPCEABI/H => }/NMWException.s (100%) rename asm/Runtime/{PPCEABI/H => }/__init_cpp_exceptions.s (100%) rename asm/Runtime/{PPCEABI/H => }/__mem.s (100%) rename asm/Runtime/{PPCEABI/H => }/__va_arg.s (100%) rename asm/Runtime/{PPCEABI/H => }/abort_exit.s (100%) rename asm/Runtime/{PPCEABI/H => }/alloc.s (100%) rename asm/Runtime/{PPCEABI/H => }/ansi_files.s (100%) rename asm/Runtime/{PPCEABI/H => }/ansi_fp.s (100%) rename asm/Runtime/{PPCEABI/H => }/arith.s (100%) rename asm/Runtime/{PPCEABI/H => }/buffer_io.s (100%) rename asm/Runtime/{PPCEABI/H => }/ctype.s (100%) rename asm/Runtime/{PPCEABI/H => }/direct_io.s (100%) rename asm/Runtime/{PPCEABI/H => }/e_acos.s (100%) rename asm/Runtime/{PPCEABI/H => }/e_asin.s (100%) rename asm/Runtime/{PPCEABI/H => }/e_atan2.s (100%) rename asm/Runtime/{PPCEABI/H => }/e_exp.s (100%) rename asm/Runtime/{PPCEABI/H => }/e_fmod.s (100%) rename asm/Runtime/{PPCEABI/H => }/e_log.s (100%) rename asm/Runtime/{PPCEABI/H => }/e_pow.s (100%) rename asm/Runtime/{PPCEABI/H => }/e_rem_pio2.s (100%) rename asm/Runtime/{PPCEABI/H => }/file_io.s (100%) rename asm/Runtime/{PPCEABI/H => }/global_destructor_chain.s (100%) rename asm/Runtime/{PPCEABI/H => }/k_cos.s (100%) rename asm/Runtime/{PPCEABI/H => }/k_rem_pio2.s (100%) rename asm/Runtime/{PPCEABI/H => }/k_sin.s (100%) rename asm/Runtime/{PPCEABI/H => }/k_tan.s (100%) rename asm/Runtime/{PPCEABI/H => }/mbstring.s (100%) rename asm/Runtime/{PPCEABI/H => }/mem.s (100%) rename asm/Runtime/{PPCEABI/H => }/mem_funcs.s (100%) rename asm/Runtime/{PPCEABI/H => }/misc_io.s (100%) rename asm/Runtime/{PPCEABI/H => }/printf.s (100%) rename asm/Runtime/{PPCEABI/H => }/ptmf.s (100%) rename asm/Runtime/{PPCEABI/H => }/qsort.s (100%) rename asm/Runtime/{PPCEABI/H => }/rand.s (100%) rename asm/Runtime/{PPCEABI/H => }/runtime.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_acos.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_asin.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_atan.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_atan2.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_copysign.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_cos.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_cosf.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_exp.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_floor.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_fmod.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_frexp.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_ldexp.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_log.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_modf.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_nextafter.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_pow.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_sin.s (100%) rename asm/Runtime/{PPCEABI/H => }/s_tan.s (100%) rename asm/Runtime/{PPCEABI/H => }/sbss.s (100%) rename asm/Runtime/{PPCEABI/H => }/sscanf.s (100%) rename asm/Runtime/{PPCEABI/H => }/string.s (100%) rename asm/Runtime/{PPCEABI/H => }/strtold.s (100%) rename asm/Runtime/{PPCEABI/H => }/uart_console_io.s (100%) rename asm/Runtime/{PPCEABI/H => }/widechar_io.s (100%) create mode 100644 src/musyx/iram_image.h diff --git a/asm/Runtime/PPCEABI/H/CPlusLibPPC.s b/asm/Runtime/CPlusLibPPC.s similarity index 100% rename from asm/Runtime/PPCEABI/H/CPlusLibPPC.s rename to asm/Runtime/CPlusLibPPC.s diff --git a/asm/Runtime/PPCEABI/H/FILE_POS.s b/asm/Runtime/FILE_POS.s similarity index 100% rename from asm/Runtime/PPCEABI/H/FILE_POS.s rename to asm/Runtime/FILE_POS.s diff --git a/asm/Runtime/PPCEABI/H/Gecko_ExceptionPPC.s b/asm/Runtime/Gecko_ExceptionPPC.s similarity index 100% rename from asm/Runtime/PPCEABI/H/Gecko_ExceptionPPC.s rename to asm/Runtime/Gecko_ExceptionPPC.s diff --git a/asm/Runtime/PPCEABI/H/NMWException.s b/asm/Runtime/NMWException.s similarity index 100% rename from asm/Runtime/PPCEABI/H/NMWException.s rename to asm/Runtime/NMWException.s diff --git a/asm/Runtime/PPCEABI/H/__init_cpp_exceptions.s b/asm/Runtime/__init_cpp_exceptions.s similarity index 100% rename from asm/Runtime/PPCEABI/H/__init_cpp_exceptions.s rename to asm/Runtime/__init_cpp_exceptions.s diff --git a/asm/Runtime/PPCEABI/H/__mem.s b/asm/Runtime/__mem.s similarity index 100% rename from asm/Runtime/PPCEABI/H/__mem.s rename to asm/Runtime/__mem.s diff --git a/asm/Runtime/PPCEABI/H/__va_arg.s b/asm/Runtime/__va_arg.s similarity index 100% rename from asm/Runtime/PPCEABI/H/__va_arg.s rename to asm/Runtime/__va_arg.s diff --git a/asm/Runtime/PPCEABI/H/abort_exit.s b/asm/Runtime/abort_exit.s similarity index 100% rename from asm/Runtime/PPCEABI/H/abort_exit.s rename to asm/Runtime/abort_exit.s diff --git a/asm/Runtime/PPCEABI/H/alloc.s b/asm/Runtime/alloc.s similarity index 100% rename from asm/Runtime/PPCEABI/H/alloc.s rename to asm/Runtime/alloc.s diff --git a/asm/Runtime/PPCEABI/H/ansi_files.s b/asm/Runtime/ansi_files.s similarity index 100% rename from asm/Runtime/PPCEABI/H/ansi_files.s rename to asm/Runtime/ansi_files.s diff --git a/asm/Runtime/PPCEABI/H/ansi_fp.s b/asm/Runtime/ansi_fp.s similarity index 100% rename from asm/Runtime/PPCEABI/H/ansi_fp.s rename to asm/Runtime/ansi_fp.s diff --git a/asm/Runtime/PPCEABI/H/arith.s b/asm/Runtime/arith.s similarity index 100% rename from asm/Runtime/PPCEABI/H/arith.s rename to asm/Runtime/arith.s diff --git a/asm/Runtime/PPCEABI/H/buffer_io.s b/asm/Runtime/buffer_io.s similarity index 100% rename from asm/Runtime/PPCEABI/H/buffer_io.s rename to asm/Runtime/buffer_io.s diff --git a/asm/Runtime/PPCEABI/H/ctype.s b/asm/Runtime/ctype.s similarity index 100% rename from asm/Runtime/PPCEABI/H/ctype.s rename to asm/Runtime/ctype.s diff --git a/asm/Runtime/PPCEABI/H/direct_io.s b/asm/Runtime/direct_io.s similarity index 100% rename from asm/Runtime/PPCEABI/H/direct_io.s rename to asm/Runtime/direct_io.s diff --git a/asm/Runtime/PPCEABI/H/e_acos.s b/asm/Runtime/e_acos.s similarity index 100% rename from asm/Runtime/PPCEABI/H/e_acos.s rename to asm/Runtime/e_acos.s diff --git a/asm/Runtime/PPCEABI/H/e_asin.s b/asm/Runtime/e_asin.s similarity index 100% rename from asm/Runtime/PPCEABI/H/e_asin.s rename to asm/Runtime/e_asin.s diff --git a/asm/Runtime/PPCEABI/H/e_atan2.s b/asm/Runtime/e_atan2.s similarity index 100% rename from asm/Runtime/PPCEABI/H/e_atan2.s rename to asm/Runtime/e_atan2.s diff --git a/asm/Runtime/PPCEABI/H/e_exp.s b/asm/Runtime/e_exp.s similarity index 100% rename from asm/Runtime/PPCEABI/H/e_exp.s rename to asm/Runtime/e_exp.s diff --git a/asm/Runtime/PPCEABI/H/e_fmod.s b/asm/Runtime/e_fmod.s similarity index 100% rename from asm/Runtime/PPCEABI/H/e_fmod.s rename to asm/Runtime/e_fmod.s diff --git a/asm/Runtime/PPCEABI/H/e_log.s b/asm/Runtime/e_log.s similarity index 100% rename from asm/Runtime/PPCEABI/H/e_log.s rename to asm/Runtime/e_log.s diff --git a/asm/Runtime/PPCEABI/H/e_pow.s b/asm/Runtime/e_pow.s similarity index 100% rename from asm/Runtime/PPCEABI/H/e_pow.s rename to asm/Runtime/e_pow.s diff --git a/asm/Runtime/PPCEABI/H/e_rem_pio2.s b/asm/Runtime/e_rem_pio2.s similarity index 100% rename from asm/Runtime/PPCEABI/H/e_rem_pio2.s rename to asm/Runtime/e_rem_pio2.s diff --git a/asm/Runtime/PPCEABI/H/file_io.s b/asm/Runtime/file_io.s similarity index 100% rename from asm/Runtime/PPCEABI/H/file_io.s rename to asm/Runtime/file_io.s diff --git a/asm/Runtime/PPCEABI/H/global_destructor_chain.s b/asm/Runtime/global_destructor_chain.s similarity index 100% rename from asm/Runtime/PPCEABI/H/global_destructor_chain.s rename to asm/Runtime/global_destructor_chain.s diff --git a/asm/Runtime/PPCEABI/H/k_cos.s b/asm/Runtime/k_cos.s similarity index 100% rename from asm/Runtime/PPCEABI/H/k_cos.s rename to asm/Runtime/k_cos.s diff --git a/asm/Runtime/PPCEABI/H/k_rem_pio2.s b/asm/Runtime/k_rem_pio2.s similarity index 100% rename from asm/Runtime/PPCEABI/H/k_rem_pio2.s rename to asm/Runtime/k_rem_pio2.s diff --git a/asm/Runtime/PPCEABI/H/k_sin.s b/asm/Runtime/k_sin.s similarity index 100% rename from asm/Runtime/PPCEABI/H/k_sin.s rename to asm/Runtime/k_sin.s diff --git a/asm/Runtime/PPCEABI/H/k_tan.s b/asm/Runtime/k_tan.s similarity index 100% rename from asm/Runtime/PPCEABI/H/k_tan.s rename to asm/Runtime/k_tan.s diff --git a/asm/Runtime/PPCEABI/H/mbstring.s b/asm/Runtime/mbstring.s similarity index 100% rename from asm/Runtime/PPCEABI/H/mbstring.s rename to asm/Runtime/mbstring.s diff --git a/asm/Runtime/PPCEABI/H/mem.s b/asm/Runtime/mem.s similarity index 100% rename from asm/Runtime/PPCEABI/H/mem.s rename to asm/Runtime/mem.s diff --git a/asm/Runtime/PPCEABI/H/mem_funcs.s b/asm/Runtime/mem_funcs.s similarity index 100% rename from asm/Runtime/PPCEABI/H/mem_funcs.s rename to asm/Runtime/mem_funcs.s diff --git a/asm/Runtime/PPCEABI/H/misc_io.s b/asm/Runtime/misc_io.s similarity index 100% rename from asm/Runtime/PPCEABI/H/misc_io.s rename to asm/Runtime/misc_io.s diff --git a/asm/Runtime/PPCEABI/H/printf.s b/asm/Runtime/printf.s similarity index 100% rename from asm/Runtime/PPCEABI/H/printf.s rename to asm/Runtime/printf.s diff --git a/asm/Runtime/PPCEABI/H/ptmf.s b/asm/Runtime/ptmf.s similarity index 100% rename from asm/Runtime/PPCEABI/H/ptmf.s rename to asm/Runtime/ptmf.s diff --git a/asm/Runtime/PPCEABI/H/qsort.s b/asm/Runtime/qsort.s similarity index 100% rename from asm/Runtime/PPCEABI/H/qsort.s rename to asm/Runtime/qsort.s diff --git a/asm/Runtime/PPCEABI/H/rand.s b/asm/Runtime/rand.s similarity index 100% rename from asm/Runtime/PPCEABI/H/rand.s rename to asm/Runtime/rand.s diff --git a/asm/Runtime/PPCEABI/H/runtime.s b/asm/Runtime/runtime.s similarity index 100% rename from asm/Runtime/PPCEABI/H/runtime.s rename to asm/Runtime/runtime.s diff --git a/asm/Runtime/PPCEABI/H/s_acos.s b/asm/Runtime/s_acos.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_acos.s rename to asm/Runtime/s_acos.s diff --git a/asm/Runtime/PPCEABI/H/s_asin.s b/asm/Runtime/s_asin.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_asin.s rename to asm/Runtime/s_asin.s diff --git a/asm/Runtime/PPCEABI/H/s_atan.s b/asm/Runtime/s_atan.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_atan.s rename to asm/Runtime/s_atan.s diff --git a/asm/Runtime/PPCEABI/H/s_atan2.s b/asm/Runtime/s_atan2.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_atan2.s rename to asm/Runtime/s_atan2.s diff --git a/asm/Runtime/PPCEABI/H/s_copysign.s b/asm/Runtime/s_copysign.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_copysign.s rename to asm/Runtime/s_copysign.s diff --git a/asm/Runtime/PPCEABI/H/s_cos.s b/asm/Runtime/s_cos.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_cos.s rename to asm/Runtime/s_cos.s diff --git a/asm/Runtime/PPCEABI/H/s_cosf.s b/asm/Runtime/s_cosf.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_cosf.s rename to asm/Runtime/s_cosf.s diff --git a/asm/Runtime/PPCEABI/H/s_exp.s b/asm/Runtime/s_exp.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_exp.s rename to asm/Runtime/s_exp.s diff --git a/asm/Runtime/PPCEABI/H/s_floor.s b/asm/Runtime/s_floor.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_floor.s rename to asm/Runtime/s_floor.s diff --git a/asm/Runtime/PPCEABI/H/s_fmod.s b/asm/Runtime/s_fmod.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_fmod.s rename to asm/Runtime/s_fmod.s diff --git a/asm/Runtime/PPCEABI/H/s_frexp.s b/asm/Runtime/s_frexp.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_frexp.s rename to asm/Runtime/s_frexp.s diff --git a/asm/Runtime/PPCEABI/H/s_ldexp.s b/asm/Runtime/s_ldexp.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_ldexp.s rename to asm/Runtime/s_ldexp.s diff --git a/asm/Runtime/PPCEABI/H/s_log.s b/asm/Runtime/s_log.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_log.s rename to asm/Runtime/s_log.s diff --git a/asm/Runtime/PPCEABI/H/s_modf.s b/asm/Runtime/s_modf.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_modf.s rename to asm/Runtime/s_modf.s diff --git a/asm/Runtime/PPCEABI/H/s_nextafter.s b/asm/Runtime/s_nextafter.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_nextafter.s rename to asm/Runtime/s_nextafter.s diff --git a/asm/Runtime/PPCEABI/H/s_pow.s b/asm/Runtime/s_pow.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_pow.s rename to asm/Runtime/s_pow.s diff --git a/asm/Runtime/PPCEABI/H/s_sin.s b/asm/Runtime/s_sin.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_sin.s rename to asm/Runtime/s_sin.s diff --git a/asm/Runtime/PPCEABI/H/s_tan.s b/asm/Runtime/s_tan.s similarity index 100% rename from asm/Runtime/PPCEABI/H/s_tan.s rename to asm/Runtime/s_tan.s diff --git a/asm/Runtime/PPCEABI/H/sbss.s b/asm/Runtime/sbss.s similarity index 100% rename from asm/Runtime/PPCEABI/H/sbss.s rename to asm/Runtime/sbss.s diff --git a/asm/Runtime/PPCEABI/H/sscanf.s b/asm/Runtime/sscanf.s similarity index 100% rename from asm/Runtime/PPCEABI/H/sscanf.s rename to asm/Runtime/sscanf.s diff --git a/asm/Runtime/PPCEABI/H/string.s b/asm/Runtime/string.s similarity index 100% rename from asm/Runtime/PPCEABI/H/string.s rename to asm/Runtime/string.s diff --git a/asm/Runtime/PPCEABI/H/strtold.s b/asm/Runtime/strtold.s similarity index 100% rename from asm/Runtime/PPCEABI/H/strtold.s rename to asm/Runtime/strtold.s diff --git a/asm/Runtime/PPCEABI/H/uart_console_io.s b/asm/Runtime/uart_console_io.s similarity index 100% rename from asm/Runtime/PPCEABI/H/uart_console_io.s rename to asm/Runtime/uart_console_io.s diff --git a/asm/Runtime/PPCEABI/H/widechar_io.s b/asm/Runtime/widechar_io.s similarity index 100% rename from asm/Runtime/PPCEABI/H/widechar_io.s rename to asm/Runtime/widechar_io.s diff --git a/asm/extab.s b/asm/extab.s index af0715bd..4e077a6c 100644 --- a/asm/extab.s +++ b/asm/extab.s @@ -1,6 +1,6 @@ .include "macros.inc" -.section extab_, "wa" # 0x800035A0 - 0x800035E0 +.section .extab, "wa" # 0x800035A0 - 0x800035E0 .global __destroy_arr_extab __destroy_arr_extab: # ROM: 0x3C8120 diff --git a/asm/extabindex.s b/asm/extabindex.s index 5059c169..9ed65857 100644 --- a/asm/extabindex.s +++ b/asm/extabindex.s @@ -1,6 +1,6 @@ .include "macros.inc" -.section extabindex_, "wa" # 0x800035E0 - 0x80003640 +.section .extabindex, "wa" # 0x800035E0 - 0x80003640 lbl_extabindex: # ROM: 0x3C8160 .4byte __destroy_arr diff --git a/asm/rodata.s b/asm/rodata.s index 2bf2346f..503cbcf9 100644 --- a/asm/rodata.s +++ b/asm/rodata.s @@ -1697,6 +1697,7 @@ lbl_803D8560: .global lbl_803D8568 lbl_803D8568: .incbin "baserom.dol", 0x3D5568, 0x8 +# -- END TEXT -- .global lbl_803D8570 lbl_803D8570: .incbin "baserom.dol", 0x3D5570, 0x18 diff --git a/asm/sbss.s b/asm/sbss.s index 02ab3d0f..c882d42f 100644 --- a/asm/sbss.s +++ b/asm/sbss.s @@ -1923,6 +1923,7 @@ lbl_805A96AC: .global lbl_805A96B0 lbl_805A96B0: .skip 0x8 +# -- END .TEXT -- # .global lbl_805A96B8 lbl_805A96B8: .skip 0x4 diff --git a/asm/sdata.s b/asm/sdata.s index eb500882..f8111210 100644 --- a/asm/sdata.s +++ b/asm/sdata.s @@ -5594,6 +5594,7 @@ lbl_805A8A5D: .global lbl_805A8A60 lbl_805A8A60: .incbin "baserom.dol", 0x3F6400, 0x8 +# -- END .TEXT -- # .global lbl_805A8A68 lbl_805A8A68: .incbin "baserom.dol", 0x3F6408, 0x8 diff --git a/asm/sdata2.s b/asm/sdata2.s index fc843968..a700d44d 100644 --- a/asm/sdata2.s +++ b/asm/sdata2.s @@ -12998,6 +12998,7 @@ lbl_805AEB18: .global lbl_805AEB1C lbl_805AEB1C: .incbin "baserom.dol", 0x3FB3BC, 0x4 +#-- END .TEXT --# .global lbl_805AEB20 lbl_805AEB20: .incbin "baserom.dol", 0x3FB3C0, 0x4 diff --git a/ldscript.lcf b/ldscript.lcf index 700b9aa6..d98798e0 100644 --- a/ldscript.lcf +++ b/ldscript.lcf @@ -8,9 +8,8 @@ SECTIONS GROUP: { .init ALIGN(0x20):{} - /* TODO: should be extab and extabindex */ - extab_ ALIGN(0x20):{} - extabindex_ ALIGN(0x20):{} + .extab ALIGN(0x20):{} + .extabindex ALIGN(0x20):{} .text ALIGN(0x20):{} .ctors ALIGN(0x20):{} .dtors ALIGN(0x20):{} @@ -42,4 +41,5 @@ FORCEFILES misc_io.o printf.o uart_console_io.o + iram_image.o } diff --git a/ldscript.ld b/ldscript.ld index 70f50cfd..331cfa96 100644 --- a/ldscript.ld +++ b/ldscript.ld @@ -5,8 +5,8 @@ PHDRS { init PT_LOAD; text PT_LOAD; - extab_ PT_LOAD; - extabindex_ PT_LOAD; + extab PT_LOAD; + extabindex PT_LOAD; ctors PT_LOAD; dtors PT_LOAD; rodata PT_LOAD; @@ -21,8 +21,8 @@ SECTIONS { .init 0x80003100 : { *(.init) } : init .text 0x80003640 : { *(.text) } : text - extab_ 0x800035A0 : { *(extab_) } : extab_ - extabindex_ 0x800035E0 : { *(extabindex_) } : extabindex_ + .extab 0x800035A0 : { *(.extab) } : extab + .extabindex 0x800035E0 : { *(.extabindex) } : extabindex .ctors 0x803CB1C0 : { *(.ctors) } : ctors .dtors 0x803CB380 : { *(.dtors) } : dtors .rodata 0x803CB3A0 : { *(.rodata) } : rodata diff --git a/obj_files.mk b/obj_files.mk index 5f21d2a7..348631fb 100644 --- a/obj_files.mk +++ b/obj_files.mk @@ -1,7 +1,7 @@ INIT_O_FILES :=\ $(BUILD_DIR)/src/os/__start.o\ $(BUILD_DIR)/src/os/__ppc_eabi_init.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/__mem.o + $(BUILD_DIR)/asm/Runtime/__mem.o KYOTO_CWD :=\ $(BUILD_DIR)/asm/Kyoto_CWD/main.o\ @@ -93,67 +93,67 @@ VI_FILES :=\ $(BUILD_DIR)/asm/Dolphin/vi.o MSL_PPCEABI_BARE_H :=\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/sbss.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/__va_arg.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/global_destructor_chain.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/CPlusLibPPC.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/NMWException.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/ptmf.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/runtime.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/__init_cpp_exceptions.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/Gecko_ExceptionPPC.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/abort_exit.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/alloc.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/ansi_files.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/ansi_fp.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/arith.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/buffer_io.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/ctype.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/direct_io.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/file_io.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/FILE_POS.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/mbstring.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/mem.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/mem_funcs.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/misc_io.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/printf.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/qsort.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/rand.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/sscanf.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/string.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/strtold.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/uart_console_io.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/widechar_io.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/e_acos.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/e_asin.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/e_atan2.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/e_exp.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/e_fmod.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/e_log.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/e_pow.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/e_rem_pio2.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/k_cos.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/k_rem_pio2.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/k_sin.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/k_tan.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_atan.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_copysign.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_cos.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_floor.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_frexp.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_ldexp.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_modf.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_nextafter.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_sin.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_tan.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_acos.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_asin.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_atan2.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_exp.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_fmod.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_log.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_pow.o\ - $(BUILD_DIR)/asm/Runtime/PPCEABI/H/s_cosf.o\ + $(BUILD_DIR)/asm/Runtime/sbss.o\ + $(BUILD_DIR)/asm/Runtime/__va_arg.o\ + $(BUILD_DIR)/asm/Runtime/global_destructor_chain.o\ + $(BUILD_DIR)/asm/Runtime/CPlusLibPPC.o\ + $(BUILD_DIR)/asm/Runtime/NMWException.o\ + $(BUILD_DIR)/asm/Runtime/ptmf.o\ + $(BUILD_DIR)/asm/Runtime/runtime.o\ + $(BUILD_DIR)/asm/Runtime/__init_cpp_exceptions.o\ + $(BUILD_DIR)/asm/Runtime/Gecko_ExceptionPPC.o\ + $(BUILD_DIR)/asm/Runtime/abort_exit.o\ + $(BUILD_DIR)/asm/Runtime/alloc.o\ + $(BUILD_DIR)/asm/Runtime/ansi_files.o\ + $(BUILD_DIR)/asm/Runtime/ansi_fp.o\ + $(BUILD_DIR)/asm/Runtime/arith.o\ + $(BUILD_DIR)/asm/Runtime/buffer_io.o\ + $(BUILD_DIR)/asm/Runtime/ctype.o\ + $(BUILD_DIR)/asm/Runtime/direct_io.o\ + $(BUILD_DIR)/asm/Runtime/file_io.o\ + $(BUILD_DIR)/asm/Runtime/FILE_POS.o\ + $(BUILD_DIR)/asm/Runtime/mbstring.o\ + $(BUILD_DIR)/asm/Runtime/mem.o\ + $(BUILD_DIR)/asm/Runtime/mem_funcs.o\ + $(BUILD_DIR)/asm/Runtime/misc_io.o\ + $(BUILD_DIR)/asm/Runtime/printf.o\ + $(BUILD_DIR)/asm/Runtime/qsort.o\ + $(BUILD_DIR)/asm/Runtime/rand.o\ + $(BUILD_DIR)/asm/Runtime/sscanf.o\ + $(BUILD_DIR)/asm/Runtime/string.o\ + $(BUILD_DIR)/asm/Runtime/strtold.o\ + $(BUILD_DIR)/asm/Runtime/uart_console_io.o\ + $(BUILD_DIR)/asm/Runtime/widechar_io.o\ + $(BUILD_DIR)/asm/Runtime/e_acos.o\ + $(BUILD_DIR)/asm/Runtime/e_asin.o\ + $(BUILD_DIR)/asm/Runtime/e_atan2.o\ + $(BUILD_DIR)/asm/Runtime/e_exp.o\ + $(BUILD_DIR)/asm/Runtime/e_fmod.o\ + $(BUILD_DIR)/asm/Runtime/e_log.o\ + $(BUILD_DIR)/asm/Runtime/e_pow.o\ + $(BUILD_DIR)/asm/Runtime/e_rem_pio2.o\ + $(BUILD_DIR)/asm/Runtime/k_cos.o\ + $(BUILD_DIR)/asm/Runtime/k_rem_pio2.o\ + $(BUILD_DIR)/asm/Runtime/k_sin.o\ + $(BUILD_DIR)/asm/Runtime/k_tan.o\ + $(BUILD_DIR)/asm/Runtime/s_atan.o\ + $(BUILD_DIR)/asm/Runtime/s_copysign.o\ + $(BUILD_DIR)/asm/Runtime/s_cos.o\ + $(BUILD_DIR)/asm/Runtime/s_floor.o\ + $(BUILD_DIR)/asm/Runtime/s_frexp.o\ + $(BUILD_DIR)/asm/Runtime/s_ldexp.o\ + $(BUILD_DIR)/asm/Runtime/s_modf.o\ + $(BUILD_DIR)/asm/Runtime/s_nextafter.o\ + $(BUILD_DIR)/asm/Runtime/s_sin.o\ + $(BUILD_DIR)/asm/Runtime/s_tan.o\ + $(BUILD_DIR)/asm/Runtime/s_acos.o\ + $(BUILD_DIR)/asm/Runtime/s_asin.o\ + $(BUILD_DIR)/asm/Runtime/s_atan2.o\ + $(BUILD_DIR)/asm/Runtime/s_exp.o\ + $(BUILD_DIR)/asm/Runtime/s_fmod.o\ + $(BUILD_DIR)/asm/Runtime/s_log.o\ + $(BUILD_DIR)/asm/Runtime/s_pow.o\ + $(BUILD_DIR)/asm/Runtime/s_cosf.o\ MUSYX_FILES :=\ $(BUILD_DIR)/asm/musyx/sbss.o\ diff --git a/src/musyx/iram_image.c b/src/musyx/iram_image.c index bbbd30f7..d180e8f6 100644 --- a/src/musyx/iram_image.c +++ b/src/musyx/iram_image.c @@ -1,4 +1,9 @@ -char dspSlave[] = +#include "src/musyx/iram_image.h" + +#ifdef __cpluplus +extern "C" { +#endif +static const char dspSlave[] = { 0x00, 0x00, 0x00, 0x00, 0x02, 0x9F, 0x0C, 0x10, 0x02, 0x9F, 0x0C, 0x1F, 0x02, 0x9F, 0x0C, 0x3B, 0x02, 0x9F, 0x0C, 0x4A, 0x02, 0x9F, 0x0C, 0x50, 0x02, 0x9F, 0x0C, 0x82, 0x02, 0x9F, 0x0C, 0x88, 0x13, 0x02, 0x13, 0x03, 0x12, 0x04, 0x13, 0x05, 0x13, 0x06, 0x8E, 0x00, 0x8C, 0x00, 0x8B, 0x00, 0x00, 0x92, 0x00, 0xFF, 0x81, 0x00, 0x89, 0x00, 0x00, 0x9E, 0x0E, 0x80, 0x00, 0xFE, 0x0E, 0x1B, @@ -210,4 +215,7 @@ char dspSlave[] = 0x0 }; -int dspSlaveLength = sizeof(dspSlave); +static const int dspSlaveLength = sizeof(dspSlave); +#ifdef __cpluplus +} +#endif diff --git a/src/musyx/iram_image.h b/src/musyx/iram_image.h new file mode 100644 index 00000000..99111e97 --- /dev/null +++ b/src/musyx/iram_image.h @@ -0,0 +1,12 @@ +#ifndef MUSYX_IRAM_IMAGE_H +#define MUSYX_IRAM_IMAGE_H + +#ifdef __cpluplus +extern "C" { +#endif +static const char dspSlave[]; +static const int dspSlaveLength; +#ifdef __cpluplus +} +#endif +#endif