summaryrefslogtreecommitdiff
path: root/asm/Dolphin/gd
diff options
context:
space:
mode:
Diffstat (limited to 'asm/Dolphin/gd')
-rw-r--r--asm/Dolphin/gd/GDBase.s121
-rw-r--r--asm/Dolphin/gd/GDGeometry.s1573
-rw-r--r--asm/Dolphin/gd/GDLight.s1125
-rw-r--r--asm/Dolphin/gd/GDPixel.s450
-rw-r--r--asm/Dolphin/gd/GDTev.s677
-rw-r--r--asm/Dolphin/gd/GDTransform.s259
6 files changed, 4205 insertions, 0 deletions
diff --git a/asm/Dolphin/gd/GDBase.s b/asm/Dolphin/gd/GDBase.s
new file mode 100644
index 0000000..4066b98
--- /dev/null
+++ b/asm/Dolphin/gd/GDBase.s
@@ -0,0 +1,121 @@
+.include "macros.inc"
+
+.section .text, "ax" # 0x80005600 - 0x8036FBA0
+.global GDInitGDLObj
+GDInitGDLObj:
+/* 800AF018 000ABF58 90 83 00 00 */ stw r4, 0(r3)
+/* 800AF01C 000ABF5C 7C 04 2A 14 */ add r0, r4, r5
+/* 800AF020 000ABF60 90 83 00 08 */ stw r4, 8(r3)
+/* 800AF024 000ABF64 90 03 00 0C */ stw r0, 0xc(r3)
+/* 800AF028 000ABF68 90 A3 00 04 */ stw r5, 4(r3)
+/* 800AF02C 000ABF6C 4E 80 00 20 */ blr
+
+.global GDFlushCurrToMem
+GDFlushCurrToMem:
+/* 800AF030 000ABF70 7C 08 02 A6 */ mflr r0
+/* 800AF034 000ABF74 90 01 00 04 */ stw r0, 4(r1)
+/* 800AF038 000ABF78 94 21 FF F8 */ stwu r1, -8(r1)
+/* 800AF03C 000ABF7C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF040 000ABF80 80 64 00 00 */ lwz r3, 0(r4)
+/* 800AF044 000ABF84 80 84 00 04 */ lwz r4, 4(r4)
+/* 800AF048 000ABF88 4B FD EF 65 */ bl DCFlushRange
+/* 800AF04C 000ABF8C 80 01 00 0C */ lwz r0, 0xc(r1)
+/* 800AF050 000ABF90 38 21 00 08 */ addi r1, r1, 8
+/* 800AF054 000ABF94 7C 08 03 A6 */ mtlr r0
+/* 800AF058 000ABF98 4E 80 00 20 */ blr
+
+.global GDPadCurr32
+GDPadCurr32:
+/* 800AF05C 000ABF9C 80 6D 95 B8 */ lwz r3, __GDCurrentDL@sda21(r13)
+/* 800AF060 000ABFA0 80 03 00 08 */ lwz r0, 8(r3)
+/* 800AF064 000ABFA4 54 00 06 FF */ clrlwi. r0, r0, 0x1b
+/* 800AF068 000ABFA8 4D 82 00 20 */ beqlr
+/* 800AF06C 000ABFAC 28 00 00 20 */ cmplwi r0, 0x20
+/* 800AF070 000ABFB0 20 60 00 20 */ subfic r3, r0, 0x20
+/* 800AF074 000ABFB4 38 C0 00 00 */ li r6, 0
+/* 800AF078 000ABFB8 4C 80 00 20 */ bgelr
+/* 800AF07C 000ABFBC 54 60 E8 FF */ rlwinm. r0, r3, 0x1d, 3, 0x1f
+/* 800AF080 000ABFC0 7C 09 03 A6 */ mtctr r0
+/* 800AF084 000ABFC4 41 82 00 B0 */ beq lbl_800AF134
+lbl_800AF088:
+/* 800AF088 000ABFC8 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AF08C 000ABFCC 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AF090 000ABFD0 38 04 00 01 */ addi r0, r4, 1
+/* 800AF094 000ABFD4 90 05 00 08 */ stw r0, 8(r5)
+/* 800AF098 000ABFD8 98 C4 00 00 */ stb r6, 0(r4)
+/* 800AF09C 000ABFDC 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AF0A0 000ABFE0 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AF0A4 000ABFE4 38 04 00 01 */ addi r0, r4, 1
+/* 800AF0A8 000ABFE8 90 05 00 08 */ stw r0, 8(r5)
+/* 800AF0AC 000ABFEC 98 C4 00 00 */ stb r6, 0(r4)
+/* 800AF0B0 000ABFF0 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AF0B4 000ABFF4 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AF0B8 000ABFF8 38 04 00 01 */ addi r0, r4, 1
+/* 800AF0BC 000ABFFC 90 05 00 08 */ stw r0, 8(r5)
+/* 800AF0C0 000AC000 98 C4 00 00 */ stb r6, 0(r4)
+/* 800AF0C4 000AC004 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AF0C8 000AC008 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AF0CC 000AC00C 38 04 00 01 */ addi r0, r4, 1
+/* 800AF0D0 000AC010 90 05 00 08 */ stw r0, 8(r5)
+/* 800AF0D4 000AC014 98 C4 00 00 */ stb r6, 0(r4)
+/* 800AF0D8 000AC018 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AF0DC 000AC01C 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AF0E0 000AC020 38 04 00 01 */ addi r0, r4, 1
+/* 800AF0E4 000AC024 90 05 00 08 */ stw r0, 8(r5)
+/* 800AF0E8 000AC028 98 C4 00 00 */ stb r6, 0(r4)
+/* 800AF0EC 000AC02C 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AF0F0 000AC030 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AF0F4 000AC034 38 04 00 01 */ addi r0, r4, 1
+/* 800AF0F8 000AC038 90 05 00 08 */ stw r0, 8(r5)
+/* 800AF0FC 000AC03C 98 C4 00 00 */ stb r6, 0(r4)
+/* 800AF100 000AC040 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AF104 000AC044 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AF108 000AC048 38 04 00 01 */ addi r0, r4, 1
+/* 800AF10C 000AC04C 90 05 00 08 */ stw r0, 8(r5)
+/* 800AF110 000AC050 98 C4 00 00 */ stb r6, 0(r4)
+/* 800AF114 000AC054 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AF118 000AC058 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AF11C 000AC05C 38 04 00 01 */ addi r0, r4, 1
+/* 800AF120 000AC060 90 05 00 08 */ stw r0, 8(r5)
+/* 800AF124 000AC064 98 C4 00 00 */ stb r6, 0(r4)
+/* 800AF128 000AC068 42 00 FF 60 */ bdnz lbl_800AF088
+/* 800AF12C 000AC06C 70 63 00 07 */ andi. r3, r3, 7
+/* 800AF130 000AC070 4D 82 00 20 */ beqlr
+lbl_800AF134:
+/* 800AF134 000AC074 7C 69 03 A6 */ mtctr r3
+lbl_800AF138:
+/* 800AF138 000AC078 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AF13C 000AC07C 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AF140 000AC080 38 04 00 01 */ addi r0, r4, 1
+/* 800AF144 000AC084 90 05 00 08 */ stw r0, 8(r5)
+/* 800AF148 000AC088 98 C4 00 00 */ stb r6, 0(r4)
+/* 800AF14C 000AC08C 42 00 FF EC */ bdnz lbl_800AF138
+/* 800AF150 000AC090 4E 80 00 20 */ blr
+
+.global GDOverflowed
+GDOverflowed:
+/* 800AF154 000AC094 7C 08 02 A6 */ mflr r0
+/* 800AF158 000AC098 90 01 00 04 */ stw r0, 4(r1)
+/* 800AF15C 000AC09C 94 21 FF F8 */ stwu r1, -8(r1)
+/* 800AF160 000AC0A0 81 8D 95 BC */ lwz r12, overflowcb@sda21(r13)
+/* 800AF164 000AC0A4 28 0C 00 00 */ cmplwi r12, 0
+/* 800AF168 000AC0A8 41 82 00 0C */ beq lbl_800AF174
+/* 800AF16C 000AC0AC 7D 88 03 A6 */ mtlr r12
+/* 800AF170 000AC0B0 4E 80 00 21 */ blrl
+lbl_800AF174:
+/* 800AF174 000AC0B4 80 01 00 0C */ lwz r0, 0xc(r1)
+/* 800AF178 000AC0B8 38 21 00 08 */ addi r1, r1, 8
+/* 800AF17C 000AC0BC 7C 08 03 A6 */ mtlr r0
+/* 800AF180 000AC0C0 4E 80 00 20 */ blr
+
+.global GDSetOverflowCallback
+GDSetOverflowCallback:
+/* 800AF184 000AC0C4 90 6D 95 BC */ stw r3, overflowcb@sda21(r13)
+/* 800AF188 000AC0C8 4E 80 00 20 */ blr
+
+.section .sbss, "wa" # 0x804097C0 - 0x8040B45C
+.global __GDCurrentDL
+__GDCurrentDL:
+ .skip 0x4
+overflowcb:
+ .skip 0x4
diff --git a/asm/Dolphin/gd/GDGeometry.s b/asm/Dolphin/gd/GDGeometry.s
new file mode 100644
index 0000000..e46effa
--- /dev/null
+++ b/asm/Dolphin/gd/GDGeometry.s
@@ -0,0 +1,1573 @@
+.include "macros.inc"
+
+.section .text, "ax" # 0x80005600 - 0x8036FBA0
+.global GDSetVtxDescv
+GDSetVtxDescv:
+/* 800AF18C 000AC0CC 7C 08 02 A6 */ mflr r0
+/* 800AF190 000AC0D0 3C 80 80 3B */ lis r4, "@121"@ha
+/* 800AF194 000AC0D4 90 01 00 04 */ stw r0, 4(r1)
+/* 800AF198 000AC0D8 38 84 1C 48 */ addi r4, r4, "@121"@l
+/* 800AF19C 000AC0DC 94 21 FF A8 */ stwu r1, -0x58(r1)
+/* 800AF1A0 000AC0E0 BD E1 00 14 */ stmw r15, 0x14(r1)
+/* 800AF1A4 000AC0E4 3B E0 00 00 */ li r31, 0
+/* 800AF1A8 000AC0E8 3B C0 00 00 */ li r30, 0
+/* 800AF1AC 000AC0EC 3B A0 00 00 */ li r29, 0
+/* 800AF1B0 000AC0F0 3B 80 00 00 */ li r28, 0
+/* 800AF1B4 000AC0F4 3B 60 00 00 */ li r27, 0
+/* 800AF1B8 000AC0F8 3B 40 00 01 */ li r26, 1
+/* 800AF1BC 000AC0FC 3B 20 00 00 */ li r25, 0
+/* 800AF1C0 000AC100 3B 00 00 00 */ li r24, 0
+/* 800AF1C4 000AC104 3A E0 00 00 */ li r23, 0
+/* 800AF1C8 000AC108 3A C0 00 00 */ li r22, 0
+/* 800AF1CC 000AC10C 3A A0 00 00 */ li r21, 0
+/* 800AF1D0 000AC110 3A 80 00 00 */ li r20, 0
+/* 800AF1D4 000AC114 3A 60 00 00 */ li r19, 0
+/* 800AF1D8 000AC118 3A 40 00 00 */ li r18, 0
+/* 800AF1DC 000AC11C 3A 20 00 00 */ li r17, 0
+/* 800AF1E0 000AC120 3A 00 00 00 */ li r16, 0
+/* 800AF1E4 000AC124 39 E0 00 00 */ li r15, 0
+/* 800AF1E8 000AC128 48 00 02 10 */ b lbl_800AF3F8
+lbl_800AF1EC:
+/* 800AF1EC 000AC12C 28 00 00 19 */ cmplwi r0, 0x19
+/* 800AF1F0 000AC130 41 81 02 04 */ bgt lbl_800AF3F4
+/* 800AF1F4 000AC134 54 00 10 3A */ slwi r0, r0, 2
+/* 800AF1F8 000AC138 7C 04 00 2E */ lwzx r0, r4, r0
+/* 800AF1FC 000AC13C 7C 09 03 A6 */ mtctr r0
+/* 800AF200 000AC140 4E 80 04 20 */ bctr
+lbl_800AF204:
+/* 800AF204 000AC144 83 83 00 04 */ lwz r28, 4(r3)
+/* 800AF208 000AC148 48 00 01 EC */ b lbl_800AF3F4
+lbl_800AF20C:
+/* 800AF20C 000AC14C 80 03 00 04 */ lwz r0, 4(r3)
+/* 800AF210 000AC150 57 65 00 3C */ rlwinm r5, r27, 0, 0, 0x1e
+/* 800AF214 000AC154 7C BB 03 78 */ or r27, r5, r0
+/* 800AF218 000AC158 48 00 01 DC */ b lbl_800AF3F4
+lbl_800AF21C:
+/* 800AF21C 000AC15C 80 03 00 04 */ lwz r0, 4(r3)
+/* 800AF220 000AC160 57 65 07 FA */ rlwinm r5, r27, 0, 0x1f, 0x1d
+/* 800AF224 000AC164 54 00 08 3C */ slwi r0, r0, 1
+/* 800AF228 000AC168 7C BB 03 78 */ or r27, r5, r0
+/* 800AF22C 000AC16C 48 00 01 C8 */ b lbl_800AF3F4
+lbl_800AF230:
+/* 800AF230 000AC170 80 03 00 04 */ lwz r0, 4(r3)
+/* 800AF234 000AC174 57 65 07 B8 */ rlwinm r5, r27, 0, 0x1e, 0x1c
+/* 800AF238 000AC178 54 00 10 3A */ slwi r0, r0, 2
+/* 800AF23C 000AC17C 7C BB 03 78 */ or r27, r5, r0
+/* 800AF240 000AC180 48 00 01 B4 */ b lbl_800AF3F4
+lbl_800AF244:
+/* 800AF244 000AC184 80 03 00 04 */ lwz r0, 4(r3)
+/* 800AF248 000AC188 57 65 07 76 */ rlwinm r5, r27, 0, 0x1d, 0x1b
+/* 800AF24C 000AC18C 54 00 18 38 */ slwi r0, r0, 3
+/* 800AF250 000AC190 7C BB 03 78 */ or r27, r5, r0
+/* 800AF254 000AC194 48 00 01 A0 */ b lbl_800AF3F4
+lbl_800AF258:
+/* 800AF258 000AC198 80 03 00 04 */ lwz r0, 4(r3)
+/* 800AF25C 000AC19C 57 65 07 34 */ rlwinm r5, r27, 0, 0x1c, 0x1a
+/* 800AF260 000AC1A0 54 00 20 36 */ slwi r0, r0, 4
+/* 800AF264 000AC1A4 7C BB 03 78 */ or r27, r5, r0
+/* 800AF268 000AC1A8 48 00 01 8C */ b lbl_800AF3F4
+lbl_800AF26C:
+/* 800AF26C 000AC1AC 80 03 00 04 */ lwz r0, 4(r3)
+/* 800AF270 000AC1B0 57 65 06 F2 */ rlwinm r5, r27, 0, 0x1b, 0x19
+/* 800AF274 000AC1B4 54 00 28 34 */ slwi r0, r0, 5
+/* 800AF278 000AC1B8 7C BB 03 78 */ or r27, r5, r0
+/* 800AF27C 000AC1BC 48 00 01 78 */ b lbl_800AF3F4
+lbl_800AF280:
+/* 800AF280 000AC1C0 80 03 00 04 */ lwz r0, 4(r3)
+/* 800AF284 000AC1C4 57 65 06 B0 */ rlwinm r5, r27, 0, 0x1a, 0x18
+/* 800AF288 000AC1C8 54 00 30 32 */ slwi r0, r0, 6
+/* 800AF28C 000AC1CC 7C BB 03 78 */ or r27, r5, r0
+/* 800AF290 000AC1D0 48 00 01 64 */ b lbl_800AF3F4
+lbl_800AF294:
+/* 800AF294 000AC1D4 80 03 00 04 */ lwz r0, 4(r3)
+/* 800AF298 000AC1D8 57 65 06 6E */ rlwinm r5, r27, 0, 0x19, 0x17
+/* 800AF29C 000AC1DC 54 00 38 30 */ slwi r0, r0, 7
+/* 800AF2A0 000AC1E0 7C BB 03 78 */ or r27, r5, r0
+/* 800AF2A4 000AC1E4 48 00 01 50 */ b lbl_800AF3F4
+lbl_800AF2A8:
+/* 800AF2A8 000AC1E8 83 43 00 04 */ lwz r26, 4(r3)
+/* 800AF2AC 000AC1EC 48 00 01 48 */ b lbl_800AF3F4
+lbl_800AF2B0:
+/* 800AF2B0 000AC1F0 80 03 00 04 */ lwz r0, 4(r3)
+/* 800AF2B4 000AC1F4 2C 00 00 00 */ cmpwi r0, 0
+/* 800AF2B8 000AC1F8 41 82 01 3C */ beq lbl_800AF3F4
+/* 800AF2BC 000AC1FC 7C 19 03 78 */ mr r25, r0
+/* 800AF2C0 000AC200 3B E0 00 01 */ li r31, 1
+/* 800AF2C4 000AC204 48 00 01 30 */ b lbl_800AF3F4
+lbl_800AF2C8:
+/* 800AF2C8 000AC208 80 03 00 04 */ lwz r0, 4(r3)
+/* 800AF2CC 000AC20C 2C 00 00 00 */ cmpwi r0, 0
+/* 800AF2D0 000AC210 41 82 01 24 */ beq lbl_800AF3F4
+/* 800AF2D4 000AC214 7C 19 03 78 */ mr r25, r0
+/* 800AF2D8 000AC218 3B E0 00 02 */ li r31, 2
+/* 800AF2DC 000AC21C 48 00 01 18 */ b lbl_800AF3F4
+lbl_800AF2E0:
+/* 800AF2E0 000AC220 80 C3 00 04 */ lwz r6, 4(r3)
+/* 800AF2E4 000AC224 7C A6 00 D0 */ neg r5, r6
+/* 800AF2E8 000AC228 30 05 FF FF */ addic r0, r5, -1
+/* 800AF2EC 000AC22C 7C 00 29 10 */ subfe r0, r0, r5
+/* 800AF2F0 000AC230 3B 06 00 00 */ addi r24, r6, 0
+/* 800AF2F4 000AC234 7F DE 02 14 */ add r30, r30, r0
+/* 800AF2F8 000AC238 48 00 00 FC */ b lbl_800AF3F4
+lbl_800AF2FC:
+/* 800AF2FC 000AC23C 80 C3 00 04 */ lwz r6, 4(r3)
+/* 800AF300 000AC240 7C A6 00 D0 */ neg r5, r6
+/* 800AF304 000AC244 30 05 FF FF */ addic r0, r5, -1
+/* 800AF308 000AC248 7C 00 29 10 */ subfe r0, r0, r5
+/* 800AF30C 000AC24C 3A E6 00 00 */ addi r23, r6, 0
+/* 800AF310 000AC250 7F DE 02 14 */ add r30, r30, r0
+/* 800AF314 000AC254 48 00 00 E0 */ b lbl_800AF3F4
+lbl_800AF318:
+/* 800AF318 000AC258 80 C3 00 04 */ lwz r6, 4(r3)
+/* 800AF31C 000AC25C 7C A6 00 D0 */ neg r5, r6
+/* 800AF320 000AC260 30 05 FF FF */ addic r0, r5, -1
+/* 800AF324 000AC264 7C 00 29 10 */ subfe r0, r0, r5
+/* 800AF328 000AC268 3A C6 00 00 */ addi r22, r6, 0
+/* 800AF32C 000AC26C 7F BD 02 14 */ add r29, r29, r0
+/* 800AF330 000AC270 48 00 00 C4 */ b lbl_800AF3F4
+lbl_800AF334:
+/* 800AF334 000AC274 80 C3 00 04 */ lwz r6, 4(r3)
+/* 800AF338 000AC278 7C A6 00 D0 */ neg r5, r6
+/* 800AF33C 000AC27C 30 05 FF FF */ addic r0, r5, -1
+/* 800AF340 000AC280 7C 00 29 10 */ subfe r0, r0, r5
+/* 800AF344 000AC284 3A A6 00 00 */ addi r21, r6, 0
+/* 800AF348 000AC288 7F BD 02 14 */ add r29, r29, r0
+/* 800AF34C 000AC28C 48 00 00 A8 */ b lbl_800AF3F4
+lbl_800AF350:
+/* 800AF350 000AC290 80 C3 00 04 */ lwz r6, 4(r3)
+/* 800AF354 000AC294 7C A6 00 D0 */ neg r5, r6
+/* 800AF358 000AC298 30 05 FF FF */ addic r0, r5, -1
+/* 800AF35C 000AC29C 7C 00 29 10 */ subfe r0, r0, r5
+/* 800AF360 000AC2A0 3A 86 00 00 */ addi r20, r6, 0
+/* 800AF364 000AC2A4 7F BD 02 14 */ add r29, r29, r0
+/* 800AF368 000AC2A8 48 00 00 8C */ b lbl_800AF3F4
+lbl_800AF36C:
+/* 800AF36C 000AC2AC 80 C3 00 04 */ lwz r6, 4(r3)
+/* 800AF370 000AC2B0 7C A6 00 D0 */ neg r5, r6
+/* 800AF374 000AC2B4 30 05 FF FF */ addic r0, r5, -1
+/* 800AF378 000AC2B8 7C 00 29 10 */ subfe r0, r0, r5
+/* 800AF37C 000AC2BC 3A 66 00 00 */ addi r19, r6, 0
+/* 800AF380 000AC2C0 7F BD 02 14 */ add r29, r29, r0
+/* 800AF384 000AC2C4 48 00 00 70 */ b lbl_800AF3F4
+lbl_800AF388:
+/* 800AF388 000AC2C8 80 C3 00 04 */ lwz r6, 4(r3)
+/* 800AF38C 000AC2CC 7C A6 00 D0 */ neg r5, r6
+/* 800AF390 000AC2D0 30 05 FF FF */ addic r0, r5, -1
+/* 800AF394 000AC2D4 7C 00 29 10 */ subfe r0, r0, r5
+/* 800AF398 000AC2D8 3A 46 00 00 */ addi r18, r6, 0
+/* 800AF39C 000AC2DC 7F BD 02 14 */ add r29, r29, r0
+/* 800AF3A0 000AC2E0 48 00 00 54 */ b lbl_800AF3F4
+lbl_800AF3A4:
+/* 800AF3A4 000AC2E4 80 C3 00 04 */ lwz r6, 4(r3)
+/* 800AF3A8 000AC2E8 7C A6 00 D0 */ neg r5, r6
+/* 800AF3AC 000AC2EC 30 05 FF FF */ addic r0, r5, -1
+/* 800AF3B0 000AC2F0 7C 00 29 10 */ subfe r0, r0, r5
+/* 800AF3B4 000AC2F4 3A 26 00 00 */ addi r17, r6, 0
+/* 800AF3B8 000AC2F8 7F BD 02 14 */ add r29, r29, r0
+/* 800AF3BC 000AC2FC 48 00 00 38 */ b lbl_800AF3F4
+lbl_800AF3C0:
+/* 800AF3C0 000AC300 80 C3 00 04 */ lwz r6, 4(r3)
+/* 800AF3C4 000AC304 7C A6 00 D0 */ neg r5, r6
+/* 800AF3C8 000AC308 30 05 FF FF */ addic r0, r5, -1
+/* 800AF3CC 000AC30C 7C 00 29 10 */ subfe r0, r0, r5
+/* 800AF3D0 000AC310 3A 06 00 00 */ addi r16, r6, 0
+/* 800AF3D4 000AC314 7F BD 02 14 */ add r29, r29, r0
+/* 800AF3D8 000AC318 48 00 00 1C */ b lbl_800AF3F4
+lbl_800AF3DC:
+/* 800AF3DC 000AC31C 80 C3 00 04 */ lwz r6, 4(r3)
+/* 800AF3E0 000AC320 7C A6 00 D0 */ neg r5, r6
+/* 800AF3E4 000AC324 30 05 FF FF */ addic r0, r5, -1
+/* 800AF3E8 000AC328 7C 00 29 10 */ subfe r0, r0, r5
+/* 800AF3EC 000AC32C 39 E6 00 00 */ addi r15, r6, 0
+/* 800AF3F0 000AC330 7F BD 02 14 */ add r29, r29, r0
+lbl_800AF3F4:
+/* 800AF3F4 000AC334 38 63 00 08 */ addi r3, r3, 8
+lbl_800AF3F8:
+/* 800AF3F8 000AC338 80 03 00 00 */ lwz r0, 0(r3)
+/* 800AF3FC 000AC33C 2C 00 00 FF */ cmpwi r0, 0xff
+/* 800AF400 000AC340 40 82 FD EC */ bne lbl_800AF1EC
+/* 800AF404 000AC344 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF408 000AC348 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF40C 000AC34C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF410 000AC350 38 63 00 01 */ addi r3, r3, 1
+/* 800AF414 000AC354 7C 03 00 40 */ cmplw r3, r0
+/* 800AF418 000AC358 40 81 00 08 */ ble lbl_800AF420
+/* 800AF41C 000AC35C 4B FF FD 39 */ bl GDOverflowed
+lbl_800AF420:
+/* 800AF420 000AC360 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF424 000AC364 38 A0 00 08 */ li r5, 8
+/* 800AF428 000AC368 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF42C 000AC36C 38 03 00 01 */ addi r0, r3, 1
+/* 800AF430 000AC370 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF434 000AC374 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF438 000AC378 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF43C 000AC37C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF440 000AC380 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF444 000AC384 38 63 00 01 */ addi r3, r3, 1
+/* 800AF448 000AC388 7C 03 00 40 */ cmplw r3, r0
+/* 800AF44C 000AC38C 40 81 00 08 */ ble lbl_800AF454
+/* 800AF450 000AC390 4B FF FD 05 */ bl GDOverflowed
+lbl_800AF454:
+/* 800AF454 000AC394 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF458 000AC398 38 A0 00 50 */ li r5, 0x50
+/* 800AF45C 000AC39C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF460 000AC3A0 38 03 00 01 */ addi r0, r3, 1
+/* 800AF464 000AC3A4 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF468 000AC3A8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF46C 000AC3AC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF470 000AC3B0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF474 000AC3B4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF478 000AC3B8 38 63 00 04 */ addi r3, r3, 4
+/* 800AF47C 000AC3BC 7C 03 00 40 */ cmplw r3, r0
+/* 800AF480 000AC3C0 40 81 00 08 */ ble lbl_800AF488
+/* 800AF484 000AC3C4 4B FF FC D1 */ bl GDOverflowed
+lbl_800AF488:
+/* 800AF488 000AC3C8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF48C 000AC3CC 57 60 08 3C */ slwi r0, r27, 1
+/* 800AF490 000AC3D0 57 45 48 2C */ slwi r5, r26, 9
+/* 800AF494 000AC3D4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF498 000AC3D8 7F 80 03 78 */ or r0, r28, r0
+/* 800AF49C 000AC3DC 7C A5 03 78 */ or r5, r5, r0
+/* 800AF4A0 000AC3E0 38 03 00 01 */ addi r0, r3, 1
+/* 800AF4A4 000AC3E4 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF4A8 000AC3E8 57 26 58 28 */ slwi r6, r25, 0xb
+/* 800AF4AC 000AC3EC 57 07 68 24 */ slwi r7, r24, 0xd
+/* 800AF4B0 000AC3F0 7C C0 2B 78 */ or r0, r6, r5
+/* 800AF4B4 000AC3F4 56 E4 78 20 */ slwi r4, r23, 0xf
+/* 800AF4B8 000AC3F8 7C E0 03 78 */ or r0, r7, r0
+/* 800AF4BC 000AC3FC 7C 87 03 78 */ or r7, r4, r0
+/* 800AF4C0 000AC400 54 E0 46 3E */ srwi r0, r7, 0x18
+/* 800AF4C4 000AC404 98 03 00 00 */ stb r0, 0(r3)
+/* 800AF4C8 000AC408 54 E6 86 3E */ rlwinm r6, r7, 0x10, 0x18, 0x1f
+/* 800AF4CC 000AC40C 54 E5 C6 3E */ rlwinm r5, r7, 0x18, 0x18, 0x1f
+/* 800AF4D0 000AC410 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF4D4 000AC414 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF4D8 000AC418 38 03 00 01 */ addi r0, r3, 1
+/* 800AF4DC 000AC41C 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF4E0 000AC420 98 C3 00 00 */ stb r6, 0(r3)
+/* 800AF4E4 000AC424 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF4E8 000AC428 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF4EC 000AC42C 38 03 00 01 */ addi r0, r3, 1
+/* 800AF4F0 000AC430 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF4F4 000AC434 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF4F8 000AC438 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF4FC 000AC43C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF500 000AC440 38 03 00 01 */ addi r0, r3, 1
+/* 800AF504 000AC444 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF508 000AC448 98 E3 00 00 */ stb r7, 0(r3)
+/* 800AF50C 000AC44C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF510 000AC450 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF514 000AC454 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF518 000AC458 38 63 00 01 */ addi r3, r3, 1
+/* 800AF51C 000AC45C 7C 03 00 40 */ cmplw r3, r0
+/* 800AF520 000AC460 40 81 00 08 */ ble lbl_800AF528
+/* 800AF524 000AC464 4B FF FC 31 */ bl GDOverflowed
+lbl_800AF528:
+/* 800AF528 000AC468 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF52C 000AC46C 38 A0 00 08 */ li r5, 8
+/* 800AF530 000AC470 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF534 000AC474 38 03 00 01 */ addi r0, r3, 1
+/* 800AF538 000AC478 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF53C 000AC47C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF540 000AC480 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF544 000AC484 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF548 000AC488 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF54C 000AC48C 38 63 00 01 */ addi r3, r3, 1
+/* 800AF550 000AC490 7C 03 00 40 */ cmplw r3, r0
+/* 800AF554 000AC494 40 81 00 08 */ ble lbl_800AF55C
+/* 800AF558 000AC498 4B FF FB FD */ bl GDOverflowed
+lbl_800AF55C:
+/* 800AF55C 000AC49C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF560 000AC4A0 38 A0 00 60 */ li r5, 0x60
+/* 800AF564 000AC4A4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF568 000AC4A8 38 03 00 01 */ addi r0, r3, 1
+/* 800AF56C 000AC4AC 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF570 000AC4B0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF574 000AC4B4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF578 000AC4B8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF57C 000AC4BC 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF580 000AC4C0 38 63 00 04 */ addi r3, r3, 4
+/* 800AF584 000AC4C4 7C 03 00 40 */ cmplw r3, r0
+/* 800AF588 000AC4C8 40 81 00 08 */ ble lbl_800AF590
+/* 800AF58C 000AC4CC 4B FF FB C9 */ bl GDOverflowed
+lbl_800AF590:
+/* 800AF590 000AC4D0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF594 000AC4D4 56 A0 10 3A */ slwi r0, r21, 2
+/* 800AF598 000AC4D8 56 85 20 36 */ slwi r5, r20, 4
+/* 800AF59C 000AC4DC 7E C0 03 78 */ or r0, r22, r0
+/* 800AF5A0 000AC4E0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF5A4 000AC4E4 56 66 30 32 */ slwi r6, r19, 6
+/* 800AF5A8 000AC4E8 7C A0 03 78 */ or r0, r5, r0
+/* 800AF5AC 000AC4EC 7C C5 03 78 */ or r5, r6, r0
+/* 800AF5B0 000AC4F0 38 03 00 01 */ addi r0, r3, 1
+/* 800AF5B4 000AC4F4 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF5B8 000AC4F8 56 47 40 2E */ slwi r7, r18, 8
+/* 800AF5BC 000AC4FC 7C E0 2B 78 */ or r0, r7, r5
+/* 800AF5C0 000AC500 56 26 50 2A */ slwi r6, r17, 0xa
+/* 800AF5C4 000AC504 56 04 60 26 */ slwi r4, r16, 0xc
+/* 800AF5C8 000AC508 7C C0 03 78 */ or r0, r6, r0
+/* 800AF5CC 000AC50C 55 E5 70 22 */ slwi r5, r15, 0xe
+/* 800AF5D0 000AC510 7C 80 03 78 */ or r0, r4, r0
+/* 800AF5D4 000AC514 7C A7 03 78 */ or r7, r5, r0
+/* 800AF5D8 000AC518 54 E0 46 3E */ srwi r0, r7, 0x18
+/* 800AF5DC 000AC51C 98 03 00 00 */ stb r0, 0(r3)
+/* 800AF5E0 000AC520 54 E6 86 3E */ rlwinm r6, r7, 0x10, 0x18, 0x1f
+/* 800AF5E4 000AC524 54 E5 C6 3E */ rlwinm r5, r7, 0x18, 0x18, 0x1f
+/* 800AF5E8 000AC528 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF5EC 000AC52C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF5F0 000AC530 38 03 00 01 */ addi r0, r3, 1
+/* 800AF5F4 000AC534 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF5F8 000AC538 98 C3 00 00 */ stb r6, 0(r3)
+/* 800AF5FC 000AC53C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF600 000AC540 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF604 000AC544 38 03 00 01 */ addi r0, r3, 1
+/* 800AF608 000AC548 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF60C 000AC54C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF610 000AC550 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF614 000AC554 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF618 000AC558 38 03 00 01 */ addi r0, r3, 1
+/* 800AF61C 000AC55C 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF620 000AC560 98 E3 00 00 */ stb r7, 0(r3)
+/* 800AF624 000AC564 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF628 000AC568 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF62C 000AC56C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF630 000AC570 38 63 00 01 */ addi r3, r3, 1
+/* 800AF634 000AC574 7C 03 00 40 */ cmplw r3, r0
+/* 800AF638 000AC578 40 81 00 08 */ ble lbl_800AF640
+/* 800AF63C 000AC57C 4B FF FB 19 */ bl GDOverflowed
+lbl_800AF640:
+/* 800AF640 000AC580 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF644 000AC584 38 A0 00 10 */ li r5, 0x10
+/* 800AF648 000AC588 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF64C 000AC58C 38 03 00 01 */ addi r0, r3, 1
+/* 800AF650 000AC590 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF654 000AC594 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF658 000AC598 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF65C 000AC59C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF660 000AC5A0 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF664 000AC5A4 38 63 00 02 */ addi r3, r3, 2
+/* 800AF668 000AC5A8 7C 03 00 40 */ cmplw r3, r0
+/* 800AF66C 000AC5AC 40 81 00 08 */ ble lbl_800AF674
+/* 800AF670 000AC5B0 4B FF FA E5 */ bl GDOverflowed
+lbl_800AF674:
+/* 800AF674 000AC5B4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF678 000AC5B8 38 A0 00 00 */ li r5, 0
+/* 800AF67C 000AC5BC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF680 000AC5C0 38 03 00 01 */ addi r0, r3, 1
+/* 800AF684 000AC5C4 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF688 000AC5C8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF68C 000AC5CC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF690 000AC5D0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF694 000AC5D4 38 03 00 01 */ addi r0, r3, 1
+/* 800AF698 000AC5D8 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF69C 000AC5DC 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF6A0 000AC5E0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF6A4 000AC5E4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF6A8 000AC5E8 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF6AC 000AC5EC 38 63 00 02 */ addi r3, r3, 2
+/* 800AF6B0 000AC5F0 7C 03 00 40 */ cmplw r3, r0
+/* 800AF6B4 000AC5F4 40 81 00 08 */ ble lbl_800AF6BC
+/* 800AF6B8 000AC5F8 4B FF FA 9D */ bl GDOverflowed
+lbl_800AF6BC:
+/* 800AF6BC 000AC5FC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF6C0 000AC600 38 C0 00 10 */ li r6, 0x10
+/* 800AF6C4 000AC604 38 A0 00 08 */ li r5, 8
+/* 800AF6C8 000AC608 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF6CC 000AC60C 38 03 00 01 */ addi r0, r3, 1
+/* 800AF6D0 000AC610 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF6D4 000AC614 98 C3 00 00 */ stb r6, 0(r3)
+/* 800AF6D8 000AC618 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF6DC 000AC61C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF6E0 000AC620 38 03 00 01 */ addi r0, r3, 1
+/* 800AF6E4 000AC624 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF6E8 000AC628 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF6EC 000AC62C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF6F0 000AC630 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF6F4 000AC634 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF6F8 000AC638 38 63 00 04 */ addi r3, r3, 4
+/* 800AF6FC 000AC63C 7C 03 00 40 */ cmplw r3, r0
+/* 800AF700 000AC640 40 81 00 08 */ ble lbl_800AF708
+/* 800AF704 000AC644 4B FF FA 51 */ bl GDOverflowed
+lbl_800AF708:
+/* 800AF708 000AC648 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF70C 000AC64C 57 E0 10 3A */ slwi r0, r31, 2
+/* 800AF710 000AC650 57 A5 20 36 */ slwi r5, r29, 4
+/* 800AF714 000AC654 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF718 000AC658 7F C0 03 78 */ or r0, r30, r0
+/* 800AF71C 000AC65C 7C A7 03 78 */ or r7, r5, r0
+/* 800AF720 000AC660 38 03 00 01 */ addi r0, r3, 1
+/* 800AF724 000AC664 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF728 000AC668 54 E0 46 3E */ srwi r0, r7, 0x18
+/* 800AF72C 000AC66C 54 E6 86 3E */ rlwinm r6, r7, 0x10, 0x18, 0x1f
+/* 800AF730 000AC670 98 03 00 00 */ stb r0, 0(r3)
+/* 800AF734 000AC674 54 E5 C6 3E */ rlwinm r5, r7, 0x18, 0x18, 0x1f
+/* 800AF738 000AC678 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF73C 000AC67C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF740 000AC680 38 03 00 01 */ addi r0, r3, 1
+/* 800AF744 000AC684 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF748 000AC688 98 C3 00 00 */ stb r6, 0(r3)
+/* 800AF74C 000AC68C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF750 000AC690 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF754 000AC694 38 03 00 01 */ addi r0, r3, 1
+/* 800AF758 000AC698 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF75C 000AC69C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AF760 000AC6A0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF764 000AC6A4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF768 000AC6A8 38 03 00 01 */ addi r0, r3, 1
+/* 800AF76C 000AC6AC 90 04 00 08 */ stw r0, 8(r4)
+/* 800AF770 000AC6B0 98 E3 00 00 */ stb r7, 0(r3)
+/* 800AF774 000AC6B4 B9 E1 00 14 */ lmw r15, 0x14(r1)
+/* 800AF778 000AC6B8 80 01 00 5C */ lwz r0, 0x5c(r1)
+/* 800AF77C 000AC6BC 38 21 00 58 */ addi r1, r1, 0x58
+/* 800AF780 000AC6C0 7C 08 03 A6 */ mtlr r0
+/* 800AF784 000AC6C4 4E 80 00 20 */ blr
+
+.global GDSetVtxAttrFmtv
+GDSetVtxAttrFmtv:
+/* 800AF788 000AC6C8 7C 08 02 A6 */ mflr r0
+/* 800AF78C 000AC6CC 3C A0 80 3B */ lis r5, "@207"@ha
+/* 800AF790 000AC6D0 90 01 00 04 */ stw r0, 4(r1)
+/* 800AF794 000AC6D4 38 00 00 01 */ li r0, 1
+/* 800AF798 000AC6D8 94 21 FF 60 */ stwu r1, -0xa0(r1)
+/* 800AF79C 000AC6DC BD C1 00 58 */ stmw r14, 0x58(r1)
+/* 800AF7A0 000AC6E0 3B C0 00 00 */ li r30, 0
+/* 800AF7A4 000AC6E4 3B E0 00 00 */ li r31, 0
+/* 800AF7A8 000AC6E8 90 01 00 50 */ stw r0, 0x50(r1)
+/* 800AF7AC 000AC6EC 38 00 00 04 */ li r0, 4
+/* 800AF7B0 000AC6F0 3B 00 00 00 */ li r24, 0
+/* 800AF7B4 000AC6F4 90 01 00 4C */ stw r0, 0x4c(r1)
+/* 800AF7B8 000AC6F8 38 00 00 00 */ li r0, 0
+/* 800AF7BC 000AC6FC 3A E0 00 01 */ li r23, 1
+/* 800AF7C0 000AC700 90 01 00 48 */ stw r0, 0x48(r1)
+/* 800AF7C4 000AC704 38 00 00 04 */ li r0, 4
+/* 800AF7C8 000AC708 3B 20 00 04 */ li r25, 4
+/* 800AF7CC 000AC70C 90 01 00 44 */ stw r0, 0x44(r1)
+/* 800AF7D0 000AC710 38 00 00 01 */ li r0, 1
+/* 800AF7D4 000AC714 3A 80 00 00 */ li r20, 0
+/* 800AF7D8 000AC718 90 01 00 40 */ stw r0, 0x40(r1)
+/* 800AF7DC 000AC71C 38 00 00 05 */ li r0, 5
+/* 800AF7E0 000AC720 3A A0 00 01 */ li r21, 1
+/* 800AF7E4 000AC724 90 01 00 3C */ stw r0, 0x3c(r1)
+/* 800AF7E8 000AC728 38 00 00 01 */ li r0, 1
+/* 800AF7EC 000AC72C 3A C0 00 04 */ li r22, 4
+/* 800AF7F0 000AC730 90 01 00 38 */ stw r0, 0x38(r1)
+/* 800AF7F4 000AC734 38 00 00 05 */ li r0, 5
+/* 800AF7F8 000AC738 39 C0 00 00 */ li r14, 0
+/* 800AF7FC 000AC73C 90 01 00 34 */ stw r0, 0x34(r1)
+/* 800AF800 000AC740 38 00 00 01 */ li r0, 1
+/* 800AF804 000AC744 39 E0 00 01 */ li r15, 1
+/* 800AF808 000AC748 90 01 00 30 */ stw r0, 0x30(r1)
+/* 800AF80C 000AC74C 38 00 00 04 */ li r0, 4
+/* 800AF810 000AC750 3A 00 00 04 */ li r16, 4
+/* 800AF814 000AC754 90 01 00 2C */ stw r0, 0x2c(r1)
+/* 800AF818 000AC758 38 00 00 00 */ li r0, 0
+/* 800AF81C 000AC75C 3A 20 00 00 */ li r17, 0
+/* 800AF820 000AC760 90 01 00 28 */ stw r0, 0x28(r1)
+/* 800AF824 000AC764 38 00 00 01 */ li r0, 1
+/* 800AF828 000AC768 3A 40 00 01 */ li r18, 1
+/* 800AF82C 000AC76C 90 01 00 24 */ stw r0, 0x24(r1)
+/* 800AF830 000AC770 38 00 00 04 */ li r0, 4
+/* 800AF834 000AC774 3A 60 00 04 */ li r19, 4
+/* 800AF838 000AC778 90 01 00 20 */ stw r0, 0x20(r1)
+/* 800AF83C 000AC77C 38 00 00 00 */ li r0, 0
+/* 800AF840 000AC780 3B 40 00 00 */ li r26, 0
+/* 800AF844 000AC784 90 01 00 1C */ stw r0, 0x1c(r1)
+/* 800AF848 000AC788 38 00 00 01 */ li r0, 1
+/* 800AF84C 000AC78C 3B 60 00 01 */ li r27, 1
+/* 800AF850 000AC790 90 01 00 18 */ stw r0, 0x18(r1)
+/* 800AF854 000AC794 38 00 00 04 */ li r0, 4
+/* 800AF858 000AC798 3B 80 00 04 */ li r28, 4
+/* 800AF85C 000AC79C 90 61 00 10 */ stw r3, 0x10(r1)
+/* 800AF860 000AC7A0 38 65 1C B0 */ addi r3, r5, "@207"@l
+/* 800AF864 000AC7A4 3B A0 00 00 */ li r29, 0
+/* 800AF868 000AC7A8 90 01 00 14 */ stw r0, 0x14(r1)
+/* 800AF86C 000AC7AC 48 00 01 30 */ b lbl_800AF99C
+lbl_800AF870:
+/* 800AF870 000AC7B0 38 05 FF F7 */ addi r0, r5, -9
+/* 800AF874 000AC7B4 28 00 00 10 */ cmplwi r0, 0x10
+/* 800AF878 000AC7B8 41 81 01 20 */ bgt lbl_800AF998
+/* 800AF87C 000AC7BC 54 00 10 3A */ slwi r0, r0, 2
+/* 800AF880 000AC7C0 7C 03 00 2E */ lwzx r0, r3, r0
+/* 800AF884 000AC7C4 7C 09 03 A6 */ mtctr r0
+/* 800AF888 000AC7C8 4E 80 04 20 */ bctr
+lbl_800AF88C:
+/* 800AF88C 000AC7CC 80 04 00 04 */ lwz r0, 4(r4)
+/* 800AF890 000AC7D0 90 01 00 50 */ stw r0, 0x50(r1)
+/* 800AF894 000AC7D4 80 04 00 08 */ lwz r0, 8(r4)
+/* 800AF898 000AC7D8 90 01 00 4C */ stw r0, 0x4c(r1)
+/* 800AF89C 000AC7DC 88 04 00 0C */ lbz r0, 0xc(r4)
+/* 800AF8A0 000AC7E0 90 01 00 48 */ stw r0, 0x48(r1)
+/* 800AF8A4 000AC7E4 48 00 00 F4 */ b lbl_800AF998
+lbl_800AF8A8:
+/* 800AF8A8 000AC7E8 80 A4 00 04 */ lwz r5, 4(r4)
+/* 800AF8AC 000AC7EC 80 04 00 08 */ lwz r0, 8(r4)
+/* 800AF8B0 000AC7F0 2C 05 00 02 */ cmpwi r5, 2
+/* 800AF8B4 000AC7F4 90 01 00 44 */ stw r0, 0x44(r1)
+/* 800AF8B8 000AC7F8 40 82 00 10 */ bne lbl_800AF8C8
+/* 800AF8BC 000AC7FC 3B C0 00 01 */ li r30, 1
+/* 800AF8C0 000AC800 3B E0 00 01 */ li r31, 1
+/* 800AF8C4 000AC804 48 00 00 D4 */ b lbl_800AF998
+lbl_800AF8C8:
+/* 800AF8C8 000AC808 3B C5 00 00 */ addi r30, r5, 0
+/* 800AF8CC 000AC80C 3B E0 00 00 */ li r31, 0
+/* 800AF8D0 000AC810 48 00 00 C8 */ b lbl_800AF998
+lbl_800AF8D4:
+/* 800AF8D4 000AC814 80 04 00 04 */ lwz r0, 4(r4)
+/* 800AF8D8 000AC818 90 01 00 40 */ stw r0, 0x40(r1)
+/* 800AF8DC 000AC81C 80 04 00 08 */ lwz r0, 8(r4)
+/* 800AF8E0 000AC820 90 01 00 3C */ stw r0, 0x3c(r1)
+/* 800AF8E4 000AC824 48 00 00 B4 */ b lbl_800AF998
+lbl_800AF8E8:
+/* 800AF8E8 000AC828 80 04 00 04 */ lwz r0, 4(r4)
+/* 800AF8EC 000AC82C 90 01 00 38 */ stw r0, 0x38(r1)
+/* 800AF8F0 000AC830 80 04 00 08 */ lwz r0, 8(r4)
+/* 800AF8F4 000AC834 90 01 00 34 */ stw r0, 0x34(r1)
+/* 800AF8F8 000AC838 48 00 00 A0 */ b lbl_800AF998
+lbl_800AF8FC:
+/* 800AF8FC 000AC83C 80 04 00 04 */ lwz r0, 4(r4)
+/* 800AF900 000AC840 90 01 00 30 */ stw r0, 0x30(r1)
+/* 800AF904 000AC844 80 04 00 08 */ lwz r0, 8(r4)
+/* 800AF908 000AC848 90 01 00 2C */ stw r0, 0x2c(r1)
+/* 800AF90C 000AC84C 88 04 00 0C */ lbz r0, 0xc(r4)
+/* 800AF910 000AC850 90 01 00 28 */ stw r0, 0x28(r1)
+/* 800AF914 000AC854 48 00 00 84 */ b lbl_800AF998
+lbl_800AF918:
+/* 800AF918 000AC858 80 04 00 04 */ lwz r0, 4(r4)
+/* 800AF91C 000AC85C 90 01 00 24 */ stw r0, 0x24(r1)
+/* 800AF920 000AC860 80 04 00 08 */ lwz r0, 8(r4)
+/* 800AF924 000AC864 90 01 00 20 */ stw r0, 0x20(r1)
+/* 800AF928 000AC868 88 04 00 0C */ lbz r0, 0xc(r4)
+/* 800AF92C 000AC86C 90 01 00 1C */ stw r0, 0x1c(r1)
+/* 800AF930 000AC870 48 00 00 68 */ b lbl_800AF998
+lbl_800AF934:
+/* 800AF934 000AC874 80 04 00 04 */ lwz r0, 4(r4)
+/* 800AF938 000AC878 8B 04 00 0C */ lbz r24, 0xc(r4)
+/* 800AF93C 000AC87C 90 01 00 18 */ stw r0, 0x18(r1)
+/* 800AF940 000AC880 80 04 00 08 */ lwz r0, 8(r4)
+/* 800AF944 000AC884 90 01 00 14 */ stw r0, 0x14(r1)
+/* 800AF948 000AC888 48 00 00 50 */ b lbl_800AF998
+lbl_800AF94C:
+/* 800AF94C 000AC88C 82 E4 00 04 */ lwz r23, 4(r4)
+/* 800AF950 000AC890 83 24 00 08 */ lwz r25, 8(r4)
+/* 800AF954 000AC894 8A 84 00 0C */ lbz r20, 0xc(r4)
+/* 800AF958 000AC898 48 00 00 40 */ b lbl_800AF998
+lbl_800AF95C:
+/* 800AF95C 000AC89C 82 A4 00 04 */ lwz r21, 4(r4)
+/* 800AF960 000AC8A0 82 C4 00 08 */ lwz r22, 8(r4)
+/* 800AF964 000AC8A4 89 C4 00 0C */ lbz r14, 0xc(r4)
+/* 800AF968 000AC8A8 48 00 00 30 */ b lbl_800AF998
+lbl_800AF96C:
+/* 800AF96C 000AC8AC 81 E4 00 04 */ lwz r15, 4(r4)
+/* 800AF970 000AC8B0 82 04 00 08 */ lwz r16, 8(r4)
+/* 800AF974 000AC8B4 8A 24 00 0C */ lbz r17, 0xc(r4)
+/* 800AF978 000AC8B8 48 00 00 20 */ b lbl_800AF998
+lbl_800AF97C:
+/* 800AF97C 000AC8BC 82 44 00 04 */ lwz r18, 4(r4)
+/* 800AF980 000AC8C0 82 64 00 08 */ lwz r19, 8(r4)
+/* 800AF984 000AC8C4 8B 44 00 0C */ lbz r26, 0xc(r4)
+/* 800AF988 000AC8C8 48 00 00 10 */ b lbl_800AF998
+lbl_800AF98C:
+/* 800AF98C 000AC8CC 83 64 00 04 */ lwz r27, 4(r4)
+/* 800AF990 000AC8D0 83 84 00 08 */ lwz r28, 8(r4)
+/* 800AF994 000AC8D4 8B A4 00 0C */ lbz r29, 0xc(r4)
+lbl_800AF998:
+/* 800AF998 000AC8D8 38 84 00 10 */ addi r4, r4, 0x10
+lbl_800AF99C:
+/* 800AF99C 000AC8DC 80 A4 00 00 */ lwz r5, 0(r4)
+/* 800AF9A0 000AC8E0 2C 05 00 FF */ cmpwi r5, 0xff
+/* 800AF9A4 000AC8E4 40 82 FE CC */ bne lbl_800AF870
+/* 800AF9A8 000AC8E8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF9AC 000AC8EC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF9B0 000AC8F0 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF9B4 000AC8F4 38 63 00 01 */ addi r3, r3, 1
+/* 800AF9B8 000AC8F8 7C 03 00 40 */ cmplw r3, r0
+/* 800AF9BC 000AC8FC 40 81 00 08 */ ble lbl_800AF9C4
+/* 800AF9C0 000AC900 4B FF F7 95 */ bl GDOverflowed
+lbl_800AF9C4:
+/* 800AF9C4 000AC904 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF9C8 000AC908 38 00 00 08 */ li r0, 8
+/* 800AF9CC 000AC90C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF9D0 000AC910 38 A3 00 01 */ addi r5, r3, 1
+/* 800AF9D4 000AC914 90 A4 00 08 */ stw r5, 8(r4)
+/* 800AF9D8 000AC918 98 03 00 00 */ stb r0, 0(r3)
+/* 800AF9DC 000AC91C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AF9E0 000AC920 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AF9E4 000AC924 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AF9E8 000AC928 38 63 00 01 */ addi r3, r3, 1
+/* 800AF9EC 000AC92C 7C 03 00 40 */ cmplw r3, r0
+/* 800AF9F0 000AC930 40 81 00 08 */ ble lbl_800AF9F8
+/* 800AF9F4 000AC934 4B FF F7 61 */ bl GDOverflowed
+lbl_800AF9F8:
+/* 800AF9F8 000AC938 80 61 00 10 */ lwz r3, 0x10(r1)
+/* 800AF9FC 000AC93C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFA00 000AC940 38 03 00 70 */ addi r0, r3, 0x70
+/* 800AFA04 000AC944 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFA08 000AC948 38 A3 00 01 */ addi r5, r3, 1
+/* 800AFA0C 000AC94C 90 A4 00 08 */ stw r5, 8(r4)
+/* 800AFA10 000AC950 98 03 00 00 */ stb r0, 0(r3)
+/* 800AFA14 000AC954 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFA18 000AC958 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFA1C 000AC95C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFA20 000AC960 38 63 00 04 */ addi r3, r3, 4
+/* 800AFA24 000AC964 7C 03 00 40 */ cmplw r3, r0
+/* 800AFA28 000AC968 40 81 00 08 */ ble lbl_800AFA30
+/* 800AFA2C 000AC96C 4B FF F7 29 */ bl GDOverflowed
+lbl_800AFA30:
+/* 800AFA30 000AC970 80 01 00 4C */ lwz r0, 0x4c(r1)
+/* 800AFA34 000AC974 57 C5 48 2C */ slwi r5, r30, 9
+/* 800AFA38 000AC978 80 ED 95 B8 */ lwz r7, __GDCurrentDL@sda21(r13)
+/* 800AFA3C 000AC97C 54 03 08 3C */ slwi r3, r0, 1
+/* 800AFA40 000AC980 80 01 00 48 */ lwz r0, 0x48(r1)
+/* 800AFA44 000AC984 54 04 20 36 */ slwi r4, r0, 4
+/* 800AFA48 000AC988 80 01 00 50 */ lwz r0, 0x50(r1)
+/* 800AFA4C 000AC98C 7C 00 1B 78 */ or r0, r0, r3
+/* 800AFA50 000AC990 80 67 00 08 */ lwz r3, 8(r7)
+/* 800AFA54 000AC994 7C 84 03 78 */ or r4, r4, r0
+/* 800AFA58 000AC998 80 01 00 44 */ lwz r0, 0x44(r1)
+/* 800AFA5C 000AC99C 7C A5 23 78 */ or r5, r5, r4
+/* 800AFA60 000AC9A0 80 81 00 40 */ lwz r4, 0x40(r1)
+/* 800AFA64 000AC9A4 54 00 50 2A */ slwi r0, r0, 0xa
+/* 800AFA68 000AC9A8 7C 05 2B 78 */ or r5, r0, r5
+/* 800AFA6C 000AC9AC 80 01 00 3C */ lwz r0, 0x3c(r1)
+/* 800AFA70 000AC9B0 54 84 68 24 */ slwi r4, r4, 0xd
+/* 800AFA74 000AC9B4 7C 84 2B 78 */ or r4, r4, r5
+/* 800AFA78 000AC9B8 80 A1 00 38 */ lwz r5, 0x38(r1)
+/* 800AFA7C 000AC9BC 54 00 70 22 */ slwi r0, r0, 0xe
+/* 800AFA80 000AC9C0 7C 04 23 78 */ or r4, r0, r4
+/* 800AFA84 000AC9C4 80 01 00 34 */ lwz r0, 0x34(r1)
+/* 800AFA88 000AC9C8 54 A5 88 1C */ slwi r5, r5, 0x11
+/* 800AFA8C 000AC9CC 7C A5 23 78 */ or r5, r5, r4
+/* 800AFA90 000AC9D0 80 81 00 30 */ lwz r4, 0x30(r1)
+/* 800AFA94 000AC9D4 54 00 90 1A */ slwi r0, r0, 0x12
+/* 800AFA98 000AC9D8 7C 00 2B 78 */ or r0, r0, r5
+/* 800AFA9C 000AC9DC 80 A1 00 2C */ lwz r5, 0x2c(r1)
+/* 800AFAA0 000AC9E0 54 84 A8 14 */ slwi r4, r4, 0x15
+/* 800AFAA4 000AC9E4 7C 84 03 78 */ or r4, r4, r0
+/* 800AFAA8 000AC9E8 80 01 00 28 */ lwz r0, 0x28(r1)
+/* 800AFAAC 000AC9EC 54 A5 B0 12 */ slwi r5, r5, 0x16
+/* 800AFAB0 000AC9F0 38 C3 00 01 */ addi r6, r3, 1
+/* 800AFAB4 000AC9F4 54 00 C8 0C */ slwi r0, r0, 0x19
+/* 800AFAB8 000AC9F8 90 C7 00 08 */ stw r6, 8(r7)
+/* 800AFABC 000AC9FC 7C A4 23 78 */ or r4, r5, r4
+/* 800AFAC0 000ACA00 7C 00 23 78 */ or r0, r0, r4
+/* 800AFAC4 000ACA04 57 E4 F8 00 */ slwi r4, r31, 0x1f
+/* 800AFAC8 000ACA08 64 00 40 00 */ oris r0, r0, 0x4000
+/* 800AFACC 000ACA0C 7C 86 03 78 */ or r6, r4, r0
+/* 800AFAD0 000ACA10 54 C0 46 3E */ srwi r0, r6, 0x18
+/* 800AFAD4 000ACA14 98 03 00 00 */ stb r0, 0(r3)
+/* 800AFAD8 000ACA18 54 C5 86 3E */ rlwinm r5, r6, 0x10, 0x18, 0x1f
+/* 800AFADC 000ACA1C 54 C7 C6 3E */ rlwinm r7, r6, 0x18, 0x18, 0x1f
+/* 800AFAE0 000ACA20 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFAE4 000ACA24 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFAE8 000ACA28 38 03 00 01 */ addi r0, r3, 1
+/* 800AFAEC 000ACA2C 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFAF0 000ACA30 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFAF4 000ACA34 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFAF8 000ACA38 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFAFC 000ACA3C 38 03 00 01 */ addi r0, r3, 1
+/* 800AFB00 000ACA40 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFB04 000ACA44 98 E3 00 00 */ stb r7, 0(r3)
+/* 800AFB08 000ACA48 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFB0C 000ACA4C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFB10 000ACA50 38 03 00 01 */ addi r0, r3, 1
+/* 800AFB14 000ACA54 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFB18 000ACA58 98 C3 00 00 */ stb r6, 0(r3)
+/* 800AFB1C 000ACA5C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFB20 000ACA60 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFB24 000ACA64 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFB28 000ACA68 38 63 00 01 */ addi r3, r3, 1
+/* 800AFB2C 000ACA6C 7C 03 00 40 */ cmplw r3, r0
+/* 800AFB30 000ACA70 40 81 00 08 */ ble lbl_800AFB38
+/* 800AFB34 000ACA74 4B FF F6 21 */ bl GDOverflowed
+lbl_800AFB38:
+/* 800AFB38 000ACA78 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFB3C 000ACA7C 38 A0 00 08 */ li r5, 8
+/* 800AFB40 000ACA80 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFB44 000ACA84 38 03 00 01 */ addi r0, r3, 1
+/* 800AFB48 000ACA88 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFB4C 000ACA8C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFB50 000ACA90 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFB54 000ACA94 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFB58 000ACA98 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFB5C 000ACA9C 38 63 00 01 */ addi r3, r3, 1
+/* 800AFB60 000ACAA0 7C 03 00 40 */ cmplw r3, r0
+/* 800AFB64 000ACAA4 40 81 00 08 */ ble lbl_800AFB6C
+/* 800AFB68 000ACAA8 4B FF F5 ED */ bl GDOverflowed
+lbl_800AFB6C:
+/* 800AFB6C 000ACAAC 80 61 00 10 */ lwz r3, 0x10(r1)
+/* 800AFB70 000ACAB0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFB74 000ACAB4 38 A3 00 80 */ addi r5, r3, 0x80
+/* 800AFB78 000ACAB8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFB7C 000ACABC 38 03 00 01 */ addi r0, r3, 1
+/* 800AFB80 000ACAC0 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFB84 000ACAC4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFB88 000ACAC8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFB8C 000ACACC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFB90 000ACAD0 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFB94 000ACAD4 38 63 00 04 */ addi r3, r3, 4
+/* 800AFB98 000ACAD8 7C 03 00 40 */ cmplw r3, r0
+/* 800AFB9C 000ACADC 40 81 00 08 */ ble lbl_800AFBA4
+/* 800AFBA0 000ACAE0 4B FF F5 B5 */ bl GDOverflowed
+lbl_800AFBA4:
+/* 800AFBA4 000ACAE4 80 01 00 20 */ lwz r0, 0x20(r1)
+/* 800AFBA8 000ACAE8 57 27 98 18 */ slwi r7, r25, 0x13
+/* 800AFBAC 000ACAEC 80 C1 00 18 */ lwz r6, 0x18(r1)
+/* 800AFBB0 000ACAF0 54 03 08 3C */ slwi r3, r0, 1
+/* 800AFBB4 000ACAF4 80 01 00 1C */ lwz r0, 0x1c(r1)
+/* 800AFBB8 000ACAF8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFBBC 000ACAFC 54 C6 48 2C */ slwi r6, r6, 9
+/* 800AFBC0 000ACB00 54 05 20 36 */ slwi r5, r0, 4
+/* 800AFBC4 000ACB04 80 01 00 24 */ lwz r0, 0x24(r1)
+/* 800AFBC8 000ACB08 7C 00 1B 78 */ or r0, r0, r3
+/* 800AFBCC 000ACB0C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFBD0 000ACB10 7C A5 03 78 */ or r5, r5, r0
+/* 800AFBD4 000ACB14 80 01 00 14 */ lwz r0, 0x14(r1)
+/* 800AFBD8 000ACB18 7C C5 2B 78 */ or r5, r6, r5
+/* 800AFBDC 000ACB1C 54 00 50 2A */ slwi r0, r0, 0xa
+/* 800AFBE0 000ACB20 7C 00 2B 78 */ or r0, r0, r5
+/* 800AFBE4 000ACB24 57 06 68 24 */ slwi r6, r24, 0xd
+/* 800AFBE8 000ACB28 7C C6 03 78 */ or r6, r6, r0
+/* 800AFBEC 000ACB2C 38 03 00 01 */ addi r0, r3, 1
+/* 800AFBF0 000ACB30 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFBF4 000ACB34 56 E5 90 1A */ slwi r5, r23, 0x12
+/* 800AFBF8 000ACB38 7C A0 33 78 */ or r0, r5, r6
+/* 800AFBFC 000ACB3C 56 84 B0 12 */ slwi r4, r20, 0x16
+/* 800AFC00 000ACB40 7C E0 03 78 */ or r0, r7, r0
+/* 800AFC04 000ACB44 7C 80 03 78 */ or r0, r4, r0
+/* 800AFC08 000ACB48 56 A5 D8 08 */ slwi r5, r21, 0x1b
+/* 800AFC0C 000ACB4C 56 C4 E0 06 */ slwi r4, r22, 0x1c
+/* 800AFC10 000ACB50 7C A0 03 78 */ or r0, r5, r0
+/* 800AFC14 000ACB54 7C 80 03 78 */ or r0, r4, r0
+/* 800AFC18 000ACB58 64 00 80 00 */ oris r0, r0, 0x8000
+/* 800AFC1C 000ACB5C 54 04 46 3E */ srwi r4, r0, 0x18
+/* 800AFC20 000ACB60 98 83 00 00 */ stb r4, 0(r3)
+/* 800AFC24 000ACB64 54 07 86 3E */ rlwinm r7, r0, 0x10, 0x18, 0x1f
+/* 800AFC28 000ACB68 54 03 C6 3E */ rlwinm r3, r0, 0x18, 0x18, 0x1f
+/* 800AFC2C 000ACB6C 80 CD 95 B8 */ lwz r6, __GDCurrentDL@sda21(r13)
+/* 800AFC30 000ACB70 80 A6 00 08 */ lwz r5, 8(r6)
+/* 800AFC34 000ACB74 38 85 00 01 */ addi r4, r5, 1
+/* 800AFC38 000ACB78 90 86 00 08 */ stw r4, 8(r6)
+/* 800AFC3C 000ACB7C 98 E5 00 00 */ stb r7, 0(r5)
+/* 800AFC40 000ACB80 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AFC44 000ACB84 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AFC48 000ACB88 38 C4 00 01 */ addi r6, r4, 1
+/* 800AFC4C 000ACB8C 90 C5 00 08 */ stw r6, 8(r5)
+/* 800AFC50 000ACB90 98 64 00 00 */ stb r3, 0(r4)
+/* 800AFC54 000ACB94 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFC58 000ACB98 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFC5C 000ACB9C 38 A3 00 01 */ addi r5, r3, 1
+/* 800AFC60 000ACBA0 90 A4 00 08 */ stw r5, 8(r4)
+/* 800AFC64 000ACBA4 98 03 00 00 */ stb r0, 0(r3)
+/* 800AFC68 000ACBA8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFC6C 000ACBAC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFC70 000ACBB0 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFC74 000ACBB4 38 63 00 01 */ addi r3, r3, 1
+/* 800AFC78 000ACBB8 7C 03 00 40 */ cmplw r3, r0
+/* 800AFC7C 000ACBBC 40 81 00 08 */ ble lbl_800AFC84
+/* 800AFC80 000ACBC0 4B FF F4 D5 */ bl GDOverflowed
+lbl_800AFC84:
+/* 800AFC84 000ACBC4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFC88 000ACBC8 38 A0 00 08 */ li r5, 8
+/* 800AFC8C 000ACBCC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFC90 000ACBD0 38 03 00 01 */ addi r0, r3, 1
+/* 800AFC94 000ACBD4 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFC98 000ACBD8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFC9C 000ACBDC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFCA0 000ACBE0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFCA4 000ACBE4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFCA8 000ACBE8 38 63 00 01 */ addi r3, r3, 1
+/* 800AFCAC 000ACBEC 7C 03 00 40 */ cmplw r3, r0
+/* 800AFCB0 000ACBF0 40 81 00 08 */ ble lbl_800AFCB8
+/* 800AFCB4 000ACBF4 4B FF F4 A1 */ bl GDOverflowed
+lbl_800AFCB8:
+/* 800AFCB8 000ACBF8 80 81 00 10 */ lwz r4, 0x10(r1)
+/* 800AFCBC 000ACBFC 80 6D 95 B8 */ lwz r3, __GDCurrentDL@sda21(r13)
+/* 800AFCC0 000ACC00 38 A4 00 90 */ addi r5, r4, 0x90
+/* 800AFCC4 000ACC04 80 83 00 08 */ lwz r4, 8(r3)
+/* 800AFCC8 000ACC08 38 04 00 01 */ addi r0, r4, 1
+/* 800AFCCC 000ACC0C 90 03 00 08 */ stw r0, 8(r3)
+/* 800AFCD0 000ACC10 98 A4 00 00 */ stb r5, 0(r4)
+/* 800AFCD4 000ACC14 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFCD8 000ACC18 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFCDC 000ACC1C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFCE0 000ACC20 38 63 00 04 */ addi r3, r3, 4
+/* 800AFCE4 000ACC24 7C 03 00 40 */ cmplw r3, r0
+/* 800AFCE8 000ACC28 40 81 00 08 */ ble lbl_800AFCF0
+/* 800AFCEC 000ACC2C 4B FF F4 69 */ bl GDOverflowed
+lbl_800AFCF0:
+/* 800AFCF0 000ACC30 55 E0 28 34 */ slwi r0, r15, 5
+/* 800AFCF4 000ACC34 80 6D 95 B8 */ lwz r3, __GDCurrentDL@sda21(r13)
+/* 800AFCF8 000ACC38 56 04 30 32 */ slwi r4, r16, 6
+/* 800AFCFC 000ACC3C 7D C0 03 78 */ or r0, r14, r0
+/* 800AFD00 000ACC40 80 A3 00 08 */ lwz r5, 8(r3)
+/* 800AFD04 000ACC44 7C 80 03 78 */ or r0, r4, r0
+/* 800AFD08 000ACC48 56 26 48 2C */ slwi r6, r17, 9
+/* 800AFD0C 000ACC4C 7C C0 03 78 */ or r0, r6, r0
+/* 800AFD10 000ACC50 56 44 70 22 */ slwi r4, r18, 0xe
+/* 800AFD14 000ACC54 7C 84 03 78 */ or r4, r4, r0
+/* 800AFD18 000ACC58 38 05 00 01 */ addi r0, r5, 1
+/* 800AFD1C 000ACC5C 90 03 00 08 */ stw r0, 8(r3)
+/* 800AFD20 000ACC60 56 66 78 20 */ slwi r6, r19, 0xf
+/* 800AFD24 000ACC64 7C C0 23 78 */ or r0, r6, r4
+/* 800AFD28 000ACC68 57 47 90 1A */ slwi r7, r26, 0x12
+/* 800AFD2C 000ACC6C 57 63 B8 10 */ slwi r3, r27, 0x17
+/* 800AFD30 000ACC70 7C E0 03 78 */ or r0, r7, r0
+/* 800AFD34 000ACC74 7C 60 03 78 */ or r0, r3, r0
+/* 800AFD38 000ACC78 57 84 C0 0E */ slwi r4, r28, 0x18
+/* 800AFD3C 000ACC7C 57 A3 D8 08 */ slwi r3, r29, 0x1b
+/* 800AFD40 000ACC80 7C 80 03 78 */ or r0, r4, r0
+/* 800AFD44 000ACC84 7C 60 03 78 */ or r0, r3, r0
+/* 800AFD48 000ACC88 54 03 46 3E */ srwi r3, r0, 0x18
+/* 800AFD4C 000ACC8C 98 65 00 00 */ stb r3, 0(r5)
+/* 800AFD50 000ACC90 54 07 86 3E */ rlwinm r7, r0, 0x10, 0x18, 0x1f
+/* 800AFD54 000ACC94 54 06 C6 3E */ rlwinm r6, r0, 0x18, 0x18, 0x1f
+/* 800AFD58 000ACC98 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AFD5C 000ACC9C 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AFD60 000ACCA0 38 64 00 01 */ addi r3, r4, 1
+/* 800AFD64 000ACCA4 90 65 00 08 */ stw r3, 8(r5)
+/* 800AFD68 000ACCA8 98 E4 00 00 */ stb r7, 0(r4)
+/* 800AFD6C 000ACCAC 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AFD70 000ACCB0 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AFD74 000ACCB4 38 64 00 01 */ addi r3, r4, 1
+/* 800AFD78 000ACCB8 90 65 00 08 */ stw r3, 8(r5)
+/* 800AFD7C 000ACCBC 98 C4 00 00 */ stb r6, 0(r4)
+/* 800AFD80 000ACCC0 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800AFD84 000ACCC4 80 85 00 08 */ lwz r4, 8(r5)
+/* 800AFD88 000ACCC8 38 64 00 01 */ addi r3, r4, 1
+/* 800AFD8C 000ACCCC 90 65 00 08 */ stw r3, 8(r5)
+/* 800AFD90 000ACCD0 98 04 00 00 */ stb r0, 0(r4)
+/* 800AFD94 000ACCD4 B9 C1 00 58 */ lmw r14, 0x58(r1)
+/* 800AFD98 000ACCD8 80 01 00 A4 */ lwz r0, 0xa4(r1)
+/* 800AFD9C 000ACCDC 38 21 00 A0 */ addi r1, r1, 0xa0
+/* 800AFDA0 000ACCE0 7C 08 03 A6 */ mtlr r0
+/* 800AFDA4 000ACCE4 4E 80 00 20 */ blr
+
+.global GDSetArray
+GDSetArray:
+/* 800AFDA8 000ACCE8 7C 08 02 A6 */ mflr r0
+/* 800AFDAC 000ACCEC 2C 03 00 19 */ cmpwi r3, 0x19
+/* 800AFDB0 000ACCF0 90 01 00 04 */ stw r0, 4(r1)
+/* 800AFDB4 000ACCF4 94 21 FF D8 */ stwu r1, -0x28(r1)
+/* 800AFDB8 000ACCF8 93 E1 00 24 */ stw r31, 0x24(r1)
+/* 800AFDBC 000ACCFC 93 C1 00 20 */ stw r30, 0x20(r1)
+/* 800AFDC0 000ACD00 3B C5 00 00 */ addi r30, r5, 0
+/* 800AFDC4 000ACD04 93 A1 00 1C */ stw r29, 0x1c(r1)
+/* 800AFDC8 000ACD08 3B A4 00 00 */ addi r29, r4, 0
+/* 800AFDCC 000ACD0C 40 82 00 0C */ bne lbl_800AFDD8
+/* 800AFDD0 000ACD10 3B E0 00 01 */ li r31, 1
+/* 800AFDD4 000ACD14 48 00 00 08 */ b lbl_800AFDDC
+lbl_800AFDD8:
+/* 800AFDD8 000ACD18 3B E3 FF F7 */ addi r31, r3, -9
+lbl_800AFDDC:
+/* 800AFDDC 000ACD1C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFDE0 000ACD20 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFDE4 000ACD24 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFDE8 000ACD28 38 63 00 01 */ addi r3, r3, 1
+/* 800AFDEC 000ACD2C 7C 03 00 40 */ cmplw r3, r0
+/* 800AFDF0 000ACD30 40 81 00 08 */ ble lbl_800AFDF8
+/* 800AFDF4 000ACD34 4B FF F3 61 */ bl GDOverflowed
+lbl_800AFDF8:
+/* 800AFDF8 000ACD38 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFDFC 000ACD3C 38 A0 00 08 */ li r5, 8
+/* 800AFE00 000ACD40 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFE04 000ACD44 38 03 00 01 */ addi r0, r3, 1
+/* 800AFE08 000ACD48 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFE0C 000ACD4C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFE10 000ACD50 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFE14 000ACD54 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFE18 000ACD58 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFE1C 000ACD5C 38 63 00 01 */ addi r3, r3, 1
+/* 800AFE20 000ACD60 7C 03 00 40 */ cmplw r3, r0
+/* 800AFE24 000ACD64 40 81 00 08 */ ble lbl_800AFE2C
+/* 800AFE28 000ACD68 4B FF F3 2D */ bl GDOverflowed
+lbl_800AFE2C:
+/* 800AFE2C 000ACD6C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFE30 000ACD70 38 BF 00 A0 */ addi r5, r31, 0xa0
+/* 800AFE34 000ACD74 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFE38 000ACD78 38 03 00 01 */ addi r0, r3, 1
+/* 800AFE3C 000ACD7C 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFE40 000ACD80 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFE44 000ACD84 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFE48 000ACD88 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFE4C 000ACD8C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFE50 000ACD90 38 63 00 04 */ addi r3, r3, 4
+/* 800AFE54 000ACD94 7C 03 00 40 */ cmplw r3, r0
+/* 800AFE58 000ACD98 40 81 00 08 */ ble lbl_800AFE60
+/* 800AFE5C 000ACD9C 4B FF F2 F9 */ bl GDOverflowed
+lbl_800AFE60:
+/* 800AFE60 000ACDA0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFE64 000ACDA4 3D 1D 80 00 */ addis r8, r29, 0x8000
+/* 800AFE68 000ACDA8 55 07 46 3E */ srwi r7, r8, 0x18
+/* 800AFE6C 000ACDAC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFE70 000ACDB0 55 06 86 3E */ rlwinm r6, r8, 0x10, 0x18, 0x1f
+/* 800AFE74 000ACDB4 55 05 C6 3E */ rlwinm r5, r8, 0x18, 0x18, 0x1f
+/* 800AFE78 000ACDB8 38 03 00 01 */ addi r0, r3, 1
+/* 800AFE7C 000ACDBC 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFE80 000ACDC0 98 E3 00 00 */ stb r7, 0(r3)
+/* 800AFE84 000ACDC4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFE88 000ACDC8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFE8C 000ACDCC 38 03 00 01 */ addi r0, r3, 1
+/* 800AFE90 000ACDD0 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFE94 000ACDD4 98 C3 00 00 */ stb r6, 0(r3)
+/* 800AFE98 000ACDD8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFE9C 000ACDDC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFEA0 000ACDE0 38 03 00 01 */ addi r0, r3, 1
+/* 800AFEA4 000ACDE4 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFEA8 000ACDE8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFEAC 000ACDEC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFEB0 000ACDF0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFEB4 000ACDF4 38 03 00 01 */ addi r0, r3, 1
+/* 800AFEB8 000ACDF8 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFEBC 000ACDFC 99 03 00 00 */ stb r8, 0(r3)
+/* 800AFEC0 000ACE00 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFEC4 000ACE04 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFEC8 000ACE08 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFECC 000ACE0C 38 63 00 01 */ addi r3, r3, 1
+/* 800AFED0 000ACE10 7C 03 00 40 */ cmplw r3, r0
+/* 800AFED4 000ACE14 40 81 00 08 */ ble lbl_800AFEDC
+/* 800AFED8 000ACE18 4B FF F2 7D */ bl GDOverflowed
+lbl_800AFEDC:
+/* 800AFEDC 000ACE1C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFEE0 000ACE20 38 A0 00 08 */ li r5, 8
+/* 800AFEE4 000ACE24 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFEE8 000ACE28 38 03 00 01 */ addi r0, r3, 1
+/* 800AFEEC 000ACE2C 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFEF0 000ACE30 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFEF4 000ACE34 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFEF8 000ACE38 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFEFC 000ACE3C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFF00 000ACE40 38 63 00 01 */ addi r3, r3, 1
+/* 800AFF04 000ACE44 7C 03 00 40 */ cmplw r3, r0
+/* 800AFF08 000ACE48 40 81 00 08 */ ble lbl_800AFF10
+/* 800AFF0C 000ACE4C 4B FF F2 49 */ bl GDOverflowed
+lbl_800AFF10:
+/* 800AFF10 000ACE50 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFF14 000ACE54 38 BF 00 B0 */ addi r5, r31, 0xb0
+/* 800AFF18 000ACE58 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFF1C 000ACE5C 38 03 00 01 */ addi r0, r3, 1
+/* 800AFF20 000ACE60 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFF24 000ACE64 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFF28 000ACE68 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFF2C 000ACE6C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFF30 000ACE70 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFF34 000ACE74 38 63 00 04 */ addi r3, r3, 4
+/* 800AFF38 000ACE78 7C 03 00 40 */ cmplw r3, r0
+/* 800AFF3C 000ACE7C 40 81 00 08 */ ble lbl_800AFF44
+/* 800AFF40 000ACE80 4B FF F2 15 */ bl GDOverflowed
+lbl_800AFF44:
+/* 800AFF44 000ACE84 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFF48 000ACE88 38 A0 00 00 */ li r5, 0
+/* 800AFF4C 000ACE8C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFF50 000ACE90 38 03 00 01 */ addi r0, r3, 1
+/* 800AFF54 000ACE94 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFF58 000ACE98 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFF5C 000ACE9C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFF60 000ACEA0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFF64 000ACEA4 38 03 00 01 */ addi r0, r3, 1
+/* 800AFF68 000ACEA8 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFF6C 000ACEAC 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFF70 000ACEB0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFF74 000ACEB4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFF78 000ACEB8 38 03 00 01 */ addi r0, r3, 1
+/* 800AFF7C 000ACEBC 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFF80 000ACEC0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800AFF84 000ACEC4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFF88 000ACEC8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFF8C 000ACECC 38 03 00 01 */ addi r0, r3, 1
+/* 800AFF90 000ACED0 90 04 00 08 */ stw r0, 8(r4)
+/* 800AFF94 000ACED4 9B C3 00 00 */ stb r30, 0(r3)
+/* 800AFF98 000ACED8 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800AFF9C 000ACEDC 83 E1 00 24 */ lwz r31, 0x24(r1)
+/* 800AFFA0 000ACEE0 83 C1 00 20 */ lwz r30, 0x20(r1)
+/* 800AFFA4 000ACEE4 83 A1 00 1C */ lwz r29, 0x1c(r1)
+/* 800AFFA8 000ACEE8 38 21 00 28 */ addi r1, r1, 0x28
+/* 800AFFAC 000ACEEC 7C 08 03 A6 */ mtlr r0
+/* 800AFFB0 000ACEF0 4E 80 00 20 */ blr
+
+.global GDSetArrayRaw
+GDSetArrayRaw:
+/* 800AFFB4 000ACEF4 7C 08 02 A6 */ mflr r0
+/* 800AFFB8 000ACEF8 2C 03 00 19 */ cmpwi r3, 0x19
+/* 800AFFBC 000ACEFC 90 01 00 04 */ stw r0, 4(r1)
+/* 800AFFC0 000ACF00 94 21 FF D8 */ stwu r1, -0x28(r1)
+/* 800AFFC4 000ACF04 93 E1 00 24 */ stw r31, 0x24(r1)
+/* 800AFFC8 000ACF08 93 C1 00 20 */ stw r30, 0x20(r1)
+/* 800AFFCC 000ACF0C 3B C5 00 00 */ addi r30, r5, 0
+/* 800AFFD0 000ACF10 93 A1 00 1C */ stw r29, 0x1c(r1)
+/* 800AFFD4 000ACF14 3B A4 00 00 */ addi r29, r4, 0
+/* 800AFFD8 000ACF18 40 82 00 0C */ bne lbl_800AFFE4
+/* 800AFFDC 000ACF1C 3B E0 00 01 */ li r31, 1
+/* 800AFFE0 000ACF20 48 00 00 08 */ b lbl_800AFFE8
+lbl_800AFFE4:
+/* 800AFFE4 000ACF24 3B E3 FF F7 */ addi r31, r3, -9
+lbl_800AFFE8:
+/* 800AFFE8 000ACF28 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800AFFEC 000ACF2C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800AFFF0 000ACF30 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800AFFF4 000ACF34 38 63 00 01 */ addi r3, r3, 1
+/* 800AFFF8 000ACF38 7C 03 00 40 */ cmplw r3, r0
+/* 800AFFFC 000ACF3C 40 81 00 08 */ ble lbl_800B0004
+/* 800B0000 000ACF40 4B FF F1 55 */ bl GDOverflowed
+lbl_800B0004:
+/* 800B0004 000ACF44 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0008 000ACF48 38 A0 00 08 */ li r5, 8
+/* 800B000C 000ACF4C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0010 000ACF50 38 03 00 01 */ addi r0, r3, 1
+/* 800B0014 000ACF54 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0018 000ACF58 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B001C 000ACF5C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0020 000ACF60 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0024 000ACF64 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0028 000ACF68 38 63 00 01 */ addi r3, r3, 1
+/* 800B002C 000ACF6C 7C 03 00 40 */ cmplw r3, r0
+/* 800B0030 000ACF70 40 81 00 08 */ ble lbl_800B0038
+/* 800B0034 000ACF74 4B FF F1 21 */ bl GDOverflowed
+lbl_800B0038:
+/* 800B0038 000ACF78 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B003C 000ACF7C 38 BF 00 A0 */ addi r5, r31, 0xa0
+/* 800B0040 000ACF80 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0044 000ACF84 38 03 00 01 */ addi r0, r3, 1
+/* 800B0048 000ACF88 90 04 00 08 */ stw r0, 8(r4)
+/* 800B004C 000ACF8C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0050 000ACF90 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0054 000ACF94 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0058 000ACF98 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B005C 000ACF9C 38 63 00 04 */ addi r3, r3, 4
+/* 800B0060 000ACFA0 7C 03 00 40 */ cmplw r3, r0
+/* 800B0064 000ACFA4 40 81 00 08 */ ble lbl_800B006C
+/* 800B0068 000ACFA8 4B FF F0 ED */ bl GDOverflowed
+lbl_800B006C:
+/* 800B006C 000ACFAC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0070 000ACFB0 57 A7 46 3E */ srwi r7, r29, 0x18
+/* 800B0074 000ACFB4 57 A6 86 3E */ rlwinm r6, r29, 0x10, 0x18, 0x1f
+/* 800B0078 000ACFB8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B007C 000ACFBC 57 A5 C6 3E */ rlwinm r5, r29, 0x18, 0x18, 0x1f
+/* 800B0080 000ACFC0 38 03 00 01 */ addi r0, r3, 1
+/* 800B0084 000ACFC4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0088 000ACFC8 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B008C 000ACFCC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0090 000ACFD0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0094 000ACFD4 38 03 00 01 */ addi r0, r3, 1
+/* 800B0098 000ACFD8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B009C 000ACFDC 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B00A0 000ACFE0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B00A4 000ACFE4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B00A8 000ACFE8 38 03 00 01 */ addi r0, r3, 1
+/* 800B00AC 000ACFEC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B00B0 000ACFF0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B00B4 000ACFF4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B00B8 000ACFF8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B00BC 000ACFFC 38 03 00 01 */ addi r0, r3, 1
+/* 800B00C0 000AD000 90 04 00 08 */ stw r0, 8(r4)
+/* 800B00C4 000AD004 9B A3 00 00 */ stb r29, 0(r3)
+/* 800B00C8 000AD008 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B00CC 000AD00C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B00D0 000AD010 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B00D4 000AD014 38 63 00 01 */ addi r3, r3, 1
+/* 800B00D8 000AD018 7C 03 00 40 */ cmplw r3, r0
+/* 800B00DC 000AD01C 40 81 00 08 */ ble lbl_800B00E4
+/* 800B00E0 000AD020 4B FF F0 75 */ bl GDOverflowed
+lbl_800B00E4:
+/* 800B00E4 000AD024 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B00E8 000AD028 38 A0 00 08 */ li r5, 8
+/* 800B00EC 000AD02C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B00F0 000AD030 38 03 00 01 */ addi r0, r3, 1
+/* 800B00F4 000AD034 90 04 00 08 */ stw r0, 8(r4)
+/* 800B00F8 000AD038 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B00FC 000AD03C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0100 000AD040 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0104 000AD044 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0108 000AD048 38 63 00 01 */ addi r3, r3, 1
+/* 800B010C 000AD04C 7C 03 00 40 */ cmplw r3, r0
+/* 800B0110 000AD050 40 81 00 08 */ ble lbl_800B0118
+/* 800B0114 000AD054 4B FF F0 41 */ bl GDOverflowed
+lbl_800B0118:
+/* 800B0118 000AD058 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B011C 000AD05C 38 BF 00 B0 */ addi r5, r31, 0xb0
+/* 800B0120 000AD060 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0124 000AD064 38 03 00 01 */ addi r0, r3, 1
+/* 800B0128 000AD068 90 04 00 08 */ stw r0, 8(r4)
+/* 800B012C 000AD06C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0130 000AD070 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0134 000AD074 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0138 000AD078 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B013C 000AD07C 38 63 00 04 */ addi r3, r3, 4
+/* 800B0140 000AD080 7C 03 00 40 */ cmplw r3, r0
+/* 800B0144 000AD084 40 81 00 08 */ ble lbl_800B014C
+/* 800B0148 000AD088 4B FF F0 0D */ bl GDOverflowed
+lbl_800B014C:
+/* 800B014C 000AD08C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0150 000AD090 38 A0 00 00 */ li r5, 0
+/* 800B0154 000AD094 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0158 000AD098 38 03 00 01 */ addi r0, r3, 1
+/* 800B015C 000AD09C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0160 000AD0A0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0164 000AD0A4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0168 000AD0A8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B016C 000AD0AC 38 03 00 01 */ addi r0, r3, 1
+/* 800B0170 000AD0B0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0174 000AD0B4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0178 000AD0B8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B017C 000AD0BC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0180 000AD0C0 38 03 00 01 */ addi r0, r3, 1
+/* 800B0184 000AD0C4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0188 000AD0C8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B018C 000AD0CC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0190 000AD0D0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0194 000AD0D4 38 03 00 01 */ addi r0, r3, 1
+/* 800B0198 000AD0D8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B019C 000AD0DC 9B C3 00 00 */ stb r30, 0(r3)
+/* 800B01A0 000AD0E0 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800B01A4 000AD0E4 83 E1 00 24 */ lwz r31, 0x24(r1)
+/* 800B01A8 000AD0E8 83 C1 00 20 */ lwz r30, 0x20(r1)
+/* 800B01AC 000AD0EC 83 A1 00 1C */ lwz r29, 0x1c(r1)
+/* 800B01B0 000AD0F0 38 21 00 28 */ addi r1, r1, 0x28
+/* 800B01B4 000AD0F4 7C 08 03 A6 */ mtlr r0
+/* 800B01B8 000AD0F8 4E 80 00 20 */ blr
+
+.global GDSetCullMode
+GDSetCullMode:
+/* 800B01BC 000AD0FC 7C 08 02 A6 */ mflr r0
+/* 800B01C0 000AD100 90 01 00 04 */ stw r0, 4(r1)
+/* 800B01C4 000AD104 94 21 FF E8 */ stwu r1, -0x18(r1)
+/* 800B01C8 000AD108 93 E1 00 14 */ stw r31, 0x14(r1)
+/* 800B01CC 000AD10C 7C 7F 1B 78 */ mr r31, r3
+/* 800B01D0 000AD110 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B01D4 000AD114 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B01D8 000AD118 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B01DC 000AD11C 38 63 00 01 */ addi r3, r3, 1
+/* 800B01E0 000AD120 7C 03 00 40 */ cmplw r3, r0
+/* 800B01E4 000AD124 40 81 00 08 */ ble lbl_800B01EC
+/* 800B01E8 000AD128 4B FF EF 6D */ bl GDOverflowed
+lbl_800B01EC:
+/* 800B01EC 000AD12C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B01F0 000AD130 38 A0 00 61 */ li r5, 0x61
+/* 800B01F4 000AD134 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B01F8 000AD138 38 03 00 01 */ addi r0, r3, 1
+/* 800B01FC 000AD13C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0200 000AD140 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0204 000AD144 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0208 000AD148 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B020C 000AD14C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0210 000AD150 38 63 00 04 */ addi r3, r3, 4
+/* 800B0214 000AD154 7C 03 00 40 */ cmplw r3, r0
+/* 800B0218 000AD158 40 81 00 08 */ ble lbl_800B0220
+/* 800B021C 000AD15C 4B FF EF 39 */ bl GDOverflowed
+lbl_800B0220:
+/* 800B0220 000AD160 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B0224 000AD164 39 00 00 FE */ li r8, 0xfe
+/* 800B0228 000AD168 38 E0 00 00 */ li r7, 0
+/* 800B022C 000AD16C 80 85 00 08 */ lwz r4, 8(r5)
+/* 800B0230 000AD170 38 C0 00 C0 */ li r6, 0xc0
+/* 800B0234 000AD174 38 6D 82 F0 */ addi r3, r13, cm2hw$400@sda21
+/* 800B0238 000AD178 38 04 00 01 */ addi r0, r4, 1
+/* 800B023C 000AD17C 90 05 00 08 */ stw r0, 8(r5)
+/* 800B0240 000AD180 99 04 00 00 */ stb r8, 0(r4)
+/* 800B0244 000AD184 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B0248 000AD188 80 85 00 08 */ lwz r4, 8(r5)
+/* 800B024C 000AD18C 38 04 00 01 */ addi r0, r4, 1
+/* 800B0250 000AD190 90 05 00 08 */ stw r0, 8(r5)
+/* 800B0254 000AD194 98 E4 00 00 */ stb r7, 0(r4)
+/* 800B0258 000AD198 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B025C 000AD19C 80 85 00 08 */ lwz r4, 8(r5)
+/* 800B0260 000AD1A0 38 04 00 01 */ addi r0, r4, 1
+/* 800B0264 000AD1A4 90 05 00 08 */ stw r0, 8(r5)
+/* 800B0268 000AD1A8 98 C4 00 00 */ stb r6, 0(r4)
+/* 800B026C 000AD1AC 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B0270 000AD1B0 80 85 00 08 */ lwz r4, 8(r5)
+/* 800B0274 000AD1B4 38 04 00 01 */ addi r0, r4, 1
+/* 800B0278 000AD1B8 90 05 00 08 */ stw r0, 8(r5)
+/* 800B027C 000AD1BC 98 E4 00 00 */ stb r7, 0(r4)
+/* 800B0280 000AD1C0 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B0284 000AD1C4 7C 83 F8 AE */ lbzx r4, r3, r31
+/* 800B0288 000AD1C8 80 65 00 08 */ lwz r3, 8(r5)
+/* 800B028C 000AD1CC 80 05 00 0C */ lwz r0, 0xc(r5)
+/* 800B0290 000AD1D0 54 9F 70 22 */ slwi r31, r4, 0xe
+/* 800B0294 000AD1D4 38 63 00 01 */ addi r3, r3, 1
+/* 800B0298 000AD1D8 7C 03 00 40 */ cmplw r3, r0
+/* 800B029C 000AD1DC 40 81 00 08 */ ble lbl_800B02A4
+/* 800B02A0 000AD1E0 4B FF EE B5 */ bl GDOverflowed
+lbl_800B02A4:
+/* 800B02A4 000AD1E4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B02A8 000AD1E8 38 A0 00 61 */ li r5, 0x61
+/* 800B02AC 000AD1EC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B02B0 000AD1F0 38 03 00 01 */ addi r0, r3, 1
+/* 800B02B4 000AD1F4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B02B8 000AD1F8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B02BC 000AD1FC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B02C0 000AD200 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B02C4 000AD204 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B02C8 000AD208 38 63 00 04 */ addi r3, r3, 4
+/* 800B02CC 000AD20C 7C 03 00 40 */ cmplw r3, r0
+/* 800B02D0 000AD210 40 81 00 08 */ ble lbl_800B02D8
+/* 800B02D4 000AD214 4B FF EE 81 */ bl GDOverflowed
+lbl_800B02D8:
+/* 800B02D8 000AD218 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B02DC 000AD21C 57 E7 46 3E */ srwi r7, r31, 0x18
+/* 800B02E0 000AD220 57 E6 86 3E */ rlwinm r6, r31, 0x10, 0x18, 0x1f
+/* 800B02E4 000AD224 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B02E8 000AD228 57 E5 C6 3E */ rlwinm r5, r31, 0x18, 0x18, 0x1f
+/* 800B02EC 000AD22C 38 03 00 01 */ addi r0, r3, 1
+/* 800B02F0 000AD230 90 04 00 08 */ stw r0, 8(r4)
+/* 800B02F4 000AD234 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B02F8 000AD238 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B02FC 000AD23C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0300 000AD240 38 03 00 01 */ addi r0, r3, 1
+/* 800B0304 000AD244 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0308 000AD248 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B030C 000AD24C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0310 000AD250 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0314 000AD254 38 03 00 01 */ addi r0, r3, 1
+/* 800B0318 000AD258 90 04 00 08 */ stw r0, 8(r4)
+/* 800B031C 000AD25C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0320 000AD260 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0324 000AD264 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0328 000AD268 38 03 00 01 */ addi r0, r3, 1
+/* 800B032C 000AD26C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0330 000AD270 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B0334 000AD274 80 01 00 1C */ lwz r0, 0x1c(r1)
+/* 800B0338 000AD278 83 E1 00 14 */ lwz r31, 0x14(r1)
+/* 800B033C 000AD27C 38 21 00 18 */ addi r1, r1, 0x18
+/* 800B0340 000AD280 7C 08 03 A6 */ mtlr r0
+/* 800B0344 000AD284 4E 80 00 20 */ blr
+
+.global GDSetGenMode2
+GDSetGenMode2:
+/* 800B0348 000AD288 7C 08 02 A6 */ mflr r0
+/* 800B034C 000AD28C 90 01 00 04 */ stw r0, 4(r1)
+/* 800B0350 000AD290 94 21 FF D8 */ stwu r1, -0x28(r1)
+/* 800B0354 000AD294 BF 61 00 14 */ stmw r27, 0x14(r1)
+/* 800B0358 000AD298 3B A3 00 00 */ addi r29, r3, 0
+/* 800B035C 000AD29C 3B 64 00 00 */ addi r27, r4, 0
+/* 800B0360 000AD2A0 7C BE 2B 78 */ mr r30, r5
+/* 800B0364 000AD2A4 3B 86 00 00 */ addi r28, r6, 0
+/* 800B0368 000AD2A8 3B E7 00 00 */ addi r31, r7, 0
+/* 800B036C 000AD2AC 81 0D 95 B8 */ lwz r8, __GDCurrentDL@sda21(r13)
+/* 800B0370 000AD2B0 80 68 00 08 */ lwz r3, 8(r8)
+/* 800B0374 000AD2B4 80 08 00 0C */ lwz r0, 0xc(r8)
+/* 800B0378 000AD2B8 38 63 00 01 */ addi r3, r3, 1
+/* 800B037C 000AD2BC 7C 03 00 40 */ cmplw r3, r0
+/* 800B0380 000AD2C0 40 81 00 08 */ ble lbl_800B0388
+/* 800B0384 000AD2C4 4B FF ED D1 */ bl GDOverflowed
+lbl_800B0388:
+/* 800B0388 000AD2C8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B038C 000AD2CC 38 A0 00 61 */ li r5, 0x61
+/* 800B0390 000AD2D0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0394 000AD2D4 38 03 00 01 */ addi r0, r3, 1
+/* 800B0398 000AD2D8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B039C 000AD2DC 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B03A0 000AD2E0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B03A4 000AD2E4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B03A8 000AD2E8 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B03AC 000AD2EC 38 63 00 04 */ addi r3, r3, 4
+/* 800B03B0 000AD2F0 7C 03 00 40 */ cmplw r3, r0
+/* 800B03B4 000AD2F4 40 81 00 08 */ ble lbl_800B03BC
+/* 800B03B8 000AD2F8 4B FF ED 9D */ bl GDOverflowed
+lbl_800B03BC:
+/* 800B03BC 000AD2FC 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B03C0 000AD300 57 C3 06 3E */ clrlwi r3, r30, 0x18
+/* 800B03C4 000AD304 38 63 FF FF */ addi r3, r3, -1
+/* 800B03C8 000AD308 80 85 00 08 */ lwz r4, 8(r5)
+/* 800B03CC 000AD30C 39 40 00 07 */ li r10, 7
+/* 800B03D0 000AD310 57 BD 06 3E */ clrlwi r29, r29, 0x18
+/* 800B03D4 000AD314 38 04 00 01 */ addi r0, r4, 1
+/* 800B03D8 000AD318 90 05 00 08 */ stw r0, 8(r5)
+/* 800B03DC 000AD31C 38 00 00 FE */ li r0, 0xfe
+/* 800B03E0 000AD320 54 63 50 2A */ slwi r3, r3, 0xa
+/* 800B03E4 000AD324 98 04 00 00 */ stb r0, 0(r4)
+/* 800B03E8 000AD328 57 60 25 36 */ rlwinm r0, r27, 4, 0x14, 0x1b
+/* 800B03EC 000AD32C 7F A0 03 78 */ or r0, r29, r0
+/* 800B03F0 000AD330 80 ED 95 B8 */ lwz r7, __GDCurrentDL@sda21(r13)
+/* 800B03F4 000AD334 39 20 00 FC */ li r9, 0xfc
+/* 800B03F8 000AD338 39 00 00 3F */ li r8, 0x3f
+/* 800B03FC 000AD33C 80 C7 00 08 */ lwz r6, 8(r7)
+/* 800B0400 000AD340 38 AD 82 F4 */ addi r5, r13, cm2hw$515@sda21
+/* 800B0404 000AD344 57 7E 06 3E */ clrlwi r30, r27, 0x18
+/* 800B0408 000AD348 38 86 00 01 */ addi r4, r6, 1
+/* 800B040C 000AD34C 90 87 00 08 */ stw r4, 8(r7)
+/* 800B0410 000AD350 7C 64 03 78 */ or r4, r3, r0
+/* 800B0414 000AD354 99 46 00 00 */ stb r10, 0(r6)
+/* 800B0418 000AD358 57 86 82 1E */ rlwinm r6, r28, 0x10, 8, 0xf
+/* 800B041C 000AD35C 80 ED 95 B8 */ lwz r7, __GDCurrentDL@sda21(r13)
+/* 800B0420 000AD360 80 67 00 08 */ lwz r3, 8(r7)
+/* 800B0424 000AD364 38 03 00 01 */ addi r0, r3, 1
+/* 800B0428 000AD368 90 07 00 08 */ stw r0, 8(r7)
+/* 800B042C 000AD36C 99 23 00 00 */ stb r9, 0(r3)
+/* 800B0430 000AD370 80 ED 95 B8 */ lwz r7, __GDCurrentDL@sda21(r13)
+/* 800B0434 000AD374 80 67 00 08 */ lwz r3, 8(r7)
+/* 800B0438 000AD378 38 03 00 01 */ addi r0, r3, 1
+/* 800B043C 000AD37C 90 07 00 08 */ stw r0, 8(r7)
+/* 800B0440 000AD380 99 03 00 00 */ stb r8, 0(r3)
+/* 800B0444 000AD384 80 ED 95 B8 */ lwz r7, __GDCurrentDL@sda21(r13)
+/* 800B0448 000AD388 7C A5 F8 AE */ lbzx r5, r5, r31
+/* 800B044C 000AD38C 80 67 00 08 */ lwz r3, 8(r7)
+/* 800B0450 000AD390 80 07 00 0C */ lwz r0, 0xc(r7)
+/* 800B0454 000AD394 54 A5 70 22 */ slwi r5, r5, 0xe
+/* 800B0458 000AD398 38 63 00 01 */ addi r3, r3, 1
+/* 800B045C 000AD39C 7C 03 00 40 */ cmplw r3, r0
+/* 800B0460 000AD3A0 7C A0 23 78 */ or r0, r5, r4
+/* 800B0464 000AD3A4 7C DF 03 78 */ or r31, r6, r0
+/* 800B0468 000AD3A8 40 81 00 08 */ ble lbl_800B0470
+/* 800B046C 000AD3AC 4B FF EC E9 */ bl GDOverflowed
+lbl_800B0470:
+/* 800B0470 000AD3B0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0474 000AD3B4 38 A0 00 61 */ li r5, 0x61
+/* 800B0478 000AD3B8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B047C 000AD3BC 38 03 00 01 */ addi r0, r3, 1
+/* 800B0480 000AD3C0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0484 000AD3C4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0488 000AD3C8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B048C 000AD3CC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0490 000AD3D0 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0494 000AD3D4 38 63 00 04 */ addi r3, r3, 4
+/* 800B0498 000AD3D8 7C 03 00 40 */ cmplw r3, r0
+/* 800B049C 000AD3DC 40 81 00 08 */ ble lbl_800B04A4
+/* 800B04A0 000AD3E0 4B FF EC B5 */ bl GDOverflowed
+lbl_800B04A4:
+/* 800B04A4 000AD3E4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B04A8 000AD3E8 57 E7 46 3E */ srwi r7, r31, 0x18
+/* 800B04AC 000AD3EC 57 E6 86 3E */ rlwinm r6, r31, 0x10, 0x18, 0x1f
+/* 800B04B0 000AD3F0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B04B4 000AD3F4 57 E5 C6 3E */ rlwinm r5, r31, 0x18, 0x18, 0x1f
+/* 800B04B8 000AD3F8 38 03 00 01 */ addi r0, r3, 1
+/* 800B04BC 000AD3FC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B04C0 000AD400 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B04C4 000AD404 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B04C8 000AD408 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B04CC 000AD40C 38 03 00 01 */ addi r0, r3, 1
+/* 800B04D0 000AD410 90 04 00 08 */ stw r0, 8(r4)
+/* 800B04D4 000AD414 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B04D8 000AD418 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B04DC 000AD41C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B04E0 000AD420 38 03 00 01 */ addi r0, r3, 1
+/* 800B04E4 000AD424 90 04 00 08 */ stw r0, 8(r4)
+/* 800B04E8 000AD428 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B04EC 000AD42C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B04F0 000AD430 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B04F4 000AD434 38 03 00 01 */ addi r0, r3, 1
+/* 800B04F8 000AD438 90 04 00 08 */ stw r0, 8(r4)
+/* 800B04FC 000AD43C 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B0500 000AD440 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0504 000AD444 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0508 000AD448 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B050C 000AD44C 38 63 00 01 */ addi r3, r3, 1
+/* 800B0510 000AD450 7C 03 00 40 */ cmplw r3, r0
+/* 800B0514 000AD454 40 81 00 08 */ ble lbl_800B051C
+/* 800B0518 000AD458 4B FF EC 3D */ bl GDOverflowed
+lbl_800B051C:
+/* 800B051C 000AD45C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0520 000AD460 38 A0 00 10 */ li r5, 0x10
+/* 800B0524 000AD464 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0528 000AD468 38 03 00 01 */ addi r0, r3, 1
+/* 800B052C 000AD46C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0530 000AD470 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0534 000AD474 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0538 000AD478 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B053C 000AD47C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0540 000AD480 38 63 00 02 */ addi r3, r3, 2
+/* 800B0544 000AD484 7C 03 00 40 */ cmplw r3, r0
+/* 800B0548 000AD488 40 81 00 08 */ ble lbl_800B0550
+/* 800B054C 000AD48C 4B FF EC 09 */ bl GDOverflowed
+lbl_800B0550:
+/* 800B0550 000AD490 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0554 000AD494 38 A0 00 00 */ li r5, 0
+/* 800B0558 000AD498 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B055C 000AD49C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0560 000AD4A0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0564 000AD4A4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0568 000AD4A8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B056C 000AD4AC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0570 000AD4B0 38 03 00 01 */ addi r0, r3, 1
+/* 800B0574 000AD4B4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0578 000AD4B8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B057C 000AD4BC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0580 000AD4C0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0584 000AD4C4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0588 000AD4C8 38 63 00 02 */ addi r3, r3, 2
+/* 800B058C 000AD4CC 7C 03 00 40 */ cmplw r3, r0
+/* 800B0590 000AD4D0 40 81 00 08 */ ble lbl_800B0598
+/* 800B0594 000AD4D4 4B FF EB C1 */ bl GDOverflowed
+lbl_800B0598:
+/* 800B0598 000AD4D8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B059C 000AD4DC 38 C0 00 10 */ li r6, 0x10
+/* 800B05A0 000AD4E0 38 A0 00 09 */ li r5, 9
+/* 800B05A4 000AD4E4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B05A8 000AD4E8 38 03 00 01 */ addi r0, r3, 1
+/* 800B05AC 000AD4EC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B05B0 000AD4F0 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B05B4 000AD4F4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B05B8 000AD4F8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B05BC 000AD4FC 38 03 00 01 */ addi r0, r3, 1
+/* 800B05C0 000AD500 90 04 00 08 */ stw r0, 8(r4)
+/* 800B05C4 000AD504 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B05C8 000AD508 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B05CC 000AD50C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B05D0 000AD510 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B05D4 000AD514 38 63 00 04 */ addi r3, r3, 4
+/* 800B05D8 000AD518 7C 03 00 40 */ cmplw r3, r0
+/* 800B05DC 000AD51C 40 81 00 08 */ ble lbl_800B05E4
+/* 800B05E0 000AD520 4B FF EB 75 */ bl GDOverflowed
+lbl_800B05E4:
+/* 800B05E4 000AD524 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B05E8 000AD528 38 A0 00 00 */ li r5, 0
+/* 800B05EC 000AD52C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B05F0 000AD530 38 03 00 01 */ addi r0, r3, 1
+/* 800B05F4 000AD534 90 04 00 08 */ stw r0, 8(r4)
+/* 800B05F8 000AD538 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B05FC 000AD53C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0600 000AD540 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0604 000AD544 38 03 00 01 */ addi r0, r3, 1
+/* 800B0608 000AD548 90 04 00 08 */ stw r0, 8(r4)
+/* 800B060C 000AD54C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0610 000AD550 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0614 000AD554 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0618 000AD558 38 03 00 01 */ addi r0, r3, 1
+/* 800B061C 000AD55C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0620 000AD560 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0624 000AD564 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0628 000AD568 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B062C 000AD56C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0630 000AD570 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0634 000AD574 9B C3 00 00 */ stb r30, 0(r3)
+/* 800B0638 000AD578 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B063C 000AD57C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0640 000AD580 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0644 000AD584 38 63 00 01 */ addi r3, r3, 1
+/* 800B0648 000AD588 7C 03 00 40 */ cmplw r3, r0
+/* 800B064C 000AD58C 40 81 00 08 */ ble lbl_800B0654
+/* 800B0650 000AD590 4B FF EB 05 */ bl GDOverflowed
+lbl_800B0654:
+/* 800B0654 000AD594 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0658 000AD598 38 A0 00 10 */ li r5, 0x10
+/* 800B065C 000AD59C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0660 000AD5A0 38 03 00 01 */ addi r0, r3, 1
+/* 800B0664 000AD5A4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0668 000AD5A8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B066C 000AD5AC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0670 000AD5B0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0674 000AD5B4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0678 000AD5B8 38 63 00 02 */ addi r3, r3, 2
+/* 800B067C 000AD5BC 7C 03 00 40 */ cmplw r3, r0
+/* 800B0680 000AD5C0 40 81 00 08 */ ble lbl_800B0688
+/* 800B0684 000AD5C4 4B FF EA D1 */ bl GDOverflowed
+lbl_800B0688:
+/* 800B0688 000AD5C8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B068C 000AD5CC 38 A0 00 00 */ li r5, 0
+/* 800B0690 000AD5D0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0694 000AD5D4 38 03 00 01 */ addi r0, r3, 1
+/* 800B0698 000AD5D8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B069C 000AD5DC 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B06A0 000AD5E0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B06A4 000AD5E4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B06A8 000AD5E8 38 03 00 01 */ addi r0, r3, 1
+/* 800B06AC 000AD5EC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B06B0 000AD5F0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B06B4 000AD5F4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B06B8 000AD5F8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B06BC 000AD5FC 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B06C0 000AD600 38 63 00 02 */ addi r3, r3, 2
+/* 800B06C4 000AD604 7C 03 00 40 */ cmplw r3, r0
+/* 800B06C8 000AD608 40 81 00 08 */ ble lbl_800B06D0
+/* 800B06CC 000AD60C 4B FF EA 89 */ bl GDOverflowed
+lbl_800B06D0:
+/* 800B06D0 000AD610 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B06D4 000AD614 38 C0 00 10 */ li r6, 0x10
+/* 800B06D8 000AD618 38 A0 00 3F */ li r5, 0x3f
+/* 800B06DC 000AD61C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B06E0 000AD620 38 03 00 01 */ addi r0, r3, 1
+/* 800B06E4 000AD624 90 04 00 08 */ stw r0, 8(r4)
+/* 800B06E8 000AD628 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B06EC 000AD62C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B06F0 000AD630 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B06F4 000AD634 38 03 00 01 */ addi r0, r3, 1
+/* 800B06F8 000AD638 90 04 00 08 */ stw r0, 8(r4)
+/* 800B06FC 000AD63C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0700 000AD640 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0704 000AD644 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0708 000AD648 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B070C 000AD64C 38 63 00 04 */ addi r3, r3, 4
+/* 800B0710 000AD650 7C 03 00 40 */ cmplw r3, r0
+/* 800B0714 000AD654 40 81 00 08 */ ble lbl_800B071C
+/* 800B0718 000AD658 4B FF EA 3D */ bl GDOverflowed
+lbl_800B071C:
+/* 800B071C 000AD65C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0720 000AD660 38 A0 00 00 */ li r5, 0
+/* 800B0724 000AD664 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0728 000AD668 38 03 00 01 */ addi r0, r3, 1
+/* 800B072C 000AD66C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0730 000AD670 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0734 000AD674 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0738 000AD678 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B073C 000AD67C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0740 000AD680 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0744 000AD684 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0748 000AD688 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B074C 000AD68C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0750 000AD690 38 03 00 01 */ addi r0, r3, 1
+/* 800B0754 000AD694 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0758 000AD698 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B075C 000AD69C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0760 000AD6A0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0764 000AD6A4 38 03 00 01 */ addi r0, r3, 1
+/* 800B0768 000AD6A8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B076C 000AD6AC 9B A3 00 00 */ stb r29, 0(r3)
+/* 800B0770 000AD6B0 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800B0774 000AD6B4 BB 61 00 14 */ lmw r27, 0x14(r1)
+/* 800B0778 000AD6B8 38 21 00 28 */ addi r1, r1, 0x28
+/* 800B077C 000AD6BC 7C 08 03 A6 */ mtlr r0
+/* 800B0780 000AD6C0 4E 80 00 20 */ blr
+
+.section .data, "wa" # 0x803A8380 - 0x803E6000
+ .balign 8
+"@121":
+ .4byte lbl_800AF204
+ .4byte lbl_800AF20C
+ .4byte lbl_800AF21C
+ .4byte lbl_800AF230
+ .4byte lbl_800AF244
+ .4byte lbl_800AF258
+ .4byte lbl_800AF26C
+ .4byte lbl_800AF280
+ .4byte lbl_800AF294
+ .4byte lbl_800AF2A8
+ .4byte lbl_800AF2B0
+ .4byte lbl_800AF2E0
+ .4byte lbl_800AF2FC
+ .4byte lbl_800AF318
+ .4byte lbl_800AF334
+ .4byte lbl_800AF350
+ .4byte lbl_800AF36C
+ .4byte lbl_800AF388
+ .4byte lbl_800AF3A4
+ .4byte lbl_800AF3C0
+ .4byte lbl_800AF3DC
+ .4byte lbl_800AF3F4
+ .4byte lbl_800AF3F4
+ .4byte lbl_800AF3F4
+ .4byte lbl_800AF3F4
+ .4byte lbl_800AF2C8
+"@207":
+ .4byte lbl_800AF88C
+ .4byte lbl_800AF8A8
+ .4byte lbl_800AF8D4
+ .4byte lbl_800AF8E8
+ .4byte lbl_800AF8FC
+ .4byte lbl_800AF918
+ .4byte lbl_800AF934
+ .4byte lbl_800AF94C
+ .4byte lbl_800AF95C
+ .4byte lbl_800AF96C
+ .4byte lbl_800AF97C
+ .4byte lbl_800AF98C
+ .4byte lbl_800AF998
+ .4byte lbl_800AF998
+ .4byte lbl_800AF998
+ .4byte lbl_800AF998
+ .4byte lbl_800AF8A8
+.section .sdata, "wa" # 0x80408AC0 - 0x804097C0
+cm2hw$400:
+ .4byte 0x00020103
+cm2hw$515:
+ .4byte 0x00020103
+ .4byte 0
+ .4byte 0
diff --git a/asm/Dolphin/gd/GDLight.s b/asm/Dolphin/gd/GDLight.s
new file mode 100644
index 0000000..6e2a25d
--- /dev/null
+++ b/asm/Dolphin/gd/GDLight.s
@@ -0,0 +1,1125 @@
+.include "macros.inc"
+
+.section .text, "ax" # 0x80005600 - 0x8036FBA0
+.global GDSetLightAttn
+GDSetLightAttn:
+/* 800B0784 000AD6C4 7C 08 02 A6 */ mflr r0
+/* 800B0788 000AD6C8 90 01 00 04 */ stw r0, 4(r1)
+/* 800B078C 000AD6CC 7C 60 00 34 */ cntlzw r0, r3
+/* 800B0790 000AD6D0 20 80 00 1F */ subfic r4, r0, 0x1f
+/* 800B0794 000AD6D4 94 21 FF 70 */ stwu r1, -0x90(r1)
+/* 800B0798 000AD6D8 54 80 04 3E */ clrlwi r0, r4, 0x10
+/* 800B079C 000AD6DC 28 00 00 07 */ cmplwi r0, 7
+/* 800B07A0 000AD6E0 DB E1 00 88 */ stfd f31, 0x88(r1)
+/* 800B07A4 000AD6E4 FF E0 30 90 */ fmr f31, f6
+/* 800B07A8 000AD6E8 DB C1 00 80 */ stfd f30, 0x80(r1)
+/* 800B07AC 000AD6EC FF C0 28 90 */ fmr f30, f5
+/* 800B07B0 000AD6F0 DB A1 00 78 */ stfd f29, 0x78(r1)
+/* 800B07B4 000AD6F4 FF A0 20 90 */ fmr f29, f4
+/* 800B07B8 000AD6F8 DB 81 00 70 */ stfd f28, 0x70(r1)
+/* 800B07BC 000AD6FC FF 80 18 90 */ fmr f28, f3
+/* 800B07C0 000AD700 DB 61 00 68 */ stfd f27, 0x68(r1)
+/* 800B07C4 000AD704 FF 60 10 90 */ fmr f27, f2
+/* 800B07C8 000AD708 DB 41 00 60 */ stfd f26, 0x60(r1)
+/* 800B07CC 000AD70C FF 40 08 90 */ fmr f26, f1
+/* 800B07D0 000AD710 93 E1 00 5C */ stw r31, 0x5c(r1)
+/* 800B07D4 000AD714 40 81 00 08 */ ble lbl_800B07DC
+/* 800B07D8 000AD718 38 80 00 00 */ li r4, 0
+lbl_800B07DC:
+/* 800B07DC 000AD71C 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B07E0 000AD720 54 84 24 36 */ rlwinm r4, r4, 4, 0x10, 0x1b
+/* 800B07E4 000AD724 3B E4 06 04 */ addi r31, r4, 0x604
+/* 800B07E8 000AD728 80 65 00 08 */ lwz r3, 8(r5)
+/* 800B07EC 000AD72C 80 05 00 0C */ lwz r0, 0xc(r5)
+/* 800B07F0 000AD730 38 63 00 01 */ addi r3, r3, 1
+/* 800B07F4 000AD734 7C 03 00 40 */ cmplw r3, r0
+/* 800B07F8 000AD738 40 81 00 08 */ ble lbl_800B0800
+/* 800B07FC 000AD73C 4B FF E9 59 */ bl GDOverflowed
+lbl_800B0800:
+/* 800B0800 000AD740 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0804 000AD744 38 A0 00 10 */ li r5, 0x10
+/* 800B0808 000AD748 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B080C 000AD74C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0810 000AD750 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0814 000AD754 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0818 000AD758 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B081C 000AD75C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0820 000AD760 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0824 000AD764 38 63 00 02 */ addi r3, r3, 2
+/* 800B0828 000AD768 7C 03 00 40 */ cmplw r3, r0
+/* 800B082C 000AD76C 40 81 00 08 */ ble lbl_800B0834
+/* 800B0830 000AD770 4B FF E9 25 */ bl GDOverflowed
+lbl_800B0834:
+/* 800B0834 000AD774 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0838 000AD778 38 C0 00 00 */ li r6, 0
+/* 800B083C 000AD77C 38 A0 00 05 */ li r5, 5
+/* 800B0840 000AD780 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0844 000AD784 38 03 00 01 */ addi r0, r3, 1
+/* 800B0848 000AD788 90 04 00 08 */ stw r0, 8(r4)
+/* 800B084C 000AD78C 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B0850 000AD790 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0854 000AD794 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0858 000AD798 38 03 00 01 */ addi r0, r3, 1
+/* 800B085C 000AD79C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0860 000AD7A0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0864 000AD7A4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0868 000AD7A8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B086C 000AD7AC 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0870 000AD7B0 38 63 00 02 */ addi r3, r3, 2
+/* 800B0874 000AD7B4 7C 03 00 40 */ cmplw r3, r0
+/* 800B0878 000AD7B8 40 81 00 08 */ ble lbl_800B0880
+/* 800B087C 000AD7BC 4B FF E8 D9 */ bl GDOverflowed
+lbl_800B0880:
+/* 800B0880 000AD7C0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0884 000AD7C4 57 E5 C6 3E */ rlwinm r5, r31, 0x18, 0x18, 0x1f
+/* 800B0888 000AD7C8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B088C 000AD7CC 38 03 00 01 */ addi r0, r3, 1
+/* 800B0890 000AD7D0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0894 000AD7D4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0898 000AD7D8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B089C 000AD7DC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B08A0 000AD7E0 38 03 00 01 */ addi r0, r3, 1
+/* 800B08A4 000AD7E4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B08A8 000AD7E8 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B08AC 000AD7EC D3 41 00 54 */ stfs f26, 0x54(r1)
+/* 800B08B0 000AD7F0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B08B4 000AD7F4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B08B8 000AD7F8 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B08BC 000AD7FC 38 63 00 04 */ addi r3, r3, 4
+/* 800B08C0 000AD800 7C 03 00 40 */ cmplw r3, r0
+/* 800B08C4 000AD804 40 81 00 08 */ ble lbl_800B08CC
+/* 800B08C8 000AD808 4B FF E8 8D */ bl GDOverflowed
+lbl_800B08CC:
+/* 800B08CC 000AD80C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B08D0 000AD810 80 01 00 54 */ lwz r0, 0x54(r1)
+/* 800B08D4 000AD814 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B08D8 000AD818 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B08DC 000AD81C 38 03 00 01 */ addi r0, r3, 1
+/* 800B08E0 000AD820 90 04 00 08 */ stw r0, 8(r4)
+/* 800B08E4 000AD824 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B08E8 000AD828 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B08EC 000AD82C 80 01 00 54 */ lwz r0, 0x54(r1)
+/* 800B08F0 000AD830 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B08F4 000AD834 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B08F8 000AD838 38 03 00 01 */ addi r0, r3, 1
+/* 800B08FC 000AD83C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0900 000AD840 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0904 000AD844 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0908 000AD848 80 01 00 54 */ lwz r0, 0x54(r1)
+/* 800B090C 000AD84C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0910 000AD850 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B0914 000AD854 38 03 00 01 */ addi r0, r3, 1
+/* 800B0918 000AD858 90 04 00 08 */ stw r0, 8(r4)
+/* 800B091C 000AD85C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0920 000AD860 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0924 000AD864 80 A1 00 54 */ lwz r5, 0x54(r1)
+/* 800B0928 000AD868 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B092C 000AD86C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0930 000AD870 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0934 000AD874 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0938 000AD878 D3 61 00 50 */ stfs f27, 0x50(r1)
+/* 800B093C 000AD87C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0940 000AD880 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0944 000AD884 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0948 000AD888 38 63 00 04 */ addi r3, r3, 4
+/* 800B094C 000AD88C 7C 03 00 40 */ cmplw r3, r0
+/* 800B0950 000AD890 40 81 00 08 */ ble lbl_800B0958
+/* 800B0954 000AD894 4B FF E8 01 */ bl GDOverflowed
+lbl_800B0958:
+/* 800B0958 000AD898 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B095C 000AD89C 80 01 00 50 */ lwz r0, 0x50(r1)
+/* 800B0960 000AD8A0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0964 000AD8A4 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B0968 000AD8A8 38 03 00 01 */ addi r0, r3, 1
+/* 800B096C 000AD8AC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0970 000AD8B0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0974 000AD8B4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0978 000AD8B8 80 01 00 50 */ lwz r0, 0x50(r1)
+/* 800B097C 000AD8BC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0980 000AD8C0 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B0984 000AD8C4 38 03 00 01 */ addi r0, r3, 1
+/* 800B0988 000AD8C8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B098C 000AD8CC 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0990 000AD8D0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0994 000AD8D4 80 01 00 50 */ lwz r0, 0x50(r1)
+/* 800B0998 000AD8D8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B099C 000AD8DC 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B09A0 000AD8E0 38 03 00 01 */ addi r0, r3, 1
+/* 800B09A4 000AD8E4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B09A8 000AD8E8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B09AC 000AD8EC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B09B0 000AD8F0 80 A1 00 50 */ lwz r5, 0x50(r1)
+/* 800B09B4 000AD8F4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B09B8 000AD8F8 38 03 00 01 */ addi r0, r3, 1
+/* 800B09BC 000AD8FC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B09C0 000AD900 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B09C4 000AD904 D3 81 00 4C */ stfs f28, 0x4c(r1)
+/* 800B09C8 000AD908 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B09CC 000AD90C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B09D0 000AD910 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B09D4 000AD914 38 63 00 04 */ addi r3, r3, 4
+/* 800B09D8 000AD918 7C 03 00 40 */ cmplw r3, r0
+/* 800B09DC 000AD91C 40 81 00 08 */ ble lbl_800B09E4
+/* 800B09E0 000AD920 4B FF E7 75 */ bl GDOverflowed
+lbl_800B09E4:
+/* 800B09E4 000AD924 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B09E8 000AD928 80 01 00 4C */ lwz r0, 0x4c(r1)
+/* 800B09EC 000AD92C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B09F0 000AD930 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B09F4 000AD934 38 03 00 01 */ addi r0, r3, 1
+/* 800B09F8 000AD938 90 04 00 08 */ stw r0, 8(r4)
+/* 800B09FC 000AD93C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0A00 000AD940 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0A04 000AD944 80 01 00 4C */ lwz r0, 0x4c(r1)
+/* 800B0A08 000AD948 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0A0C 000AD94C 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B0A10 000AD950 38 03 00 01 */ addi r0, r3, 1
+/* 800B0A14 000AD954 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0A18 000AD958 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0A1C 000AD95C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0A20 000AD960 80 01 00 4C */ lwz r0, 0x4c(r1)
+/* 800B0A24 000AD964 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0A28 000AD968 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B0A2C 000AD96C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0A30 000AD970 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0A34 000AD974 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0A38 000AD978 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0A3C 000AD97C 80 A1 00 4C */ lwz r5, 0x4c(r1)
+/* 800B0A40 000AD980 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0A44 000AD984 38 03 00 01 */ addi r0, r3, 1
+/* 800B0A48 000AD988 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0A4C 000AD98C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0A50 000AD990 D3 A1 00 48 */ stfs f29, 0x48(r1)
+/* 800B0A54 000AD994 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0A58 000AD998 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0A5C 000AD99C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0A60 000AD9A0 38 63 00 04 */ addi r3, r3, 4
+/* 800B0A64 000AD9A4 7C 03 00 40 */ cmplw r3, r0
+/* 800B0A68 000AD9A8 40 81 00 08 */ ble lbl_800B0A70
+/* 800B0A6C 000AD9AC 4B FF E6 E9 */ bl GDOverflowed
+lbl_800B0A70:
+/* 800B0A70 000AD9B0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0A74 000AD9B4 80 01 00 48 */ lwz r0, 0x48(r1)
+/* 800B0A78 000AD9B8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0A7C 000AD9BC 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B0A80 000AD9C0 38 03 00 01 */ addi r0, r3, 1
+/* 800B0A84 000AD9C4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0A88 000AD9C8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0A8C 000AD9CC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0A90 000AD9D0 80 01 00 48 */ lwz r0, 0x48(r1)
+/* 800B0A94 000AD9D4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0A98 000AD9D8 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B0A9C 000AD9DC 38 03 00 01 */ addi r0, r3, 1
+/* 800B0AA0 000AD9E0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0AA4 000AD9E4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0AA8 000AD9E8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0AAC 000AD9EC 80 01 00 48 */ lwz r0, 0x48(r1)
+/* 800B0AB0 000AD9F0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0AB4 000AD9F4 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B0AB8 000AD9F8 38 03 00 01 */ addi r0, r3, 1
+/* 800B0ABC 000AD9FC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0AC0 000ADA00 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0AC4 000ADA04 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0AC8 000ADA08 80 A1 00 48 */ lwz r5, 0x48(r1)
+/* 800B0ACC 000ADA0C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0AD0 000ADA10 38 03 00 01 */ addi r0, r3, 1
+/* 800B0AD4 000ADA14 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0AD8 000ADA18 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0ADC 000ADA1C D3 C1 00 44 */ stfs f30, 0x44(r1)
+/* 800B0AE0 000ADA20 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0AE4 000ADA24 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0AE8 000ADA28 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0AEC 000ADA2C 38 63 00 04 */ addi r3, r3, 4
+/* 800B0AF0 000ADA30 7C 03 00 40 */ cmplw r3, r0
+/* 800B0AF4 000ADA34 40 81 00 08 */ ble lbl_800B0AFC
+/* 800B0AF8 000ADA38 4B FF E6 5D */ bl GDOverflowed
+lbl_800B0AFC:
+/* 800B0AFC 000ADA3C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0B00 000ADA40 80 01 00 44 */ lwz r0, 0x44(r1)
+/* 800B0B04 000ADA44 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0B08 000ADA48 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B0B0C 000ADA4C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0B10 000ADA50 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0B14 000ADA54 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0B18 000ADA58 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0B1C 000ADA5C 80 01 00 44 */ lwz r0, 0x44(r1)
+/* 800B0B20 000ADA60 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0B24 000ADA64 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B0B28 000ADA68 38 03 00 01 */ addi r0, r3, 1
+/* 800B0B2C 000ADA6C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0B30 000ADA70 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0B34 000ADA74 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0B38 000ADA78 80 01 00 44 */ lwz r0, 0x44(r1)
+/* 800B0B3C 000ADA7C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0B40 000ADA80 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B0B44 000ADA84 38 03 00 01 */ addi r0, r3, 1
+/* 800B0B48 000ADA88 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0B4C 000ADA8C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0B50 000ADA90 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0B54 000ADA94 80 A1 00 44 */ lwz r5, 0x44(r1)
+/* 800B0B58 000ADA98 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0B5C 000ADA9C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0B60 000ADAA0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0B64 000ADAA4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0B68 000ADAA8 D3 E1 00 40 */ stfs f31, 0x40(r1)
+/* 800B0B6C 000ADAAC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0B70 000ADAB0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0B74 000ADAB4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0B78 000ADAB8 38 63 00 04 */ addi r3, r3, 4
+/* 800B0B7C 000ADABC 7C 03 00 40 */ cmplw r3, r0
+/* 800B0B80 000ADAC0 40 81 00 08 */ ble lbl_800B0B88
+/* 800B0B84 000ADAC4 4B FF E5 D1 */ bl GDOverflowed
+lbl_800B0B88:
+/* 800B0B88 000ADAC8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0B8C 000ADACC 80 01 00 40 */ lwz r0, 0x40(r1)
+/* 800B0B90 000ADAD0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0B94 000ADAD4 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B0B98 000ADAD8 38 03 00 01 */ addi r0, r3, 1
+/* 800B0B9C 000ADADC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0BA0 000ADAE0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0BA4 000ADAE4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0BA8 000ADAE8 80 01 00 40 */ lwz r0, 0x40(r1)
+/* 800B0BAC 000ADAEC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0BB0 000ADAF0 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B0BB4 000ADAF4 38 03 00 01 */ addi r0, r3, 1
+/* 800B0BB8 000ADAF8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0BBC 000ADAFC 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0BC0 000ADB00 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0BC4 000ADB04 80 01 00 40 */ lwz r0, 0x40(r1)
+/* 800B0BC8 000ADB08 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0BCC 000ADB0C 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B0BD0 000ADB10 38 03 00 01 */ addi r0, r3, 1
+/* 800B0BD4 000ADB14 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0BD8 000ADB18 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0BDC 000ADB1C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0BE0 000ADB20 80 A1 00 40 */ lwz r5, 0x40(r1)
+/* 800B0BE4 000ADB24 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0BE8 000ADB28 38 03 00 01 */ addi r0, r3, 1
+/* 800B0BEC 000ADB2C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0BF0 000ADB30 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0BF4 000ADB34 80 01 00 94 */ lwz r0, 0x94(r1)
+/* 800B0BF8 000ADB38 CB E1 00 88 */ lfd f31, 0x88(r1)
+/* 800B0BFC 000ADB3C CB C1 00 80 */ lfd f30, 0x80(r1)
+/* 800B0C00 000ADB40 CB A1 00 78 */ lfd f29, 0x78(r1)
+/* 800B0C04 000ADB44 CB 81 00 70 */ lfd f28, 0x70(r1)
+/* 800B0C08 000ADB48 CB 61 00 68 */ lfd f27, 0x68(r1)
+/* 800B0C0C 000ADB4C CB 41 00 60 */ lfd f26, 0x60(r1)
+/* 800B0C10 000ADB50 83 E1 00 5C */ lwz r31, 0x5c(r1)
+/* 800B0C14 000ADB54 38 21 00 90 */ addi r1, r1, 0x90
+/* 800B0C18 000ADB58 7C 08 03 A6 */ mtlr r0
+/* 800B0C1C 000ADB5C 4E 80 00 20 */ blr
+
+.global GDSetLightColor
+GDSetLightColor:
+/* 800B0C20 000ADB60 7C 08 02 A6 */ mflr r0
+/* 800B0C24 000ADB64 90 01 00 04 */ stw r0, 4(r1)
+/* 800B0C28 000ADB68 7C 60 00 34 */ cntlzw r0, r3
+/* 800B0C2C 000ADB6C 20 E0 00 1F */ subfic r7, r0, 0x1f
+/* 800B0C30 000ADB70 94 21 FF E0 */ stwu r1, -0x20(r1)
+/* 800B0C34 000ADB74 54 E0 04 3E */ clrlwi r0, r7, 0x10
+/* 800B0C38 000ADB78 28 00 00 07 */ cmplwi r0, 7
+/* 800B0C3C 000ADB7C 93 E1 00 1C */ stw r31, 0x1c(r1)
+/* 800B0C40 000ADB80 93 C1 00 18 */ stw r30, 0x18(r1)
+/* 800B0C44 000ADB84 88 64 00 01 */ lbz r3, 1(r4)
+/* 800B0C48 000ADB88 88 A4 00 00 */ lbz r5, 0(r4)
+/* 800B0C4C 000ADB8C 88 C4 00 02 */ lbz r6, 2(r4)
+/* 800B0C50 000ADB90 54 63 80 1E */ slwi r3, r3, 0x10
+/* 800B0C54 000ADB94 50 A3 C0 0E */ rlwimi r3, r5, 0x18, 0, 7
+/* 800B0C58 000ADB98 88 84 00 03 */ lbz r4, 3(r4)
+/* 800B0C5C 000ADB9C 50 C3 44 2E */ rlwimi r3, r6, 8, 0x10, 0x17
+/* 800B0C60 000ADBA0 7C 9E 1B 78 */ or r30, r4, r3
+/* 800B0C64 000ADBA4 40 81 00 08 */ ble lbl_800B0C6C
+/* 800B0C68 000ADBA8 38 E0 00 00 */ li r7, 0
+lbl_800B0C6C:
+/* 800B0C6C 000ADBAC 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B0C70 000ADBB0 54 E4 24 36 */ rlwinm r4, r7, 4, 0x10, 0x1b
+/* 800B0C74 000ADBB4 3B E4 06 03 */ addi r31, r4, 0x603
+/* 800B0C78 000ADBB8 80 65 00 08 */ lwz r3, 8(r5)
+/* 800B0C7C 000ADBBC 80 05 00 0C */ lwz r0, 0xc(r5)
+/* 800B0C80 000ADBC0 38 63 00 01 */ addi r3, r3, 1
+/* 800B0C84 000ADBC4 7C 03 00 40 */ cmplw r3, r0
+/* 800B0C88 000ADBC8 40 81 00 08 */ ble lbl_800B0C90
+/* 800B0C8C 000ADBCC 4B FF E4 C9 */ bl GDOverflowed
+lbl_800B0C90:
+/* 800B0C90 000ADBD0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0C94 000ADBD4 38 A0 00 10 */ li r5, 0x10
+/* 800B0C98 000ADBD8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0C9C 000ADBDC 38 03 00 01 */ addi r0, r3, 1
+/* 800B0CA0 000ADBE0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0CA4 000ADBE4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0CA8 000ADBE8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0CAC 000ADBEC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0CB0 000ADBF0 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0CB4 000ADBF4 38 63 00 02 */ addi r3, r3, 2
+/* 800B0CB8 000ADBF8 7C 03 00 40 */ cmplw r3, r0
+/* 800B0CBC 000ADBFC 40 81 00 08 */ ble lbl_800B0CC4
+/* 800B0CC0 000ADC00 4B FF E4 95 */ bl GDOverflowed
+lbl_800B0CC4:
+/* 800B0CC4 000ADC04 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0CC8 000ADC08 38 A0 00 00 */ li r5, 0
+/* 800B0CCC 000ADC0C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0CD0 000ADC10 38 03 00 01 */ addi r0, r3, 1
+/* 800B0CD4 000ADC14 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0CD8 000ADC18 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0CDC 000ADC1C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0CE0 000ADC20 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0CE4 000ADC24 38 03 00 01 */ addi r0, r3, 1
+/* 800B0CE8 000ADC28 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0CEC 000ADC2C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0CF0 000ADC30 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0CF4 000ADC34 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0CF8 000ADC38 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0CFC 000ADC3C 38 63 00 02 */ addi r3, r3, 2
+/* 800B0D00 000ADC40 7C 03 00 40 */ cmplw r3, r0
+/* 800B0D04 000ADC44 40 81 00 08 */ ble lbl_800B0D0C
+/* 800B0D08 000ADC48 4B FF E4 4D */ bl GDOverflowed
+lbl_800B0D0C:
+/* 800B0D0C 000ADC4C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0D10 000ADC50 57 E5 C6 3E */ rlwinm r5, r31, 0x18, 0x18, 0x1f
+/* 800B0D14 000ADC54 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0D18 000ADC58 38 03 00 01 */ addi r0, r3, 1
+/* 800B0D1C 000ADC5C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0D20 000ADC60 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0D24 000ADC64 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0D28 000ADC68 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0D2C 000ADC6C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0D30 000ADC70 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0D34 000ADC74 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B0D38 000ADC78 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0D3C 000ADC7C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0D40 000ADC80 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0D44 000ADC84 38 63 00 04 */ addi r3, r3, 4
+/* 800B0D48 000ADC88 7C 03 00 40 */ cmplw r3, r0
+/* 800B0D4C 000ADC8C 40 81 00 08 */ ble lbl_800B0D54
+/* 800B0D50 000ADC90 4B FF E4 05 */ bl GDOverflowed
+lbl_800B0D54:
+/* 800B0D54 000ADC94 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0D58 000ADC98 57 C7 46 3E */ srwi r7, r30, 0x18
+/* 800B0D5C 000ADC9C 57 C6 86 3E */ rlwinm r6, r30, 0x10, 0x18, 0x1f
+/* 800B0D60 000ADCA0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0D64 000ADCA4 57 C5 C6 3E */ rlwinm r5, r30, 0x18, 0x18, 0x1f
+/* 800B0D68 000ADCA8 38 03 00 01 */ addi r0, r3, 1
+/* 800B0D6C 000ADCAC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0D70 000ADCB0 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B0D74 000ADCB4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0D78 000ADCB8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0D7C 000ADCBC 38 03 00 01 */ addi r0, r3, 1
+/* 800B0D80 000ADCC0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0D84 000ADCC4 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B0D88 000ADCC8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0D8C 000ADCCC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0D90 000ADCD0 38 03 00 01 */ addi r0, r3, 1
+/* 800B0D94 000ADCD4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0D98 000ADCD8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0D9C 000ADCDC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0DA0 000ADCE0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0DA4 000ADCE4 38 03 00 01 */ addi r0, r3, 1
+/* 800B0DA8 000ADCE8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0DAC 000ADCEC 9B C3 00 00 */ stb r30, 0(r3)
+/* 800B0DB0 000ADCF0 80 01 00 24 */ lwz r0, 0x24(r1)
+/* 800B0DB4 000ADCF4 83 E1 00 1C */ lwz r31, 0x1c(r1)
+/* 800B0DB8 000ADCF8 83 C1 00 18 */ lwz r30, 0x18(r1)
+/* 800B0DBC 000ADCFC 38 21 00 20 */ addi r1, r1, 0x20
+/* 800B0DC0 000ADD00 7C 08 03 A6 */ mtlr r0
+/* 800B0DC4 000ADD04 4E 80 00 20 */ blr
+
+.global GDSetLightPos
+GDSetLightPos:
+/* 800B0DC8 000ADD08 7C 08 02 A6 */ mflr r0
+/* 800B0DCC 000ADD0C 90 01 00 04 */ stw r0, 4(r1)
+/* 800B0DD0 000ADD10 7C 60 00 34 */ cntlzw r0, r3
+/* 800B0DD4 000ADD14 20 80 00 1F */ subfic r4, r0, 0x1f
+/* 800B0DD8 000ADD18 94 21 FF A8 */ stwu r1, -0x58(r1)
+/* 800B0DDC 000ADD1C 54 80 04 3E */ clrlwi r0, r4, 0x10
+/* 800B0DE0 000ADD20 28 00 00 07 */ cmplwi r0, 7
+/* 800B0DE4 000ADD24 DB E1 00 50 */ stfd f31, 0x50(r1)
+/* 800B0DE8 000ADD28 FF E0 18 90 */ fmr f31, f3
+/* 800B0DEC 000ADD2C DB C1 00 48 */ stfd f30, 0x48(r1)
+/* 800B0DF0 000ADD30 FF C0 10 90 */ fmr f30, f2
+/* 800B0DF4 000ADD34 DB A1 00 40 */ stfd f29, 0x40(r1)
+/* 800B0DF8 000ADD38 FF A0 08 90 */ fmr f29, f1
+/* 800B0DFC 000ADD3C 93 E1 00 3C */ stw r31, 0x3c(r1)
+/* 800B0E00 000ADD40 40 81 00 08 */ ble lbl_800B0E08
+/* 800B0E04 000ADD44 38 80 00 00 */ li r4, 0
+lbl_800B0E08:
+/* 800B0E08 000ADD48 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B0E0C 000ADD4C 54 84 24 36 */ rlwinm r4, r4, 4, 0x10, 0x1b
+/* 800B0E10 000ADD50 3B E4 06 0A */ addi r31, r4, 0x60a
+/* 800B0E14 000ADD54 80 65 00 08 */ lwz r3, 8(r5)
+/* 800B0E18 000ADD58 80 05 00 0C */ lwz r0, 0xc(r5)
+/* 800B0E1C 000ADD5C 38 63 00 01 */ addi r3, r3, 1
+/* 800B0E20 000ADD60 7C 03 00 40 */ cmplw r3, r0
+/* 800B0E24 000ADD64 40 81 00 08 */ ble lbl_800B0E2C
+/* 800B0E28 000ADD68 4B FF E3 2D */ bl GDOverflowed
+lbl_800B0E2C:
+/* 800B0E2C 000ADD6C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0E30 000ADD70 38 A0 00 10 */ li r5, 0x10
+/* 800B0E34 000ADD74 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0E38 000ADD78 38 03 00 01 */ addi r0, r3, 1
+/* 800B0E3C 000ADD7C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0E40 000ADD80 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0E44 000ADD84 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0E48 000ADD88 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0E4C 000ADD8C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0E50 000ADD90 38 63 00 02 */ addi r3, r3, 2
+/* 800B0E54 000ADD94 7C 03 00 40 */ cmplw r3, r0
+/* 800B0E58 000ADD98 40 81 00 08 */ ble lbl_800B0E60
+/* 800B0E5C 000ADD9C 4B FF E2 F9 */ bl GDOverflowed
+lbl_800B0E60:
+/* 800B0E60 000ADDA0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0E64 000ADDA4 38 C0 00 00 */ li r6, 0
+/* 800B0E68 000ADDA8 38 A0 00 02 */ li r5, 2
+/* 800B0E6C 000ADDAC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0E70 000ADDB0 38 03 00 01 */ addi r0, r3, 1
+/* 800B0E74 000ADDB4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0E78 000ADDB8 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B0E7C 000ADDBC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0E80 000ADDC0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0E84 000ADDC4 38 03 00 01 */ addi r0, r3, 1
+/* 800B0E88 000ADDC8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0E8C 000ADDCC 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0E90 000ADDD0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0E94 000ADDD4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0E98 000ADDD8 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0E9C 000ADDDC 38 63 00 02 */ addi r3, r3, 2
+/* 800B0EA0 000ADDE0 7C 03 00 40 */ cmplw r3, r0
+/* 800B0EA4 000ADDE4 40 81 00 08 */ ble lbl_800B0EAC
+/* 800B0EA8 000ADDE8 4B FF E2 AD */ bl GDOverflowed
+lbl_800B0EAC:
+/* 800B0EAC 000ADDEC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0EB0 000ADDF0 57 E5 C6 3E */ rlwinm r5, r31, 0x18, 0x18, 0x1f
+/* 800B0EB4 000ADDF4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0EB8 000ADDF8 38 03 00 01 */ addi r0, r3, 1
+/* 800B0EBC 000ADDFC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0EC0 000ADE00 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0EC4 000ADE04 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0EC8 000ADE08 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0ECC 000ADE0C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0ED0 000ADE10 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0ED4 000ADE14 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B0ED8 000ADE18 D3 A1 00 30 */ stfs f29, 0x30(r1)
+/* 800B0EDC 000ADE1C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0EE0 000ADE20 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0EE4 000ADE24 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0EE8 000ADE28 38 63 00 04 */ addi r3, r3, 4
+/* 800B0EEC 000ADE2C 7C 03 00 40 */ cmplw r3, r0
+/* 800B0EF0 000ADE30 40 81 00 08 */ ble lbl_800B0EF8
+/* 800B0EF4 000ADE34 4B FF E2 61 */ bl GDOverflowed
+lbl_800B0EF8:
+/* 800B0EF8 000ADE38 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0EFC 000ADE3C 80 01 00 30 */ lwz r0, 0x30(r1)
+/* 800B0F00 000ADE40 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0F04 000ADE44 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B0F08 000ADE48 38 03 00 01 */ addi r0, r3, 1
+/* 800B0F0C 000ADE4C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0F10 000ADE50 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0F14 000ADE54 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0F18 000ADE58 80 01 00 30 */ lwz r0, 0x30(r1)
+/* 800B0F1C 000ADE5C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0F20 000ADE60 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B0F24 000ADE64 38 03 00 01 */ addi r0, r3, 1
+/* 800B0F28 000ADE68 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0F2C 000ADE6C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0F30 000ADE70 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0F34 000ADE74 80 01 00 30 */ lwz r0, 0x30(r1)
+/* 800B0F38 000ADE78 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0F3C 000ADE7C 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B0F40 000ADE80 38 03 00 01 */ addi r0, r3, 1
+/* 800B0F44 000ADE84 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0F48 000ADE88 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0F4C 000ADE8C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0F50 000ADE90 80 A1 00 30 */ lwz r5, 0x30(r1)
+/* 800B0F54 000ADE94 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0F58 000ADE98 38 03 00 01 */ addi r0, r3, 1
+/* 800B0F5C 000ADE9C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0F60 000ADEA0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0F64 000ADEA4 D3 C1 00 2C */ stfs f30, 0x2c(r1)
+/* 800B0F68 000ADEA8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0F6C 000ADEAC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0F70 000ADEB0 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B0F74 000ADEB4 38 63 00 04 */ addi r3, r3, 4
+/* 800B0F78 000ADEB8 7C 03 00 40 */ cmplw r3, r0
+/* 800B0F7C 000ADEBC 40 81 00 08 */ ble lbl_800B0F84
+/* 800B0F80 000ADEC0 4B FF E1 D5 */ bl GDOverflowed
+lbl_800B0F84:
+/* 800B0F84 000ADEC4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0F88 000ADEC8 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800B0F8C 000ADECC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0F90 000ADED0 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B0F94 000ADED4 38 03 00 01 */ addi r0, r3, 1
+/* 800B0F98 000ADED8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0F9C 000ADEDC 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0FA0 000ADEE0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0FA4 000ADEE4 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800B0FA8 000ADEE8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0FAC 000ADEEC 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B0FB0 000ADEF0 38 03 00 01 */ addi r0, r3, 1
+/* 800B0FB4 000ADEF4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0FB8 000ADEF8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0FBC 000ADEFC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0FC0 000ADF00 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800B0FC4 000ADF04 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0FC8 000ADF08 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B0FCC 000ADF0C 38 03 00 01 */ addi r0, r3, 1
+/* 800B0FD0 000ADF10 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0FD4 000ADF14 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0FD8 000ADF18 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0FDC 000ADF1C 80 A1 00 2C */ lwz r5, 0x2c(r1)
+/* 800B0FE0 000ADF20 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0FE4 000ADF24 38 03 00 01 */ addi r0, r3, 1
+/* 800B0FE8 000ADF28 90 04 00 08 */ stw r0, 8(r4)
+/* 800B0FEC 000ADF2C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B0FF0 000ADF30 D3 E1 00 28 */ stfs f31, 0x28(r1)
+/* 800B0FF4 000ADF34 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B0FF8 000ADF38 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B0FFC 000ADF3C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1000 000ADF40 38 63 00 04 */ addi r3, r3, 4
+/* 800B1004 000ADF44 7C 03 00 40 */ cmplw r3, r0
+/* 800B1008 000ADF48 40 81 00 08 */ ble lbl_800B1010
+/* 800B100C 000ADF4C 4B FF E1 49 */ bl GDOverflowed
+lbl_800B1010:
+/* 800B1010 000ADF50 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1014 000ADF54 80 01 00 28 */ lwz r0, 0x28(r1)
+/* 800B1018 000ADF58 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B101C 000ADF5C 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B1020 000ADF60 38 03 00 01 */ addi r0, r3, 1
+/* 800B1024 000ADF64 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1028 000ADF68 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B102C 000ADF6C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1030 000ADF70 80 01 00 28 */ lwz r0, 0x28(r1)
+/* 800B1034 000ADF74 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1038 000ADF78 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B103C 000ADF7C 38 03 00 01 */ addi r0, r3, 1
+/* 800B1040 000ADF80 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1044 000ADF84 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1048 000ADF88 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B104C 000ADF8C 80 01 00 28 */ lwz r0, 0x28(r1)
+/* 800B1050 000ADF90 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1054 000ADF94 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B1058 000ADF98 38 03 00 01 */ addi r0, r3, 1
+/* 800B105C 000ADF9C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1060 000ADFA0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1064 000ADFA4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1068 000ADFA8 80 A1 00 28 */ lwz r5, 0x28(r1)
+/* 800B106C 000ADFAC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1070 000ADFB0 38 03 00 01 */ addi r0, r3, 1
+/* 800B1074 000ADFB4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1078 000ADFB8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B107C 000ADFBC 80 01 00 5C */ lwz r0, 0x5c(r1)
+/* 800B1080 000ADFC0 CB E1 00 50 */ lfd f31, 0x50(r1)
+/* 800B1084 000ADFC4 CB C1 00 48 */ lfd f30, 0x48(r1)
+/* 800B1088 000ADFC8 CB A1 00 40 */ lfd f29, 0x40(r1)
+/* 800B108C 000ADFCC 83 E1 00 3C */ lwz r31, 0x3c(r1)
+/* 800B1090 000ADFD0 38 21 00 58 */ addi r1, r1, 0x58
+/* 800B1094 000ADFD4 7C 08 03 A6 */ mtlr r0
+/* 800B1098 000ADFD8 4E 80 00 20 */ blr
+
+.global GDSetLightDir
+GDSetLightDir:
+/* 800B109C 000ADFDC 7C 08 02 A6 */ mflr r0
+/* 800B10A0 000ADFE0 90 01 00 04 */ stw r0, 4(r1)
+/* 800B10A4 000ADFE4 7C 60 00 34 */ cntlzw r0, r3
+/* 800B10A8 000ADFE8 20 80 00 1F */ subfic r4, r0, 0x1f
+/* 800B10AC 000ADFEC 94 21 FF A8 */ stwu r1, -0x58(r1)
+/* 800B10B0 000ADFF0 54 80 04 3E */ clrlwi r0, r4, 0x10
+/* 800B10B4 000ADFF4 28 00 00 07 */ cmplwi r0, 7
+/* 800B10B8 000ADFF8 DB E1 00 50 */ stfd f31, 0x50(r1)
+/* 800B10BC 000ADFFC FF E0 18 90 */ fmr f31, f3
+/* 800B10C0 000AE000 DB C1 00 48 */ stfd f30, 0x48(r1)
+/* 800B10C4 000AE004 FF C0 10 90 */ fmr f30, f2
+/* 800B10C8 000AE008 DB A1 00 40 */ stfd f29, 0x40(r1)
+/* 800B10CC 000AE00C FF A0 08 90 */ fmr f29, f1
+/* 800B10D0 000AE010 93 E1 00 3C */ stw r31, 0x3c(r1)
+/* 800B10D4 000AE014 40 81 00 08 */ ble lbl_800B10DC
+/* 800B10D8 000AE018 38 80 00 00 */ li r4, 0
+lbl_800B10DC:
+/* 800B10DC 000AE01C 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B10E0 000AE020 54 84 24 36 */ rlwinm r4, r4, 4, 0x10, 0x1b
+/* 800B10E4 000AE024 3B E4 06 0D */ addi r31, r4, 0x60d
+/* 800B10E8 000AE028 80 65 00 08 */ lwz r3, 8(r5)
+/* 800B10EC 000AE02C 80 05 00 0C */ lwz r0, 0xc(r5)
+/* 800B10F0 000AE030 38 63 00 01 */ addi r3, r3, 1
+/* 800B10F4 000AE034 7C 03 00 40 */ cmplw r3, r0
+/* 800B10F8 000AE038 40 81 00 08 */ ble lbl_800B1100
+/* 800B10FC 000AE03C 4B FF E0 59 */ bl GDOverflowed
+lbl_800B1100:
+/* 800B1100 000AE040 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1104 000AE044 38 A0 00 10 */ li r5, 0x10
+/* 800B1108 000AE048 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B110C 000AE04C 38 03 00 01 */ addi r0, r3, 1
+/* 800B1110 000AE050 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1114 000AE054 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1118 000AE058 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B111C 000AE05C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1120 000AE060 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1124 000AE064 38 63 00 02 */ addi r3, r3, 2
+/* 800B1128 000AE068 7C 03 00 40 */ cmplw r3, r0
+/* 800B112C 000AE06C 40 81 00 08 */ ble lbl_800B1134
+/* 800B1130 000AE070 4B FF E0 25 */ bl GDOverflowed
+lbl_800B1134:
+/* 800B1134 000AE074 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1138 000AE078 38 C0 00 00 */ li r6, 0
+/* 800B113C 000AE07C 38 A0 00 02 */ li r5, 2
+/* 800B1140 000AE080 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1144 000AE084 38 03 00 01 */ addi r0, r3, 1
+/* 800B1148 000AE088 90 04 00 08 */ stw r0, 8(r4)
+/* 800B114C 000AE08C 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B1150 000AE090 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1154 000AE094 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1158 000AE098 38 03 00 01 */ addi r0, r3, 1
+/* 800B115C 000AE09C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1160 000AE0A0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1164 000AE0A4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1168 000AE0A8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B116C 000AE0AC 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1170 000AE0B0 38 63 00 02 */ addi r3, r3, 2
+/* 800B1174 000AE0B4 7C 03 00 40 */ cmplw r3, r0
+/* 800B1178 000AE0B8 40 81 00 08 */ ble lbl_800B1180
+/* 800B117C 000AE0BC 4B FF DF D9 */ bl GDOverflowed
+lbl_800B1180:
+/* 800B1180 000AE0C0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1184 000AE0C4 57 E5 C6 3E */ rlwinm r5, r31, 0x18, 0x18, 0x1f
+/* 800B1188 000AE0C8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B118C 000AE0CC 38 03 00 01 */ addi r0, r3, 1
+/* 800B1190 000AE0D0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1194 000AE0D4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1198 000AE0D8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B119C 000AE0DC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B11A0 000AE0E0 38 03 00 01 */ addi r0, r3, 1
+/* 800B11A4 000AE0E4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B11A8 000AE0E8 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B11AC 000AE0EC D3 A1 00 30 */ stfs f29, 0x30(r1)
+/* 800B11B0 000AE0F0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B11B4 000AE0F4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B11B8 000AE0F8 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B11BC 000AE0FC 38 63 00 04 */ addi r3, r3, 4
+/* 800B11C0 000AE100 7C 03 00 40 */ cmplw r3, r0
+/* 800B11C4 000AE104 40 81 00 08 */ ble lbl_800B11CC
+/* 800B11C8 000AE108 4B FF DF 8D */ bl GDOverflowed
+lbl_800B11CC:
+/* 800B11CC 000AE10C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B11D0 000AE110 80 01 00 30 */ lwz r0, 0x30(r1)
+/* 800B11D4 000AE114 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B11D8 000AE118 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B11DC 000AE11C 38 03 00 01 */ addi r0, r3, 1
+/* 800B11E0 000AE120 90 04 00 08 */ stw r0, 8(r4)
+/* 800B11E4 000AE124 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B11E8 000AE128 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B11EC 000AE12C 80 01 00 30 */ lwz r0, 0x30(r1)
+/* 800B11F0 000AE130 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B11F4 000AE134 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B11F8 000AE138 38 03 00 01 */ addi r0, r3, 1
+/* 800B11FC 000AE13C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1200 000AE140 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1204 000AE144 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1208 000AE148 80 01 00 30 */ lwz r0, 0x30(r1)
+/* 800B120C 000AE14C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1210 000AE150 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B1214 000AE154 38 03 00 01 */ addi r0, r3, 1
+/* 800B1218 000AE158 90 04 00 08 */ stw r0, 8(r4)
+/* 800B121C 000AE15C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1220 000AE160 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1224 000AE164 80 A1 00 30 */ lwz r5, 0x30(r1)
+/* 800B1228 000AE168 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B122C 000AE16C 38 03 00 01 */ addi r0, r3, 1
+/* 800B1230 000AE170 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1234 000AE174 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1238 000AE178 D3 C1 00 2C */ stfs f30, 0x2c(r1)
+/* 800B123C 000AE17C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1240 000AE180 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1244 000AE184 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1248 000AE188 38 63 00 04 */ addi r3, r3, 4
+/* 800B124C 000AE18C 7C 03 00 40 */ cmplw r3, r0
+/* 800B1250 000AE190 40 81 00 08 */ ble lbl_800B1258
+/* 800B1254 000AE194 4B FF DF 01 */ bl GDOverflowed
+lbl_800B1258:
+/* 800B1258 000AE198 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B125C 000AE19C 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800B1260 000AE1A0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1264 000AE1A4 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B1268 000AE1A8 38 03 00 01 */ addi r0, r3, 1
+/* 800B126C 000AE1AC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1270 000AE1B0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1274 000AE1B4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1278 000AE1B8 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800B127C 000AE1BC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1280 000AE1C0 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B1284 000AE1C4 38 03 00 01 */ addi r0, r3, 1
+/* 800B1288 000AE1C8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B128C 000AE1CC 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1290 000AE1D0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1294 000AE1D4 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800B1298 000AE1D8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B129C 000AE1DC 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B12A0 000AE1E0 38 03 00 01 */ addi r0, r3, 1
+/* 800B12A4 000AE1E4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B12A8 000AE1E8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B12AC 000AE1EC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B12B0 000AE1F0 80 A1 00 2C */ lwz r5, 0x2c(r1)
+/* 800B12B4 000AE1F4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B12B8 000AE1F8 38 03 00 01 */ addi r0, r3, 1
+/* 800B12BC 000AE1FC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B12C0 000AE200 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B12C4 000AE204 D3 E1 00 28 */ stfs f31, 0x28(r1)
+/* 800B12C8 000AE208 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B12CC 000AE20C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B12D0 000AE210 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B12D4 000AE214 38 63 00 04 */ addi r3, r3, 4
+/* 800B12D8 000AE218 7C 03 00 40 */ cmplw r3, r0
+/* 800B12DC 000AE21C 40 81 00 08 */ ble lbl_800B12E4
+/* 800B12E0 000AE220 4B FF DE 75 */ bl GDOverflowed
+lbl_800B12E4:
+/* 800B12E4 000AE224 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B12E8 000AE228 80 01 00 28 */ lwz r0, 0x28(r1)
+/* 800B12EC 000AE22C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B12F0 000AE230 54 05 46 3E */ srwi r5, r0, 0x18
+/* 800B12F4 000AE234 38 03 00 01 */ addi r0, r3, 1
+/* 800B12F8 000AE238 90 04 00 08 */ stw r0, 8(r4)
+/* 800B12FC 000AE23C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1300 000AE240 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1304 000AE244 80 01 00 28 */ lwz r0, 0x28(r1)
+/* 800B1308 000AE248 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B130C 000AE24C 54 05 86 3E */ rlwinm r5, r0, 0x10, 0x18, 0x1f
+/* 800B1310 000AE250 38 03 00 01 */ addi r0, r3, 1
+/* 800B1314 000AE254 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1318 000AE258 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B131C 000AE25C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1320 000AE260 80 01 00 28 */ lwz r0, 0x28(r1)
+/* 800B1324 000AE264 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1328 000AE268 54 05 C6 3E */ rlwinm r5, r0, 0x18, 0x18, 0x1f
+/* 800B132C 000AE26C 38 03 00 01 */ addi r0, r3, 1
+/* 800B1330 000AE270 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1334 000AE274 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1338 000AE278 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B133C 000AE27C 80 A1 00 28 */ lwz r5, 0x28(r1)
+/* 800B1340 000AE280 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1344 000AE284 38 03 00 01 */ addi r0, r3, 1
+/* 800B1348 000AE288 90 04 00 08 */ stw r0, 8(r4)
+/* 800B134C 000AE28C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1350 000AE290 80 01 00 5C */ lwz r0, 0x5c(r1)
+/* 800B1354 000AE294 CB E1 00 50 */ lfd f31, 0x50(r1)
+/* 800B1358 000AE298 CB C1 00 48 */ lfd f30, 0x48(r1)
+/* 800B135C 000AE29C CB A1 00 40 */ lfd f29, 0x40(r1)
+/* 800B1360 000AE2A0 83 E1 00 3C */ lwz r31, 0x3c(r1)
+/* 800B1364 000AE2A4 38 21 00 58 */ addi r1, r1, 0x58
+/* 800B1368 000AE2A8 7C 08 03 A6 */ mtlr r0
+/* 800B136C 000AE2AC 4E 80 00 20 */ blr
+
+.global GDSetChanMatColor
+GDSetChanMatColor:
+/* 800B1370 000AE2B0 7C 08 02 A6 */ mflr r0
+/* 800B1374 000AE2B4 90 01 00 04 */ stw r0, 4(r1)
+/* 800B1378 000AE2B8 94 21 FF E8 */ stwu r1, -0x18(r1)
+/* 800B137C 000AE2BC 93 E1 00 14 */ stw r31, 0x14(r1)
+/* 800B1380 000AE2C0 93 C1 00 10 */ stw r30, 0x10(r1)
+/* 800B1384 000AE2C4 7C 7E 1B 78 */ mr r30, r3
+/* 800B1388 000AE2C8 81 0D 95 B8 */ lwz r8, __GDCurrentDL@sda21(r13)
+/* 800B138C 000AE2CC 88 04 00 01 */ lbz r0, 1(r4)
+/* 800B1390 000AE2D0 80 68 00 08 */ lwz r3, 8(r8)
+/* 800B1394 000AE2D4 54 05 80 1E */ slwi r5, r0, 0x10
+/* 800B1398 000AE2D8 80 08 00 0C */ lwz r0, 0xc(r8)
+/* 800B139C 000AE2DC 88 C4 00 00 */ lbz r6, 0(r4)
+/* 800B13A0 000AE2E0 38 63 00 01 */ addi r3, r3, 1
+/* 800B13A4 000AE2E4 88 E4 00 02 */ lbz r7, 2(r4)
+/* 800B13A8 000AE2E8 7C 03 00 40 */ cmplw r3, r0
+/* 800B13AC 000AE2EC 50 C5 C0 0E */ rlwimi r5, r6, 0x18, 0, 7
+/* 800B13B0 000AE2F0 88 84 00 03 */ lbz r4, 3(r4)
+/* 800B13B4 000AE2F4 50 E5 44 2E */ rlwimi r5, r7, 8, 0x10, 0x17
+/* 800B13B8 000AE2F8 7C 9F 2B 78 */ or r31, r4, r5
+/* 800B13BC 000AE2FC 40 81 00 08 */ ble lbl_800B13C4
+/* 800B13C0 000AE300 4B FF DD 95 */ bl GDOverflowed
+lbl_800B13C4:
+/* 800B13C4 000AE304 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B13C8 000AE308 38 A0 00 10 */ li r5, 0x10
+/* 800B13CC 000AE30C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B13D0 000AE310 38 03 00 01 */ addi r0, r3, 1
+/* 800B13D4 000AE314 90 04 00 08 */ stw r0, 8(r4)
+/* 800B13D8 000AE318 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B13DC 000AE31C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B13E0 000AE320 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B13E4 000AE324 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B13E8 000AE328 38 63 00 02 */ addi r3, r3, 2
+/* 800B13EC 000AE32C 7C 03 00 40 */ cmplw r3, r0
+/* 800B13F0 000AE330 40 81 00 08 */ ble lbl_800B13F8
+/* 800B13F4 000AE334 4B FF DD 61 */ bl GDOverflowed
+lbl_800B13F8:
+/* 800B13F8 000AE338 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B13FC 000AE33C 38 A0 00 00 */ li r5, 0
+/* 800B1400 000AE340 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1404 000AE344 38 03 00 01 */ addi r0, r3, 1
+/* 800B1408 000AE348 90 04 00 08 */ stw r0, 8(r4)
+/* 800B140C 000AE34C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1410 000AE350 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1414 000AE354 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1418 000AE358 38 03 00 01 */ addi r0, r3, 1
+/* 800B141C 000AE35C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1420 000AE360 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1424 000AE364 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1428 000AE368 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B142C 000AE36C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1430 000AE370 38 63 00 02 */ addi r3, r3, 2
+/* 800B1434 000AE374 7C 03 00 40 */ cmplw r3, r0
+/* 800B1438 000AE378 40 81 00 08 */ ble lbl_800B1440
+/* 800B143C 000AE37C 4B FF DD 19 */ bl GDOverflowed
+lbl_800B1440:
+/* 800B1440 000AE380 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1444 000AE384 57 C3 07 FE */ clrlwi r3, r30, 0x1f
+/* 800B1448 000AE388 38 C3 10 0C */ addi r6, r3, 0x100c
+/* 800B144C 000AE38C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1450 000AE390 54 C6 04 3E */ clrlwi r6, r6, 0x10
+/* 800B1454 000AE394 7C C5 46 70 */ srawi r5, r6, 8
+/* 800B1458 000AE398 38 03 00 01 */ addi r0, r3, 1
+/* 800B145C 000AE39C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1460 000AE3A0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1464 000AE3A4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1468 000AE3A8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B146C 000AE3AC 38 03 00 01 */ addi r0, r3, 1
+/* 800B1470 000AE3B0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1474 000AE3B4 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B1478 000AE3B8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B147C 000AE3BC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1480 000AE3C0 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1484 000AE3C4 38 63 00 04 */ addi r3, r3, 4
+/* 800B1488 000AE3C8 7C 03 00 40 */ cmplw r3, r0
+/* 800B148C 000AE3CC 40 81 00 08 */ ble lbl_800B1494
+/* 800B1490 000AE3D0 4B FF DC C5 */ bl GDOverflowed
+lbl_800B1494:
+/* 800B1494 000AE3D4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1498 000AE3D8 57 E7 46 3E */ srwi r7, r31, 0x18
+/* 800B149C 000AE3DC 57 E6 86 3E */ rlwinm r6, r31, 0x10, 0x18, 0x1f
+/* 800B14A0 000AE3E0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B14A4 000AE3E4 57 E5 C6 3E */ rlwinm r5, r31, 0x18, 0x18, 0x1f
+/* 800B14A8 000AE3E8 38 03 00 01 */ addi r0, r3, 1
+/* 800B14AC 000AE3EC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B14B0 000AE3F0 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B14B4 000AE3F4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B14B8 000AE3F8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B14BC 000AE3FC 38 03 00 01 */ addi r0, r3, 1
+/* 800B14C0 000AE400 90 04 00 08 */ stw r0, 8(r4)
+/* 800B14C4 000AE404 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B14C8 000AE408 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B14CC 000AE40C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B14D0 000AE410 38 03 00 01 */ addi r0, r3, 1
+/* 800B14D4 000AE414 90 04 00 08 */ stw r0, 8(r4)
+/* 800B14D8 000AE418 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B14DC 000AE41C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B14E0 000AE420 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B14E4 000AE424 38 03 00 01 */ addi r0, r3, 1
+/* 800B14E8 000AE428 90 04 00 08 */ stw r0, 8(r4)
+/* 800B14EC 000AE42C 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B14F0 000AE430 80 01 00 1C */ lwz r0, 0x1c(r1)
+/* 800B14F4 000AE434 83 E1 00 14 */ lwz r31, 0x14(r1)
+/* 800B14F8 000AE438 83 C1 00 10 */ lwz r30, 0x10(r1)
+/* 800B14FC 000AE43C 38 21 00 18 */ addi r1, r1, 0x18
+/* 800B1500 000AE440 7C 08 03 A6 */ mtlr r0
+/* 800B1504 000AE444 4E 80 00 20 */ blr
+
+.global GDSetChanCtrl
+GDSetChanCtrl:
+/* 800B1508 000AE448 7C 08 02 A6 */ mflr r0
+/* 800B150C 000AE44C 2C 09 00 00 */ cmpwi r9, 0
+/* 800B1510 000AE450 90 01 00 04 */ stw r0, 4(r1)
+/* 800B1514 000AE454 94 21 FF C0 */ stwu r1, -0x40(r1)
+/* 800B1518 000AE458 BF 41 00 28 */ stmw r26, 0x28(r1)
+/* 800B151C 000AE45C 3B 43 00 00 */ addi r26, r3, 0
+/* 800B1520 000AE460 40 82 00 08 */ bne lbl_800B1528
+/* 800B1524 000AE464 39 00 00 00 */ li r8, 0
+lbl_800B1528:
+/* 800B1528 000AE468 7C 69 00 D0 */ neg r3, r9
+/* 800B152C 000AE46C 81 4D 95 B8 */ lwz r10, __GDCurrentDL@sda21(r13)
+/* 800B1530 000AE470 30 03 FF FF */ addic r0, r3, -1
+/* 800B1534 000AE474 7D 60 19 10 */ subfe r11, r0, r3
+/* 800B1538 000AE478 80 6A 00 08 */ lwz r3, 8(r10)
+/* 800B153C 000AE47C 80 0A 00 0C */ lwz r0, 0xc(r10)
+/* 800B1540 000AE480 21 49 00 02 */ subfic r10, r9, 2
+/* 800B1544 000AE484 54 84 0D FC */ rlwinm r4, r4, 1, 0x17, 0x1e
+/* 800B1548 000AE488 31 2A FF FF */ addic r9, r10, -1
+/* 800B154C 000AE48C 7D 49 51 10 */ subfe r10, r9, r10
+/* 800B1550 000AE490 7C C4 23 78 */ or r4, r6, r4
+/* 800B1554 000AE494 54 E9 16 BA */ rlwinm r9, r7, 2, 0x1a, 0x1d
+/* 800B1558 000AE498 38 63 00 01 */ addi r3, r3, 1
+/* 800B155C 000AE49C 7C 03 00 40 */ cmplw r3, r0
+/* 800B1560 000AE4A0 54 A5 30 32 */ slwi r5, r5, 6
+/* 800B1564 000AE4A4 7D 24 23 78 */ or r4, r9, r4
+/* 800B1568 000AE4A8 7C A5 23 78 */ or r5, r5, r4
+/* 800B156C 000AE4AC 55 04 38 30 */ slwi r4, r8, 7
+/* 800B1570 000AE4B0 55 46 48 2C */ slwi r6, r10, 9
+/* 800B1574 000AE4B4 7C A4 23 78 */ or r4, r5, r4
+/* 800B1578 000AE4B8 7C C0 23 78 */ or r0, r6, r4
+/* 800B157C 000AE4BC 55 63 50 2A */ slwi r3, r11, 0xa
+/* 800B1580 000AE4C0 54 E4 3C 68 */ rlwinm r4, r7, 7, 0x11, 0x14
+/* 800B1584 000AE4C4 7C 60 03 78 */ or r0, r3, r0
+/* 800B1588 000AE4C8 7C 9B 03 78 */ or r27, r4, r0
+/* 800B158C 000AE4CC 40 81 00 08 */ ble lbl_800B1594
+/* 800B1590 000AE4D0 4B FF DB C5 */ bl GDOverflowed
+lbl_800B1594:
+/* 800B1594 000AE4D4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1598 000AE4D8 38 A0 00 10 */ li r5, 0x10
+/* 800B159C 000AE4DC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B15A0 000AE4E0 38 03 00 01 */ addi r0, r3, 1
+/* 800B15A4 000AE4E4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B15A8 000AE4E8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B15AC 000AE4EC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B15B0 000AE4F0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B15B4 000AE4F4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B15B8 000AE4F8 38 63 00 02 */ addi r3, r3, 2
+/* 800B15BC 000AE4FC 7C 03 00 40 */ cmplw r3, r0
+/* 800B15C0 000AE500 40 81 00 08 */ ble lbl_800B15C8
+/* 800B15C4 000AE504 4B FF DB 91 */ bl GDOverflowed
+lbl_800B15C8:
+/* 800B15C8 000AE508 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B15CC 000AE50C 38 A0 00 00 */ li r5, 0
+/* 800B15D0 000AE510 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B15D4 000AE514 38 03 00 01 */ addi r0, r3, 1
+/* 800B15D8 000AE518 90 04 00 08 */ stw r0, 8(r4)
+/* 800B15DC 000AE51C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B15E0 000AE520 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B15E4 000AE524 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B15E8 000AE528 38 03 00 01 */ addi r0, r3, 1
+/* 800B15EC 000AE52C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B15F0 000AE530 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B15F4 000AE534 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B15F8 000AE538 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B15FC 000AE53C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1600 000AE540 38 63 00 02 */ addi r3, r3, 2
+/* 800B1604 000AE544 7C 03 00 40 */ cmplw r3, r0
+/* 800B1608 000AE548 40 81 00 08 */ ble lbl_800B1610
+/* 800B160C 000AE54C 4B FF DB 49 */ bl GDOverflowed
+lbl_800B1610:
+/* 800B1610 000AE550 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1614 000AE554 57 43 07 BE */ clrlwi r3, r26, 0x1e
+/* 800B1618 000AE558 38 C3 10 0E */ addi r6, r3, 0x100e
+/* 800B161C 000AE55C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1620 000AE560 54 C6 04 3E */ clrlwi r6, r6, 0x10
+/* 800B1624 000AE564 7C C5 46 70 */ srawi r5, r6, 8
+/* 800B1628 000AE568 38 03 00 01 */ addi r0, r3, 1
+/* 800B162C 000AE56C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1630 000AE570 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1634 000AE574 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1638 000AE578 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B163C 000AE57C 38 03 00 01 */ addi r0, r3, 1
+/* 800B1640 000AE580 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1644 000AE584 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B1648 000AE588 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B164C 000AE58C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1650 000AE590 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1654 000AE594 38 63 00 04 */ addi r3, r3, 4
+/* 800B1658 000AE598 7C 03 00 40 */ cmplw r3, r0
+/* 800B165C 000AE59C 40 81 00 08 */ ble lbl_800B1664
+/* 800B1660 000AE5A0 4B FF DA F5 */ bl GDOverflowed
+lbl_800B1664:
+/* 800B1664 000AE5A4 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B1668 000AE5A8 38 1A FF FC */ addi r0, r26, -4
+/* 800B166C 000AE5AC 57 7F 46 3E */ srwi r31, r27, 0x18
+/* 800B1670 000AE5B0 80 85 00 08 */ lwz r4, 8(r5)
+/* 800B1674 000AE5B4 57 7E 86 3E */ rlwinm r30, r27, 0x10, 0x18, 0x1f
+/* 800B1678 000AE5B8 57 7D C6 3E */ rlwinm r29, r27, 0x18, 0x18, 0x1f
+/* 800B167C 000AE5BC 38 64 00 01 */ addi r3, r4, 1
+/* 800B1680 000AE5C0 90 65 00 08 */ stw r3, 8(r5)
+/* 800B1684 000AE5C4 28 00 00 01 */ cmplwi r0, 1
+/* 800B1688 000AE5C8 57 7C 06 3E */ clrlwi r28, r27, 0x18
+/* 800B168C 000AE5CC 9B E4 00 00 */ stb r31, 0(r4)
+/* 800B1690 000AE5D0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1694 000AE5D4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1698 000AE5D8 38 03 00 01 */ addi r0, r3, 1
+/* 800B169C 000AE5DC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B16A0 000AE5E0 9B C3 00 00 */ stb r30, 0(r3)
+/* 800B16A4 000AE5E4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B16A8 000AE5E8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B16AC 000AE5EC 38 03 00 01 */ addi r0, r3, 1
+/* 800B16B0 000AE5F0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B16B4 000AE5F4 9B A3 00 00 */ stb r29, 0(r3)
+/* 800B16B8 000AE5F8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B16BC 000AE5FC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B16C0 000AE600 38 03 00 01 */ addi r0, r3, 1
+/* 800B16C4 000AE604 90 04 00 08 */ stw r0, 8(r4)
+/* 800B16C8 000AE608 9B 63 00 00 */ stb r27, 0(r3)
+/* 800B16CC 000AE60C 41 81 01 3C */ bgt lbl_800B1808
+/* 800B16D0 000AE610 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B16D4 000AE614 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B16D8 000AE618 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B16DC 000AE61C 38 63 00 01 */ addi r3, r3, 1
+/* 800B16E0 000AE620 7C 03 00 40 */ cmplw r3, r0
+/* 800B16E4 000AE624 40 81 00 08 */ ble lbl_800B16EC
+/* 800B16E8 000AE628 4B FF DA 6D */ bl GDOverflowed
+lbl_800B16EC:
+/* 800B16EC 000AE62C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B16F0 000AE630 38 A0 00 10 */ li r5, 0x10
+/* 800B16F4 000AE634 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B16F8 000AE638 38 03 00 01 */ addi r0, r3, 1
+/* 800B16FC 000AE63C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1700 000AE640 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1704 000AE644 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1708 000AE648 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B170C 000AE64C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1710 000AE650 38 63 00 02 */ addi r3, r3, 2
+/* 800B1714 000AE654 7C 03 00 40 */ cmplw r3, r0
+/* 800B1718 000AE658 40 81 00 08 */ ble lbl_800B1720
+/* 800B171C 000AE65C 4B FF DA 39 */ bl GDOverflowed
+lbl_800B1720:
+/* 800B1720 000AE660 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1724 000AE664 38 A0 00 00 */ li r5, 0
+/* 800B1728 000AE668 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B172C 000AE66C 38 03 00 01 */ addi r0, r3, 1
+/* 800B1730 000AE670 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1734 000AE674 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1738 000AE678 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B173C 000AE67C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1740 000AE680 38 03 00 01 */ addi r0, r3, 1
+/* 800B1744 000AE684 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1748 000AE688 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B174C 000AE68C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1750 000AE690 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1754 000AE694 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1758 000AE698 38 63 00 02 */ addi r3, r3, 2
+/* 800B175C 000AE69C 7C 03 00 40 */ cmplw r3, r0
+/* 800B1760 000AE6A0 40 81 00 08 */ ble lbl_800B1768
+/* 800B1764 000AE6A4 4B FF D9 F1 */ bl GDOverflowed
+lbl_800B1768:
+/* 800B1768 000AE6A8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B176C 000AE6AC 38 DA 10 0C */ addi r6, r26, 0x100c
+/* 800B1770 000AE6B0 54 C6 04 3E */ clrlwi r6, r6, 0x10
+/* 800B1774 000AE6B4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1778 000AE6B8 7C C5 46 70 */ srawi r5, r6, 8
+/* 800B177C 000AE6BC 38 03 00 01 */ addi r0, r3, 1
+/* 800B1780 000AE6C0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1784 000AE6C4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1788 000AE6C8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B178C 000AE6CC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1790 000AE6D0 38 03 00 01 */ addi r0, r3, 1
+/* 800B1794 000AE6D4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1798 000AE6D8 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B179C 000AE6DC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B17A0 000AE6E0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B17A4 000AE6E4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B17A8 000AE6E8 38 63 00 04 */ addi r3, r3, 4
+/* 800B17AC 000AE6EC 7C 03 00 40 */ cmplw r3, r0
+/* 800B17B0 000AE6F0 40 81 00 08 */ ble lbl_800B17B8
+/* 800B17B4 000AE6F4 4B FF D9 A1 */ bl GDOverflowed
+lbl_800B17B8:
+/* 800B17B8 000AE6F8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B17BC 000AE6FC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B17C0 000AE700 38 03 00 01 */ addi r0, r3, 1
+/* 800B17C4 000AE704 90 04 00 08 */ stw r0, 8(r4)
+/* 800B17C8 000AE708 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B17CC 000AE70C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B17D0 000AE710 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B17D4 000AE714 38 03 00 01 */ addi r0, r3, 1
+/* 800B17D8 000AE718 90 04 00 08 */ stw r0, 8(r4)
+/* 800B17DC 000AE71C 9B C3 00 00 */ stb r30, 0(r3)
+/* 800B17E0 000AE720 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B17E4 000AE724 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B17E8 000AE728 38 03 00 01 */ addi r0, r3, 1
+/* 800B17EC 000AE72C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B17F0 000AE730 9B A3 00 00 */ stb r29, 0(r3)
+/* 800B17F4 000AE734 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B17F8 000AE738 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B17FC 000AE73C 38 03 00 01 */ addi r0, r3, 1
+/* 800B1800 000AE740 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1804 000AE744 9B 83 00 00 */ stb r28, 0(r3)
+lbl_800B1808:
+/* 800B1808 000AE748 BB 41 00 28 */ lmw r26, 0x28(r1)
+/* 800B180C 000AE74C 80 01 00 44 */ lwz r0, 0x44(r1)
+/* 800B1810 000AE750 38 21 00 40 */ addi r1, r1, 0x40
+/* 800B1814 000AE754 7C 08 03 A6 */ mtlr r0
+/* 800B1818 000AE758 4E 80 00 20 */ blr
diff --git a/asm/Dolphin/gd/GDPixel.s b/asm/Dolphin/gd/GDPixel.s
new file mode 100644
index 0000000..95d6f0f
--- /dev/null
+++ b/asm/Dolphin/gd/GDPixel.s
@@ -0,0 +1,450 @@
+.include "macros.inc"
+
+.section .text, "ax" # 0x80005600 - 0x8036FBA0
+.global GDSetBlendMode
+GDSetBlendMode:
+/* 800B181C 000AE75C 7C 08 02 A6 */ mflr r0
+/* 800B1820 000AE760 90 01 00 04 */ stw r0, 4(r1)
+/* 800B1824 000AE764 94 21 FF D8 */ stwu r1, -0x28(r1)
+/* 800B1828 000AE768 93 E1 00 24 */ stw r31, 0x24(r1)
+/* 800B182C 000AE76C 3B E6 00 00 */ addi r31, r6, 0
+/* 800B1830 000AE770 93 C1 00 20 */ stw r30, 0x20(r1)
+/* 800B1834 000AE774 7C BE 2B 78 */ mr r30, r5
+/* 800B1838 000AE778 93 A1 00 1C */ stw r29, 0x1c(r1)
+/* 800B183C 000AE77C 3B A4 00 00 */ addi r29, r4, 0
+/* 800B1840 000AE780 93 81 00 18 */ stw r28, 0x18(r1)
+/* 800B1844 000AE784 3B 83 00 00 */ addi r28, r3, 0
+/* 800B1848 000AE788 80 ED 95 B8 */ lwz r7, __GDCurrentDL@sda21(r13)
+/* 800B184C 000AE78C 80 67 00 08 */ lwz r3, 8(r7)
+/* 800B1850 000AE790 80 07 00 0C */ lwz r0, 0xc(r7)
+/* 800B1854 000AE794 38 63 00 01 */ addi r3, r3, 1
+/* 800B1858 000AE798 7C 03 00 40 */ cmplw r3, r0
+/* 800B185C 000AE79C 40 81 00 08 */ ble lbl_800B1864
+/* 800B1860 000AE7A0 4B FF D8 F5 */ bl GDOverflowed
+lbl_800B1864:
+/* 800B1864 000AE7A4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1868 000AE7A8 38 A0 00 61 */ li r5, 0x61
+/* 800B186C 000AE7AC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1870 000AE7B0 38 03 00 01 */ addi r0, r3, 1
+/* 800B1874 000AE7B4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1878 000AE7B8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B187C 000AE7BC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1880 000AE7C0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1884 000AE7C4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1888 000AE7C8 38 63 00 04 */ addi r3, r3, 4
+/* 800B188C 000AE7CC 7C 03 00 40 */ cmplw r3, r0
+/* 800B1890 000AE7D0 40 81 00 08 */ ble lbl_800B1898
+/* 800B1894 000AE7D4 4B FF D8 C1 */ bl GDOverflowed
+lbl_800B1898:
+/* 800B1898 000AE7D8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B189C 000AE7DC 39 00 00 FE */ li r8, 0xfe
+/* 800B18A0 000AE7E0 38 E0 00 00 */ li r7, 0
+/* 800B18A4 000AE7E4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B18A8 000AE7E8 38 C0 00 1F */ li r6, 0x1f
+/* 800B18AC 000AE7EC 38 A0 00 E3 */ li r5, 0xe3
+/* 800B18B0 000AE7F0 38 03 00 01 */ addi r0, r3, 1
+/* 800B18B4 000AE7F4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B18B8 000AE7F8 99 03 00 00 */ stb r8, 0(r3)
+/* 800B18BC 000AE7FC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B18C0 000AE800 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B18C4 000AE804 38 03 00 01 */ addi r0, r3, 1
+/* 800B18C8 000AE808 90 04 00 08 */ stw r0, 8(r4)
+/* 800B18CC 000AE80C 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B18D0 000AE810 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B18D4 000AE814 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B18D8 000AE818 38 03 00 01 */ addi r0, r3, 1
+/* 800B18DC 000AE81C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B18E0 000AE820 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B18E4 000AE824 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B18E8 000AE828 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B18EC 000AE82C 38 03 00 01 */ addi r0, r3, 1
+/* 800B18F0 000AE830 90 04 00 08 */ stw r0, 8(r4)
+/* 800B18F4 000AE834 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B18F8 000AE838 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B18FC 000AE83C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1900 000AE840 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1904 000AE844 38 63 00 01 */ addi r3, r3, 1
+/* 800B1908 000AE848 7C 03 00 40 */ cmplw r3, r0
+/* 800B190C 000AE84C 40 81 00 08 */ ble lbl_800B1914
+/* 800B1910 000AE850 4B FF D8 45 */ bl GDOverflowed
+lbl_800B1914:
+/* 800B1914 000AE854 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1918 000AE858 38 A0 00 61 */ li r5, 0x61
+/* 800B191C 000AE85C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1920 000AE860 38 03 00 01 */ addi r0, r3, 1
+/* 800B1924 000AE864 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1928 000AE868 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B192C 000AE86C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1930 000AE870 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1934 000AE874 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1938 000AE878 38 63 00 04 */ addi r3, r3, 4
+/* 800B193C 000AE87C 7C 03 00 40 */ cmplw r3, r0
+/* 800B1940 000AE880 40 81 00 08 */ ble lbl_800B1948
+/* 800B1944 000AE884 4B FF D8 11 */ bl GDOverflowed
+lbl_800B1948:
+/* 800B1948 000AE888 2C 1C 00 01 */ cmpwi r28, 1
+/* 800B194C 000AE88C 38 80 00 01 */ li r4, 1
+/* 800B1950 000AE890 41 82 00 10 */ beq lbl_800B1960
+/* 800B1954 000AE894 2C 1C 00 03 */ cmpwi r28, 3
+/* 800B1958 000AE898 41 82 00 08 */ beq lbl_800B1960
+/* 800B195C 000AE89C 38 80 00 00 */ li r4, 0
+lbl_800B1960:
+/* 800B1960 000AE8A0 20 7C 00 03 */ subfic r3, r28, 3
+/* 800B1964 000AE8A4 80 CD 95 B8 */ lwz r6, __GDCurrentDL@sda21(r13)
+/* 800B1968 000AE8A8 20 1C 00 02 */ subfic r0, r28, 2
+/* 800B196C 000AE8AC 7C 00 00 34 */ cntlzw r0, r0
+/* 800B1970 000AE8B0 80 E6 00 08 */ lwz r7, 8(r6)
+/* 800B1974 000AE8B4 54 00 E1 3C */ rlwinm r0, r0, 0x1c, 4, 0x1e
+/* 800B1978 000AE8B8 7C 69 00 34 */ cntlzw r9, r3
+/* 800B197C 000AE8BC 7C 08 23 78 */ or r8, r0, r4
+/* 800B1980 000AE8C0 38 A7 00 01 */ addi r5, r7, 1
+/* 800B1984 000AE8C4 90 A6 00 08 */ stw r5, 8(r6)
+/* 800B1988 000AE8C8 57 C3 28 34 */ slwi r3, r30, 5
+/* 800B198C 000AE8CC 57 A4 40 2E */ slwi r4, r29, 8
+/* 800B1990 000AE8D0 7C 66 43 78 */ or r6, r3, r8
+/* 800B1994 000AE8D4 7C 88 33 78 */ or r8, r4, r6
+/* 800B1998 000AE8D8 55 25 30 28 */ rlwinm r5, r9, 6, 0, 0x14
+/* 800B199C 000AE8DC 57 E6 60 26 */ slwi r6, r31, 0xc
+/* 800B19A0 000AE8E0 7C A8 43 78 */ or r8, r5, r8
+/* 800B19A4 000AE8E4 7C C8 43 78 */ or r8, r6, r8
+/* 800B19A8 000AE8E8 65 08 41 00 */ oris r8, r8, 0x4100
+/* 800B19AC 000AE8EC 55 08 46 3E */ srwi r8, r8, 0x18
+/* 800B19B0 000AE8F0 99 07 00 00 */ stb r8, 0(r7)
+/* 800B19B4 000AE8F4 2C 1C 00 01 */ cmpwi r28, 1
+/* 800B19B8 000AE8F8 38 E0 00 01 */ li r7, 1
+/* 800B19BC 000AE8FC 41 82 00 10 */ beq lbl_800B19CC
+/* 800B19C0 000AE900 2C 1C 00 03 */ cmpwi r28, 3
+/* 800B19C4 000AE904 41 82 00 08 */ beq lbl_800B19CC
+/* 800B19C8 000AE908 38 E0 00 00 */ li r7, 0
+lbl_800B19CC:
+/* 800B19CC 000AE90C 7C 07 3B 78 */ or r7, r0, r7
+/* 800B19D0 000AE910 81 2D 95 B8 */ lwz r9, __GDCurrentDL@sda21(r13)
+/* 800B19D4 000AE914 7C 67 3B 78 */ or r7, r3, r7
+/* 800B19D8 000AE918 7C 87 3B 78 */ or r7, r4, r7
+/* 800B19DC 000AE91C 81 09 00 08 */ lwz r8, 8(r9)
+/* 800B19E0 000AE920 7C A7 3B 78 */ or r7, r5, r7
+/* 800B19E4 000AE924 7C CA 3B 78 */ or r10, r6, r7
+/* 800B19E8 000AE928 38 E8 00 01 */ addi r7, r8, 1
+/* 800B19EC 000AE92C 65 4A 41 00 */ oris r10, r10, 0x4100
+/* 800B19F0 000AE930 90 E9 00 08 */ stw r7, 8(r9)
+/* 800B19F4 000AE934 55 47 86 3E */ rlwinm r7, r10, 0x10, 0x18, 0x1f
+/* 800B19F8 000AE938 2C 1C 00 01 */ cmpwi r28, 1
+/* 800B19FC 000AE93C 98 E8 00 00 */ stb r7, 0(r8)
+/* 800B1A00 000AE940 38 E0 00 01 */ li r7, 1
+/* 800B1A04 000AE944 41 82 00 10 */ beq lbl_800B1A14
+/* 800B1A08 000AE948 2C 1C 00 03 */ cmpwi r28, 3
+/* 800B1A0C 000AE94C 41 82 00 08 */ beq lbl_800B1A14
+/* 800B1A10 000AE950 38 E0 00 00 */ li r7, 0
+lbl_800B1A14:
+/* 800B1A14 000AE954 7C 07 3B 78 */ or r7, r0, r7
+/* 800B1A18 000AE958 81 2D 95 B8 */ lwz r9, __GDCurrentDL@sda21(r13)
+/* 800B1A1C 000AE95C 7C 67 3B 78 */ or r7, r3, r7
+/* 800B1A20 000AE960 7C 87 3B 78 */ or r7, r4, r7
+/* 800B1A24 000AE964 81 09 00 08 */ lwz r8, 8(r9)
+/* 800B1A28 000AE968 7C A7 3B 78 */ or r7, r5, r7
+/* 800B1A2C 000AE96C 7C CA 3B 78 */ or r10, r6, r7
+/* 800B1A30 000AE970 38 E8 00 01 */ addi r7, r8, 1
+/* 800B1A34 000AE974 65 4A 41 00 */ oris r10, r10, 0x4100
+/* 800B1A38 000AE978 90 E9 00 08 */ stw r7, 8(r9)
+/* 800B1A3C 000AE97C 55 47 C6 3E */ rlwinm r7, r10, 0x18, 0x18, 0x1f
+/* 800B1A40 000AE980 2C 1C 00 01 */ cmpwi r28, 1
+/* 800B1A44 000AE984 98 E8 00 00 */ stb r7, 0(r8)
+/* 800B1A48 000AE988 38 E0 00 01 */ li r7, 1
+/* 800B1A4C 000AE98C 41 82 00 10 */ beq lbl_800B1A5C
+/* 800B1A50 000AE990 2C 1C 00 03 */ cmpwi r28, 3
+/* 800B1A54 000AE994 41 82 00 08 */ beq lbl_800B1A5C
+/* 800B1A58 000AE998 38 E0 00 00 */ li r7, 0
+lbl_800B1A5C:
+/* 800B1A5C 000AE99C 7C 00 3B 78 */ or r0, r0, r7
+/* 800B1A60 000AE9A0 80 ED 95 B8 */ lwz r7, __GDCurrentDL@sda21(r13)
+/* 800B1A64 000AE9A4 7C 60 03 78 */ or r0, r3, r0
+/* 800B1A68 000AE9A8 7C 80 03 78 */ or r0, r4, r0
+/* 800B1A6C 000AE9AC 80 67 00 08 */ lwz r3, 8(r7)
+/* 800B1A70 000AE9B0 7C A0 03 78 */ or r0, r5, r0
+/* 800B1A74 000AE9B4 7C C4 03 78 */ or r4, r6, r0
+/* 800B1A78 000AE9B8 38 03 00 01 */ addi r0, r3, 1
+/* 800B1A7C 000AE9BC 90 07 00 08 */ stw r0, 8(r7)
+/* 800B1A80 000AE9C0 60 84 00 00 */ ori r4, r4, 0
+/* 800B1A84 000AE9C4 98 83 00 00 */ stb r4, 0(r3)
+/* 800B1A88 000AE9C8 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800B1A8C 000AE9CC 83 E1 00 24 */ lwz r31, 0x24(r1)
+/* 800B1A90 000AE9D0 83 C1 00 20 */ lwz r30, 0x20(r1)
+/* 800B1A94 000AE9D4 83 A1 00 1C */ lwz r29, 0x1c(r1)
+/* 800B1A98 000AE9D8 83 81 00 18 */ lwz r28, 0x18(r1)
+/* 800B1A9C 000AE9DC 38 21 00 28 */ addi r1, r1, 0x28
+/* 800B1AA0 000AE9E0 7C 08 03 A6 */ mtlr r0
+/* 800B1AA4 000AE9E4 4E 80 00 20 */ blr
+
+.global GDSetBlendModeEtc
+GDSetBlendModeEtc:
+/* 800B1AA8 000AE9E8 7C 08 02 A6 */ mflr r0
+/* 800B1AAC 000AE9EC 90 01 00 04 */ stw r0, 4(r1)
+/* 800B1AB0 000AE9F0 94 21 FF C0 */ stwu r1, -0x40(r1)
+/* 800B1AB4 000AE9F4 BF 21 00 24 */ stmw r25, 0x24(r1)
+/* 800B1AB8 000AE9F8 3B 23 00 00 */ addi r25, r3, 0
+/* 800B1ABC 000AE9FC 3B 44 00 00 */ addi r26, r4, 0
+/* 800B1AC0 000AEA00 7C BB 2B 78 */ mr r27, r5
+/* 800B1AC4 000AEA04 3B 86 00 00 */ addi r28, r6, 0
+/* 800B1AC8 000AEA08 3B A7 00 00 */ addi r29, r7, 0
+/* 800B1ACC 000AEA0C 3B C8 00 00 */ addi r30, r8, 0
+/* 800B1AD0 000AEA10 3B E9 00 00 */ addi r31, r9, 0
+/* 800B1AD4 000AEA14 81 4D 95 B8 */ lwz r10, __GDCurrentDL@sda21(r13)
+/* 800B1AD8 000AEA18 80 6A 00 08 */ lwz r3, 8(r10)
+/* 800B1ADC 000AEA1C 80 0A 00 0C */ lwz r0, 0xc(r10)
+/* 800B1AE0 000AEA20 38 63 00 01 */ addi r3, r3, 1
+/* 800B1AE4 000AEA24 7C 03 00 40 */ cmplw r3, r0
+/* 800B1AE8 000AEA28 40 81 00 08 */ ble lbl_800B1AF0
+/* 800B1AEC 000AEA2C 4B FF D6 69 */ bl GDOverflowed
+lbl_800B1AF0:
+/* 800B1AF0 000AEA30 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1AF4 000AEA34 38 A0 00 61 */ li r5, 0x61
+/* 800B1AF8 000AEA38 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1AFC 000AEA3C 38 03 00 01 */ addi r0, r3, 1
+/* 800B1B00 000AEA40 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1B04 000AEA44 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1B08 000AEA48 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1B0C 000AEA4C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1B10 000AEA50 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1B14 000AEA54 38 63 00 04 */ addi r3, r3, 4
+/* 800B1B18 000AEA58 7C 03 00 40 */ cmplw r3, r0
+/* 800B1B1C 000AEA5C 40 81 00 08 */ ble lbl_800B1B24
+/* 800B1B20 000AEA60 4B FF D6 35 */ bl GDOverflowed
+lbl_800B1B24:
+/* 800B1B24 000AEA64 2C 19 00 01 */ cmpwi r25, 1
+/* 800B1B28 000AEA68 38 80 00 01 */ li r4, 1
+/* 800B1B2C 000AEA6C 41 82 00 10 */ beq lbl_800B1B3C
+/* 800B1B30 000AEA70 2C 19 00 03 */ cmpwi r25, 3
+/* 800B1B34 000AEA74 41 82 00 08 */ beq lbl_800B1B3C
+/* 800B1B38 000AEA78 38 80 00 00 */ li r4, 0
+lbl_800B1B3C:
+/* 800B1B3C 000AEA7C 20 79 00 03 */ subfic r3, r25, 3
+/* 800B1B40 000AEA80 80 CD 95 B8 */ lwz r6, __GDCurrentDL@sda21(r13)
+/* 800B1B44 000AEA84 20 19 00 02 */ subfic r0, r25, 2
+/* 800B1B48 000AEA88 7C 00 00 34 */ cntlzw r0, r0
+/* 800B1B4C 000AEA8C 81 46 00 08 */ lwz r10, 8(r6)
+/* 800B1B50 000AEA90 54 00 E1 3C */ rlwinm r0, r0, 0x1c, 4, 0x1e
+/* 800B1B54 000AEA94 7C 6B 00 34 */ cntlzw r11, r3
+/* 800B1B58 000AEA98 7C 07 23 78 */ or r7, r0, r4
+/* 800B1B5C 000AEA9C 38 AA 00 01 */ addi r5, r10, 1
+/* 800B1B60 000AEAA0 90 A6 00 08 */ stw r5, 8(r6)
+/* 800B1B64 000AEAA4 57 E3 15 BA */ rlwinm r3, r31, 2, 0x16, 0x1d
+/* 800B1B68 000AEAA8 57 A4 1D 78 */ rlwinm r4, r29, 3, 0x15, 0x1c
+/* 800B1B6C 000AEAAC 7C 66 3B 78 */ or r6, r3, r7
+/* 800B1B70 000AEAB0 7C 87 33 78 */ or r7, r4, r6
+/* 800B1B74 000AEAB4 57 C5 25 36 */ rlwinm r5, r30, 4, 0x14, 0x1b
+/* 800B1B78 000AEAB8 7C A8 3B 78 */ or r8, r5, r7
+/* 800B1B7C 000AEABC 57 66 28 34 */ slwi r6, r27, 5
+/* 800B1B80 000AEAC0 7C C9 43 78 */ or r9, r6, r8
+/* 800B1B84 000AEAC4 57 47 40 2E */ slwi r7, r26, 8
+/* 800B1B88 000AEAC8 55 68 30 28 */ rlwinm r8, r11, 6, 0, 0x14
+/* 800B1B8C 000AEACC 7C EB 4B 78 */ or r11, r7, r9
+/* 800B1B90 000AEAD0 57 89 60 26 */ slwi r9, r28, 0xc
+/* 800B1B94 000AEAD4 7D 0B 5B 78 */ or r11, r8, r11
+/* 800B1B98 000AEAD8 7D 2B 5B 78 */ or r11, r9, r11
+/* 800B1B9C 000AEADC 65 6B 41 00 */ oris r11, r11, 0x4100
+/* 800B1BA0 000AEAE0 55 6B 46 3E */ srwi r11, r11, 0x18
+/* 800B1BA4 000AEAE4 99 6A 00 00 */ stb r11, 0(r10)
+/* 800B1BA8 000AEAE8 2C 19 00 01 */ cmpwi r25, 1
+/* 800B1BAC 000AEAEC 39 40 00 01 */ li r10, 1
+/* 800B1BB0 000AEAF0 41 82 00 10 */ beq lbl_800B1BC0
+/* 800B1BB4 000AEAF4 2C 19 00 03 */ cmpwi r25, 3
+/* 800B1BB8 000AEAF8 41 82 00 08 */ beq lbl_800B1BC0
+/* 800B1BBC 000AEAFC 39 40 00 00 */ li r10, 0
+lbl_800B1BC0:
+/* 800B1BC0 000AEB00 7C 0A 53 78 */ or r10, r0, r10
+/* 800B1BC4 000AEB04 81 8D 95 B8 */ lwz r12, __GDCurrentDL@sda21(r13)
+/* 800B1BC8 000AEB08 7C 6A 53 78 */ or r10, r3, r10
+/* 800B1BCC 000AEB0C 7C 8A 53 78 */ or r10, r4, r10
+/* 800B1BD0 000AEB10 81 6C 00 08 */ lwz r11, 8(r12)
+/* 800B1BD4 000AEB14 7C AA 53 78 */ or r10, r5, r10
+/* 800B1BD8 000AEB18 7C CA 53 78 */ or r10, r6, r10
+/* 800B1BDC 000AEB1C 7C EA 53 78 */ or r10, r7, r10
+/* 800B1BE0 000AEB20 7D 0A 53 78 */ or r10, r8, r10
+/* 800B1BE4 000AEB24 7D 3A 53 78 */ or r26, r9, r10
+/* 800B1BE8 000AEB28 39 4B 00 01 */ addi r10, r11, 1
+/* 800B1BEC 000AEB2C 67 5A 41 00 */ oris r26, r26, 0x4100
+/* 800B1BF0 000AEB30 91 4C 00 08 */ stw r10, 8(r12)
+/* 800B1BF4 000AEB34 57 4A 86 3E */ rlwinm r10, r26, 0x10, 0x18, 0x1f
+/* 800B1BF8 000AEB38 2C 19 00 01 */ cmpwi r25, 1
+/* 800B1BFC 000AEB3C 99 4B 00 00 */ stb r10, 0(r11)
+/* 800B1C00 000AEB40 39 40 00 01 */ li r10, 1
+/* 800B1C04 000AEB44 41 82 00 10 */ beq lbl_800B1C14
+/* 800B1C08 000AEB48 2C 19 00 03 */ cmpwi r25, 3
+/* 800B1C0C 000AEB4C 41 82 00 08 */ beq lbl_800B1C14
+/* 800B1C10 000AEB50 39 40 00 00 */ li r10, 0
+lbl_800B1C14:
+/* 800B1C14 000AEB54 7C 0A 53 78 */ or r10, r0, r10
+/* 800B1C18 000AEB58 81 8D 95 B8 */ lwz r12, __GDCurrentDL@sda21(r13)
+/* 800B1C1C 000AEB5C 7C 6A 53 78 */ or r10, r3, r10
+/* 800B1C20 000AEB60 7C 8A 53 78 */ or r10, r4, r10
+/* 800B1C24 000AEB64 81 6C 00 08 */ lwz r11, 8(r12)
+/* 800B1C28 000AEB68 7C AA 53 78 */ or r10, r5, r10
+/* 800B1C2C 000AEB6C 7C CA 53 78 */ or r10, r6, r10
+/* 800B1C30 000AEB70 7C EA 53 78 */ or r10, r7, r10
+/* 800B1C34 000AEB74 7D 0A 53 78 */ or r10, r8, r10
+/* 800B1C38 000AEB78 7D 3A 53 78 */ or r26, r9, r10
+/* 800B1C3C 000AEB7C 39 4B 00 01 */ addi r10, r11, 1
+/* 800B1C40 000AEB80 67 5A 41 00 */ oris r26, r26, 0x4100
+/* 800B1C44 000AEB84 91 4C 00 08 */ stw r10, 8(r12)
+/* 800B1C48 000AEB88 57 4A C6 3E */ rlwinm r10, r26, 0x18, 0x18, 0x1f
+/* 800B1C4C 000AEB8C 2C 19 00 01 */ cmpwi r25, 1
+/* 800B1C50 000AEB90 99 4B 00 00 */ stb r10, 0(r11)
+/* 800B1C54 000AEB94 39 40 00 01 */ li r10, 1
+/* 800B1C58 000AEB98 41 82 00 10 */ beq lbl_800B1C68
+/* 800B1C5C 000AEB9C 2C 19 00 03 */ cmpwi r25, 3
+/* 800B1C60 000AEBA0 41 82 00 08 */ beq lbl_800B1C68
+/* 800B1C64 000AEBA4 39 40 00 00 */ li r10, 0
+lbl_800B1C68:
+/* 800B1C68 000AEBA8 7C 00 53 78 */ or r0, r0, r10
+/* 800B1C6C 000AEBAC 81 4D 95 B8 */ lwz r10, __GDCurrentDL@sda21(r13)
+/* 800B1C70 000AEBB0 7C 60 03 78 */ or r0, r3, r0
+/* 800B1C74 000AEBB4 7C 80 03 78 */ or r0, r4, r0
+/* 800B1C78 000AEBB8 80 6A 00 08 */ lwz r3, 8(r10)
+/* 800B1C7C 000AEBBC 7C A0 03 78 */ or r0, r5, r0
+/* 800B1C80 000AEBC0 7C C0 03 78 */ or r0, r6, r0
+/* 800B1C84 000AEBC4 7C E0 03 78 */ or r0, r7, r0
+/* 800B1C88 000AEBC8 7D 00 03 78 */ or r0, r8, r0
+/* 800B1C8C 000AEBCC 7D 24 03 78 */ or r4, r9, r0
+/* 800B1C90 000AEBD0 38 03 00 01 */ addi r0, r3, 1
+/* 800B1C94 000AEBD4 90 0A 00 08 */ stw r0, 8(r10)
+/* 800B1C98 000AEBD8 60 84 00 00 */ ori r4, r4, 0
+/* 800B1C9C 000AEBDC 98 83 00 00 */ stb r4, 0(r3)
+/* 800B1CA0 000AEBE0 BB 21 00 24 */ lmw r25, 0x24(r1)
+/* 800B1CA4 000AEBE4 80 01 00 44 */ lwz r0, 0x44(r1)
+/* 800B1CA8 000AEBE8 38 21 00 40 */ addi r1, r1, 0x40
+/* 800B1CAC 000AEBEC 7C 08 03 A6 */ mtlr r0
+/* 800B1CB0 000AEBF0 4E 80 00 20 */ blr
+
+.global GDSetZMode
+GDSetZMode:
+/* 800B1CB4 000AEBF4 7C 08 02 A6 */ mflr r0
+/* 800B1CB8 000AEBF8 90 01 00 04 */ stw r0, 4(r1)
+/* 800B1CBC 000AEBFC 94 21 FF D8 */ stwu r1, -0x28(r1)
+/* 800B1CC0 000AEC00 93 E1 00 24 */ stw r31, 0x24(r1)
+/* 800B1CC4 000AEC04 7C BF 2B 78 */ mr r31, r5
+/* 800B1CC8 000AEC08 93 C1 00 20 */ stw r30, 0x20(r1)
+/* 800B1CCC 000AEC0C 3B C4 00 00 */ addi r30, r4, 0
+/* 800B1CD0 000AEC10 93 A1 00 1C */ stw r29, 0x1c(r1)
+/* 800B1CD4 000AEC14 3B A3 00 00 */ addi r29, r3, 0
+/* 800B1CD8 000AEC18 80 CD 95 B8 */ lwz r6, __GDCurrentDL@sda21(r13)
+/* 800B1CDC 000AEC1C 80 66 00 08 */ lwz r3, 8(r6)
+/* 800B1CE0 000AEC20 80 06 00 0C */ lwz r0, 0xc(r6)
+/* 800B1CE4 000AEC24 38 63 00 01 */ addi r3, r3, 1
+/* 800B1CE8 000AEC28 7C 03 00 40 */ cmplw r3, r0
+/* 800B1CEC 000AEC2C 40 81 00 08 */ ble lbl_800B1CF4
+/* 800B1CF0 000AEC30 4B FF D4 65 */ bl GDOverflowed
+lbl_800B1CF4:
+/* 800B1CF4 000AEC34 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1CF8 000AEC38 38 A0 00 61 */ li r5, 0x61
+/* 800B1CFC 000AEC3C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1D00 000AEC40 38 03 00 01 */ addi r0, r3, 1
+/* 800B1D04 000AEC44 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1D08 000AEC48 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1D0C 000AEC4C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1D10 000AEC50 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1D14 000AEC54 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1D18 000AEC58 38 63 00 04 */ addi r3, r3, 4
+/* 800B1D1C 000AEC5C 7C 03 00 40 */ cmplw r3, r0
+/* 800B1D20 000AEC60 40 81 00 08 */ ble lbl_800B1D28
+/* 800B1D24 000AEC64 4B FF D4 31 */ bl GDOverflowed
+lbl_800B1D28:
+/* 800B1D28 000AEC68 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1D2C 000AEC6C 57 A5 06 3E */ clrlwi r5, r29, 0x18
+/* 800B1D30 000AEC70 57 C0 08 3C */ slwi r0, r30, 1
+/* 800B1D34 000AEC74 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1D38 000AEC78 57 E6 25 36 */ rlwinm r6, r31, 4, 0x14, 0x1b
+/* 800B1D3C 000AEC7C 7C A0 03 78 */ or r0, r5, r0
+/* 800B1D40 000AEC80 7C C0 03 78 */ or r0, r6, r0
+/* 800B1D44 000AEC84 64 07 40 00 */ oris r7, r0, 0x4000
+/* 800B1D48 000AEC88 38 03 00 01 */ addi r0, r3, 1
+/* 800B1D4C 000AEC8C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1D50 000AEC90 54 E0 46 3E */ srwi r0, r7, 0x18
+/* 800B1D54 000AEC94 54 E6 86 3E */ rlwinm r6, r7, 0x10, 0x18, 0x1f
+/* 800B1D58 000AEC98 98 03 00 00 */ stb r0, 0(r3)
+/* 800B1D5C 000AEC9C 54 E5 C6 3E */ rlwinm r5, r7, 0x18, 0x18, 0x1f
+/* 800B1D60 000AECA0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1D64 000AECA4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1D68 000AECA8 38 03 00 01 */ addi r0, r3, 1
+/* 800B1D6C 000AECAC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1D70 000AECB0 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B1D74 000AECB4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1D78 000AECB8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1D7C 000AECBC 38 03 00 01 */ addi r0, r3, 1
+/* 800B1D80 000AECC0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1D84 000AECC4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1D88 000AECC8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1D8C 000AECCC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1D90 000AECD0 38 03 00 01 */ addi r0, r3, 1
+/* 800B1D94 000AECD4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1D98 000AECD8 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B1D9C 000AECDC 80 01 00 2C */ lwz r0, 0x2c(r1)
+/* 800B1DA0 000AECE0 83 E1 00 24 */ lwz r31, 0x24(r1)
+/* 800B1DA4 000AECE4 83 C1 00 20 */ lwz r30, 0x20(r1)
+/* 800B1DA8 000AECE8 83 A1 00 1C */ lwz r29, 0x1c(r1)
+/* 800B1DAC 000AECEC 38 21 00 28 */ addi r1, r1, 0x28
+/* 800B1DB0 000AECF0 7C 08 03 A6 */ mtlr r0
+/* 800B1DB4 000AECF4 4E 80 00 20 */ blr
+
+.global GDSetDstAlpha
+GDSetDstAlpha:
+/* 800B1DB8 000AECF8 7C 08 02 A6 */ mflr r0
+/* 800B1DBC 000AECFC 90 01 00 04 */ stw r0, 4(r1)
+/* 800B1DC0 000AED00 94 21 FF E8 */ stwu r1, -0x18(r1)
+/* 800B1DC4 000AED04 93 E1 00 14 */ stw r31, 0x14(r1)
+/* 800B1DC8 000AED08 3B E4 00 00 */ addi r31, r4, 0
+/* 800B1DCC 000AED0C 93 C1 00 10 */ stw r30, 0x10(r1)
+/* 800B1DD0 000AED10 3B C3 00 00 */ addi r30, r3, 0
+/* 800B1DD4 000AED14 80 AD 95 B8 */ lwz r5, __GDCurrentDL@sda21(r13)
+/* 800B1DD8 000AED18 80 65 00 08 */ lwz r3, 8(r5)
+/* 800B1DDC 000AED1C 80 05 00 0C */ lwz r0, 0xc(r5)
+/* 800B1DE0 000AED20 38 63 00 01 */ addi r3, r3, 1
+/* 800B1DE4 000AED24 7C 03 00 40 */ cmplw r3, r0
+/* 800B1DE8 000AED28 40 81 00 08 */ ble lbl_800B1DF0
+/* 800B1DEC 000AED2C 4B FF D3 69 */ bl GDOverflowed
+lbl_800B1DF0:
+/* 800B1DF0 000AED30 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1DF4 000AED34 38 A0 00 61 */ li r5, 0x61
+/* 800B1DF8 000AED38 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1DFC 000AED3C 38 03 00 01 */ addi r0, r3, 1
+/* 800B1E00 000AED40 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1E04 000AED44 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1E08 000AED48 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1E0C 000AED4C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1E10 000AED50 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B1E14 000AED54 38 63 00 04 */ addi r3, r3, 4
+/* 800B1E18 000AED58 7C 03 00 40 */ cmplw r3, r0
+/* 800B1E1C 000AED5C 40 81 00 08 */ ble lbl_800B1E24
+/* 800B1E20 000AED60 4B FF D3 35 */ bl GDOverflowed
+lbl_800B1E24:
+/* 800B1E24 000AED64 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1E28 000AED68 57 C5 44 2E */ rlwinm r5, r30, 8, 0x10, 0x17
+/* 800B1E2C 000AED6C 53 E5 06 3E */ rlwimi r5, r31, 0, 0x18, 0x1f
+/* 800B1E30 000AED70 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1E34 000AED74 64 A7 42 00 */ oris r7, r5, 0x4200
+/* 800B1E38 000AED78 54 E6 86 3E */ rlwinm r6, r7, 0x10, 0x18, 0x1f
+/* 800B1E3C 000AED7C 38 03 00 01 */ addi r0, r3, 1
+/* 800B1E40 000AED80 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1E44 000AED84 54 E0 46 3E */ srwi r0, r7, 0x18
+/* 800B1E48 000AED88 54 E5 C6 3E */ rlwinm r5, r7, 0x18, 0x18, 0x1f
+/* 800B1E4C 000AED8C 98 03 00 00 */ stb r0, 0(r3)
+/* 800B1E50 000AED90 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1E54 000AED94 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1E58 000AED98 38 03 00 01 */ addi r0, r3, 1
+/* 800B1E5C 000AED9C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1E60 000AEDA0 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B1E64 000AEDA4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1E68 000AEDA8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1E6C 000AEDAC 38 03 00 01 */ addi r0, r3, 1
+/* 800B1E70 000AEDB0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1E74 000AEDB4 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B1E78 000AEDB8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B1E7C 000AEDBC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B1E80 000AEDC0 38 03 00 01 */ addi r0, r3, 1
+/* 800B1E84 000AEDC4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B1E88 000AEDC8 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B1E8C 000AEDCC 80 01 00 1C */ lwz r0, 0x1c(r1)
+/* 800B1E90 000AEDD0 83 E1 00 14 */ lwz r31, 0x14(r1)
+/* 800B1E94 000AEDD4 83 C1 00 10 */ lwz r30, 0x10(r1)
+/* 800B1E98 000AEDD8 38 21 00 18 */ addi r1, r1, 0x18
+/* 800B1E9C 000AEDDC 7C 08 03 A6 */ mtlr r0
+/* 800B1EA0 000AEDE0 4E 80 00 20 */ blr
diff --git a/asm/Dolphin/gd/GDTev.s b/asm/Dolphin/gd/GDTev.s
new file mode 100644
index 0000000..c9ec42f
--- /dev/null
+++ b/asm/Dolphin/gd/GDTev.s
@@ -0,0 +1,677 @@
+.include "macros.inc"
+
+.section .text, "ax" # 0x80005600 - 0x8036FBA0
+.global GDSetTevOp
+GDSetTevOp:
+/* 800B1EA4 000AEDE4 7C 08 02 A6 */ mflr r0
+/* 800B1EA8 000AEDE8 38 C0 00 0A */ li r6, 0xa
+/* 800B1EAC 000AEDEC 90 01 00 04 */ stw r0, 4(r1)
+/* 800B1EB0 000AEDF0 94 21 FF D0 */ stwu r1, -0x30(r1)
+/* 800B1EB4 000AEDF4 93 E1 00 2C */ stw r31, 0x2c(r1)
+/* 800B1EB8 000AEDF8 93 C1 00 28 */ stw r30, 0x28(r1)
+/* 800B1EBC 000AEDFC 93 A1 00 24 */ stw r29, 0x24(r1)
+/* 800B1EC0 000AEE00 3B A0 00 05 */ li r29, 5
+/* 800B1EC4 000AEE04 93 81 00 20 */ stw r28, 0x20(r1)
+/* 800B1EC8 000AEE08 7C 7C 1B 79 */ or. r28, r3, r3
+/* 800B1ECC 000AEE0C 41 82 00 0C */ beq lbl_800B1ED8
+/* 800B1ED0 000AEE10 38 C0 00 00 */ li r6, 0
+/* 800B1ED4 000AEE14 3B A0 00 00 */ li r29, 0
+lbl_800B1ED8:
+/* 800B1ED8 000AEE18 2C 04 00 02 */ cmpwi r4, 2
+/* 800B1EDC 000AEE1C 41 82 00 FC */ beq lbl_800B1FD8
+/* 800B1EE0 000AEE20 40 80 00 14 */ bge lbl_800B1EF4
+/* 800B1EE4 000AEE24 2C 04 00 00 */ cmpwi r4, 0
+/* 800B1EE8 000AEE28 41 82 00 1C */ beq lbl_800B1F04
+/* 800B1EEC 000AEE2C 40 80 00 80 */ bge lbl_800B1F6C
+/* 800B1EF0 000AEE30 48 00 02 28 */ b lbl_800B2118
+lbl_800B1EF4:
+/* 800B1EF4 000AEE34 2C 04 00 04 */ cmpwi r4, 4
+/* 800B1EF8 000AEE38 41 82 01 B8 */ beq lbl_800B20B0
+/* 800B1EFC 000AEE3C 40 80 02 1C */ bge lbl_800B2118
+/* 800B1F00 000AEE40 48 00 01 44 */ b lbl_800B2044
+lbl_800B1F04:
+/* 800B1F04 000AEE44 3B E0 00 01 */ li r31, 1
+/* 800B1F08 000AEE48 93 E1 00 08 */ stw r31, 8(r1)
+/* 800B1F0C 000AEE4C 3B C0 00 00 */ li r30, 0
+/* 800B1F10 000AEE50 38 7C 00 00 */ addi r3, r28, 0
+/* 800B1F14 000AEE54 93 C1 00 0C */ stw r30, 0xc(r1)
+/* 800B1F18 000AEE58 38 80 00 0F */ li r4, 0xf
+/* 800B1F1C 000AEE5C 38 A0 00 08 */ li r5, 8
+/* 800B1F20 000AEE60 38 E0 00 0F */ li r7, 0xf
+/* 800B1F24 000AEE64 39 00 00 00 */ li r8, 0
+/* 800B1F28 000AEE68 39 20 00 00 */ li r9, 0
+/* 800B1F2C 000AEE6C 39 40 00 00 */ li r10, 0
+/* 800B1F30 000AEE70 48 00 02 09 */ bl GDSetTevColorCalc
+/* 800B1F34 000AEE74 93 E1 00 08 */ stw r31, 8(r1)
+/* 800B1F38 000AEE78 38 7C 00 00 */ addi r3, r28, 0
+/* 800B1F3C 000AEE7C 38 DD 00 00 */ addi r6, r29, 0
+/* 800B1F40 000AEE80 93 C1 00 0C */ stw r30, 0xc(r1)
+/* 800B1F44 000AEE84 38 80 00 07 */ li r4, 7
+/* 800B1F48 000AEE88 38 A0 00 04 */ li r5, 4
+/* 800B1F4C 000AEE8C 93 C1 00 10 */ stw r30, 0x10(r1)
+/* 800B1F50 000AEE90 38 E0 00 07 */ li r7, 7
+/* 800B1F54 000AEE94 39 00 00 00 */ li r8, 0
+/* 800B1F58 000AEE98 93 C1 00 14 */ stw r30, 0x14(r1)
+/* 800B1F5C 000AEE9C 39 20 00 00 */ li r9, 0
+/* 800B1F60 000AEEA0 39 40 00 00 */ li r10, 0
+/* 800B1F64 000AEEA4 48 00 04 21 */ bl GDSetTevAlphaCalcAndSwap
+/* 800B1F68 000AEEA8 48 00 01 B0 */ b lbl_800B2118
+lbl_800B1F6C:
+/* 800B1F6C 000AEEAC 3B E0 00 01 */ li r31, 1
+/* 800B1F70 000AEEB0 93 E1 00 08 */ stw r31, 8(r1)
+/* 800B1F74 000AEEB4 3B C0 00 00 */ li r30, 0
+/* 800B1F78 000AEEB8 38 7C 00 00 */ addi r3, r28, 0
+/* 800B1F7C 000AEEBC 93 C1 00 0C */ stw r30, 0xc(r1)
+/* 800B1F80 000AEEC0 38 86 00 00 */ addi r4, r6, 0
+/* 800B1F84 000AEEC4 38 A0 00 08 */ li r5, 8
+/* 800B1F88 000AEEC8 38 C0 00 09 */ li r6, 9
+/* 800B1F8C 000AEECC 38 E0 00 0F */ li r7, 0xf
+/* 800B1F90 000AEED0 39 00 00 00 */ li r8, 0
+/* 800B1F94 000AEED4 39 20 00 00 */ li r9, 0
+/* 800B1F98 000AEED8 39 40 00 00 */ li r10, 0
+/* 800B1F9C 000AEEDC 48 00 01 9D */ bl GDSetTevColorCalc
+/* 800B1FA0 000AEEE0 93 E1 00 08 */ stw r31, 8(r1)
+/* 800B1FA4 000AEEE4 38 7C 00 00 */ addi r3, r28, 0
+/* 800B1FA8 000AEEE8 38 FD 00 00 */ addi r7, r29, 0
+/* 800B1FAC 000AEEEC 93 C1 00 0C */ stw r30, 0xc(r1)
+/* 800B1FB0 000AEEF0 38 80 00 07 */ li r4, 7
+/* 800B1FB4 000AEEF4 38 A0 00 07 */ li r5, 7
+/* 800B1FB8 000AEEF8 93 C1 00 10 */ stw r30, 0x10(r1)
+/* 800B1FBC 000AEEFC 38 C0 00 07 */ li r6, 7
+/* 800B1FC0 000AEF00 39 00 00 00 */ li r8, 0
+/* 800B1FC4 000AEF04 93 C1 00 14 */ stw r30, 0x14(r1)
+/* 800B1FC8 000AEF08 39 20 00 00 */ li r9, 0
+/* 800B1FCC 000AEF0C 39 40 00 00 */ li r10, 0
+/* 800B1FD0 000AEF10 48 00 03 B5 */ bl GDSetTevAlphaCalcAndSwap
+/* 800B1FD4 000AEF14 48 00 01 44 */ b lbl_800B2118
+lbl_800B1FD8:
+/* 800B1FD8 000AEF18 3B E0 00 01 */ li r31, 1
+/* 800B1FDC 000AEF1C 93 E1 00 08 */ stw r31, 8(r1)
+/* 800B1FE0 000AEF20 3B C0 00 00 */ li r30, 0
+/* 800B1FE4 000AEF24 38 7C 00 00 */ addi r3, r28, 0
+/* 800B1FE8 000AEF28 93 C1 00 0C */ stw r30, 0xc(r1)
+/* 800B1FEC 000AEF2C 38 86 00 00 */ addi r4, r6, 0
+/* 800B1FF0 000AEF30 38 A0 00 0C */ li r5, 0xc
+/* 800B1FF4 000AEF34 38 C0 00 08 */ li r6, 8
+/* 800B1FF8 000AEF38 38 E0 00 0F */ li r7, 0xf
+/* 800B1FFC 000AEF3C 39 00 00 00 */ li r8, 0
+/* 800B2000 000AEF40 39 20 00 00 */ li r9, 0
+/* 800B2004 000AEF44 39 40 00 00 */ li r10, 0
+/* 800B2008 000AEF48 48 00 01 31 */ bl GDSetTevColorCalc
+/* 800B200C 000AEF4C 93 E1 00 08 */ stw r31, 8(r1)
+/* 800B2010 000AEF50 38 7C 00 00 */ addi r3, r28, 0
+/* 800B2014 000AEF54 38 DD 00 00 */ addi r6, r29, 0
+/* 800B2018 000AEF58 93 C1 00 0C */ stw r30, 0xc(r1)
+/* 800B201C 000AEF5C 38 80 00 07 */ li r4, 7
+/* 800B2020 000AEF60 38 A0 00 04 */ li r5, 4
+/* 800B2024 000AEF64 93 C1 00 10 */ stw r30, 0x10(r1)
+/* 800B2028 000AEF68 38 E0 00 07 */ li r7, 7
+/* 800B202C 000AEF6C 39 00 00 00 */ li r8, 0
+/* 800B2030 000AEF70 93 C1 00 14 */ stw r30, 0x14(r1)
+/* 800B2034 000AEF74 39 20 00 00 */ li r9, 0
+/* 800B2038 000AEF78 39 40 00 00 */ li r10, 0
+/* 800B203C 000AEF7C 48 00 03 49 */ bl GDSetTevAlphaCalcAndSwap
+/* 800B2040 000AEF80 48 00 00 D8 */ b lbl_800B2118
+lbl_800B2044:
+/* 800B2044 000AEF84 3B E0 00 01 */ li r31, 1
+/* 800B2048 000AEF88 93 E1 00 08 */ stw r31, 8(r1)
+/* 800B204C 000AEF8C 3B C0 00 00 */ li r30, 0
+/* 800B2050 000AEF90 38 7C 00 00 */ addi r3, r28, 0
+/* 800B2054 000AEF94 93 C1 00 0C */ stw r30, 0xc(r1)
+/* 800B2058 000AEF98 38 80 00 0F */ li r4, 0xf
+/* 800B205C 000AEF9C 38 A0 00 0F */ li r5, 0xf
+/* 800B2060 000AEFA0 38 C0 00 0F */ li r6, 0xf
+/* 800B2064 000AEFA4 38 E0 00 08 */ li r7, 8
+/* 800B2068 000AEFA8 39 00 00 00 */ li r8, 0
+/* 800B206C 000AEFAC 39 20 00 00 */ li r9, 0
+/* 800B2070 000AEFB0 39 40 00 00 */ li r10, 0
+/* 800B2074 000AEFB4 48 00 00 C5 */ bl GDSetTevColorCalc
+/* 800B2078 000AEFB8 93 E1 00 08 */ stw r31, 8(r1)
+/* 800B207C 000AEFBC 38 7C 00 00 */ addi r3, r28, 0
+/* 800B2080 000AEFC0 38 80 00 07 */ li r4, 7
+/* 800B2084 000AEFC4 93 C1 00 0C */ stw r30, 0xc(r1)
+/* 800B2088 000AEFC8 38 A0 00 07 */ li r5, 7
+/* 800B208C 000AEFCC 38 C0 00 07 */ li r6, 7
+/* 800B2090 000AEFD0 93 C1 00 10 */ stw r30, 0x10(r1)
+/* 800B2094 000AEFD4 38 E0 00 04 */ li r7, 4
+/* 800B2098 000AEFD8 39 00 00 00 */ li r8, 0
+/* 800B209C 000AEFDC 93 C1 00 14 */ stw r30, 0x14(r1)
+/* 800B20A0 000AEFE0 39 20 00 00 */ li r9, 0
+/* 800B20A4 000AEFE4 39 40 00 00 */ li r10, 0
+/* 800B20A8 000AEFE8 48 00 02 DD */ bl GDSetTevAlphaCalcAndSwap
+/* 800B20AC 000AEFEC 48 00 00 6C */ b lbl_800B2118
+lbl_800B20B0:
+/* 800B20B0 000AEFF0 3B C0 00 01 */ li r30, 1
+/* 800B20B4 000AEFF4 93 C1 00 08 */ stw r30, 8(r1)
+/* 800B20B8 000AEFF8 3B E0 00 00 */ li r31, 0
+/* 800B20BC 000AEFFC 38 7C 00 00 */ addi r3, r28, 0
+/* 800B20C0 000AF000 93 E1 00 0C */ stw r31, 0xc(r1)
+/* 800B20C4 000AF004 38 E6 00 00 */ addi r7, r6, 0
+/* 800B20C8 000AF008 38 80 00 0F */ li r4, 0xf
+/* 800B20CC 000AF00C 38 A0 00 0F */ li r5, 0xf
+/* 800B20D0 000AF010 38 C0 00 0F */ li r6, 0xf
+/* 800B20D4 000AF014 39 00 00 00 */ li r8, 0
+/* 800B20D8 000AF018 39 20 00 00 */ li r9, 0
+/* 800B20DC 000AF01C 39 40 00 00 */ li r10, 0
+/* 800B20E0 000AF020 48 00 00 59 */ bl GDSetTevColorCalc
+/* 800B20E4 000AF024 93 C1 00 08 */ stw r30, 8(r1)
+/* 800B20E8 000AF028 38 7C 00 00 */ addi r3, r28, 0
+/* 800B20EC 000AF02C 38 FD 00 00 */ addi r7, r29, 0
+/* 800B20F0 000AF030 93 E1 00 0C */ stw r31, 0xc(r1)
+/* 800B20F4 000AF034 38 80 00 07 */ li r4, 7
+/* 800B20F8 000AF038 38 A0 00 07 */ li r5, 7
+/* 800B20FC 000AF03C 93 E1 00 10 */ stw r31, 0x10(r1)
+/* 800B2100 000AF040 38 C0 00 07 */ li r6, 7
+/* 800B2104 000AF044 39 00 00 00 */ li r8, 0
+/* 800B2108 000AF048 93 E1 00 14 */ stw r31, 0x14(r1)
+/* 800B210C 000AF04C 39 20 00 00 */ li r9, 0
+/* 800B2110 000AF050 39 40 00 00 */ li r10, 0
+/* 800B2114 000AF054 48 00 02 71 */ bl GDSetTevAlphaCalcAndSwap
+lbl_800B2118:
+/* 800B2118 000AF058 80 01 00 34 */ lwz r0, 0x34(r1)
+/* 800B211C 000AF05C 83 E1 00 2C */ lwz r31, 0x2c(r1)
+/* 800B2120 000AF060 83 C1 00 28 */ lwz r30, 0x28(r1)
+/* 800B2124 000AF064 83 A1 00 24 */ lwz r29, 0x24(r1)
+/* 800B2128 000AF068 83 81 00 20 */ lwz r28, 0x20(r1)
+/* 800B212C 000AF06C 38 21 00 30 */ addi r1, r1, 0x30
+/* 800B2130 000AF070 7C 08 03 A6 */ mtlr r0
+/* 800B2134 000AF074 4E 80 00 20 */ blr
+
+.global GDSetTevColorCalc
+GDSetTevColorCalc:
+/* 800B2138 000AF078 7C 08 02 A6 */ mflr r0
+/* 800B213C 000AF07C 90 01 00 04 */ stw r0, 4(r1)
+/* 800B2140 000AF080 94 21 FF B0 */ stwu r1, -0x50(r1)
+/* 800B2144 000AF084 BE C1 00 28 */ stmw r22, 0x28(r1)
+/* 800B2148 000AF088 7D 1B 43 78 */ mr r27, r8
+/* 800B214C 000AF08C 2C 1B 00 01 */ cmpwi r27, 1
+/* 800B2150 000AF090 8B C1 00 5B */ lbz r30, 0x5b(r1)
+/* 800B2154 000AF094 83 E1 00 5C */ lwz r31, 0x5c(r1)
+/* 800B2158 000AF098 3A C3 00 00 */ addi r22, r3, 0
+/* 800B215C 000AF09C 3A E4 00 00 */ addi r23, r4, 0
+/* 800B2160 000AF0A0 3B 05 00 00 */ addi r24, r5, 0
+/* 800B2164 000AF0A4 3B 26 00 00 */ addi r25, r6, 0
+/* 800B2168 000AF0A8 3B 47 00 00 */ addi r26, r7, 0
+/* 800B216C 000AF0AC 3B 89 00 00 */ addi r28, r9, 0
+/* 800B2170 000AF0B0 3B AA 00 00 */ addi r29, r10, 0
+/* 800B2174 000AF0B4 41 81 01 04 */ bgt lbl_800B2278
+/* 800B2178 000AF0B8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B217C 000AF0BC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2180 000AF0C0 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B2184 000AF0C4 38 63 00 01 */ addi r3, r3, 1
+/* 800B2188 000AF0C8 7C 03 00 40 */ cmplw r3, r0
+/* 800B218C 000AF0CC 40 81 00 08 */ ble lbl_800B2194
+/* 800B2190 000AF0D0 4B FF CF C5 */ bl GDOverflowed
+lbl_800B2194:
+/* 800B2194 000AF0D4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2198 000AF0D8 38 A0 00 61 */ li r5, 0x61
+/* 800B219C 000AF0DC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B21A0 000AF0E0 38 03 00 01 */ addi r0, r3, 1
+/* 800B21A4 000AF0E4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B21A8 000AF0E8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B21AC 000AF0EC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B21B0 000AF0F0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B21B4 000AF0F4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B21B8 000AF0F8 38 63 00 04 */ addi r3, r3, 4
+/* 800B21BC 000AF0FC 7C 03 00 40 */ cmplw r3, r0
+/* 800B21C0 000AF100 40 81 00 08 */ ble lbl_800B21C8
+/* 800B21C4 000AF104 4B FF CF 91 */ bl GDOverflowed
+lbl_800B21C8:
+/* 800B21C8 000AF108 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B21CC 000AF10C 57 20 20 36 */ slwi r0, r25, 4
+/* 800B21D0 000AF110 57 05 40 2E */ slwi r5, r24, 8
+/* 800B21D4 000AF114 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B21D8 000AF118 7F 40 03 78 */ or r0, r26, r0
+/* 800B21DC 000AF11C 7C A6 03 78 */ or r6, r5, r0
+/* 800B21E0 000AF120 38 03 00 01 */ addi r0, r3, 1
+/* 800B21E4 000AF124 90 04 00 08 */ stw r0, 8(r4)
+/* 800B21E8 000AF128 56 E7 60 26 */ slwi r7, r23, 0xc
+/* 800B21EC 000AF12C 7C E0 33 78 */ or r0, r7, r6
+/* 800B21F0 000AF130 57 88 80 1E */ slwi r8, r28, 0x10
+/* 800B21F4 000AF134 56 C5 08 3C */ slwi r5, r22, 1
+/* 800B21F8 000AF138 57 64 93 5A */ rlwinm r4, r27, 0x12, 0xd, 0xd
+/* 800B21FC 000AF13C 7D 00 03 78 */ or r0, r8, r0
+/* 800B2200 000AF140 7C 80 03 78 */ or r0, r4, r0
+/* 800B2204 000AF144 57 C6 98 18 */ slwi r6, r30, 0x13
+/* 800B2208 000AF148 7C C0 03 78 */ or r0, r6, r0
+/* 800B220C 000AF14C 57 A4 A0 16 */ slwi r4, r29, 0x14
+/* 800B2210 000AF150 38 A5 00 C0 */ addi r5, r5, 0xc0
+/* 800B2214 000AF154 57 E6 B0 12 */ slwi r6, r31, 0x16
+/* 800B2218 000AF158 7C 80 03 78 */ or r0, r4, r0
+/* 800B221C 000AF15C 7C C4 03 78 */ or r4, r6, r0
+/* 800B2220 000AF160 54 A0 C0 0E */ slwi r0, r5, 0x18
+/* 800B2224 000AF164 7C 87 03 78 */ or r7, r4, r0
+/* 800B2228 000AF168 54 E0 46 3E */ srwi r0, r7, 0x18
+/* 800B222C 000AF16C 98 03 00 00 */ stb r0, 0(r3)
+/* 800B2230 000AF170 54 E6 86 3E */ rlwinm r6, r7, 0x10, 0x18, 0x1f
+/* 800B2234 000AF174 54 E5 C6 3E */ rlwinm r5, r7, 0x18, 0x18, 0x1f
+/* 800B2238 000AF178 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B223C 000AF17C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2240 000AF180 38 03 00 01 */ addi r0, r3, 1
+/* 800B2244 000AF184 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2248 000AF188 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B224C 000AF18C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2250 000AF190 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2254 000AF194 38 03 00 01 */ addi r0, r3, 1
+/* 800B2258 000AF198 90 04 00 08 */ stw r0, 8(r4)
+/* 800B225C 000AF19C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B2260 000AF1A0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2264 000AF1A4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2268 000AF1A8 38 03 00 01 */ addi r0, r3, 1
+/* 800B226C 000AF1AC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2270 000AF1B0 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B2274 000AF1B4 48 00 00 FC */ b lbl_800B2370
+lbl_800B2278:
+/* 800B2278 000AF1B8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B227C 000AF1BC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2280 000AF1C0 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B2284 000AF1C4 38 63 00 01 */ addi r3, r3, 1
+/* 800B2288 000AF1C8 7C 03 00 40 */ cmplw r3, r0
+/* 800B228C 000AF1CC 40 81 00 08 */ ble lbl_800B2294
+/* 800B2290 000AF1D0 4B FF CE C5 */ bl GDOverflowed
+lbl_800B2294:
+/* 800B2294 000AF1D4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2298 000AF1D8 38 A0 00 61 */ li r5, 0x61
+/* 800B229C 000AF1DC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B22A0 000AF1E0 38 03 00 01 */ addi r0, r3, 1
+/* 800B22A4 000AF1E4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B22A8 000AF1E8 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B22AC 000AF1EC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B22B0 000AF1F0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B22B4 000AF1F4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B22B8 000AF1F8 38 63 00 04 */ addi r3, r3, 4
+/* 800B22BC 000AF1FC 7C 03 00 40 */ cmplw r3, r0
+/* 800B22C0 000AF200 40 81 00 08 */ ble lbl_800B22C8
+/* 800B22C4 000AF204 4B FF CE 91 */ bl GDOverflowed
+lbl_800B22C8:
+/* 800B22C8 000AF208 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B22CC 000AF20C 57 20 20 36 */ slwi r0, r25, 4
+/* 800B22D0 000AF210 57 05 40 2E */ slwi r5, r24, 8
+/* 800B22D4 000AF214 7F 40 03 78 */ or r0, r26, r0
+/* 800B22D8 000AF218 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B22DC 000AF21C 7C A0 03 78 */ or r0, r5, r0
+/* 800B22E0 000AF220 56 E6 60 26 */ slwi r6, r23, 0xc
+/* 800B22E4 000AF224 7C C6 03 78 */ or r6, r6, r0
+/* 800B22E8 000AF228 38 03 00 01 */ addi r0, r3, 1
+/* 800B22EC 000AF22C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B22F0 000AF230 64 C0 00 03 */ oris r0, r6, 3
+/* 800B22F4 000AF234 57 67 93 5A */ rlwinm r7, r27, 0x12, 0xd, 0xd
+/* 800B22F8 000AF238 56 C5 08 3C */ slwi r5, r22, 1
+/* 800B22FC 000AF23C 57 C4 98 18 */ slwi r4, r30, 0x13
+/* 800B2300 000AF240 7C E0 03 78 */ or r0, r7, r0
+/* 800B2304 000AF244 7C 80 03 78 */ or r0, r4, r0
+/* 800B2308 000AF248 57 66 9A 96 */ rlwinm r6, r27, 0x13, 0xa, 0xb
+/* 800B230C 000AF24C 38 A5 00 C0 */ addi r5, r5, 0xc0
+/* 800B2310 000AF250 57 E4 B0 12 */ slwi r4, r31, 0x16
+/* 800B2314 000AF254 7C C0 03 78 */ or r0, r6, r0
+/* 800B2318 000AF258 7C 84 03 78 */ or r4, r4, r0
+/* 800B231C 000AF25C 54 A0 C0 0E */ slwi r0, r5, 0x18
+/* 800B2320 000AF260 7C 87 03 78 */ or r7, r4, r0
+/* 800B2324 000AF264 54 E0 46 3E */ srwi r0, r7, 0x18
+/* 800B2328 000AF268 98 03 00 00 */ stb r0, 0(r3)
+/* 800B232C 000AF26C 54 E6 86 3E */ rlwinm r6, r7, 0x10, 0x18, 0x1f
+/* 800B2330 000AF270 54 E5 C6 3E */ rlwinm r5, r7, 0x18, 0x18, 0x1f
+/* 800B2334 000AF274 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2338 000AF278 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B233C 000AF27C 38 03 00 01 */ addi r0, r3, 1
+/* 800B2340 000AF280 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2344 000AF284 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B2348 000AF288 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B234C 000AF28C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2350 000AF290 38 03 00 01 */ addi r0, r3, 1
+/* 800B2354 000AF294 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2358 000AF298 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B235C 000AF29C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2360 000AF2A0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2364 000AF2A4 38 03 00 01 */ addi r0, r3, 1
+/* 800B2368 000AF2A8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B236C 000AF2AC 98 E3 00 00 */ stb r7, 0(r3)
+lbl_800B2370:
+/* 800B2370 000AF2B0 BA C1 00 28 */ lmw r22, 0x28(r1)
+/* 800B2374 000AF2B4 80 01 00 54 */ lwz r0, 0x54(r1)
+/* 800B2378 000AF2B8 38 21 00 50 */ addi r1, r1, 0x50
+/* 800B237C 000AF2BC 7C 08 03 A6 */ mtlr r0
+/* 800B2380 000AF2C0 4E 80 00 20 */ blr
+
+.global GDSetTevAlphaCalcAndSwap
+GDSetTevAlphaCalcAndSwap:
+/* 800B2384 000AF2C4 7C 08 02 A6 */ mflr r0
+/* 800B2388 000AF2C8 90 01 00 04 */ stw r0, 4(r1)
+/* 800B238C 000AF2CC 94 21 FF A8 */ stwu r1, -0x58(r1)
+/* 800B2390 000AF2D0 BE 81 00 28 */ stmw r20, 0x28(r1)
+/* 800B2394 000AF2D4 7D 19 43 78 */ mr r25, r8
+/* 800B2398 000AF2D8 2C 19 00 01 */ cmpwi r25, 1
+/* 800B239C 000AF2DC 8B 81 00 63 */ lbz r28, 0x63(r1)
+/* 800B23A0 000AF2E0 83 A1 00 64 */ lwz r29, 0x64(r1)
+/* 800B23A4 000AF2E4 83 C1 00 68 */ lwz r30, 0x68(r1)
+/* 800B23A8 000AF2E8 7C 74 1B 78 */ mr r20, r3
+/* 800B23AC 000AF2EC 83 E1 00 6C */ lwz r31, 0x6c(r1)
+/* 800B23B0 000AF2F0 3A A4 00 00 */ addi r21, r4, 0
+/* 800B23B4 000AF2F4 3A C5 00 00 */ addi r22, r5, 0
+/* 800B23B8 000AF2F8 3A E6 00 00 */ addi r23, r6, 0
+/* 800B23BC 000AF2FC 3B 07 00 00 */ addi r24, r7, 0
+/* 800B23C0 000AF300 3B 49 00 00 */ addi r26, r9, 0
+/* 800B23C4 000AF304 3B 6A 00 00 */ addi r27, r10, 0
+/* 800B23C8 000AF308 41 81 01 14 */ bgt lbl_800B24DC
+/* 800B23CC 000AF30C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B23D0 000AF310 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B23D4 000AF314 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B23D8 000AF318 38 63 00 01 */ addi r3, r3, 1
+/* 800B23DC 000AF31C 7C 03 00 40 */ cmplw r3, r0
+/* 800B23E0 000AF320 40 81 00 08 */ ble lbl_800B23E8
+/* 800B23E4 000AF324 4B FF CD 71 */ bl GDOverflowed
+lbl_800B23E8:
+/* 800B23E8 000AF328 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B23EC 000AF32C 38 A0 00 61 */ li r5, 0x61
+/* 800B23F0 000AF330 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B23F4 000AF334 38 03 00 01 */ addi r0, r3, 1
+/* 800B23F8 000AF338 90 04 00 08 */ stw r0, 8(r4)
+/* 800B23FC 000AF33C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B2400 000AF340 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2404 000AF344 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2408 000AF348 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B240C 000AF34C 38 63 00 04 */ addi r3, r3, 4
+/* 800B2410 000AF350 7C 03 00 40 */ cmplw r3, r0
+/* 800B2414 000AF354 40 81 00 08 */ ble lbl_800B241C
+/* 800B2418 000AF358 4B FF CD 3D */ bl GDOverflowed
+lbl_800B241C:
+/* 800B241C 000AF35C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2420 000AF360 57 E0 10 3A */ slwi r0, r31, 2
+/* 800B2424 000AF364 57 05 20 36 */ slwi r5, r24, 4
+/* 800B2428 000AF368 7F C0 03 78 */ or r0, r30, r0
+/* 800B242C 000AF36C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2430 000AF370 7C A0 03 78 */ or r0, r5, r0
+/* 800B2434 000AF374 56 E6 38 30 */ slwi r6, r23, 7
+/* 800B2438 000AF378 7C C6 03 78 */ or r6, r6, r0
+/* 800B243C 000AF37C 38 03 00 01 */ addi r0, r3, 1
+/* 800B2440 000AF380 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2444 000AF384 56 C7 50 2A */ slwi r7, r22, 0xa
+/* 800B2448 000AF388 7C E0 33 78 */ or r0, r7, r6
+/* 800B244C 000AF38C 56 A8 68 24 */ slwi r8, r21, 0xd
+/* 800B2450 000AF390 56 85 08 3C */ slwi r5, r20, 1
+/* 800B2454 000AF394 57 44 80 1E */ slwi r4, r26, 0x10
+/* 800B2458 000AF398 7D 00 03 78 */ or r0, r8, r0
+/* 800B245C 000AF39C 7C 80 03 78 */ or r0, r4, r0
+/* 800B2460 000AF3A0 57 26 93 5A */ rlwinm r6, r25, 0x12, 0xd, 0xd
+/* 800B2464 000AF3A4 7C C0 03 78 */ or r0, r6, r0
+/* 800B2468 000AF3A8 57 84 98 18 */ slwi r4, r28, 0x13
+/* 800B246C 000AF3AC 7C 80 03 78 */ or r0, r4, r0
+/* 800B2470 000AF3B0 57 66 A0 16 */ slwi r6, r27, 0x14
+/* 800B2474 000AF3B4 38 A5 00 C1 */ addi r5, r5, 0xc1
+/* 800B2478 000AF3B8 57 A4 B0 12 */ slwi r4, r29, 0x16
+/* 800B247C 000AF3BC 7C C0 03 78 */ or r0, r6, r0
+/* 800B2480 000AF3C0 7C 84 03 78 */ or r4, r4, r0
+/* 800B2484 000AF3C4 54 A0 C0 0E */ slwi r0, r5, 0x18
+/* 800B2488 000AF3C8 7C 87 03 78 */ or r7, r4, r0
+/* 800B248C 000AF3CC 54 E0 46 3E */ srwi r0, r7, 0x18
+/* 800B2490 000AF3D0 98 03 00 00 */ stb r0, 0(r3)
+/* 800B2494 000AF3D4 54 E6 86 3E */ rlwinm r6, r7, 0x10, 0x18, 0x1f
+/* 800B2498 000AF3D8 54 E5 C6 3E */ rlwinm r5, r7, 0x18, 0x18, 0x1f
+/* 800B249C 000AF3DC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B24A0 000AF3E0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B24A4 000AF3E4 38 03 00 01 */ addi r0, r3, 1
+/* 800B24A8 000AF3E8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B24AC 000AF3EC 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B24B0 000AF3F0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B24B4 000AF3F4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B24B8 000AF3F8 38 03 00 01 */ addi r0, r3, 1
+/* 800B24BC 000AF3FC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B24C0 000AF400 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B24C4 000AF404 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B24C8 000AF408 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B24CC 000AF40C 38 03 00 01 */ addi r0, r3, 1
+/* 800B24D0 000AF410 90 04 00 08 */ stw r0, 8(r4)
+/* 800B24D4 000AF414 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B24D8 000AF418 48 00 01 0C */ b lbl_800B25E4
+lbl_800B24DC:
+/* 800B24DC 000AF41C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B24E0 000AF420 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B24E4 000AF424 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B24E8 000AF428 38 63 00 01 */ addi r3, r3, 1
+/* 800B24EC 000AF42C 7C 03 00 40 */ cmplw r3, r0
+/* 800B24F0 000AF430 40 81 00 08 */ ble lbl_800B24F8
+/* 800B24F4 000AF434 4B FF CC 61 */ bl GDOverflowed
+lbl_800B24F8:
+/* 800B24F8 000AF438 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B24FC 000AF43C 38 A0 00 61 */ li r5, 0x61
+/* 800B2500 000AF440 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2504 000AF444 38 03 00 01 */ addi r0, r3, 1
+/* 800B2508 000AF448 90 04 00 08 */ stw r0, 8(r4)
+/* 800B250C 000AF44C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B2510 000AF450 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2514 000AF454 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2518 000AF458 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B251C 000AF45C 38 63 00 04 */ addi r3, r3, 4
+/* 800B2520 000AF460 7C 03 00 40 */ cmplw r3, r0
+/* 800B2524 000AF464 40 81 00 08 */ ble lbl_800B252C
+/* 800B2528 000AF468 4B FF CC 2D */ bl GDOverflowed
+lbl_800B252C:
+/* 800B252C 000AF46C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2530 000AF470 57 E0 10 3A */ slwi r0, r31, 2
+/* 800B2534 000AF474 57 05 20 36 */ slwi r5, r24, 4
+/* 800B2538 000AF478 7F C0 03 78 */ or r0, r30, r0
+/* 800B253C 000AF47C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2540 000AF480 7C A0 03 78 */ or r0, r5, r0
+/* 800B2544 000AF484 56 E6 38 30 */ slwi r6, r23, 7
+/* 800B2548 000AF488 7C C6 03 78 */ or r6, r6, r0
+/* 800B254C 000AF48C 38 03 00 01 */ addi r0, r3, 1
+/* 800B2550 000AF490 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2554 000AF494 56 C7 50 2A */ slwi r7, r22, 0xa
+/* 800B2558 000AF498 7C E0 33 78 */ or r0, r7, r6
+/* 800B255C 000AF49C 56 A8 68 24 */ slwi r8, r21, 0xd
+/* 800B2560 000AF4A0 7D 00 03 78 */ or r0, r8, r0
+/* 800B2564 000AF4A4 56 85 08 3C */ slwi r5, r20, 1
+/* 800B2568 000AF4A8 57 24 93 5A */ rlwinm r4, r25, 0x12, 0xd, 0xd
+/* 800B256C 000AF4AC 64 00 00 03 */ oris r0, r0, 3
+/* 800B2570 000AF4B0 7C 80 03 78 */ or r0, r4, r0
+/* 800B2574 000AF4B4 57 86 98 18 */ slwi r6, r28, 0x13
+/* 800B2578 000AF4B8 7C C0 03 78 */ or r0, r6, r0
+/* 800B257C 000AF4BC 57 24 9A 96 */ rlwinm r4, r25, 0x13, 0xa, 0xb
+/* 800B2580 000AF4C0 38 A5 00 C1 */ addi r5, r5, 0xc1
+/* 800B2584 000AF4C4 57 A6 B0 12 */ slwi r6, r29, 0x16
+/* 800B2588 000AF4C8 7C 80 03 78 */ or r0, r4, r0
+/* 800B258C 000AF4CC 7C C4 03 78 */ or r4, r6, r0
+/* 800B2590 000AF4D0 54 A0 C0 0E */ slwi r0, r5, 0x18
+/* 800B2594 000AF4D4 7C 87 03 78 */ or r7, r4, r0
+/* 800B2598 000AF4D8 54 E0 46 3E */ srwi r0, r7, 0x18
+/* 800B259C 000AF4DC 98 03 00 00 */ stb r0, 0(r3)
+/* 800B25A0 000AF4E0 54 E6 86 3E */ rlwinm r6, r7, 0x10, 0x18, 0x1f
+/* 800B25A4 000AF4E4 54 E5 C6 3E */ rlwinm r5, r7, 0x18, 0x18, 0x1f
+/* 800B25A8 000AF4E8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B25AC 000AF4EC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B25B0 000AF4F0 38 03 00 01 */ addi r0, r3, 1
+/* 800B25B4 000AF4F4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B25B8 000AF4F8 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B25BC 000AF4FC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B25C0 000AF500 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B25C4 000AF504 38 03 00 01 */ addi r0, r3, 1
+/* 800B25C8 000AF508 90 04 00 08 */ stw r0, 8(r4)
+/* 800B25CC 000AF50C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B25D0 000AF510 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B25D4 000AF514 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B25D8 000AF518 38 03 00 01 */ addi r0, r3, 1
+/* 800B25DC 000AF51C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B25E0 000AF520 98 E3 00 00 */ stb r7, 0(r3)
+lbl_800B25E4:
+/* 800B25E4 000AF524 BA 81 00 28 */ lmw r20, 0x28(r1)
+/* 800B25E8 000AF528 80 01 00 5C */ lwz r0, 0x5c(r1)
+/* 800B25EC 000AF52C 38 21 00 58 */ addi r1, r1, 0x58
+/* 800B25F0 000AF530 7C 08 03 A6 */ mtlr r0
+/* 800B25F4 000AF534 4E 80 00 20 */ blr
+
+.global GDSetAlphaCompare
+GDSetAlphaCompare:
+/* 800B25F8 000AF538 7C 08 02 A6 */ mflr r0
+/* 800B25FC 000AF53C 90 01 00 04 */ stw r0, 4(r1)
+/* 800B2600 000AF540 94 21 FF C8 */ stwu r1, -0x38(r1)
+/* 800B2604 000AF544 BF 61 00 24 */ stmw r27, 0x24(r1)
+/* 800B2608 000AF548 3B 83 00 00 */ addi r28, r3, 0
+/* 800B260C 000AF54C 3B A4 00 00 */ addi r29, r4, 0
+/* 800B2610 000AF550 7C BE 2B 78 */ mr r30, r5
+/* 800B2614 000AF554 3B E6 00 00 */ addi r31, r6, 0
+/* 800B2618 000AF558 3B 67 00 00 */ addi r27, r7, 0
+/* 800B261C 000AF55C 81 0D 95 B8 */ lwz r8, __GDCurrentDL@sda21(r13)
+/* 800B2620 000AF560 80 68 00 08 */ lwz r3, 8(r8)
+/* 800B2624 000AF564 80 08 00 0C */ lwz r0, 0xc(r8)
+/* 800B2628 000AF568 38 63 00 01 */ addi r3, r3, 1
+/* 800B262C 000AF56C 7C 03 00 40 */ cmplw r3, r0
+/* 800B2630 000AF570 40 81 00 08 */ ble lbl_800B2638
+/* 800B2634 000AF574 4B FF CB 21 */ bl GDOverflowed
+lbl_800B2638:
+/* 800B2638 000AF578 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B263C 000AF57C 38 A0 00 61 */ li r5, 0x61
+/* 800B2640 000AF580 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2644 000AF584 38 03 00 01 */ addi r0, r3, 1
+/* 800B2648 000AF588 90 04 00 08 */ stw r0, 8(r4)
+/* 800B264C 000AF58C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B2650 000AF590 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2654 000AF594 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2658 000AF598 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B265C 000AF59C 38 63 00 04 */ addi r3, r3, 4
+/* 800B2660 000AF5A0 7C 03 00 40 */ cmplw r3, r0
+/* 800B2664 000AF5A4 40 81 00 08 */ ble lbl_800B266C
+/* 800B2668 000AF5A8 4B FF CA ED */ bl GDOverflowed
+lbl_800B266C:
+/* 800B266C 000AF5AC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2670 000AF5B0 57 65 44 2E */ rlwinm r5, r27, 8, 0x10, 0x17
+/* 800B2674 000AF5B4 53 A5 06 3E */ rlwimi r5, r29, 0, 0x18, 0x1f
+/* 800B2678 000AF5B8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B267C 000AF5BC 57 E6 98 18 */ slwi r6, r31, 0x13
+/* 800B2680 000AF5C0 53 85 80 1E */ rlwimi r5, r28, 0x10, 0, 0xf
+/* 800B2684 000AF5C4 38 03 00 01 */ addi r0, r3, 1
+/* 800B2688 000AF5C8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B268C 000AF5CC 57 C4 B0 12 */ slwi r4, r30, 0x16
+/* 800B2690 000AF5D0 7C C0 2B 78 */ or r0, r6, r5
+/* 800B2694 000AF5D4 7C 80 03 78 */ or r0, r4, r0
+/* 800B2698 000AF5D8 64 07 F3 00 */ oris r7, r0, 0xf300
+/* 800B269C 000AF5DC 54 E0 46 3E */ srwi r0, r7, 0x18
+/* 800B26A0 000AF5E0 98 03 00 00 */ stb r0, 0(r3)
+/* 800B26A4 000AF5E4 54 E6 86 3E */ rlwinm r6, r7, 0x10, 0x18, 0x1f
+/* 800B26A8 000AF5E8 54 E5 C6 3E */ rlwinm r5, r7, 0x18, 0x18, 0x1f
+/* 800B26AC 000AF5EC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B26B0 000AF5F0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B26B4 000AF5F4 38 03 00 01 */ addi r0, r3, 1
+/* 800B26B8 000AF5F8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B26BC 000AF5FC 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B26C0 000AF600 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B26C4 000AF604 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B26C8 000AF608 38 03 00 01 */ addi r0, r3, 1
+/* 800B26CC 000AF60C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B26D0 000AF610 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B26D4 000AF614 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B26D8 000AF618 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B26DC 000AF61C 38 03 00 01 */ addi r0, r3, 1
+/* 800B26E0 000AF620 90 04 00 08 */ stw r0, 8(r4)
+/* 800B26E4 000AF624 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B26E8 000AF628 BB 61 00 24 */ lmw r27, 0x24(r1)
+/* 800B26EC 000AF62C 80 01 00 3C */ lwz r0, 0x3c(r1)
+/* 800B26F0 000AF630 38 21 00 38 */ addi r1, r1, 0x38
+/* 800B26F4 000AF634 7C 08 03 A6 */ mtlr r0
+/* 800B26F8 000AF638 4E 80 00 20 */ blr
+
+.global GDSetTevOrder
+GDSetTevOrder:
+/* 800B26FC 000AF63C 7C 08 02 A6 */ mflr r0
+/* 800B2700 000AF640 2C 05 00 FF */ cmpwi r5, 0xff
+/* 800B2704 000AF644 90 01 00 04 */ stw r0, 4(r1)
+/* 800B2708 000AF648 94 21 FF D0 */ stwu r1, -0x30(r1)
+/* 800B270C 000AF64C 93 E1 00 2C */ stw r31, 0x2c(r1)
+/* 800B2710 000AF650 3B E0 00 00 */ li r31, 0
+/* 800B2714 000AF654 93 C1 00 28 */ stw r30, 0x28(r1)
+/* 800B2718 000AF658 41 82 00 10 */ beq lbl_800B2728
+/* 800B271C 000AF65C 54 A0 05 EF */ rlwinm. r0, r5, 0, 0x17, 0x17
+/* 800B2720 000AF660 40 82 00 08 */ bne lbl_800B2728
+/* 800B2724 000AF664 3B E0 00 01 */ li r31, 1
+lbl_800B2728:
+/* 800B2728 000AF668 2C 08 00 FF */ cmpwi r8, 0xff
+/* 800B272C 000AF66C 38 00 00 00 */ li r0, 0
+/* 800B2730 000AF670 41 82 00 10 */ beq lbl_800B2740
+/* 800B2734 000AF674 55 0A 05 EF */ rlwinm. r10, r8, 0, 0x17, 0x17
+/* 800B2738 000AF678 40 82 00 08 */ bne lbl_800B2740
+/* 800B273C 000AF67C 38 00 00 01 */ li r0, 1
+lbl_800B2740:
+/* 800B2740 000AF680 3D 40 80 3B */ lis r10, c2r$382@ha
+/* 800B2744 000AF684 83 CD 95 B8 */ lwz r30, __GDCurrentDL@sda21(r13)
+/* 800B2748 000AF688 39 8A 1C F8 */ addi r12, r10, c2r$382@l
+/* 800B274C 000AF68C 54 C6 07 3E */ clrlwi r6, r6, 0x1c
+/* 800B2750 000AF690 81 5E 00 08 */ lwz r10, 8(r30)
+/* 800B2754 000AF694 7D 6C 32 14 */ add r11, r12, r6
+/* 800B2758 000AF698 80 DE 00 0C */ lwz r6, 0xc(r30)
+/* 800B275C 000AF69C 89 6B 00 00 */ lbz r11, 0(r11)
+/* 800B2760 000AF6A0 55 29 07 3E */ clrlwi r9, r9, 0x1c
+/* 800B2764 000AF6A4 54 84 1E B8 */ rlwinm r4, r4, 3, 0x1a, 0x1c
+/* 800B2768 000AF6A8 50 A4 07 7E */ rlwimi r4, r5, 0, 0x1d, 0x1f
+/* 800B276C 000AF6AC 7D 2C 4A 14 */ add r9, r12, r9
+/* 800B2770 000AF6B0 7C 6C 0E 70 */ srawi r12, r3, 1
+/* 800B2774 000AF6B4 89 29 00 00 */ lbz r9, 0(r9)
+/* 800B2778 000AF6B8 38 6A 00 01 */ addi r3, r10, 1
+/* 800B277C 000AF6BC 7D 8C 01 94 */ addze r12, r12
+/* 800B2780 000AF6C0 7C 03 30 40 */ cmplw r3, r6
+/* 800B2784 000AF6C4 55 65 38 30 */ slwi r5, r11, 7
+/* 800B2788 000AF6C8 53 E4 30 32 */ rlwimi r4, r31, 6, 0, 0x19
+/* 800B278C 000AF6CC 7C A4 23 78 */ or r4, r5, r4
+/* 800B2790 000AF6D0 55 08 64 66 */ rlwinm r8, r8, 0xc, 0x11, 0x13
+/* 800B2794 000AF6D4 54 E5 7B A0 */ rlwinm r5, r7, 0xf, 0xe, 0x10
+/* 800B2798 000AF6D8 7D 04 23 78 */ or r4, r8, r4
+/* 800B279C 000AF6DC 54 07 90 1A */ slwi r7, r0, 0x12
+/* 800B27A0 000AF6E0 7C A0 23 78 */ or r0, r5, r4
+/* 800B27A4 000AF6E4 39 4C 00 28 */ addi r10, r12, 0x28
+/* 800B27A8 000AF6E8 55 23 98 18 */ slwi r3, r9, 0x13
+/* 800B27AC 000AF6EC 7C E0 03 78 */ or r0, r7, r0
+/* 800B27B0 000AF6F0 55 44 C0 0E */ slwi r4, r10, 0x18
+/* 800B27B4 000AF6F4 7C 60 03 78 */ or r0, r3, r0
+/* 800B27B8 000AF6F8 7C 9F 03 78 */ or r31, r4, r0
+/* 800B27BC 000AF6FC 40 81 00 08 */ ble lbl_800B27C4
+/* 800B27C0 000AF700 4B FF C9 95 */ bl GDOverflowed
+lbl_800B27C4:
+/* 800B27C4 000AF704 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B27C8 000AF708 38 A0 00 61 */ li r5, 0x61
+/* 800B27CC 000AF70C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B27D0 000AF710 38 03 00 01 */ addi r0, r3, 1
+/* 800B27D4 000AF714 90 04 00 08 */ stw r0, 8(r4)
+/* 800B27D8 000AF718 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B27DC 000AF71C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B27E0 000AF720 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B27E4 000AF724 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B27E8 000AF728 38 63 00 04 */ addi r3, r3, 4
+/* 800B27EC 000AF72C 7C 03 00 40 */ cmplw r3, r0
+/* 800B27F0 000AF730 40 81 00 08 */ ble lbl_800B27F8
+/* 800B27F4 000AF734 4B FF C9 61 */ bl GDOverflowed
+lbl_800B27F8:
+/* 800B27F8 000AF738 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B27FC 000AF73C 57 E7 46 3E */ srwi r7, r31, 0x18
+/* 800B2800 000AF740 57 E6 86 3E */ rlwinm r6, r31, 0x10, 0x18, 0x1f
+/* 800B2804 000AF744 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2808 000AF748 57 E5 C6 3E */ rlwinm r5, r31, 0x18, 0x18, 0x1f
+/* 800B280C 000AF74C 38 03 00 01 */ addi r0, r3, 1
+/* 800B2810 000AF750 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2814 000AF754 98 E3 00 00 */ stb r7, 0(r3)
+/* 800B2818 000AF758 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B281C 000AF75C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2820 000AF760 38 03 00 01 */ addi r0, r3, 1
+/* 800B2824 000AF764 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2828 000AF768 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B282C 000AF76C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2830 000AF770 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2834 000AF774 38 03 00 01 */ addi r0, r3, 1
+/* 800B2838 000AF778 90 04 00 08 */ stw r0, 8(r4)
+/* 800B283C 000AF77C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B2840 000AF780 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2844 000AF784 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2848 000AF788 38 03 00 01 */ addi r0, r3, 1
+/* 800B284C 000AF78C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2850 000AF790 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B2854 000AF794 80 01 00 34 */ lwz r0, 0x34(r1)
+/* 800B2858 000AF798 83 E1 00 2C */ lwz r31, 0x2c(r1)
+/* 800B285C 000AF79C 83 C1 00 28 */ lwz r30, 0x28(r1)
+/* 800B2860 000AF7A0 38 21 00 30 */ addi r1, r1, 0x30
+/* 800B2864 000AF7A4 7C 08 03 A6 */ mtlr r0
+/* 800B2868 000AF7A8 4E 80 00 20 */ blr
+
+.section .data, "wa" # 0x803A8380 - 0x803E6000
+ .balign 8
+c2r$382:
+ .4byte 0x00010001
+ .4byte 0x00010705
+ .4byte 0x06000000
+ .4byte 0x00000007
diff --git a/asm/Dolphin/gd/GDTransform.s b/asm/Dolphin/gd/GDTransform.s
new file mode 100644
index 0000000..cea9831
--- /dev/null
+++ b/asm/Dolphin/gd/GDTransform.s
@@ -0,0 +1,259 @@
+.include "macros.inc"
+
+.section .text, "ax" # 0x80005600 - 0x8036FBA0
+.global GDSetCurrentMtx
+GDSetCurrentMtx:
+/* 800B286C 000AF7AC 7C 08 02 A6 */ mflr r0
+/* 800B2870 000AF7B0 54 8B 30 32 */ slwi r11, r4, 6
+/* 800B2874 000AF7B4 90 01 00 04 */ stw r0, 4(r1)
+/* 800B2878 000AF7B8 55 29 30 32 */ slwi r9, r9, 6
+/* 800B287C 000AF7BC 54 C6 90 1A */ slwi r6, r6, 0x12
+/* 800B2880 000AF7C0 94 21 FF B0 */ stwu r1, -0x50(r1)
+/* 800B2884 000AF7C4 54 E7 C0 0E */ slwi r7, r7, 0x18
+/* 800B2888 000AF7C8 BE E1 00 2C */ stmw r23, 0x2c(r1)
+/* 800B288C 000AF7CC 82 E1 00 58 */ lwz r23, 0x58(r1)
+/* 800B2890 000AF7D0 81 8D 95 B8 */ lwz r12, __GDCurrentDL@sda21(r13)
+/* 800B2894 000AF7D4 80 8C 00 08 */ lwz r4, 8(r12)
+/* 800B2898 000AF7D8 80 0C 00 0C */ lwz r0, 0xc(r12)
+/* 800B289C 000AF7DC 54 AC 60 26 */ slwi r12, r5, 0xc
+/* 800B28A0 000AF7E0 7C 65 5B 78 */ or r5, r3, r11
+/* 800B28A4 000AF7E4 38 64 00 01 */ addi r3, r4, 1
+/* 800B28A8 000AF7E8 7C 03 00 40 */ cmplw r3, r0
+/* 800B28AC 000AF7EC 7D 84 2B 78 */ or r4, r12, r5
+/* 800B28B0 000AF7F0 7C C5 23 78 */ or r5, r6, r4
+/* 800B28B4 000AF7F4 55 43 60 26 */ slwi r3, r10, 0xc
+/* 800B28B8 000AF7F8 7D 00 4B 78 */ or r0, r8, r9
+/* 800B28BC 000AF7FC 56 E4 90 1A */ slwi r4, r23, 0x12
+/* 800B28C0 000AF800 7C 60 03 78 */ or r0, r3, r0
+/* 800B28C4 000AF804 7C F8 2B 78 */ or r24, r7, r5
+/* 800B28C8 000AF808 7C 97 03 78 */ or r23, r4, r0
+/* 800B28CC 000AF80C 40 81 00 08 */ ble lbl_800B28D4
+/* 800B28D0 000AF810 4B FF C8 85 */ bl GDOverflowed
+lbl_800B28D4:
+/* 800B28D4 000AF814 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B28D8 000AF818 38 A0 00 08 */ li r5, 8
+/* 800B28DC 000AF81C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B28E0 000AF820 38 03 00 01 */ addi r0, r3, 1
+/* 800B28E4 000AF824 90 04 00 08 */ stw r0, 8(r4)
+/* 800B28E8 000AF828 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B28EC 000AF82C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B28F0 000AF830 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B28F4 000AF834 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B28F8 000AF838 38 63 00 01 */ addi r3, r3, 1
+/* 800B28FC 000AF83C 7C 03 00 40 */ cmplw r3, r0
+/* 800B2900 000AF840 40 81 00 08 */ ble lbl_800B2908
+/* 800B2904 000AF844 4B FF C8 51 */ bl GDOverflowed
+lbl_800B2908:
+/* 800B2908 000AF848 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B290C 000AF84C 38 A0 00 30 */ li r5, 0x30
+/* 800B2910 000AF850 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2914 000AF854 38 03 00 01 */ addi r0, r3, 1
+/* 800B2918 000AF858 90 04 00 08 */ stw r0, 8(r4)
+/* 800B291C 000AF85C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B2920 000AF860 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2924 000AF864 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2928 000AF868 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B292C 000AF86C 38 63 00 04 */ addi r3, r3, 4
+/* 800B2930 000AF870 7C 03 00 40 */ cmplw r3, r0
+/* 800B2934 000AF874 40 81 00 08 */ ble lbl_800B293C
+/* 800B2938 000AF878 4B FF C8 1D */ bl GDOverflowed
+lbl_800B293C:
+/* 800B293C 000AF87C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2940 000AF880 57 1F 46 3E */ srwi r31, r24, 0x18
+/* 800B2944 000AF884 57 1E 86 3E */ rlwinm r30, r24, 0x10, 0x18, 0x1f
+/* 800B2948 000AF888 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B294C 000AF88C 57 1D C6 3E */ rlwinm r29, r24, 0x18, 0x18, 0x1f
+/* 800B2950 000AF890 57 1C 06 3E */ clrlwi r28, r24, 0x18
+/* 800B2954 000AF894 38 03 00 01 */ addi r0, r3, 1
+/* 800B2958 000AF898 90 04 00 08 */ stw r0, 8(r4)
+/* 800B295C 000AF89C 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B2960 000AF8A0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2964 000AF8A4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2968 000AF8A8 38 03 00 01 */ addi r0, r3, 1
+/* 800B296C 000AF8AC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2970 000AF8B0 9B C3 00 00 */ stb r30, 0(r3)
+/* 800B2974 000AF8B4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2978 000AF8B8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B297C 000AF8BC 38 03 00 01 */ addi r0, r3, 1
+/* 800B2980 000AF8C0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2984 000AF8C4 9B A3 00 00 */ stb r29, 0(r3)
+/* 800B2988 000AF8C8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B298C 000AF8CC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2990 000AF8D0 38 03 00 01 */ addi r0, r3, 1
+/* 800B2994 000AF8D4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2998 000AF8D8 9B 03 00 00 */ stb r24, 0(r3)
+/* 800B299C 000AF8DC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B29A0 000AF8E0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B29A4 000AF8E4 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B29A8 000AF8E8 38 63 00 01 */ addi r3, r3, 1
+/* 800B29AC 000AF8EC 7C 03 00 40 */ cmplw r3, r0
+/* 800B29B0 000AF8F0 40 81 00 08 */ ble lbl_800B29B8
+/* 800B29B4 000AF8F4 4B FF C7 A1 */ bl GDOverflowed
+lbl_800B29B8:
+/* 800B29B8 000AF8F8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B29BC 000AF8FC 38 A0 00 08 */ li r5, 8
+/* 800B29C0 000AF900 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B29C4 000AF904 38 03 00 01 */ addi r0, r3, 1
+/* 800B29C8 000AF908 90 04 00 08 */ stw r0, 8(r4)
+/* 800B29CC 000AF90C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B29D0 000AF910 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B29D4 000AF914 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B29D8 000AF918 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B29DC 000AF91C 38 63 00 01 */ addi r3, r3, 1
+/* 800B29E0 000AF920 7C 03 00 40 */ cmplw r3, r0
+/* 800B29E4 000AF924 40 81 00 08 */ ble lbl_800B29EC
+/* 800B29E8 000AF928 4B FF C7 6D */ bl GDOverflowed
+lbl_800B29EC:
+/* 800B29EC 000AF92C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B29F0 000AF930 38 A0 00 40 */ li r5, 0x40
+/* 800B29F4 000AF934 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B29F8 000AF938 38 03 00 01 */ addi r0, r3, 1
+/* 800B29FC 000AF93C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2A00 000AF940 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B2A04 000AF944 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2A08 000AF948 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2A0C 000AF94C 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B2A10 000AF950 38 63 00 04 */ addi r3, r3, 4
+/* 800B2A14 000AF954 7C 03 00 40 */ cmplw r3, r0
+/* 800B2A18 000AF958 40 81 00 08 */ ble lbl_800B2A20
+/* 800B2A1C 000AF95C 4B FF C7 39 */ bl GDOverflowed
+lbl_800B2A20:
+/* 800B2A20 000AF960 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2A24 000AF964 56 FB 46 3E */ srwi r27, r23, 0x18
+/* 800B2A28 000AF968 56 FA 86 3E */ rlwinm r26, r23, 0x10, 0x18, 0x1f
+/* 800B2A2C 000AF96C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2A30 000AF970 56 F9 C6 3E */ rlwinm r25, r23, 0x18, 0x18, 0x1f
+/* 800B2A34 000AF974 56 F8 06 3E */ clrlwi r24, r23, 0x18
+/* 800B2A38 000AF978 38 03 00 01 */ addi r0, r3, 1
+/* 800B2A3C 000AF97C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2A40 000AF980 9B 63 00 00 */ stb r27, 0(r3)
+/* 800B2A44 000AF984 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2A48 000AF988 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2A4C 000AF98C 38 03 00 01 */ addi r0, r3, 1
+/* 800B2A50 000AF990 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2A54 000AF994 9B 43 00 00 */ stb r26, 0(r3)
+/* 800B2A58 000AF998 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2A5C 000AF99C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2A60 000AF9A0 38 03 00 01 */ addi r0, r3, 1
+/* 800B2A64 000AF9A4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2A68 000AF9A8 9B 23 00 00 */ stb r25, 0(r3)
+/* 800B2A6C 000AF9AC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2A70 000AF9B0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2A74 000AF9B4 38 03 00 01 */ addi r0, r3, 1
+/* 800B2A78 000AF9B8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2A7C 000AF9BC 9A E3 00 00 */ stb r23, 0(r3)
+/* 800B2A80 000AF9C0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2A84 000AF9C4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2A88 000AF9C8 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B2A8C 000AF9CC 38 63 00 01 */ addi r3, r3, 1
+/* 800B2A90 000AF9D0 7C 03 00 40 */ cmplw r3, r0
+/* 800B2A94 000AF9D4 40 81 00 08 */ ble lbl_800B2A9C
+/* 800B2A98 000AF9D8 4B FF C6 BD */ bl GDOverflowed
+lbl_800B2A9C:
+/* 800B2A9C 000AF9DC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2AA0 000AF9E0 38 A0 00 10 */ li r5, 0x10
+/* 800B2AA4 000AF9E4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2AA8 000AF9E8 38 03 00 01 */ addi r0, r3, 1
+/* 800B2AAC 000AF9EC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2AB0 000AF9F0 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B2AB4 000AF9F4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2AB8 000AF9F8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2ABC 000AF9FC 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B2AC0 000AFA00 38 63 00 02 */ addi r3, r3, 2
+/* 800B2AC4 000AFA04 7C 03 00 40 */ cmplw r3, r0
+/* 800B2AC8 000AFA08 40 81 00 08 */ ble lbl_800B2AD0
+/* 800B2ACC 000AFA0C 4B FF C6 89 */ bl GDOverflowed
+lbl_800B2AD0:
+/* 800B2AD0 000AFA10 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2AD4 000AFA14 38 C0 00 00 */ li r6, 0
+/* 800B2AD8 000AFA18 38 A0 00 01 */ li r5, 1
+/* 800B2ADC 000AFA1C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2AE0 000AFA20 38 03 00 01 */ addi r0, r3, 1
+/* 800B2AE4 000AFA24 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2AE8 000AFA28 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B2AEC 000AFA2C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2AF0 000AFA30 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2AF4 000AFA34 38 03 00 01 */ addi r0, r3, 1
+/* 800B2AF8 000AFA38 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2AFC 000AFA3C 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B2B00 000AFA40 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2B04 000AFA44 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2B08 000AFA48 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B2B0C 000AFA4C 38 63 00 02 */ addi r3, r3, 2
+/* 800B2B10 000AFA50 7C 03 00 40 */ cmplw r3, r0
+/* 800B2B14 000AFA54 40 81 00 08 */ ble lbl_800B2B1C
+/* 800B2B18 000AFA58 4B FF C6 3D */ bl GDOverflowed
+lbl_800B2B1C:
+/* 800B2B1C 000AFA5C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2B20 000AFA60 38 C0 00 10 */ li r6, 0x10
+/* 800B2B24 000AFA64 38 A0 00 18 */ li r5, 0x18
+/* 800B2B28 000AFA68 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2B2C 000AFA6C 38 03 00 01 */ addi r0, r3, 1
+/* 800B2B30 000AFA70 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2B34 000AFA74 98 C3 00 00 */ stb r6, 0(r3)
+/* 800B2B38 000AFA78 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2B3C 000AFA7C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2B40 000AFA80 38 03 00 01 */ addi r0, r3, 1
+/* 800B2B44 000AFA84 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2B48 000AFA88 98 A3 00 00 */ stb r5, 0(r3)
+/* 800B2B4C 000AFA8C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2B50 000AFA90 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2B54 000AFA94 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B2B58 000AFA98 38 63 00 04 */ addi r3, r3, 4
+/* 800B2B5C 000AFA9C 7C 03 00 40 */ cmplw r3, r0
+/* 800B2B60 000AFAA0 40 81 00 08 */ ble lbl_800B2B68
+/* 800B2B64 000AFAA4 4B FF C5 F1 */ bl GDOverflowed
+lbl_800B2B68:
+/* 800B2B68 000AFAA8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2B6C 000AFAAC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2B70 000AFAB0 38 03 00 01 */ addi r0, r3, 1
+/* 800B2B74 000AFAB4 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2B78 000AFAB8 9B E3 00 00 */ stb r31, 0(r3)
+/* 800B2B7C 000AFABC 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2B80 000AFAC0 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2B84 000AFAC4 38 03 00 01 */ addi r0, r3, 1
+/* 800B2B88 000AFAC8 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2B8C 000AFACC 9B C3 00 00 */ stb r30, 0(r3)
+/* 800B2B90 000AFAD0 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2B94 000AFAD4 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2B98 000AFAD8 38 03 00 01 */ addi r0, r3, 1
+/* 800B2B9C 000AFADC 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2BA0 000AFAE0 9B A3 00 00 */ stb r29, 0(r3)
+/* 800B2BA4 000AFAE4 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2BA8 000AFAE8 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2BAC 000AFAEC 38 03 00 01 */ addi r0, r3, 1
+/* 800B2BB0 000AFAF0 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2BB4 000AFAF4 9B 83 00 00 */ stb r28, 0(r3)
+/* 800B2BB8 000AFAF8 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2BBC 000AFAFC 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2BC0 000AFB00 80 04 00 0C */ lwz r0, 0xc(r4)
+/* 800B2BC4 000AFB04 38 63 00 04 */ addi r3, r3, 4
+/* 800B2BC8 000AFB08 7C 03 00 40 */ cmplw r3, r0
+/* 800B2BCC 000AFB0C 40 81 00 08 */ ble lbl_800B2BD4
+/* 800B2BD0 000AFB10 4B FF C5 85 */ bl GDOverflowed
+lbl_800B2BD4:
+/* 800B2BD4 000AFB14 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2BD8 000AFB18 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2BDC 000AFB1C 38 03 00 01 */ addi r0, r3, 1
+/* 800B2BE0 000AFB20 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2BE4 000AFB24 9B 63 00 00 */ stb r27, 0(r3)
+/* 800B2BE8 000AFB28 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2BEC 000AFB2C 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2BF0 000AFB30 38 03 00 01 */ addi r0, r3, 1
+/* 800B2BF4 000AFB34 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2BF8 000AFB38 9B 43 00 00 */ stb r26, 0(r3)
+/* 800B2BFC 000AFB3C 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2C00 000AFB40 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2C04 000AFB44 38 03 00 01 */ addi r0, r3, 1
+/* 800B2C08 000AFB48 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2C0C 000AFB4C 9B 23 00 00 */ stb r25, 0(r3)
+/* 800B2C10 000AFB50 80 8D 95 B8 */ lwz r4, __GDCurrentDL@sda21(r13)
+/* 800B2C14 000AFB54 80 64 00 08 */ lwz r3, 8(r4)
+/* 800B2C18 000AFB58 38 03 00 01 */ addi r0, r3, 1
+/* 800B2C1C 000AFB5C 90 04 00 08 */ stw r0, 8(r4)
+/* 800B2C20 000AFB60 9B 03 00 00 */ stb r24, 0(r3)
+/* 800B2C24 000AFB64 80 01 00 54 */ lwz r0, 0x54(r1)
+/* 800B2C28 000AFB68 BA E1 00 2C */ lmw r23, 0x2c(r1)
+/* 800B2C2C 000AFB6C 38 21 00 50 */ addi r1, r1, 0x50
+/* 800B2C30 000AFB70 7C 08 03 A6 */ mtlr r0
+/* 800B2C34 000AFB74 4E 80 00 20 */ blr