diff options
author | Max <mparisi@stevens.edu> | 2020-09-29 10:39:51 -0400 |
---|---|---|
committer | Max <mparisi@stevens.edu> | 2020-09-29 10:39:51 -0400 |
commit | a8a179cf67d8ea50160c7cb97208f5bf223f3037 (patch) | |
tree | 923c0a7736d844bbfd25ed00faca81ee80f0fe43 | |
parent | 69d5442a81cfb31123d29d33f369a9d58f7bc26c (diff) |
organize include/, split Gecko_ExceptionPPC.s
-rw-r--r-- | asm/libstdc++/Gecko_ExceptionPPC.s | 35 | ||||
-rw-r--r-- | asm/libstdc++/__init_cpp_exceptions.s | 2 | ||||
-rw-r--r-- | asm/text_5_2.s | 32 | ||||
-rw-r--r-- | include/GameSpy/darray.h (renamed from include/darray.h) | 0 | ||||
-rw-r--r-- | include/GameSpy/hashtable.h (renamed from include/hashtable.h) | 0 | ||||
-rw-r--r-- | include/GameSpy/nonport.h (renamed from include/nonport.h) | 0 | ||||
-rw-r--r-- | include/libstdc++/qsort.h (renamed from include/qsort.h) | 0 | ||||
-rw-r--r-- | obj_files.mk | 1 |
8 files changed, 37 insertions, 33 deletions
diff --git a/asm/libstdc++/Gecko_ExceptionPPC.s b/asm/libstdc++/Gecko_ExceptionPPC.s new file mode 100644 index 0000000..0291da9 --- /dev/null +++ b/asm/libstdc++/Gecko_ExceptionPPC.s @@ -0,0 +1,35 @@ +.include "macros.inc"
+
+.section .text, "ax" # 0x80006980 - 0x803E1E60
+
+.global __register_fragment
+__register_fragment:
+/* 801C7830 001C3490 3C A0 80 49 */ lis r5, lbl_8048EAE0@ha
+/* 801C7834 001C3494 38 A5 EA E0 */ addi r5, r5, lbl_8048EAE0@l
+/* 801C7838 001C3498 80 05 00 08 */ lwz r0, 8(r5)
+/* 801C783C 001C349C 2C 00 00 00 */ cmpwi r0, 0
+/* 801C7840 001C34A0 40 82 00 1C */ bne lbl_801C785C
+/* 801C7844 001C34A4 90 65 00 00 */ stw r3, 0(r5)
+/* 801C7848 001C34A8 38 00 00 01 */ li r0, 1
+/* 801C784C 001C34AC 38 60 00 00 */ li r3, 0
+/* 801C7850 001C34B0 90 85 00 04 */ stw r4, 4(r5)
+/* 801C7854 001C34B4 90 05 00 08 */ stw r0, 8(r5)
+/* 801C7858 001C34B8 4E 80 00 20 */ blr
+lbl_801C785C:
+/* 801C785C 001C34BC 38 60 FF FF */ li r3, -1
+/* 801C7860 001C34C0 4E 80 00 20 */ blr
+
+.global __unregister_fragment
+__unregister_fragment:
+/* 801C7864 001C34C4 2C 03 00 00 */ cmpwi r3, 0
+/* 801C7868 001C34C8 4D 80 00 20 */ bltlr
+/* 801C786C 001C34CC 2C 03 00 01 */ cmpwi r3, 1
+/* 801C7870 001C34D0 4C 80 00 20 */ bgelr
+/* 801C7874 001C34D4 1C 83 00 0C */ mulli r4, r3, 0xc
+/* 801C7878 001C34D8 3C 60 80 49 */ lis r3, lbl_8048EAE0@ha
+/* 801C787C 001C34DC 38 00 00 00 */ li r0, 0
+/* 801C7880 001C34E0 38 63 EA E0 */ addi r3, r3, lbl_8048EAE0@l
+/* 801C7884 001C34E4 7C 03 21 6E */ stwux r0, r3, r4
+/* 801C7888 001C34E8 90 03 00 04 */ stw r0, 4(r3)
+/* 801C788C 001C34EC 90 03 00 08 */ stw r0, 8(r3)
+/* 801C7890 001C34F0 4E 80 00 20 */ blr
diff --git a/asm/libstdc++/__init_cpp_exceptions.s b/asm/libstdc++/__init_cpp_exceptions.s index aa1fa2a..7e12b85 100644 --- a/asm/libstdc++/__init_cpp_exceptions.s +++ b/asm/libstdc++/__init_cpp_exceptions.s @@ -35,7 +35,7 @@ __fini_cpp_exceptions_tmp: #__fini_cpp_exceptions /* 801C7808 001C3468 80 6D 83 D8 */ lwz r3, lbl_8063D698-_SDA_BASE_(r13) /* 801C780C 001C346C 2C 03 FF FE */ cmpwi r3, -2 /* 801C7810 001C3470 41 82 00 10 */ beq lbl_801C7820 -/* 801C7814 001C3474 48 00 00 51 */ bl func_801C7864 +/* 801C7814 001C3474 48 00 00 51 */ bl __unregister_fragment /* 801C7818 001C3478 38 00 FF FE */ li r0, -2 /* 801C781C 001C347C 90 0D 83 D8 */ stw r0, lbl_8063D698-_SDA_BASE_(r13) lbl_801C7820: diff --git a/asm/text_5_2.s b/asm/text_5_2.s index 06e2e4e..67a841f 100644 --- a/asm/text_5_2.s +++ b/asm/text_5_2.s @@ -2,38 +2,6 @@ .section .text, "ax" # 0x80006980 - 0x803E1E60 -.global __register_fragment -__register_fragment: -/* 801C7830 001C3490 3C A0 80 49 */ lis r5, lbl_8048EAE0@ha -/* 801C7834 001C3494 38 A5 EA E0 */ addi r5, r5, lbl_8048EAE0@l -/* 801C7838 001C3498 80 05 00 08 */ lwz r0, 8(r5) -/* 801C783C 001C349C 2C 00 00 00 */ cmpwi r0, 0 -/* 801C7840 001C34A0 40 82 00 1C */ bne lbl_801C785C -/* 801C7844 001C34A4 90 65 00 00 */ stw r3, 0(r5) -/* 801C7848 001C34A8 38 00 00 01 */ li r0, 1 -/* 801C784C 001C34AC 38 60 00 00 */ li r3, 0 -/* 801C7850 001C34B0 90 85 00 04 */ stw r4, 4(r5) -/* 801C7854 001C34B4 90 05 00 08 */ stw r0, 8(r5) -/* 801C7858 001C34B8 4E 80 00 20 */ blr -lbl_801C785C: -/* 801C785C 001C34BC 38 60 FF FF */ li r3, -1 -/* 801C7860 001C34C0 4E 80 00 20 */ blr - -.global func_801C7864 -func_801C7864: -/* 801C7864 001C34C4 2C 03 00 00 */ cmpwi r3, 0 -/* 801C7868 001C34C8 4D 80 00 20 */ bltlr -/* 801C786C 001C34CC 2C 03 00 01 */ cmpwi r3, 1 -/* 801C7870 001C34D0 4C 80 00 20 */ bgelr -/* 801C7874 001C34D4 1C 83 00 0C */ mulli r4, r3, 0xc -/* 801C7878 001C34D8 3C 60 80 49 */ lis r3, lbl_8048EAE0@ha -/* 801C787C 001C34DC 38 00 00 00 */ li r0, 0 -/* 801C7880 001C34E0 38 63 EA E0 */ addi r3, r3, lbl_8048EAE0@l -/* 801C7884 001C34E4 7C 03 21 6E */ stwux r0, r3, r4 -/* 801C7888 001C34E8 90 03 00 04 */ stw r0, 4(r3) -/* 801C788C 001C34EC 90 03 00 08 */ stw r0, 8(r3) -/* 801C7890 001C34F0 4E 80 00 20 */ blr - .global func_801C7894 func_801C7894: /* 801C7894 001C34F4 94 21 FF E0 */ stwu r1, -0x20(r1) diff --git a/include/darray.h b/include/GameSpy/darray.h index 5c7c170..5c7c170 100644 --- a/include/darray.h +++ b/include/GameSpy/darray.h diff --git a/include/hashtable.h b/include/GameSpy/hashtable.h index 784ab35..784ab35 100644 --- a/include/hashtable.h +++ b/include/GameSpy/hashtable.h diff --git a/include/nonport.h b/include/GameSpy/nonport.h index c1ed0e7..c1ed0e7 100644 --- a/include/nonport.h +++ b/include/GameSpy/nonport.h diff --git a/include/qsort.h b/include/libstdc++/qsort.h index c13ae0e..c13ae0e 100644 --- a/include/qsort.h +++ b/include/libstdc++/qsort.h diff --git a/obj_files.mk b/obj_files.mk index 3f1b7f9..f4c8687 100644 --- a/obj_files.mk +++ b/obj_files.mk @@ -19,6 +19,7 @@ TEXT_O_FILES := \ $(BUILD_DIR)/src/libstdc++/ptmf.o \ $(BUILD_DIR)/asm/libstdc++/runtime.o \ $(BUILD_DIR)/asm/libstdc++/__init_cpp_exceptions.o \ + $(BUILD_DIR)/asm/libstdc++/Gecko_ExceptionPPC.o \ $(BUILD_DIR)/asm/text_5_2.o \ $(BUILD_DIR)/asm/text_6.o \ $(BUILD_DIR)/asm/MetroTRK/mem_TRK.o \ |