summaryrefslogtreecommitdiff
path: root/asm/Dolphin/gx/GXInit.s
blob: 55e6ea1b8ba5c7470e4fe81ca445ca25f1f12a6f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
.include "macros.inc"

.section .text, "ax"  # 0x80005600 - 0x8036FBA0
.global __GXDefaultTexRegionCallback
__GXDefaultTexRegionCallback:
/* 800A4EE4 000A1E24  7C 08 02 A6 */	mflr r0
/* 800A4EE8 000A1E28  90 01 00 04 */	stw r0, 4(r1)
/* 800A4EEC 000A1E2C  94 21 FF F8 */	stwu r1, -8(r1)
/* 800A4EF0 000A1E30  48 00 59 E1 */	bl GXGetTexObjFmt
/* 800A4EF4 000A1E34  2C 03 00 08 */	cmpwi r3, 8
/* 800A4EF8 000A1E38  41 82 00 38 */	beq lbl_800A4F30
/* 800A4EFC 000A1E3C  2C 03 00 09 */	cmpwi r3, 9
/* 800A4F00 000A1E40  41 82 00 30 */	beq lbl_800A4F30
/* 800A4F04 000A1E44  2C 03 00 0A */	cmpwi r3, 0xa
/* 800A4F08 000A1E48  41 82 00 28 */	beq lbl_800A4F30
/* 800A4F0C 000A1E4C  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A4F10 000A1E50  80 65 02 C8 */	lwz r3, 0x2c8(r5)
/* 800A4F14 000A1E54  54 60 07 7E */	clrlwi r0, r3, 0x1d
/* 800A4F18 000A1E58  38 83 00 01 */	addi r4, r3, 1
/* 800A4F1C 000A1E5C  54 03 20 36 */	slwi r3, r0, 4
/* 800A4F20 000A1E60  90 85 02 C8 */	stw r4, 0x2c8(r5)
/* 800A4F24 000A1E64  38 63 02 08 */	addi r3, r3, 0x208
/* 800A4F28 000A1E68  7C 65 1A 14 */	add r3, r5, r3
/* 800A4F2C 000A1E6C  48 00 00 24 */	b lbl_800A4F50
lbl_800A4F30:
/* 800A4F30 000A1E70  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A4F34 000A1E74  80 65 02 CC */	lwz r3, 0x2cc(r5)
/* 800A4F38 000A1E78  54 60 07 BE */	clrlwi r0, r3, 0x1e
/* 800A4F3C 000A1E7C  38 83 00 01 */	addi r4, r3, 1
/* 800A4F40 000A1E80  54 03 20 36 */	slwi r3, r0, 4
/* 800A4F44 000A1E84  90 85 02 CC */	stw r4, 0x2cc(r5)
/* 800A4F48 000A1E88  38 63 02 88 */	addi r3, r3, 0x288
/* 800A4F4C 000A1E8C  7C 65 1A 14 */	add r3, r5, r3
lbl_800A4F50:
/* 800A4F50 000A1E90  80 01 00 0C */	lwz r0, 0xc(r1)
/* 800A4F54 000A1E94  38 21 00 08 */	addi r1, r1, 8
/* 800A4F58 000A1E98  7C 08 03 A6 */	mtlr r0
/* 800A4F5C 000A1E9C  4E 80 00 20 */	blr 

.global __GXDefaultTlutRegionCallback
__GXDefaultTlutRegionCallback:
/* 800A4F60 000A1EA0  28 03 00 14 */	cmplwi r3, 0x14
/* 800A4F64 000A1EA4  41 80 00 0C */	blt lbl_800A4F70
/* 800A4F68 000A1EA8  38 60 00 00 */	li r3, 0
/* 800A4F6C 000A1EAC  48 00 00 14 */	b lbl_800A4F80
lbl_800A4F70:
/* 800A4F70 000A1EB0  54 63 20 36 */	slwi r3, r3, 4
/* 800A4F74 000A1EB4  80 0D 82 C8 */	lwz r0, gx@sda21(r13)
/* 800A4F78 000A1EB8  38 63 02 D0 */	addi r3, r3, 0x2d0
/* 800A4F7C 000A1EBC  7C 60 1A 14 */	add r3, r0, r3
lbl_800A4F80:
/* 800A4F80 000A1EC0  4E 80 00 20 */	blr 

.global GXInit
GXInit:
/* 800A4F84 000A1EC4  7C 08 02 A6 */	mflr r0
/* 800A4F88 000A1EC8  90 01 00 04 */	stw r0, 4(r1)
/* 800A4F8C 000A1ECC  94 21 FF B8 */	stwu r1, -0x48(r1)
/* 800A4F90 000A1ED0  BF 41 00 30 */	stmw r26, 0x30(r1)
/* 800A4F94 000A1ED4  7C 7B 1B 78 */	mr r27, r3
/* 800A4F98 000A1ED8  7C 9A 23 78 */	mr r26, r4
/* 800A4F9C 000A1EDC  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A4FA0 000A1EE0  3B E0 00 00 */	li r31, 0
/* 800A4FA4 000A1EE4  3C 80 80 3F */	lis r4, gxData@ha
/* 800A4FA8 000A1EE8  9B E3 04 F0 */	stb r31, 0x4f0(r3)
/* 800A4FAC 000A1EEC  38 00 00 01 */	li r0, 1
/* 800A4FB0 000A1EF0  3B C4 C1 A0 */	addi r30, r4, gxData@l
/* 800A4FB4 000A1EF4  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A4FB8 000A1EF8  38 60 00 01 */	li r3, 1
/* 800A4FBC 000A1EFC  38 80 00 00 */	li r4, 0
/* 800A4FC0 000A1F00  98 05 04 F1 */	stb r0, 0x4f1(r5)
/* 800A4FC4 000A1F04  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A4FC8 000A1F08  93 E5 04 DC */	stw r31, 0x4dc(r5)
/* 800A4FCC 000A1F0C  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A4FD0 000A1F10  93 E5 04 E0 */	stw r31, 0x4e0(r5)
/* 800A4FD4 000A1F14  48 00 31 C5 */	bl GXSetMisc
/* 800A4FD8 000A1F18  3C 80 CC 00 */	lis r4, 0xCC003000@ha
/* 800A4FDC 000A1F1C  38 A4 30 00 */	addi r5, r4, 0xCC003000@l
/* 800A4FE0 000A1F20  90 8D 95 5C */	stw r4, __cpReg@sda21(r13)
/* 800A4FE4 000A1F24  38 64 10 00 */	addi r3, r4, 0x1000
/* 800A4FE8 000A1F28  38 04 40 00 */	addi r0, r4, 0x4000
/* 800A4FEC 000A1F2C  90 AD 95 58 */	stw r5, __piReg@sda21(r13)
/* 800A4FF0 000A1F30  90 6D 95 60 */	stw r3, __peReg@sda21(r13)
/* 800A4FF4 000A1F34  90 0D 95 64 */	stw r0, __memReg@sda21(r13)
/* 800A4FF8 000A1F38  48 00 16 1D */	bl __GXFifoInit
/* 800A4FFC 000A1F3C  7F 64 DB 78 */	mr r4, r27
/* 800A5000 000A1F40  7F 45 D3 78 */	mr r5, r26
/* 800A5004 000A1F44  38 7E 04 F8 */	addi r3, r30, 0x4f8
/* 800A5008 000A1F48  48 00 11 09 */	bl GXInitFifoBase
/* 800A500C 000A1F4C  38 7E 04 F8 */	addi r3, r30, 0x4f8
/* 800A5010 000A1F50  48 00 11 E9 */	bl GXSetCPUFifo
/* 800A5014 000A1F54  38 7E 04 F8 */	addi r3, r30, 0x4f8
/* 800A5018 000A1F58  48 00 12 F1 */	bl GXSetGPFifo
/* 800A501C 000A1F5C  48 00 37 6D */	bl __GXPEInit
/* 800A5020 000A1F60  4B FE 73 D5 */	bl PPCMfhid2
/* 800A5024 000A1F64  3C 80 0C 01 */	lis r4, 0x0C008000@ha
/* 800A5028 000A1F68  7C 7A 1B 78 */	mr r26, r3
/* 800A502C 000A1F6C  38 64 80 00 */	addi r3, r4, 0x0C008000@l
/* 800A5030 000A1F70  4B FE 73 D5 */	bl PPCMtwpar
/* 800A5034 000A1F74  67 43 40 00 */	oris r3, r26, 0x4000
/* 800A5038 000A1F78  4B FE 73 C5 */	bl PPCMthid2
/* 800A503C 000A1F7C  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A5040 000A1F80  38 00 00 FF */	li r0, 0xff
/* 800A5044 000A1F84  38 E0 00 00 */	li r7, 0
/* 800A5048 000A1F88  93 E3 02 04 */	stw r31, 0x204(r3)
/* 800A504C 000A1F8C  38 60 00 C0 */	li r3, 0xc0
/* 800A5050 000A1F90  38 80 00 C1 */	li r4, 0xc1
/* 800A5054 000A1F94  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A5058 000A1F98  38 C5 02 04 */	addi r6, r5, 0x204
/* 800A505C 000A1F9C  80 A6 00 00 */	lwz r5, 0(r6)
/* 800A5060 000A1FA0  54 A5 02 3E */	clrlwi r5, r5, 8
/* 800A5064 000A1FA4  90 A6 00 00 */	stw r5, 0(r6)
/* 800A5068 000A1FA8  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A506C 000A1FAC  90 05 01 24 */	stw r0, 0x124(r5)
/* 800A5070 000A1FB0  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A5074 000A1FB4  38 A5 01 24 */	addi r5, r5, 0x124
/* 800A5078 000A1FB8  80 05 00 00 */	lwz r0, 0(r5)
/* 800A507C 000A1FBC  54 00 02 3E */	clrlwi r0, r0, 8
/* 800A5080 000A1FC0  64 00 0F 00 */	oris r0, r0, 0xf00
/* 800A5084 000A1FC4  90 05 00 00 */	stw r0, 0(r5)
/* 800A5088 000A1FC8  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A508C 000A1FCC  93 E5 00 7C */	stw r31, 0x7c(r5)
/* 800A5090 000A1FD0  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A5094 000A1FD4  38 A5 00 7C */	addi r5, r5, 0x7c
/* 800A5098 000A1FD8  80 05 00 00 */	lwz r0, 0(r5)
/* 800A509C 000A1FDC  54 00 02 3E */	clrlwi r0, r0, 8
/* 800A50A0 000A1FE0  64 00 22 00 */	oris r0, r0, 0x2200
/* 800A50A4 000A1FE4  90 05 00 00 */	stw r0, 0(r5)
/* 800A50A8 000A1FE8  48 00 00 04 */	b lbl_800A50AC
lbl_800A50AC:
/* 800A50AC 000A1FEC  38 00 00 10 */	li r0, 0x10
/* 800A50B0 000A1FF0  7C 09 03 A6 */	mtctr r0
/* 800A50B4 000A1FF4  48 00 00 04 */	b lbl_800A50B8
lbl_800A50B8:
/* 800A50B8 000A1FF8  48 00 00 04 */	b lbl_800A50BC
lbl_800A50BC:
/* 800A50BC 000A1FFC  80 CD 82 C8 */	lwz r6, gx@sda21(r13)
/* 800A50C0 000A2000  54 E8 F8 7E */	srwi r8, r7, 1
/* 800A50C4 000A2004  3B 5F 01 30 */	addi r26, r31, 0x130
/* 800A50C8 000A2008  38 A0 00 00 */	li r5, 0
/* 800A50CC 000A200C  7C A6 D1 2E */	stwx r5, r6, r26
/* 800A50D0 000A2010  55 1C 10 3A */	slwi r28, r8, 2
/* 800A50D4 000A2014  54 6B C0 0E */	slwi r11, r3, 0x18
/* 800A50D8 000A2018  80 CD 82 C8 */	lwz r6, gx@sda21(r13)
/* 800A50DC 000A201C  3B 7F 01 70 */	addi r27, r31, 0x170
/* 800A50E0 000A2020  39 9F 04 9C */	addi r12, r31, 0x49c
/* 800A50E4 000A2024  7C A6 D9 2E */	stwx r5, r6, r27
/* 800A50E8 000A2028  54 8A C0 0E */	slwi r10, r4, 0x18
/* 800A50EC 000A202C  39 28 00 F6 */	addi r9, r8, 0xf6
/* 800A50F0 000A2030  80 CD 82 C8 */	lwz r6, gx@sda21(r13)
/* 800A50F4 000A2034  38 1C 01 00 */	addi r0, r28, 0x100
/* 800A50F8 000A2038  39 08 00 28 */	addi r8, r8, 0x28
/* 800A50FC 000A203C  7C A6 01 2E */	stwx r5, r6, r0
/* 800A5100 000A2040  3B A0 00 FF */	li r29, 0xff
/* 800A5104 000A2044  38 DC 01 B0 */	addi r6, r28, 0x1b0
/* 800A5108 000A2048  83 8D 82 C8 */	lwz r28, gx@sda21(r13)
/* 800A510C 000A204C  55 29 C0 0E */	slwi r9, r9, 0x18
/* 800A5110 000A2050  55 08 C0 0E */	slwi r8, r8, 0x18
/* 800A5114 000A2054  7F BC 61 2E */	stwx r29, r28, r12
/* 800A5118 000A2058  3B FF 00 04 */	addi r31, r31, 4
/* 800A511C 000A205C  38 63 00 02 */	addi r3, r3, 2
/* 800A5120 000A2060  81 8D 82 C8 */	lwz r12, gx@sda21(r13)
/* 800A5124 000A2064  38 84 00 02 */	addi r4, r4, 2
/* 800A5128 000A2068  38 E7 00 01 */	addi r7, r7, 1
/* 800A512C 000A206C  7F 4C D2 14 */	add r26, r12, r26
/* 800A5130 000A2070  81 9A 00 00 */	lwz r12, 0(r26)
/* 800A5134 000A2074  55 8C 02 3E */	clrlwi r12, r12, 8
/* 800A5138 000A2078  7D 8B 5B 78 */	or r11, r12, r11
/* 800A513C 000A207C  91 7A 00 00 */	stw r11, 0(r26)
/* 800A5140 000A2080  81 6D 82 C8 */	lwz r11, gx@sda21(r13)
/* 800A5144 000A2084  7D 8B DA 14 */	add r12, r11, r27
/* 800A5148 000A2088  81 6C 00 00 */	lwz r11, 0(r12)
/* 800A514C 000A208C  55 6B 02 3E */	clrlwi r11, r11, 8
/* 800A5150 000A2090  7D 6A 53 78 */	or r10, r11, r10
/* 800A5154 000A2094  91 4C 00 00 */	stw r10, 0(r12)
/* 800A5158 000A2098  81 4D 82 C8 */	lwz r10, gx@sda21(r13)
/* 800A515C 000A209C  7C CA 32 14 */	add r6, r10, r6
/* 800A5160 000A20A0  81 46 00 00 */	lwz r10, 0(r6)
/* 800A5164 000A20A4  55 4A 02 3E */	clrlwi r10, r10, 8
/* 800A5168 000A20A8  7D 49 4B 78 */	or r9, r10, r9
/* 800A516C 000A20AC  91 26 00 00 */	stw r9, 0(r6)
/* 800A5170 000A20B0  80 CD 82 C8 */	lwz r6, gx@sda21(r13)
/* 800A5174 000A20B4  7C C6 02 14 */	add r6, r6, r0
/* 800A5178 000A20B8  80 06 00 00 */	lwz r0, 0(r6)
/* 800A517C 000A20BC  54 00 02 3E */	clrlwi r0, r0, 8
/* 800A5180 000A20C0  7C 00 43 78 */	or r0, r0, r8
/* 800A5184 000A20C4  90 06 00 00 */	stw r0, 0(r6)
/* 800A5188 000A20C8  42 00 FF 34 */	bdnz lbl_800A50BC
/* 800A518C 000A20CC  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A5190 000A20D0  39 00 00 30 */	li r8, 0x30
/* 800A5194 000A20D4  39 20 00 31 */	li r9, 0x31
/* 800A5198 000A20D8  90 A3 01 20 */	stw r5, 0x120(r3)
/* 800A519C 000A20DC  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A51A0 000A20E0  38 63 01 20 */	addi r3, r3, 0x120
/* 800A51A4 000A20E4  80 03 00 00 */	lwz r0, 0(r3)
/* 800A51A8 000A20E8  54 00 02 3E */	clrlwi r0, r0, 8
/* 800A51AC 000A20EC  64 00 27 00 */	oris r0, r0, 0x2700
/* 800A51B0 000A20F0  90 03 00 00 */	stw r0, 0(r3)
/* 800A51B4 000A20F4  48 00 00 04 */	b lbl_800A51B8
lbl_800A51B8:
/* 800A51B8 000A20F8  38 00 00 04 */	li r0, 4
/* 800A51BC 000A20FC  7C 09 03 A6 */	mtctr r0
/* 800A51C0 000A2100  48 00 00 04 */	b lbl_800A51C4
lbl_800A51C4:
/* 800A51C4 000A2104  48 00 00 04 */	b lbl_800A51C8
lbl_800A51C8:
/* 800A51C8 000A2108  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A51CC 000A210C  55 04 C0 0E */	slwi r4, r8, 0x18
/* 800A51D0 000A2110  38 E5 00 B8 */	addi r7, r5, 0xb8
/* 800A51D4 000A2114  3B A0 00 00 */	li r29, 0
/* 800A51D8 000A2118  7F A3 39 2E */	stwx r29, r3, r7
/* 800A51DC 000A211C  38 C5 00 D8 */	addi r6, r5, 0xd8
/* 800A51E0 000A2120  55 20 C0 0E */	slwi r0, r9, 0x18
/* 800A51E4 000A2124  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A51E8 000A2128  38 A5 00 04 */	addi r5, r5, 4
/* 800A51EC 000A212C  39 08 00 02 */	addi r8, r8, 2
/* 800A51F0 000A2130  7F A3 31 2E */	stwx r29, r3, r6
/* 800A51F4 000A2134  39 29 00 02 */	addi r9, r9, 2
/* 800A51F8 000A2138  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A51FC 000A213C  7D 43 3A 14 */	add r10, r3, r7
/* 800A5200 000A2140  80 6A 00 00 */	lwz r3, 0(r10)
/* 800A5204 000A2144  38 E5 00 B8 */	addi r7, r5, 0xb8
/* 800A5208 000A2148  54 63 02 3E */	clrlwi r3, r3, 8
/* 800A520C 000A214C  7C 63 23 78 */	or r3, r3, r4
/* 800A5210 000A2150  90 6A 00 00 */	stw r3, 0(r10)
/* 800A5214 000A2154  55 04 C0 0E */	slwi r4, r8, 0x18
/* 800A5218 000A2158  39 08 00 02 */	addi r8, r8, 2
/* 800A521C 000A215C  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A5220 000A2160  7D 43 32 14 */	add r10, r3, r6
/* 800A5224 000A2164  80 6A 00 00 */	lwz r3, 0(r10)
/* 800A5228 000A2168  38 C5 00 D8 */	addi r6, r5, 0xd8
/* 800A522C 000A216C  38 A5 00 04 */	addi r5, r5, 4
/* 800A5230 000A2170  54 63 02 3E */	clrlwi r3, r3, 8
/* 800A5234 000A2174  7C 60 03 78 */	or r0, r3, r0
/* 800A5238 000A2178  90 0A 00 00 */	stw r0, 0(r10)
/* 800A523C 000A217C  55 20 C0 0E */	slwi r0, r9, 0x18
/* 800A5240 000A2180  39 29 00 02 */	addi r9, r9, 2
/* 800A5244 000A2184  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A5248 000A2188  7F A3 39 2E */	stwx r29, r3, r7
/* 800A524C 000A218C  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A5250 000A2190  7F A3 31 2E */	stwx r29, r3, r6
/* 800A5254 000A2194  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A5258 000A2198  7D 43 3A 14 */	add r10, r3, r7
/* 800A525C 000A219C  80 6A 00 00 */	lwz r3, 0(r10)
/* 800A5260 000A21A0  54 63 02 3E */	clrlwi r3, r3, 8
/* 800A5264 000A21A4  7C 63 23 78 */	or r3, r3, r4
/* 800A5268 000A21A8  90 6A 00 00 */	stw r3, 0(r10)
/* 800A526C 000A21AC  80 6D 82 C8 */	lwz r3, gx@sda21(r13)
/* 800A5270 000A21B0  7D 43 32 14 */	add r10, r3, r6
/* 800A5274 000A21B4  80 6A 00 00 */	lwz r3, 0(r10)
/* 800A5278 000A21B8  54 63 02 3E */	clrlwi r3, r3, 8
/* 800A527C 000A21BC  7C 60 03 78 */	or r0, r3, r0
/* 800A5280 000A21C0  90 0A 00 00 */	stw r0, 0(r10)
/* 800A5284 000A21C4  42 00 FF 44 */	bdnz lbl_800A51C8
/* 800A5288 000A21C8  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A528C 000A21CC  3C 60 10 62 */	lis r3, 0x10624DD3@ha
/* 800A5290 000A21D0  3C 80 80 00 */	lis r4, 0x800000F8@ha
/* 800A5294 000A21D4  38 A5 00 F8 */	addi r5, r5, 0xf8
/* 800A5298 000A21D8  80 05 00 00 */	lwz r0, 0(r5)
/* 800A529C 000A21DC  38 63 4D D3 */	addi r3, r3, 0x10624DD3@l
/* 800A52A0 000A21E0  54 00 02 3E */	clrlwi r0, r0, 8
/* 800A52A4 000A21E4  64 00 20 00 */	oris r0, r0, 0x2000
/* 800A52A8 000A21E8  90 05 00 00 */	stw r0, 0(r5)
/* 800A52AC 000A21EC  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A52B0 000A21F0  38 A5 00 FC */	addi r5, r5, 0xfc
/* 800A52B4 000A21F4  80 05 00 00 */	lwz r0, 0(r5)
/* 800A52B8 000A21F8  54 00 02 3E */	clrlwi r0, r0, 8
/* 800A52BC 000A21FC  64 00 21 00 */	oris r0, r0, 0x2100
/* 800A52C0 000A2200  90 05 00 00 */	stw r0, 0(r5)
/* 800A52C4 000A2204  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A52C8 000A2208  38 A5 01 D0 */	addi r5, r5, 0x1d0
/* 800A52CC 000A220C  80 05 00 00 */	lwz r0, 0(r5)
/* 800A52D0 000A2210  54 00 02 3E */	clrlwi r0, r0, 8
/* 800A52D4 000A2214  64 00 41 00 */	oris r0, r0, 0x4100
/* 800A52D8 000A2218  90 05 00 00 */	stw r0, 0(r5)
/* 800A52DC 000A221C  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A52E0 000A2220  38 A5 01 D4 */	addi r5, r5, 0x1d4
/* 800A52E4 000A2224  80 05 00 00 */	lwz r0, 0(r5)
/* 800A52E8 000A2228  54 00 02 3E */	clrlwi r0, r0, 8
/* 800A52EC 000A222C  64 00 42 00 */	oris r0, r0, 0x4200
/* 800A52F0 000A2230  90 05 00 00 */	stw r0, 0(r5)
/* 800A52F4 000A2234  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A52F8 000A2238  38 A5 01 D8 */	addi r5, r5, 0x1d8
/* 800A52FC 000A223C  80 05 00 00 */	lwz r0, 0(r5)
/* 800A5300 000A2240  54 00 02 3E */	clrlwi r0, r0, 8
/* 800A5304 000A2244  64 00 40 00 */	oris r0, r0, 0x4000
/* 800A5308 000A2248  90 05 00 00 */	stw r0, 0(r5)
/* 800A530C 000A224C  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A5310 000A2250  38 A5 01 DC */	addi r5, r5, 0x1dc
/* 800A5314 000A2254  80 05 00 00 */	lwz r0, 0(r5)
/* 800A5318 000A2258  54 00 02 3E */	clrlwi r0, r0, 8
/* 800A531C 000A225C  64 00 43 00 */	oris r0, r0, 0x4300
/* 800A5320 000A2260  90 05 00 00 */	stw r0, 0(r5)
/* 800A5324 000A2264  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A5328 000A2268  38 A5 01 FC */	addi r5, r5, 0x1fc
/* 800A532C 000A226C  80 05 00 00 */	lwz r0, 0(r5)
/* 800A5330 000A2270  54 00 06 6C */	rlwinm r0, r0, 0, 0x19, 0x16
/* 800A5334 000A2274  90 05 00 00 */	stw r0, 0(r5)
/* 800A5338 000A2278  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A533C 000A227C  93 A5 04 F4 */	stw r29, 0x4f4(r5)
/* 800A5340 000A2280  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A5344 000A2284  9B A5 04 F2 */	stb r29, 0x4f2(r5)
/* 800A5348 000A2288  80 04 00 F8 */	lwz r0, 0x800000F8@l(r4)
/* 800A534C 000A228C  7C 03 00 16 */	mulhwu r0, r3, r0
/* 800A5350 000A2290  54 1A D9 7E */	srwi r26, r0, 5
/* 800A5354 000A2294  48 00 66 91 */	bl __GXFlushTextureState
/* 800A5358 000A2298  57 40 AA FE */	srwi r0, r26, 0xb
/* 800A535C 000A229C  64 00 69 00 */	oris r0, r0, 0x6900
/* 800A5360 000A22A0  3B 80 00 61 */	li r28, 0x61
/* 800A5364 000A22A4  3F E0 CC 01 */	lis r31, 0xCC008000@ha
/* 800A5368 000A22A8  9B 9F 80 00 */	stb r28, 0xCC008000@l(r31)
/* 800A536C 000A22AC  60 00 04 00 */	ori r0, r0, 0x400
/* 800A5370 000A22B0  90 1F 80 00 */	stw r0, -0x8000(r31)
/* 800A5374 000A22B4  48 00 66 71 */	bl __GXFlushTextureState
/* 800A5378 000A22B8  3C 60 3E 10 */	lis r3, 0x3E0F83E1@ha
/* 800A537C 000A22BC  9B 9F 80 00 */	stb r28, -0x8000(r31)
/* 800A5380 000A22C0  38 03 83 E1 */	addi r0, r3, 0x3E0F83E1@l
/* 800A5384 000A22C4  7C 00 D0 16 */	mulhwu r0, r0, r26
/* 800A5388 000A22C8  54 00 B2 BE */	srwi r0, r0, 0xa
/* 800A538C 000A22CC  64 00 46 00 */	oris r0, r0, 0x4600
/* 800A5390 000A22D0  60 00 02 00 */	ori r0, r0, 0x200
/* 800A5394 000A22D4  90 1F 80 00 */	stw r0, -0x8000(r31)
/* 800A5398 000A22D8  7F A7 EB 78 */	mr r7, r29
/* 800A539C 000A22DC  48 00 00 04 */	b lbl_800A53A0
lbl_800A53A0:
/* 800A53A0 000A22E0  38 00 00 02 */	li r0, 2
/* 800A53A4 000A22E4  7C 09 03 A6 */	mtctr r0
/* 800A53A8 000A22E8  48 00 00 04 */	b lbl_800A53AC
lbl_800A53AC:
/* 800A53AC 000A22EC  48 00 00 04 */	b lbl_800A53B0
lbl_800A53B0:
/* 800A53B0 000A22F0  80 0D 82 C8 */	lwz r0, gx@sda21(r13)
/* 800A53B4 000A22F4  39 07 00 1C */	addi r8, r7, 0x1c
/* 800A53B8 000A22F8  63 A5 00 80 */	ori r5, r29, 0x80
/* 800A53BC 000A22FC  7D 00 42 14 */	add r8, r0, r8
/* 800A53C0 000A2300  80 08 00 00 */	lwz r0, 0(r8)
/* 800A53C4 000A2304  39 27 00 3C */	addi r9, r7, 0x3c
/* 800A53C8 000A2308  38 67 00 3C */	addi r3, r7, 0x3c
/* 800A53CC 000A230C  54 00 00 80 */	rlwinm r0, r0, 0, 2, 0
/* 800A53D0 000A2310  64 00 40 00 */	oris r0, r0, 0x4000
/* 800A53D4 000A2314  90 08 00 00 */	stw r0, 0(r8)
/* 800A53D8 000A2318  38 E7 00 04 */	addi r7, r7, 4
/* 800A53DC 000A231C  38 C0 00 08 */	li r6, 8
/* 800A53E0 000A2320  80 0D 82 C8 */	lwz r0, gx@sda21(r13)
/* 800A53E4 000A2324  39 07 00 1C */	addi r8, r7, 0x1c
/* 800A53E8 000A2328  3B BD 00 01 */	addi r29, r29, 1
/* 800A53EC 000A232C  7D 20 4A 14 */	add r9, r0, r9
/* 800A53F0 000A2330  80 09 00 00 */	lwz r0, 0(r9)
/* 800A53F4 000A2334  54 00 00 7E */	clrlwi r0, r0, 1
/* 800A53F8 000A2338  64 00 80 00 */	oris r0, r0, 0x8000
/* 800A53FC 000A233C  90 09 00 00 */	stw r0, 0(r9)
/* 800A5400 000A2340  39 27 00 3C */	addi r9, r7, 0x3c
/* 800A5404 000A2344  98 DF 80 00 */	stb r6, -0x8000(r31)
/* 800A5408 000A2348  80 8D 82 C8 */	lwz r4, gx@sda21(r13)
/* 800A540C 000A234C  98 BF 80 00 */	stb r5, -0x8000(r31)
/* 800A5410 000A2350  63 A5 00 80 */	ori r5, r29, 0x80
/* 800A5414 000A2354  7D 04 42 14 */	add r8, r4, r8
/* 800A5418 000A2358  7C 04 18 2E */	lwzx r0, r4, r3
/* 800A541C 000A235C  38 67 00 3C */	addi r3, r7, 0x3c
/* 800A5420 000A2360  38 E7 00 04 */	addi r7, r7, 4
/* 800A5424 000A2364  90 1F 80 00 */	stw r0, -0x8000(r31)
/* 800A5428 000A2368  3B BD 00 01 */	addi r29, r29, 1
/* 800A542C 000A236C  80 08 00 00 */	lwz r0, 0(r8)
/* 800A5430 000A2370  54 00 00 80 */	rlwinm r0, r0, 0, 2, 0
/* 800A5434 000A2374  64 00 40 00 */	oris r0, r0, 0x4000
/* 800A5438 000A2378  90 08 00 00 */	stw r0, 0(r8)
/* 800A543C 000A237C  39 07 00 1C */	addi r8, r7, 0x1c
/* 800A5440 000A2380  80 0D 82 C8 */	lwz r0, gx@sda21(r13)
/* 800A5444 000A2384  7D 20 4A 14 */	add r9, r0, r9
/* 800A5448 000A2388  80 09 00 00 */	lwz r0, 0(r9)
/* 800A544C 000A238C  54 00 00 7E */	clrlwi r0, r0, 1
/* 800A5450 000A2390  64 00 80 00 */	oris r0, r0, 0x8000
/* 800A5454 000A2394  90 09 00 00 */	stw r0, 0(r9)
/* 800A5458 000A2398  39 27 00 3C */	addi r9, r7, 0x3c
/* 800A545C 000A239C  98 DF 80 00 */	stb r6, -0x8000(r31)
/* 800A5460 000A23A0  80 8D 82 C8 */	lwz r4, gx@sda21(r13)
/* 800A5464 000A23A4  98 BF 80 00 */	stb r5, -0x8000(r31)
/* 800A5468 000A23A8  63 A5 00 80 */	ori r5, r29, 0x80
/* 800A546C 000A23AC  7D 04 42 14 */	add r8, r4, r8
/* 800A5470 000A23B0  7C 04 18 2E */	lwzx r0, r4, r3
/* 800A5474 000A23B4  38 67 00 3C */	addi r3, r7, 0x3c
/* 800A5478 000A23B8  38 E7 00 04 */	addi r7, r7, 4
/* 800A547C 000A23BC  90 1F 80 00 */	stw r0, -0x8000(r31)
/* 800A5480 000A23C0  3B BD 00 01 */	addi r29, r29, 1
/* 800A5484 000A23C4  80 08 00 00 */	lwz r0, 0(r8)
/* 800A5488 000A23C8  54 00 00 80 */	rlwinm r0, r0, 0, 2, 0
/* 800A548C 000A23CC  64 00 40 00 */	oris r0, r0, 0x4000
/* 800A5490 000A23D0  90 08 00 00 */	stw r0, 0(r8)
/* 800A5494 000A23D4  39 07 00 1C */	addi r8, r7, 0x1c
/* 800A5498 000A23D8  80 0D 82 C8 */	lwz r0, gx@sda21(r13)
/* 800A549C 000A23DC  7D 20 4A 14 */	add r9, r0, r9
/* 800A54A0 000A23E0  80 09 00 00 */	lwz r0, 0(r9)
/* 800A54A4 000A23E4  54 00 00 7E */	clrlwi r0, r0, 1
/* 800A54A8 000A23E8  64 00 80 00 */	oris r0, r0, 0x8000
/* 800A54AC 000A23EC  90 09 00 00 */	stw r0, 0(r9)
/* 800A54B0 000A23F0  39 27 00 3C */	addi r9, r7, 0x3c
/* 800A54B4 000A23F4  98 DF 80 00 */	stb r6, -0x8000(r31)
/* 800A54B8 000A23F8  80 8D 82 C8 */	lwz r4, gx@sda21(r13)
/* 800A54BC 000A23FC  98 BF 80 00 */	stb r5, -0x8000(r31)
/* 800A54C0 000A2400  63 A5 00 80 */	ori r5, r29, 0x80
/* 800A54C4 000A2404  7D 04 42 14 */	add r8, r4, r8
/* 800A54C8 000A2408  7C 04 18 2E */	lwzx r0, r4, r3
/* 800A54CC 000A240C  38 67 00 3C */	addi r3, r7, 0x3c
/* 800A54D0 000A2410  38 E7 00 04 */	addi r7, r7, 4
/* 800A54D4 000A2414  90 1F 80 00 */	stw r0, -0x8000(r31)
/* 800A54D8 000A2418  3B BD 00 01 */	addi r29, r29, 1
/* 800A54DC 000A241C  80 08 00 00 */	lwz r0, 0(r8)
/* 800A54E0 000A2420  54 00 00 80 */	rlwinm r0, r0, 0, 2, 0
/* 800A54E4 000A2424  64 00 40 00 */	oris r0, r0, 0x4000
/* 800A54E8 000A2428  90 08 00 00 */	stw r0, 0(r8)
/* 800A54EC 000A242C  80 0D 82 C8 */	lwz r0, gx@sda21(r13)
/* 800A54F0 000A2430  7D 20 4A 14 */	add r9, r0, r9
/* 800A54F4 000A2434  80 09 00 00 */	lwz r0, 0(r9)
/* 800A54F8 000A2438  54 00 00 7E */	clrlwi r0, r0, 1
/* 800A54FC 000A243C  64 00 80 00 */	oris r0, r0, 0x8000
/* 800A5500 000A2440  90 09 00 00 */	stw r0, 0(r9)
/* 800A5504 000A2444  98 DF 80 00 */	stb r6, -0x8000(r31)
/* 800A5508 000A2448  80 8D 82 C8 */	lwz r4, gx@sda21(r13)
/* 800A550C 000A244C  98 BF 80 00 */	stb r5, -0x8000(r31)
/* 800A5510 000A2450  7C 04 18 2E */	lwzx r0, r4, r3
/* 800A5514 000A2454  90 1F 80 00 */	stw r0, -0x8000(r31)
/* 800A5518 000A2458  42 00 FE 98 */	bdnz lbl_800A53B0
/* 800A551C 000A245C  38 80 00 10 */	li r4, 0x10
/* 800A5520 000A2460  3C C0 CC 01 */	lis r6, 0xCC008000@ha
/* 800A5524 000A2464  98 86 80 00 */	stb r4, 0xCC008000@l(r6)
/* 800A5528 000A2468  38 00 10 00 */	li r0, 0x1000
/* 800A552C 000A246C  3B A0 00 00 */	li r29, 0
/* 800A5530 000A2470  90 06 80 00 */	stw r0, -0x8000(r6)
/* 800A5534 000A2474  38 00 00 3F */	li r0, 0x3f
/* 800A5538 000A2478  57 BC 78 20 */	slwi r28, r29, 0xf
/* 800A553C 000A247C  90 06 80 00 */	stw r0, -0x8000(r6)
/* 800A5540 000A2480  38 00 10 12 */	li r0, 0x1012
/* 800A5544 000A2484  38 A0 00 01 */	li r5, 1
/* 800A5548 000A2488  98 86 80 00 */	stb r4, -0x8000(r6)
/* 800A554C 000A248C  38 80 00 61 */	li r4, 0x61
/* 800A5550 000A2490  3C 60 58 00 */	lis r3, 0x5800000F@ha
/* 800A5554 000A2494  90 06 80 00 */	stw r0, -0x8000(r6)
/* 800A5558 000A2498  38 03 00 0F */	addi r0, r3, 0x5800000F@l
/* 800A555C 000A249C  3F 5C 00 08 */	addis r26, r28, 8
/* 800A5560 000A24A0  90 A6 80 00 */	stw r5, -0x8000(r6)
/* 800A5564 000A24A4  57 BB 20 36 */	slwi r27, r29, 4
/* 800A5568 000A24A8  98 86 80 00 */	stb r4, -0x8000(r6)
/* 800A556C 000A24AC  90 06 80 00 */	stw r0, -0x8000(r6)
/* 800A5570 000A24B0  48 00 00 04 */	b lbl_800A5574
lbl_800A5574:
/* 800A5574 000A24B4  48 00 00 04 */	b lbl_800A5578
lbl_800A5578:
/* 800A5578 000A24B8  48 00 00 04 */	b lbl_800A557C
lbl_800A557C:
/* 800A557C 000A24BC  80 0D 82 C8 */	lwz r0, gx@sda21(r13)
/* 800A5580 000A24C0  38 7B 02 08 */	addi r3, r27, 0x208
/* 800A5584 000A24C4  7F 85 E3 78 */	mr r5, r28
/* 800A5588 000A24C8  7F 47 D3 78 */	mr r7, r26
/* 800A558C 000A24CC  7C 60 1A 14 */	add r3, r0, r3
/* 800A5590 000A24D0  38 80 00 00 */	li r4, 0
/* 800A5594 000A24D4  38 C0 00 00 */	li r6, 0
/* 800A5598 000A24D8  39 00 00 00 */	li r8, 0
/* 800A559C 000A24DC  48 00 56 1D */	bl GXInitTexCacheRegion
/* 800A55A0 000A24E0  3F 5A 00 01 */	addis r26, r26, 1
/* 800A55A4 000A24E4  3F 9C 00 01 */	addis r28, r28, 1
/* 800A55A8 000A24E8  3B 5A 80 00 */	addi r26, r26, -32768
/* 800A55AC 000A24EC  3B 9C 80 00 */	addi r28, r28, -32768
/* 800A55B0 000A24F0  3B 7B 00 10 */	addi r27, r27, 0x10
/* 800A55B4 000A24F4  3B BD 00 01 */	addi r29, r29, 1
/* 800A55B8 000A24F8  28 1D 00 08 */	cmplwi r29, 8
/* 800A55BC 000A24FC  41 80 FF C0 */	blt lbl_800A557C
/* 800A55C0 000A2500  3B A0 00 00 */	li r29, 0
/* 800A55C4 000A2504  57 A3 08 3C */	slwi r3, r29, 1
/* 800A55C8 000A2508  3B 43 00 09 */	addi r26, r3, 9
/* 800A55CC 000A250C  3B 63 00 08 */	addi r27, r3, 8
/* 800A55D0 000A2510  57 BC 20 36 */	slwi r28, r29, 4
/* 800A55D4 000A2514  48 00 00 04 */	b lbl_800A55D8
lbl_800A55D8:
/* 800A55D8 000A2518  48 00 00 04 */	b lbl_800A55DC
lbl_800A55DC:
/* 800A55DC 000A251C  48 00 00 04 */	b lbl_800A55E0
lbl_800A55E0:
/* 800A55E0 000A2520  80 0D 82 C8 */	lwz r0, gx@sda21(r13)
/* 800A55E4 000A2524  38 7C 02 88 */	addi r3, r28, 0x288
/* 800A55E8 000A2528  57 65 78 20 */	slwi r5, r27, 0xf
/* 800A55EC 000A252C  7C 60 1A 14 */	add r3, r0, r3
/* 800A55F0 000A2530  57 47 78 20 */	slwi r7, r26, 0xf
/* 800A55F4 000A2534  38 80 00 00 */	li r4, 0
/* 800A55F8 000A2538  38 C0 00 00 */	li r6, 0
/* 800A55FC 000A253C  39 00 00 00 */	li r8, 0
/* 800A5600 000A2540  48 00 55 B9 */	bl GXInitTexCacheRegion
/* 800A5604 000A2544  3B 5A 00 02 */	addi r26, r26, 2
/* 800A5608 000A2548  3B 7B 00 02 */	addi r27, r27, 2
/* 800A560C 000A254C  3B 9C 00 10 */	addi r28, r28, 0x10
/* 800A5610 000A2550  3B BD 00 01 */	addi r29, r29, 1
/* 800A5614 000A2554  28 1D 00 04 */	cmplwi r29, 4
/* 800A5618 000A2558  41 80 FF C8 */	blt lbl_800A55E0
/* 800A561C 000A255C  3B 80 00 00 */	li r28, 0
/* 800A5620 000A2560  57 83 68 24 */	slwi r3, r28, 0xd
/* 800A5624 000A2564  3F 43 00 0C */	addis r26, r3, 0xc
/* 800A5628 000A2568  57 9B 20 36 */	slwi r27, r28, 4
/* 800A562C 000A256C  48 00 00 04 */	b lbl_800A5630
lbl_800A5630:
/* 800A5630 000A2570  48 00 00 04 */	b lbl_800A5634
lbl_800A5634:
/* 800A5634 000A2574  48 00 00 04 */	b lbl_800A5638
lbl_800A5638:
/* 800A5638 000A2578  80 0D 82 C8 */	lwz r0, gx@sda21(r13)
/* 800A563C 000A257C  38 7B 02 D0 */	addi r3, r27, 0x2d0
/* 800A5640 000A2580  7F 44 D3 78 */	mr r4, r26
/* 800A5644 000A2584  7C 60 1A 14 */	add r3, r0, r3
/* 800A5648 000A2588  38 A0 00 10 */	li r5, 0x10
/* 800A564C 000A258C  48 00 56 8D */	bl GXInitTlutRegion
/* 800A5650 000A2590  3B 5A 20 00 */	addi r26, r26, 0x2000
/* 800A5654 000A2594  3B 7B 00 10 */	addi r27, r27, 0x10
/* 800A5658 000A2598  3B 9C 00 01 */	addi r28, r28, 1
/* 800A565C 000A259C  28 1C 00 10 */	cmplwi r28, 0x10
/* 800A5660 000A25A0  41 80 FF D8 */	blt lbl_800A5638
/* 800A5664 000A25A4  3B 60 00 00 */	li r27, 0
/* 800A5668 000A25A8  57 63 78 20 */	slwi r3, r27, 0xf
/* 800A566C 000A25AC  3F 43 00 0E */	addis r26, r3, 0xe
/* 800A5670 000A25B0  48 00 00 04 */	b lbl_800A5674
lbl_800A5674:
/* 800A5674 000A25B4  48 00 00 04 */	b lbl_800A5678
lbl_800A5678:
/* 800A5678 000A25B8  48 00 00 04 */	b lbl_800A567C
lbl_800A567C:
/* 800A567C 000A25BC  38 1B 00 10 */	addi r0, r27, 0x10
/* 800A5680 000A25C0  80 AD 82 C8 */	lwz r5, gx@sda21(r13)
/* 800A5684 000A25C4  54 03 20 36 */	slwi r3, r0, 4
/* 800A5688 000A25C8  38 63 02 D0 */	addi r3, r3, 0x2d0
/* 800A568C 000A25CC  7F 44 D3 78 */	mr r4, r26
/* 800A5690 000A25D0  7C 65 1A 14 */	add r3, r5, r3
/* 800A5694 000A25D4  38 A0 00 40 */	li r5, 0x40
/* 800A5698 000A25D8  48 00 56 41 */	bl GXInitTlutRegion
/* 800A569C 000A25DC  3F 5A 00 01 */	addis r26, r26, 1
/* 800A56A0 000A25E0  3B 5A 80 00 */	addi r26, r26, -32768
/* 800A56A4 000A25E4  3B 7B 00 01 */	addi r27, r27, 1
/* 800A56A8 000A25E8  28 1B 00 04 */	cmplwi r27, 4
/* 800A56AC 000A25EC  41 80 FF D0 */	blt lbl_800A567C
/* 800A56B0 000A25F0  80 8D 95 5C */	lwz r4, __cpReg@sda21(r13)
/* 800A56B4 000A25F4  39 80 00 00 */	li r12, 0
/* 800A56B8 000A25F8  38 60 00 08 */	li r3, 8
/* 800A56BC 000A25FC  B1 84 00 06 */	sth r12, 6(r4)
/* 800A56C0 000A2600  3D 60 CC 01 */	lis r11, 0xCC008000@ha
/* 800A56C4 000A2604  39 40 00 20 */	li r10, 0x20
/* 800A56C8 000A2608  80 8D 82 C8 */	lwz r4, gx@sda21(r13)
/* 800A56CC 000A260C  39 00 00 10 */	li r8, 0x10
/* 800A56D0 000A2610  38 E0 10 06 */	li r7, 0x1006
/* 800A56D4 000A2614  38 84 04 EC */	addi r4, r4, 0x4ec
/* 800A56D8 000A2618  80 04 00 00 */	lwz r0, 0(r4)
/* 800A56DC 000A261C  38 C0 00 61 */	li r6, 0x61
/* 800A56E0 000A2620  3C A0 23 00 */	lis r5, 0x2300
/* 800A56E4 000A2624  54 00 07 2E */	rlwinm r0, r0, 0, 0x1c, 0x17
/* 800A56E8 000A2628  90 04 00 00 */	stw r0, 0(r4)
/* 800A56EC 000A262C  3C 80 24 00 */	lis r4, 0x2400
/* 800A56F0 000A2630  3C 00 67 00 */	lis r0, 0x6700
/* 800A56F4 000A2634  98 6B 80 00 */	stb r3, 0xCC008000@l(r11)
/* 800A56F8 000A2638  38 60 00 00 */	li r3, 0
/* 800A56FC 000A263C  81 2D 82 C8 */	lwz r9, gx@sda21(r13)
/* 800A5700 000A2640  99 4B 80 00 */	stb r10, -0x8000(r11)
/* 800A5704 000A2644  81 29 04 EC */	lwz r9, 0x4ec(r9)
/* 800A5708 000A2648  91 2B 80 00 */	stw r9, -0x8000(r11)
/* 800A570C 000A264C  99 0B 80 00 */	stb r8, -0x8000(r11)
/* 800A5710 000A2650  90 EB 80 00 */	stw r7, -0x8000(r11)
/* 800A5714 000A2654  91 8B 80 00 */	stw r12, -0x8000(r11)
/* 800A5718 000A2658  98 CB 80 00 */	stb r6, -0x8000(r11)
/* 800A571C 000A265C  90 AB 80 00 */	stw r5, -0x8000(r11)
/* 800A5720 000A2660  98 CB 80 00 */	stb r6, -0x8000(r11)
/* 800A5724 000A2664  90 8B 80 00 */	stw r4, -0x8000(r11)
/* 800A5728 000A2668  98 CB 80 00 */	stb r6, -0x8000(r11)
/* 800A572C 000A266C  90 0B 80 00 */	stw r0, -0x8000(r11)
/* 800A5730 000A2670  48 00 59 C9 */	bl __GXSetTmemConfig
/* 800A5734 000A2674  48 00 00 1D */	bl __GXInitGX
/* 800A5738 000A2678  38 7E 04 F8 */	addi r3, r30, 0x4f8
/* 800A573C 000A267C  BB 41 00 30 */	lmw r26, 0x30(r1)
/* 800A5740 000A2680  80 01 00 4C */	lwz r0, 0x4c(r1)
/* 800A5744 000A2684  38 21 00 48 */	addi r1, r1, 0x48
/* 800A5748 000A2688  7C 08 03 A6 */	mtlr r0
/* 800A574C 000A268C  4E 80 00 20 */	blr 

.global __GXInitGX
__GXInitGX:
/* 800A5750 000A2690  7C 08 02 A6 */	mflr r0
/* 800A5754 000A2694  90 01 00 04 */	stw r0, 4(r1)
/* 800A5758 000A2698  94 21 FF 88 */	stwu r1, -0x78(r1)
/* 800A575C 000A269C  93 E1 00 74 */	stw r31, 0x74(r1)
/* 800A5760 000A26A0  93 C1 00 70 */	stw r30, 0x70(r1)
/* 800A5764 000A26A4  80 82 8A D0 */	lwz r4, "@121"@sda21(r2)
/* 800A5768 000A26A8  80 62 8A D4 */	lwz r3, "@122"@sda21(r2)
/* 800A576C 000A26AC  80 02 8A D8 */	lwz r0, "@123"@sda21(r2)
/* 800A5770 000A26B0  90 81 00 28 */	stw r4, 0x28(r1)
/* 800A5774 000A26B4  90 61 00 24 */	stw r3, 0x24(r1)
/* 800A5778 000A26B8  90 01 00 20 */	stw r0, 0x20(r1)
/* 800A577C 000A26BC  4B FF 58 41 */	bl VIGetTvFormat
/* 800A5780 000A26C0  2C 03 00 02 */	cmpwi r3, 2
/* 800A5784 000A26C4  41 82 00 54 */	beq lbl_800A57D8
/* 800A5788 000A26C8  40 80 00 14 */	bge lbl_800A579C
/* 800A578C 000A26CC  2C 03 00 00 */	cmpwi r3, 0
/* 800A5790 000A26D0  41 82 00 18 */	beq lbl_800A57A8
/* 800A5794 000A26D4  40 80 00 24 */	bge lbl_800A57B8
/* 800A5798 000A26D8  48 00 00 50 */	b lbl_800A57E8
lbl_800A579C:
/* 800A579C 000A26DC  2C 03 00 05 */	cmpwi r3, 5
/* 800A57A0 000A26E0  41 82 00 28 */	beq lbl_800A57C8
/* 800A57A4 000A26E4  48 00 00 44 */	b lbl_800A57E8
lbl_800A57A8:
/* 800A57A8 000A26E8  3C 60 80 3B */	lis r3, GXNtsc480IntDf@ha
/* 800A57AC 000A26EC  38 03 17 B8 */	addi r0, r3, GXNtsc480IntDf@l
/* 800A57B0 000A26F0  7C 1F 03 78 */	mr r31, r0
/* 800A57B4 000A26F4  48 00 00 40 */	b lbl_800A57F4
lbl_800A57B8:
/* 800A57B8 000A26F8  3C 60 80 3B */	lis r3, GXPal528IntDf@ha
/* 800A57BC 000A26FC  38 03 18 6C */	addi r0, r3, GXPal528IntDf@l
/* 800A57C0 000A2700  7C 1F 03 78 */	mr r31, r0
/* 800A57C4 000A2704  48 00 00 30 */	b lbl_800A57F4
lbl_800A57C8:
/* 800A57C8 000A2708  3C 60 80 3B */	lis r3, GXEurgb60Hz480IntDf@ha
/* 800A57CC 000A270C  38 03 18 A8 */	addi r0, r3, GXEurgb60Hz480IntDf@l
/* 800A57D0 000A2710  7C 1F 03 78 */	mr r31, r0
/* 800A57D4 000A2714  48 00 00 20 */	b lbl_800A57F4
lbl_800A57D8:
/* 800A57D8 000A2718  3C 60 80 3B */	lis r3, GXMpal480IntDf@ha
/* 800A57DC 000A271C  38 03 18 30 */	addi r0, r3, GXMpal480IntDf@l
/* 800A57E0 000A2720  7C 1F 03 78 */	mr r31, r0
/* 800A57E4 000A2724  48 00 00 10 */	b lbl_800A57F4
lbl_800A57E8:
/* 800A57E8 000A2728  3C 60 80 3B */	lis r3, GXNtsc480IntDf@ha
/* 800A57EC 000A272C  38 03 17 B8 */	addi r0, r3, GXNtsc480IntDf@l
/* 800A57F0 000A2730  7C 1F 03 78 */	mr r31, r0
lbl_800A57F4:
/* 800A57F4 000A2734  80 01 00 28 */	lwz r0, 0x28(r1)
/* 800A57F8 000A2738  3C 80 01 00 */	lis r4, 0x00FFFFFF@ha
/* 800A57FC 000A273C  38 61 00 1C */	addi r3, r1, 0x1c
/* 800A5800 000A2740  90 01 00 1C */	stw r0, 0x1c(r1)
/* 800A5804 000A2744  38 84 FF FF */	addi r4, r4, 0x00FFFFFF@l
/* 800A5808 000A2748  48 00 3B 59 */	bl GXSetCopyClear
/* 800A580C 000A274C  38 60 00 00 */	li r3, 0
/* 800A5810 000A2750  38 80 00 01 */	li r4, 1
/* 800A5814 000A2754  38 A0 00 04 */	li r5, 4
/* 800A5818 000A2758  38 C0 00 3C */	li r6, 0x3c
/* 800A581C 000A275C  38 E0 00 00 */	li r7, 0
/* 800A5820 000A2760  39 00 00 7D */	li r8, 0x7d
/* 800A5824 000A2764  48 00 26 5D */	bl GXSetTexCoordGen2
/* 800A5828 000A2768  38 60 00 01 */	li r3, 1
/* 800A582C 000A276C  38 80 00 01 */	li r4, 1
/* 800A5830 000A2770  38 A0 00 05 */	li r5, 5
/* 800A5834 000A2774  38 C0 00 3C */	li r6, 0x3c
/* 800A5838 000A2778  38 E0 00 00 */	li r7, 0
/* 800A583C 000A277C  39 00 00 7D */	li r8, 0x7d
/* 800A5840 000A2780  48 00 26 41 */	bl GXSetTexCoordGen2
/* 800A5844 000A2784  38 60 00 02 */	li r3, 2
/* 800A5848 000A2788  38 80 00 01 */	li r4, 1
/* 800A584C 000A278C  38 A0 00 06 */	li r5, 6
/* 800A5850 000A2790  38 C0 00 3C */	li r6, 0x3c
/* 800A5854 000A2794  38 E0 00 00 */	li r7, 0
/* 800A5858 000A2798  39 00 00 7D */	li r8, 0x7d
/* 800A585C 000A279C  48 00 26 25 */	bl GXSetTexCoordGen2
/* 800A5860 000A27A0  38 60 00 03 */	li r3, 3
/* 800A5864 000A27A4  38 80 00 01 */	li r4, 1
/* 800A5868 000A27A8  38 A0 00 07 */	li r5, 7
/* 800A586C 000A27AC  38 C0 00 3C */	li r6, 0x3c
/* 800A5870 000A27B0  38 E0 00 00 */	li r7, 0
/* 800A5874 000A27B4  39 00 00 7D */	li r8, 0x7d
/* 800A5878 000A27B8  48 00 26 09 */	bl GXSetTexCoordGen2
/* 800A587C 000A27BC  38 60 00 04 */	li r3, 4
/* 800A5880 000A27C0  38 80 00 01 */	li r4, 1
/* 800A5884 000A27C4  38 A0 00 08 */	li r5, 8
/* 800A5888 000A27C8  38 C0 00 3C */	li r6, 0x3c
/* 800A588C 000A27CC  38 E0 00 00 */	li r7, 0
/* 800A5890 000A27D0  39 00 00 7D */	li r8, 0x7d
/* 800A5894 000A27D4  48 00 25 ED */	bl GXSetTexCoordGen2
/* 800A5898 000A27D8  38 60 00 05 */	li r3, 5
/* 800A589C 000A27DC  38 80 00 01 */	li r4, 1
/* 800A58A0 000A27E0  38 A0 00 09 */	li r5, 9
/* 800A58A4 000A27E4  38 C0 00 3C */	li r6, 0x3c
/* 800A58A8 000A27E8  38 E0 00 00 */	li r7, 0
/* 800A58AC 000A27EC  39 00 00 7D */	li r8, 0x7d
/* 800A58B0 000A27F0  48 00 25 D1 */	bl GXSetTexCoordGen2
/* 800A58B4 000A27F4  38 60 00 06 */	li r3, 6
/* 800A58B8 000A27F8  38 80 00 01 */	li r4, 1
/* 800A58BC 000A27FC  38 A0 00 0A */	li r5, 0xa
/* 800A58C0 000A2800  38 C0 00 3C */	li r6, 0x3c
/* 800A58C4 000A2804  38 E0 00 00 */	li r7, 0
/* 800A58C8 000A2808  39 00 00 7D */	li r8, 0x7d
/* 800A58CC 000A280C  48 00 25 B5 */	bl GXSetTexCoordGen2
/* 800A58D0 000A2810  38 60 00 07 */	li r3, 7
/* 800A58D4 000A2814  38 80 00 01 */	li r4, 1
/* 800A58D8 000A2818  38 A0 00 0B */	li r5, 0xb
/* 800A58DC 000A281C  38 C0 00 3C */	li r6, 0x3c
/* 800A58E0 000A2820  38 E0 00 00 */	li r7, 0
/* 800A58E4 000A2824  39 00 00 7D */	li r8, 0x7d
/* 800A58E8 000A2828  48 00 25 99 */	bl GXSetTexCoordGen2
/* 800A58EC 000A282C  38 60 00 01 */	li r3, 1
/* 800A58F0 000A2830  48 00 28 61 */	bl GXSetNumTexGens
/* 800A58F4 000A2834  48 00 1A 75 */	bl GXClearVtxDesc
/* 800A58F8 000A2838  48 00 25 79 */	bl GXInvalidateVtxCache
/* 800A58FC 000A283C  3B C0 00 09 */	li r30, 9
/* 800A5900 000A2840  48 00 00 04 */	b lbl_800A5904
lbl_800A5904:
/* 800A5904 000A2844  48 00 00 04 */	b lbl_800A5908
lbl_800A5908:
/* 800A5908 000A2848  48 00 00 04 */	b lbl_800A590C
lbl_800A590C:
/* 800A590C 000A284C  80 8D 82 C8 */	lwz r4, gx@sda21(r13)
/* 800A5910 000A2850  7F C3 F3 78 */	mr r3, r30
/* 800A5914 000A2854  38 A0 00 00 */	li r5, 0
/* 800A5918 000A2858  48 00 24 CD */	bl GXSetArray
/* 800A591C 000A285C  3B DE 00 01 */	addi r30, r30, 1
/* 800A5920 000A2860  28 1E 00 18 */	cmplwi r30, 0x18
/* 800A5924 000A2864  40 81 FF E8 */	ble lbl_800A590C
/* 800A5928 000A2868  38 60 00 06 */	li r3, 6
/* 800A592C 000A286C  38 80 00 00 */	li r4, 0
/* 800A5930 000A2870  48 00 30 F1 */	bl GXSetLineWidth
/* 800A5934 000A2874  38 60 00 06 */	li r3, 6
/* 800A5938 000A2878  38 80 00 00 */	li r4, 0
/* 800A593C 000A287C  48 00 31 3D */	bl GXSetPointSize
/* 800A5940 000A2880  38 60 00 00 */	li r3, 0
/* 800A5944 000A2884  38 80 00 00 */	li r4, 0
/* 800A5948 000A2888  38 A0 00 00 */	li r5, 0
/* 800A594C 000A288C  48 00 31 81 */	bl GXEnableTexOffsets
/* 800A5950 000A2890  38 60 00 01 */	li r3, 1
/* 800A5954 000A2894  38 80 00 00 */	li r4, 0
/* 800A5958 000A2898  38 A0 00 00 */	li r5, 0
/* 800A595C 000A289C  48 00 31 71 */	bl GXEnableTexOffsets
/* 800A5960 000A28A0  38 60 00 02 */	li r3, 2
/* 800A5964 000A28A4  38 80 00 00 */	li r4, 0
/* 800A5968 000A28A8  38 A0 00 00 */	li r5, 0
/* 800A596C 000A28AC  48 00 31 61 */	bl GXEnableTexOffsets
/* 800A5970 000A28B0  38 60 00 03 */	li r3, 3
/* 800A5974 000A28B4  38 80 00 00 */	li r4, 0
/* 800A5978 000A28B8  38 A0 00 00 */	li r5, 0
/* 800A597C 000A28BC  48 00 31 51 */	bl GXEnableTexOffsets
/* 800A5980 000A28C0  38 60 00 04 */	li r3, 4
/* 800A5984 000A28C4  38 80 00 00 */	li r4, 0
/* 800A5988 000A28C8  38 A0 00 00 */	li r5, 0
/* 800A598C 000A28CC  48 00 31 41 */	bl GXEnableTexOffsets
/* 800A5990 000A28D0  38 60 00 05 */	li r3, 5
/* 800A5994 000A28D4  38 80 00 00 */	li r4, 0
/* 800A5998 000A28D8  38 A0 00 00 */	li r5, 0
/* 800A599C 000A28DC  48 00 31 31 */	bl GXEnableTexOffsets
/* 800A59A0 000A28E0  38 60 00 06 */	li r3, 6
/* 800A59A4 000A28E4  38 80 00 00 */	li r4, 0
/* 800A59A8 000A28E8  38 A0 00 00 */	li r5, 0
/* 800A59AC 000A28EC  48 00 31 21 */	bl GXEnableTexOffsets
/* 800A59B0 000A28F0  38 60 00 07 */	li r3, 7
/* 800A59B4 000A28F4  38 80 00 00 */	li r4, 0
/* 800A59B8 000A28F8  38 A0 00 00 */	li r5, 0
/* 800A59BC 000A28FC  48 00 31 11 */	bl GXEnableTexOffsets
/* 800A59C0 000A2900  C0 22 8A DC */	lfs f1, "@177"@sda21(r2)
/* 800A59C4 000A2904  38 61 00 2C */	addi r3, r1, 0x2c
/* 800A59C8 000A2908  C0 02 8A E0 */	lfs f0, "@178"@sda21(r2)
/* 800A59CC 000A290C  38 80 00 00 */	li r4, 0
/* 800A59D0 000A2910  D0 21 00 2C */	stfs f1, 0x2c(r1)
/* 800A59D4 000A2914  D0 01 00 30 */	stfs f0, 0x30(r1)
/* 800A59D8 000A2918  D0 01 00 34 */	stfs f0, 0x34(r1)
/* 800A59DC 000A291C  D0 01 00 38 */	stfs f0, 0x38(r1)
/* 800A59E0 000A2920  D0 01 00 3C */	stfs f0, 0x3c(r1)
/* 800A59E4 000A2924  D0 21 00 40 */	stfs f1, 0x40(r1)
/* 800A59E8 000A2928  D0 01 00 44 */	stfs f0, 0x44(r1)
/* 800A59EC 000A292C  D0 01 00 48 */	stfs f0, 0x48(r1)
/* 800A59F0 000A2930  D0 01 00 4C */	stfs f0, 0x4c(r1)
/* 800A59F4 000A2934  D0 01 00 50 */	stfs f0, 0x50(r1)
/* 800A59F8 000A2938  D0 21 00 54 */	stfs f1, 0x54(r1)
/* 800A59FC 000A293C  D0 01 00 58 */	stfs f0, 0x58(r1)
/* 800A5A00 000A2940  48 00 7D 2D */	bl GXLoadPosMtxImm
/* 800A5A04 000A2944  38 61 00 2C */	addi r3, r1, 0x2c
/* 800A5A08 000A2948  38 80 00 00 */	li r4, 0
/* 800A5A0C 000A294C  48 00 7D 8D */	bl GXLoadNrmMtxImm
/* 800A5A10 000A2950  38 60 00 00 */	li r3, 0
/* 800A5A14 000A2954  48 00 7D F9 */	bl GXSetCurrentMtx
/* 800A5A18 000A2958  38 61 00 2C */	addi r3, r1, 0x2c
/* 800A5A1C 000A295C  38 80 00 3C */	li r4, 0x3c
/* 800A5A20 000A2960  38 A0 00 00 */	li r5, 0
/* 800A5A24 000A2964  48 00 7E 25 */	bl GXLoadTexMtxImm
/* 800A5A28 000A2968  38 61 00 2C */	addi r3, r1, 0x2c
/* 800A5A2C 000A296C  38 80 00 7D */	li r4, 0x7d
/* 800A5A30 000A2970  38 A0 00 00 */	li r5, 0
/* 800A5A34 000A2974  48 00 7E 15 */	bl GXLoadTexMtxImm
/* 800A5A38 000A2978  A0 9F 00 04 */	lhz r4, 4(r31)
/* 800A5A3C 000A297C  3C 60 43 30 */	lis r3, 0x4330
/* 800A5A40 000A2980  A0 1F 00 08 */	lhz r0, 8(r31)
/* 800A5A44 000A2984  90 81 00 6C */	stw r4, 0x6c(r1)
/* 800A5A48 000A2988  C0 22 8A E0 */	lfs f1, "@178"@sda21(r2)
/* 800A5A4C 000A298C  90 01 00 64 */	stw r0, 0x64(r1)
/* 800A5A50 000A2990  C8 82 8A E8 */	lfd f4, "@181"@sda21(r2)
/* 800A5A54 000A2994  FC 40 08 90 */	fmr f2, f1
/* 800A5A58 000A2998  90 61 00 68 */	stw r3, 0x68(r1)
/* 800A5A5C 000A299C  FC A0 08 90 */	fmr f5, f1
/* 800A5A60 000A29A0  C0 C2 8A DC */	lfs f6, "@177"@sda21(r2)
/* 800A5A64 000A29A4  90 61 00 60 */	stw r3, 0x60(r1)
/* 800A5A68 000A29A8  C8 61 00 68 */	lfd f3, 0x68(r1)
/* 800A5A6C 000A29AC  C8 01 00 60 */	lfd f0, 0x60(r1)
/* 800A5A70 000A29B0  EC 63 20 28 */	fsubs f3, f3, f4
/* 800A5A74 000A29B4  EC 80 20 28 */	fsubs f4, f0, f4
/* 800A5A78 000A29B8  48 00 7F 71 */	bl GXSetViewport
/* 800A5A7C 000A29BC  38 60 00 00 */	li r3, 0
/* 800A5A80 000A29C0  48 00 31 01 */	bl GXSetCoPlanar
/* 800A5A84 000A29C4  38 60 00 02 */	li r3, 2
/* 800A5A88 000A29C8  48 00 30 A9 */	bl GXSetCullMode
/* 800A5A8C 000A29CC  38 60 00 00 */	li r3, 0
/* 800A5A90 000A29D0  48 00 80 BD */	bl GXSetClipMode
/* 800A5A94 000A29D4  A0 BF 00 04 */	lhz r5, 4(r31)
/* 800A5A98 000A29D8  38 60 00 00 */	li r3, 0
/* 800A5A9C 000A29DC  A0 DF 00 06 */	lhz r6, 6(r31)
/* 800A5AA0 000A29E0  38 80 00 00 */	li r4, 0
/* 800A5AA4 000A29E4  48 00 7F B5 */	bl GXSetScissor
/* 800A5AA8 000A29E8  38 60 00 00 */	li r3, 0
/* 800A5AAC 000A29EC  38 80 00 00 */	li r4, 0
/* 800A5AB0 000A29F0  48 00 80 59 */	bl GXSetScissorBoxOffset
/* 800A5AB4 000A29F4  38 60 00 00 */	li r3, 0
/* 800A5AB8 000A29F8  48 00 44 ED */	bl GXSetNumChans
/* 800A5ABC 000A29FC  38 60 00 04 */	li r3, 4
/* 800A5AC0 000A2A00  38 80 00 00 */	li r4, 0
/* 800A5AC4 000A2A04  38 A0 00 00 */	li r5, 0
/* 800A5AC8 000A2A08  38 C0 00 01 */	li r6, 1
/* 800A5ACC 000A2A0C  38 E0 00 00 */	li r7, 0
/* 800A5AD0 000A2A10  39 00 00 00 */	li r8, 0
/* 800A5AD4 000A2A14  39 20 00 02 */	li r9, 2
/* 800A5AD8 000A2A18  48 00 45 19 */	bl GXSetChanCtrl
/* 800A5ADC 000A2A1C  80 01 00 24 */	lwz r0, 0x24(r1)
/* 800A5AE0 000A2A20  38 81 00 18 */	addi r4, r1, 0x18
/* 800A5AE4 000A2A24  38 60 00 04 */	li r3, 4
/* 800A5AE8 000A2A28  90 01 00 18 */	stw r0, 0x18(r1)
/* 800A5AEC 000A2A2C  48 00 41 E9 */	bl GXSetChanAmbColor
/* 800A5AF0 000A2A30  80 01 00 20 */	lwz r0, 0x20(r1)
/* 800A5AF4 000A2A34  38 81 00 14 */	addi r4, r1, 0x14
/* 800A5AF8 000A2A38  38 60 00 04 */	li r3, 4
/* 800A5AFC 000A2A3C  90 01 00 14 */	stw r0, 0x14(r1)
/* 800A5B00 000A2A40  48 00 43 3D */	bl GXSetChanMatColor
/* 800A5B04 000A2A44  38 60 00 05 */	li r3, 5
/* 800A5B08 000A2A48  38 80 00 00 */	li r4, 0
/* 800A5B0C 000A2A4C  38 A0 00 00 */	li r5, 0
/* 800A5B10 000A2A50  38 C0 00 01 */	li r6, 1
/* 800A5B14 000A2A54  38 E0 00 00 */	li r7, 0
/* 800A5B18 000A2A58  39 00 00 00 */	li r8, 0
/* 800A5B1C 000A2A5C  39 20 00 02 */	li r9, 2
/* 800A5B20 000A2A60  48 00 44 D1 */	bl GXSetChanCtrl
/* 800A5B24 000A2A64  80 01 00 24 */	lwz r0, 0x24(r1)
/* 800A5B28 000A2A68  38 81 00 10 */	addi r4, r1, 0x10
/* 800A5B2C 000A2A6C  38 60 00 05 */	li r3, 5
/* 800A5B30 000A2A70  90 01 00 10 */	stw r0, 0x10(r1)
/* 800A5B34 000A2A74  48 00 41 A1 */	bl GXSetChanAmbColor
/* 800A5B38 000A2A78  80 01 00 20 */	lwz r0, 0x20(r1)
/* 800A5B3C 000A2A7C  38 81 00 0C */	addi r4, r1, 0xc
/* 800A5B40 000A2A80  38 60 00 05 */	li r3, 5
/* 800A5B44 000A2A84  90 01 00 0C */	stw r0, 0xc(r1)
/* 800A5B48 000A2A88  48 00 42 F5 */	bl GXSetChanMatColor
/* 800A5B4C 000A2A8C  48 00 51 D5 */	bl GXInvalidateTexAll
/* 800A5B50 000A2A90  80 8D 82 C8 */	lwz r4, gx@sda21(r13)
/* 800A5B54 000A2A94  3B C0 00 00 */	li r30, 0
/* 800A5B58 000A2A98  3C 60 80 0A */	lis r3, __GXDefaultTexRegionCallback@ha
/* 800A5B5C 000A2A9C  93 C4 02 C8 */	stw r30, 0x2c8(r4)
/* 800A5B60 000A2AA0  38 63 4E E4 */	addi r3, r3, __GXDefaultTexRegionCallback@l
/* 800A5B64 000A2AA4  80 8D 82 C8 */	lwz r4, gx@sda21(r13)
/* 800A5B68 000A2AA8  93 C4 02 CC */	stw r30, 0x2cc(r4)
/* 800A5B6C 000A2AAC  48 00 51 FD */	bl GXSetTexRegionCallback
/* 800A5B70 000A2AB0  3C 60 80 0A */	lis r3, __GXDefaultTlutRegionCallback@ha
/* 800A5B74 000A2AB4  38 63 4F 60 */	addi r3, r3, __GXDefaultTlutRegionCallback@l
/* 800A5B78 000A2AB8  48 00 52 05 */	bl GXSetTlutRegionCallback
/* 800A5B7C 000A2ABC  38 60 00 00 */	li r3, 0
/* 800A5B80 000A2AC0  38 80 00 00 */	li r4, 0
/* 800A5B84 000A2AC4  38 A0 00 00 */	li r5, 0
/* 800A5B88 000A2AC8  38 C0 00 04 */	li r6, 4
/* 800A5B8C 000A2ACC  48 00 66 A5 */	bl GXSetTevOrder
/* 800A5B90 000A2AD0  38 60 00 01 */	li r3, 1
/* 800A5B94 000A2AD4  38 80 00 01 */	li r4, 1
/* 800A5B98 000A2AD8  38 A0 00 01 */	li r5, 1
/* 800A5B9C 000A2ADC  38 C0 00 04 */	li r6, 4
/* 800A5BA0 000A2AE0  48 00 66 91 */	bl GXSetTevOrder
/* 800A5BA4 000A2AE4  38 60 00 02 */	li r3, 2
/* 800A5BA8 000A2AE8  38 80 00 02 */	li r4, 2
/* 800A5BAC 000A2AEC  38 A0 00 02 */	li r5, 2
/* 800A5BB0 000A2AF0  38 C0 00 04 */	li r6, 4
/* 800A5BB4 000A2AF4  48 00 66 7D */	bl GXSetTevOrder
/* 800A5BB8 000A2AF8  38 60 00 03 */	li r3, 3
/* 800A5BBC 000A2AFC  38 80 00 03 */	li r4, 3
/* 800A5BC0 000A2B00  38 A0 00 03 */	li r5, 3
/* 800A5BC4 000A2B04  38 C0 00 04 */	li r6, 4
/* 800A5BC8 000A2B08  48 00 66 69 */	bl GXSetTevOrder
/* 800A5BCC 000A2B0C  38 60 00 04 */	li r3, 4
/* 800A5BD0 000A2B10  38 80 00 04 */	li r4, 4
/* 800A5BD4 000A2B14  38 A0 00 04 */	li r5, 4
/* 800A5BD8 000A2B18  38 C0 00 04 */	li r6, 4
/* 800A5BDC 000A2B1C  48 00 66 55 */	bl GXSetTevOrder
/* 800A5BE0 000A2B20  38 60 00 05 */	li r3, 5
/* 800A5BE4 000A2B24  38 80 00 05 */	li r4, 5
/* 800A5BE8 000A2B28  38 A0 00 05 */	li r5, 5
/* 800A5BEC 000A2B2C  38 C0 00 04 */	li r6, 4
/* 800A5BF0 000A2B30  48 00 66 41 */	bl GXSetTevOrder
/* 800A5BF4 000A2B34  38 60 00 06 */	li r3, 6
/* 800A5BF8 000A2B38  38 80 00 06 */	li r4, 6
/* 800A5BFC 000A2B3C  38 A0 00 06 */	li r5, 6
/* 800A5C00 000A2B40  38 C0 00 04 */	li r6, 4
/* 800A5C04 000A2B44  48 00 66 2D */	bl GXSetTevOrder
/* 800A5C08 000A2B48  38 60 00 07 */	li r3, 7
/* 800A5C0C 000A2B4C  38 80 00 07 */	li r4, 7
/* 800A5C10 000A2B50  38 A0 00 07 */	li r5, 7
/* 800A5C14 000A2B54  38 C0 00 04 */	li r6, 4
/* 800A5C18 000A2B58  48 00 66 19 */	bl GXSetTevOrder
/* 800A5C1C 000A2B5C  38 60 00 08 */	li r3, 8
/* 800A5C20 000A2B60  38 80 00 FF */	li r4, 0xff
/* 800A5C24 000A2B64  38 A0 00 FF */	li r5, 0xff
/* 800A5C28 000A2B68  38 C0 00 FF */	li r6, 0xff
/* 800A5C2C 000A2B6C  48 00 66 05 */	bl GXSetTevOrder
/* 800A5C30 000A2B70  38 60 00 09 */	li r3, 9
/* 800A5C34 000A2B74  38 80 00 FF */	li r4, 0xff
/* 800A5C38 000A2B78  38 A0 00 FF */	li r5, 0xff
/* 800A5C3C 000A2B7C  38 C0 00 FF */	li r6, 0xff
/* 800A5C40 000A2B80  48 00 65 F1 */	bl GXSetTevOrder
/* 800A5C44 000A2B84  38 60 00 0A */	li r3, 0xa
/* 800A5C48 000A2B88  38 80 00 FF */	li r4, 0xff
/* 800A5C4C 000A2B8C  38 A0 00 FF */	li r5, 0xff
/* 800A5C50 000A2B90  38 C0 00 FF */	li r6, 0xff
/* 800A5C54 000A2B94  48 00 65 DD */	bl GXSetTevOrder
/* 800A5C58 000A2B98  38 60 00 0B */	li r3, 0xb
/* 800A5C5C 000A2B9C  38 80 00 FF */	li r4, 0xff
/* 800A5C60 000A2BA0  38 A0 00 FF */	li r5, 0xff
/* 800A5C64 000A2BA4  38 C0 00 FF */	li r6, 0xff
/* 800A5C68 000A2BA8  48 00 65 C9 */	bl GXSetTevOrder
/* 800A5C6C 000A2BAC  38 60 00 0C */	li r3, 0xc
/* 800A5C70 000A2BB0  38 80 00 FF */	li r4, 0xff
/* 800A5C74 000A2BB4  38 A0 00 FF */	li r5, 0xff
/* 800A5C78 000A2BB8  38 C0 00 FF */	li r6, 0xff
/* 800A5C7C 000A2BBC  48 00 65 B5 */	bl GXSetTevOrder
/* 800A5C80 000A2BC0  38 60 00 0D */	li r3, 0xd
/* 800A5C84 000A2BC4  38 80 00 FF */	li r4, 0xff
/* 800A5C88 000A2BC8  38 A0 00 FF */	li r5, 0xff
/* 800A5C8C 000A2BCC  38 C0 00 FF */	li r6, 0xff
/* 800A5C90 000A2BD0  48 00 65 A1 */	bl GXSetTevOrder
/* 800A5C94 000A2BD4  38 60 00 0E */	li r3, 0xe
/* 800A5C98 000A2BD8  38 80 00 FF */	li r4, 0xff
/* 800A5C9C 000A2BDC  38 A0 00 FF */	li r5, 0xff
/* 800A5CA0 000A2BE0  38 C0 00 FF */	li r6, 0xff
/* 800A5CA4 000A2BE4  48 00 65 8D */	bl GXSetTevOrder
/* 800A5CA8 000A2BE8  38 60 00 0F */	li r3, 0xf
/* 800A5CAC 000A2BEC  38 80 00 FF */	li r4, 0xff
/* 800A5CB0 000A2BF0  38 A0 00 FF */	li r5, 0xff
/* 800A5CB4 000A2BF4  38 C0 00 FF */	li r6, 0xff
/* 800A5CB8 000A2BF8  48 00 65 79 */	bl GXSetTevOrder
/* 800A5CBC 000A2BFC  38 60 00 01 */	li r3, 1
/* 800A5CC0 000A2C00  48 00 67 4D */	bl GXSetNumTevStages
/* 800A5CC4 000A2C04  38 60 00 00 */	li r3, 0
/* 800A5CC8 000A2C08  38 80 00 03 */	li r4, 3
/* 800A5CCC 000A2C0C  48 00 5D 3D */	bl GXSetTevOp
/* 800A5CD0 000A2C10  38 60 00 07 */	li r3, 7
/* 800A5CD4 000A2C14  38 80 00 00 */	li r4, 0
/* 800A5CD8 000A2C18  38 A0 00 00 */	li r5, 0
/* 800A5CDC 000A2C1C  38 C0 00 07 */	li r6, 7
/* 800A5CE0 000A2C20  38 E0 00 00 */	li r7, 0
/* 800A5CE4 000A2C24  48 00 64 79 */	bl GXSetAlphaCompare
/* 800A5CE8 000A2C28  38 60 00 00 */	li r3, 0
/* 800A5CEC 000A2C2C  38 80 00 11 */	li r4, 0x11
/* 800A5CF0 000A2C30  38 A0 00 00 */	li r5, 0
/* 800A5CF4 000A2C34  48 00 64 B9 */	bl GXSetZTexture
/* 800A5CF8 000A2C38  48 00 00 04 */	b lbl_800A5CFC
lbl_800A5CFC:
/* 800A5CFC 000A2C3C  48 00 00 04 */	b lbl_800A5D00
lbl_800A5D00:
/* 800A5D00 000A2C40  48 00 00 04 */	b lbl_800A5D04
lbl_800A5D04:
/* 800A5D04 000A2C44  7F C3 F3 78 */	mr r3, r30
/* 800A5D08 000A2C48  38 80 00 06 */	li r4, 6
/* 800A5D0C 000A2C4C  48 00 62 81 */	bl GXSetTevKColorSel
/* 800A5D10 000A2C50  7F C3 F3 78 */	mr r3, r30
/* 800A5D14 000A2C54  38 80 00 00 */	li r4, 0
/* 800A5D18 000A2C58  48 00 62 E1 */	bl GXSetTevKAlphaSel
/* 800A5D1C 000A2C5C  7F C3 F3 78 */	mr r3, r30
/* 800A5D20 000A2C60  38 80 00 00 */	li r4, 0
/* 800A5D24 000A2C64  38 A0 00 00 */	li r5, 0
/* 800A5D28 000A2C68  48 00 63 3D */	bl GXSetTevSwapMode
/* 800A5D2C 000A2C6C  3B DE 00 01 */	addi r30, r30, 1
/* 800A5D30 000A2C70  28 1E 00 10 */	cmplwi r30, 0x10
/* 800A5D34 000A2C74  41 80 FF D0 */	blt lbl_800A5D04
/* 800A5D38 000A2C78  38 60 00 00 */	li r3, 0
/* 800A5D3C 000A2C7C  38 80 00 00 */	li r4, 0
/* 800A5D40 000A2C80  38 A0 00 01 */	li r5, 1
/* 800A5D44 000A2C84  38 C0 00 02 */	li r6, 2
/* 800A5D48 000A2C88  38 E0 00 03 */	li r7, 3
/* 800A5D4C 000A2C8C  48 00 63 71 */	bl GXSetTevSwapModeTable
/* 800A5D50 000A2C90  38 60 00 01 */	li r3, 1
/* 800A5D54 000A2C94  38 80 00 00 */	li r4, 0
/* 800A5D58 000A2C98  38 A0 00 00 */	li r5, 0
/* 800A5D5C 000A2C9C  38 C0 00 00 */	li r6, 0
/* 800A5D60 000A2CA0  38 E0 00 03 */	li r7, 3
/* 800A5D64 000A2CA4  48 00 63 59 */	bl GXSetTevSwapModeTable
/* 800A5D68 000A2CA8  38 60 00 02 */	li r3, 2
/* 800A5D6C 000A2CAC  38 80 00 01 */	li r4, 1
/* 800A5D70 000A2CB0  38 A0 00 01 */	li r5, 1
/* 800A5D74 000A2CB4  38 C0 00 01 */	li r6, 1
/* 800A5D78 000A2CB8  38 E0 00 03 */	li r7, 3
/* 800A5D7C 000A2CBC  48 00 63 41 */	bl GXSetTevSwapModeTable
/* 800A5D80 000A2CC0  38 60 00 03 */	li r3, 3
/* 800A5D84 000A2CC4  38 80 00 02 */	li r4, 2
/* 800A5D88 000A2CC8  38 A0 00 02 */	li r5, 2
/* 800A5D8C 000A2CCC  38 C0 00 02 */	li r6, 2
/* 800A5D90 000A2CD0  38 E0 00 03 */	li r7, 3
/* 800A5D94 000A2CD4  48 00 63 29 */	bl GXSetTevSwapModeTable
/* 800A5D98 000A2CD8  3B C0 00 00 */	li r30, 0
/* 800A5D9C 000A2CDC  48 00 00 04 */	b lbl_800A5DA0
lbl_800A5DA0:
/* 800A5DA0 000A2CE0  48 00 00 04 */	b lbl_800A5DA4
lbl_800A5DA4:
/* 800A5DA4 000A2CE4  48 00 00 04 */	b lbl_800A5DA8
lbl_800A5DA8:
/* 800A5DA8 000A2CE8  7F C3 F3 78 */	mr r3, r30
/* 800A5DAC 000A2CEC  48 00 5A C1 */	bl GXSetTevDirect
/* 800A5DB0 000A2CF0  3B DE 00 01 */	addi r30, r30, 1
/* 800A5DB4 000A2CF4  28 1E 00 10 */	cmplwi r30, 0x10
/* 800A5DB8 000A2CF8  41 80 FF F0 */	blt lbl_800A5DA8
/* 800A5DBC 000A2CFC  38 60 00 00 */	li r3, 0
/* 800A5DC0 000A2D00  48 00 5A 81 */	bl GXSetNumIndStages
/* 800A5DC4 000A2D04  38 60 00 00 */	li r3, 0
/* 800A5DC8 000A2D08  38 80 00 00 */	li r4, 0
/* 800A5DCC 000A2D0C  38 A0 00 00 */	li r5, 0
/* 800A5DD0 000A2D10  48 00 57 65 */	bl GXSetIndTexCoordScale
/* 800A5DD4 000A2D14  38 60 00 01 */	li r3, 1
/* 800A5DD8 000A2D18  38 80 00 00 */	li r4, 0
/* 800A5DDC 000A2D1C  38 A0 00 00 */	li r5, 0
/* 800A5DE0 000A2D20  48 00 57 55 */	bl GXSetIndTexCoordScale
/* 800A5DE4 000A2D24  38 60 00 02 */	li r3, 2
/* 800A5DE8 000A2D28  38 80 00 00 */	li r4, 0
/* 800A5DEC 000A2D2C  38 A0 00 00 */	li r5, 0
/* 800A5DF0 000A2D30  48 00 57 45 */	bl GXSetIndTexCoordScale
/* 800A5DF4 000A2D34  38 60 00 03 */	li r3, 3
/* 800A5DF8 000A2D38  38 80 00 00 */	li r4, 0
/* 800A5DFC 000A2D3C  38 A0 00 00 */	li r5, 0
/* 800A5E00 000A2D40  48 00 57 35 */	bl GXSetIndTexCoordScale
/* 800A5E04 000A2D44  C0 42 8A DC */	lfs f2, "@177"@sda21(r2)
/* 800A5E08 000A2D48  38 81 00 08 */	addi r4, r1, 8
/* 800A5E0C 000A2D4C  80 01 00 24 */	lwz r0, 0x24(r1)
/* 800A5E10 000A2D50  38 60 00 00 */	li r3, 0
/* 800A5E14 000A2D54  FC 80 10 90 */	fmr f4, f2
/* 800A5E18 000A2D58  90 01 00 08 */	stw r0, 8(r1)
/* 800A5E1C 000A2D5C  C0 22 8A E0 */	lfs f1, "@178"@sda21(r2)
/* 800A5E20 000A2D60  C0 62 8A E4 */	lfs f3, "@179"@sda21(r2)
/* 800A5E24 000A2D64  48 00 66 1D */	bl GXSetFog
/* 800A5E28 000A2D68  38 60 00 00 */	li r3, 0
/* 800A5E2C 000A2D6C  38 80 00 00 */	li r4, 0
/* 800A5E30 000A2D70  38 A0 00 00 */	li r5, 0
/* 800A5E34 000A2D74  48 00 67 BD */	bl GXSetFogRangeAdj
/* 800A5E38 000A2D78  38 60 00 00 */	li r3, 0
/* 800A5E3C 000A2D7C  38 80 00 04 */	li r4, 4
/* 800A5E40 000A2D80  38 A0 00 05 */	li r5, 5
/* 800A5E44 000A2D84  38 C0 00 00 */	li r6, 0
/* 800A5E48 000A2D88  48 00 68 A9 */	bl GXSetBlendMode
/* 800A5E4C 000A2D8C  38 60 00 01 */	li r3, 1
/* 800A5E50 000A2D90  48 00 69 A5 */	bl GXSetColorUpdate
/* 800A5E54 000A2D94  38 60 00 01 */	li r3, 1
/* 800A5E58 000A2D98  48 00 69 DD */	bl GXSetAlphaUpdate
/* 800A5E5C 000A2D9C  38 60 00 01 */	li r3, 1
/* 800A5E60 000A2DA0  38 80 00 03 */	li r4, 3
/* 800A5E64 000A2DA4  38 A0 00 01 */	li r5, 1
/* 800A5E68 000A2DA8  48 00 6A 0D */	bl GXSetZMode
/* 800A5E6C 000A2DAC  38 60 00 01 */	li r3, 1
/* 800A5E70 000A2DB0  48 00 6A 7D */	bl GXSetZCompLoc
/* 800A5E74 000A2DB4  38 60 00 01 */	li r3, 1
/* 800A5E78 000A2DB8  48 00 6B C5 */	bl GXSetDither
/* 800A5E7C 000A2DBC  38 60 00 00 */	li r3, 0
/* 800A5E80 000A2DC0  38 80 00 00 */	li r4, 0
/* 800A5E84 000A2DC4  48 00 6B F9 */	bl GXSetDstAlpha
/* 800A5E88 000A2DC8  38 60 00 00 */	li r3, 0
/* 800A5E8C 000A2DCC  38 80 00 00 */	li r4, 0
/* 800A5E90 000A2DD0  48 00 6A 9D */	bl GXSetPixelFmt
/* 800A5E94 000A2DD4  38 60 00 01 */	li r3, 1
/* 800A5E98 000A2DD8  38 80 00 01 */	li r4, 1
/* 800A5E9C 000A2DDC  48 00 6C 35 */	bl GXSetFieldMask
/* 800A5EA0 000A2DE0  A0 1F 00 08 */	lhz r0, 8(r31)
/* 800A5EA4 000A2DE4  A0 7F 00 10 */	lhz r3, 0x10(r31)
/* 800A5EA8 000A2DE8  54 00 08 3C */	slwi r0, r0, 1
/* 800A5EAC 000A2DEC  7C 03 00 00 */	cmpw r3, r0
/* 800A5EB0 000A2DF0  40 82 00 0C */	bne lbl_800A5EBC
/* 800A5EB4 000A2DF4  38 80 00 01 */	li r4, 1
/* 800A5EB8 000A2DF8  48 00 00 08 */	b lbl_800A5EC0
lbl_800A5EBC:
/* 800A5EBC 000A2DFC  38 80 00 00 */	li r4, 0
lbl_800A5EC0:
/* 800A5EC0 000A2E00  88 7F 00 18 */	lbz r3, 0x18(r31)
/* 800A5EC4 000A2E04  48 00 6C 45 */	bl GXSetFieldMode
/* 800A5EC8 000A2E08  A0 BF 00 04 */	lhz r5, 4(r31)
/* 800A5ECC 000A2E0C  38 60 00 00 */	li r3, 0
/* 800A5ED0 000A2E10  A0 DF 00 06 */	lhz r6, 6(r31)
/* 800A5ED4 000A2E14  38 80 00 00 */	li r4, 0
/* 800A5ED8 000A2E18  48 00 2D 11 */	bl GXSetDispCopySrc
/* 800A5EDC 000A2E1C  A0 7F 00 04 */	lhz r3, 4(r31)
/* 800A5EE0 000A2E20  A0 9F 00 06 */	lhz r4, 6(r31)
/* 800A5EE4 000A2E24  48 00 2E 85 */	bl GXSetDispCopyDst
/* 800A5EE8 000A2E28  A0 9F 00 08 */	lhz r4, 8(r31)
/* 800A5EEC 000A2E2C  3C 60 43 30 */	lis r3, 0x4330
/* 800A5EF0 000A2E30  A0 1F 00 06 */	lhz r0, 6(r31)
/* 800A5EF4 000A2E34  90 81 00 64 */	stw r4, 0x64(r1)
/* 800A5EF8 000A2E38  C8 42 8A E8 */	lfd f2, "@181"@sda21(r2)
/* 800A5EFC 000A2E3C  90 01 00 6C */	stw r0, 0x6c(r1)
/* 800A5F00 000A2E40  90 61 00 60 */	stw r3, 0x60(r1)
/* 800A5F04 000A2E44  90 61 00 68 */	stw r3, 0x68(r1)
/* 800A5F08 000A2E48  C8 21 00 60 */	lfd f1, 0x60(r1)
/* 800A5F0C 000A2E4C  C8 01 00 68 */	lfd f0, 0x68(r1)
/* 800A5F10 000A2E50  EC 21 10 28 */	fsubs f1, f1, f2
/* 800A5F14 000A2E54  EC 00 10 28 */	fsubs f0, f0, f2
/* 800A5F18 000A2E58  EC 21 00 24 */	fdivs f1, f1, f0
/* 800A5F1C 000A2E5C  48 00 33 71 */	bl GXSetDispCopyYScale
/* 800A5F20 000A2E60  38 60 00 03 */	li r3, 3
/* 800A5F24 000A2E64  48 00 30 25 */	bl GXSetCopyClamp
/* 800A5F28 000A2E68  88 7F 00 19 */	lbz r3, 0x19(r31)
/* 800A5F2C 000A2E6C  38 9F 00 1A */	addi r4, r31, 0x1a
/* 800A5F30 000A2E70  38 DF 00 32 */	addi r6, r31, 0x32
/* 800A5F34 000A2E74  38 A0 00 01 */	li r5, 1
/* 800A5F38 000A2E78  48 00 34 91 */	bl GXSetCopyFilter
/* 800A5F3C 000A2E7C  38 60 00 00 */	li r3, 0
/* 800A5F40 000A2E80  48 00 36 B1 */	bl GXSetDispCopyGamma
/* 800A5F44 000A2E84  38 60 00 00 */	li r3, 0
/* 800A5F48 000A2E88  48 00 2F D5 */	bl GXSetDispCopyFrame2Field
/* 800A5F4C 000A2E8C  48 00 39 C1 */	bl GXClearBoundingBox
/* 800A5F50 000A2E90  38 60 00 01 */	li r3, 1
/* 800A5F54 000A2E94  48 00 26 25 */	bl GXPokeColorUpdate
/* 800A5F58 000A2E98  38 60 00 01 */	li r3, 1
/* 800A5F5C 000A2E9C  48 00 25 79 */	bl GXPokeAlphaUpdate
/* 800A5F60 000A2EA0  38 60 00 00 */	li r3, 0
/* 800A5F64 000A2EA4  48 00 26 45 */	bl GXPokeDither
/* 800A5F68 000A2EA8  38 60 00 00 */	li r3, 0
/* 800A5F6C 000A2EAC  38 80 00 00 */	li r4, 0
/* 800A5F70 000A2EB0  38 A0 00 01 */	li r5, 1
/* 800A5F74 000A2EB4  38 C0 00 0F */	li r6, 0xf
/* 800A5F78 000A2EB8  48 00 25 79 */	bl GXPokeBlendMode
/* 800A5F7C 000A2EBC  38 60 00 07 */	li r3, 7
/* 800A5F80 000A2EC0  38 80 00 00 */	li r4, 0
/* 800A5F84 000A2EC4  48 00 25 29 */	bl GXPokeAlphaMode
/* 800A5F88 000A2EC8  38 60 00 01 */	li r3, 1
/* 800A5F8C 000A2ECC  48 00 25 35 */	bl GXPokeAlphaRead
/* 800A5F90 000A2ED0  38 60 00 00 */	li r3, 0
/* 800A5F94 000A2ED4  38 80 00 00 */	li r4, 0
/* 800A5F98 000A2ED8  48 00 25 FD */	bl GXPokeDstAlpha
/* 800A5F9C 000A2EDC  38 60 00 01 */	li r3, 1
/* 800A5FA0 000A2EE0  38 80 00 07 */	li r4, 7
/* 800A5FA4 000A2EE4  38 A0 00 01 */	li r5, 1
/* 800A5FA8 000A2EE8  48 00 26 1D */	bl GXPokeZMode
/* 800A5FAC 000A2EEC  38 60 00 23 */	li r3, 0x23
/* 800A5FB0 000A2EF0  38 80 00 16 */	li r4, 0x16
/* 800A5FB4 000A2EF4  48 00 7C 45 */	bl GXSetGPMetric
/* 800A5FB8 000A2EF8  48 00 84 D9 */	bl GXClearGPMetric
/* 800A5FBC 000A2EFC  80 01 00 7C */	lwz r0, 0x7c(r1)
/* 800A5FC0 000A2F00  83 E1 00 74 */	lwz r31, 0x74(r1)
/* 800A5FC4 000A2F04  83 C1 00 70 */	lwz r30, 0x70(r1)
/* 800A5FC8 000A2F08  38 21 00 78 */	addi r1, r1, 0x78
/* 800A5FCC 000A2F0C  7C 08 03 A6 */	mtlr r0
/* 800A5FD0 000A2F10  4E 80 00 20 */	blr 

.section .sdata, "wa"  # 0x80408AC0 - 0x804097C0
.global gx
gx:
  .4byte gxData
  .4byte 0

.section .sdata2, "a"  # 0x8040B460 - 0x80414020
.balign 8
"@121":
	.4byte 0x404040FF
"@122":
  .4byte 0
"@123":
  .4byte -1
"@177":
	.4byte 0x3F800000
"@178":
  .4byte 0
"@179":
	.4byte 0x3DCCCCCD
"@181":
	.4byte 0x43300000
	.4byte 0

.section .bss, "wa"  # 0x803E6000 - 0x80408AC0
gxData:
	.skip 0x4F8
FifoObj:
	.skip 0x80

.section .sbss, "wa"  # 0x804097C0 - 0x8040B45C
.global __piReg
__piReg:
	.skip 0x4
.global __cpReg
__cpReg:
	.skip 0x4
.global __peReg
__peReg:
	.skip 0x4
__memReg:
	.skip 0x4