papermario/asm/nonmatchings/code_376460/func_E00741E8.s
Ethan Roseman a8e550dd9a yee
2020-10-17 22:27:25 -04:00

250 lines
13 KiB
ArmAsm

.set noat # allow manual use of $at
.set noreorder # don't insert nops after branches
glabel func_E00741E8
/* 376648 E00741E8 27BDFFA0 */ addiu $sp, $sp, -0x60
/* 37664C E00741EC AFB20020 */ sw $s2, 0x20($sp)
/* 376650 E00741F0 0080902D */ daddu $s2, $a0, $zero
/* 376654 E00741F4 AFBF0028 */ sw $ra, 0x28($sp)
/* 376658 E00741F8 AFB30024 */ sw $s3, 0x24($sp)
/* 37665C E00741FC AFB1001C */ sw $s1, 0x1c($sp)
/* 376660 E0074200 AFB00018 */ sw $s0, 0x18($sp)
/* 376664 E0074204 F7BE0058 */ sdc1 $f30, 0x58($sp)
/* 376668 E0074208 F7BC0050 */ sdc1 $f28, 0x50($sp)
/* 37666C E007420C F7BA0048 */ sdc1 $f26, 0x48($sp)
/* 376670 E0074210 F7B80040 */ sdc1 $f24, 0x40($sp)
/* 376674 E0074214 F7B60038 */ sdc1 $f22, 0x38($sp)
/* 376678 E0074218 F7B40030 */ sdc1 $f20, 0x30($sp)
/* 37667C E007421C 8E440000 */ lw $a0, ($s2)
/* 376680 E0074220 8E43000C */ lw $v1, 0xc($s2)
/* 376684 E0074224 30820010 */ andi $v0, $a0, 0x10
/* 376688 E0074228 10400005 */ beqz $v0, .LE0074240
/* 37668C E007422C 2402FFEF */ addiu $v0, $zero, -0x11
/* 376690 E0074230 00821024 */ and $v0, $a0, $v0
/* 376694 E0074234 AE420000 */ sw $v0, ($s2)
/* 376698 E0074238 24020010 */ addiu $v0, $zero, 0x10
/* 37669C E007423C AC620038 */ sw $v0, 0x38($v1)
.LE0074240:
/* 3766A0 E0074240 8C640038 */ lw $a0, 0x38($v1)
/* 3766A4 E0074244 288203E8 */ slti $v0, $a0, 0x3e8
/* 3766A8 E0074248 10400002 */ beqz $v0, .LE0074254
/* 3766AC E007424C 2482FFFF */ addiu $v0, $a0, -1
/* 3766B0 E0074250 AC620038 */ sw $v0, 0x38($v1)
.LE0074254:
/* 3766B4 E0074254 8C62003C */ lw $v0, 0x3c($v1)
/* 3766B8 E0074258 8C640038 */ lw $a0, 0x38($v1)
/* 3766BC E007425C 24420001 */ addiu $v0, $v0, 1
/* 3766C0 E0074260 04810005 */ bgez $a0, .LE0074278
/* 3766C4 E0074264 AC62003C */ sw $v0, 0x3c($v1)
/* 3766C8 E0074268 0C080128 */ jal func_E02004A0
/* 3766CC E007426C 0240202D */ daddu $a0, $s2, $zero
/* 3766D0 E0074270 0801D159 */ j .LE0074564
/* 3766D4 E0074274 00000000 */ nop
.LE0074278:
/* 3766D8 E0074278 28820008 */ slti $v0, $a0, 8
/* 3766DC E007427C 10400002 */ beqz $v0, .LE0074288
/* 3766E0 E0074280 00041140 */ sll $v0, $a0, 5
/* 3766E4 E0074284 AC62004C */ sw $v0, 0x4c($v1)
.LE0074288:
/* 3766E8 E0074288 C47E0010 */ lwc1 $f30, 0x10($v1)
/* 3766EC E007428C C47C0014 */ lwc1 $f28, 0x14($v1)
/* 3766F0 E0074290 E7BC0010 */ swc1 $f28, 0x10($sp)
/* 3766F4 E0074294 8E420008 */ lw $v0, 8($s2)
/* 3766F8 E0074298 24110001 */ addiu $s1, $zero, 1
/* 3766FC E007429C 0222102A */ slt $v0, $s1, $v0
/* 376700 E00742A0 104000B0 */ beqz $v0, .LE0074564
/* 376704 E00742A4 2463006C */ addiu $v1, $v1, 0x6c
/* 376708 E00742A8 3C13E007 */ lui $s3, 0xe007
/* 37670C E00742AC 26734B80 */ addiu $s3, $s3, 0x4b80
/* 376710 E00742B0 24700020 */ addiu $s0, $v1, 0x20
/* 376714 E00742B4 3C013FE0 */ lui $at, 0x3fe0
/* 376718 E00742B8 4481C800 */ mtc1 $at, $f25
/* 37671C E00742BC 4480C000 */ mtc1 $zero, $f24
/* 376720 E00742C0 3C01E007 */ lui $at, 0xe007
/* 376724 E00742C4 D43A4BF0 */ ldc1 $f26, 0x4bf0($at)
.LE00742C8:
/* 376728 E00742C8 8E020010 */ lw $v0, 0x10($s0)
/* 37672C E00742CC 24420001 */ addiu $v0, $v0, 1
/* 376730 E00742D0 AE020010 */ sw $v0, 0x10($s0)
/* 376734 E00742D4 28420014 */ slti $v0, $v0, 0x14
/* 376738 E00742D8 50400001 */ beql $v0, $zero, .LE00742E0
/* 37673C E00742DC AE000010 */ sw $zero, 0x10($s0)
.LE00742E0:
/* 376740 E00742E0 8E020010 */ lw $v0, 0x10($s0)
/* 376744 E00742E4 0442009B */ bltzl $v0, .LE0074554
/* 376748 E00742E8 26310001 */ addiu $s1, $s1, 1
/* 37674C E00742EC 14400055 */ bnez $v0, .LE0074444
/* 376750 E00742F0 00000000 */ nop
/* 376754 E00742F4 0C080138 */ jal func_E02004E0
/* 376758 E00742F8 24040167 */ addiu $a0, $zero, 0x167
/* 37675C E00742FC 4482A000 */ mtc1 $v0, $f20
/* 376760 E0074300 00000000 */ nop
/* 376764 E0074304 4680A520 */ cvt.s.w $f20, $f20
/* 376768 E0074308 0C080138 */ jal func_E02004E0
/* 37676C E007430C 24040167 */ addiu $a0, $zero, 0x167
/* 376770 E0074310 0C080140 */ jal func_E0200500
/* 376774 E0074314 4600A306 */ mov.s $f12, $f20
/* 376778 E0074318 4600F002 */ mul.s $f0, $f30, $f0
/* 37677C E007431C 00000000 */ nop
/* 376780 E0074320 C7BC0010 */ lwc1 $f28, 0x10($sp)
/* 376784 E0074324 4600E70D */ trunc.w.s $f28, $f28
/* 376788 E0074328 4404E000 */ mfc1 $a0, $f28
/* 37678C E007432C 0C080138 */ jal func_E02004E0
/* 376790 E0074330 E600FFE4 */ swc1 $f0, -0x1c($s0)
/* 376794 E0074334 C7BC0010 */ lwc1 $f28, 0x10($sp)
/* 376798 E0074338 4600E0A1 */ cvt.d.s $f2, $f28
/* 37679C E007433C 46381082 */ mul.d $f2, $f2, $f24
/* 3767A0 E0074340 00000000 */ nop
/* 3767A4 E0074344 44820000 */ mtc1 $v0, $f0
/* 3767A8 E0074348 00000000 */ nop
/* 3767AC E007434C 46800021 */ cvt.d.w $f0, $f0
/* 3767B0 E0074350 46220001 */ sub.d $f0, $f0, $f2
/* 3767B4 E0074354 4600A306 */ mov.s $f12, $f20
/* 3767B8 E0074358 46200020 */ cvt.s.d $f0, $f0
/* 3767BC E007435C 0C080144 */ jal func_E0200510
/* 3767C0 E0074360 E600FFE8 */ swc1 $f0, -0x18($s0)
/* 3767C4 E0074364 4600F002 */ mul.s $f0, $f30, $f0
/* 3767C8 E0074368 00000000 */ nop
/* 3767CC E007436C 4600A306 */ mov.s $f12, $f20
/* 3767D0 E0074370 0C080140 */ jal func_E0200500
/* 3767D4 E0074374 E600FFEC */ swc1 $f0, -0x14($s0)
/* 3767D8 E0074378 C602FFE8 */ lwc1 $f2, -0x18($s0)
/* 3767DC E007437C 3C01E007 */ lui $at, 0xe007
/* 3767E0 E0074380 D4244BF8 */ ldc1 $f4, 0x4bf8($at)
/* 3767E4 E0074384 460010A1 */ cvt.d.s $f2, $f2
/* 3767E8 E0074388 46241082 */ mul.d $f2, $f2, $f4
/* 3767EC E007438C 00000000 */ nop
/* 3767F0 E0074390 3C014170 */ lui $at, 0x4170
/* 3767F4 E0074394 4481E000 */ mtc1 $at, $f28
/* 3767F8 E0074398 00000000 */ nop
/* 3767FC E007439C 461C0002 */ mul.s $f0, $f0, $f28
/* 376800 E00743A0 00000000 */ nop
/* 376804 E00743A4 4600A306 */ mov.s $f12, $f20
/* 376808 E00743A8 E600FFF8 */ swc1 $f0, -8($s0)
/* 37680C E00743AC 462010A0 */ cvt.s.d $f2, $f2
/* 376810 E00743B0 0C080144 */ jal func_E0200510
/* 376814 E00743B4 E602FFFC */ swc1 $f2, -4($s0)
/* 376818 E00743B8 C604FFF8 */ lwc1 $f4, -8($s0)
/* 37681C E00743BC 46002121 */ cvt.d.s $f4, $f4
/* 376820 E00743C0 46382102 */ mul.d $f4, $f4, $f24
/* 376824 E00743C4 00000000 */ nop
/* 376828 E00743C8 C602FFFC */ lwc1 $f2, -4($s0)
/* 37682C E00743CC 460010A1 */ cvt.d.s $f2, $f2
/* 376830 E00743D0 46381082 */ mul.d $f2, $f2, $f24
/* 376834 E00743D4 00000000 */ nop
/* 376838 E00743D8 461C0002 */ mul.s $f0, $f0, $f28
/* 37683C E00743DC 00000000 */ nop
/* 376840 E00743E0 E6000000 */ swc1 $f0, ($s0)
/* 376844 E00743E4 46000021 */ cvt.d.s $f0, $f0
/* 376848 E00743E8 46380002 */ mul.d $f0, $f0, $f24
/* 37684C E00743EC 00000000 */ nop
/* 376850 E00743F0 2404000F */ addiu $a0, $zero, 0xf
/* 376854 E00743F4 46202120 */ cvt.s.d $f4, $f4
/* 376858 E00743F8 462010A0 */ cvt.s.d $f2, $f2
/* 37685C E00743FC E6040004 */ swc1 $f4, 4($s0)
/* 376860 E0074400 E6020008 */ swc1 $f2, 8($s0)
/* 376864 E0074404 46200020 */ cvt.s.d $f0, $f0
/* 376868 E0074408 0C080138 */ jal func_E02004E0
/* 37686C E007440C E600000C */ swc1 $f0, 0xc($s0)
/* 376870 E0074410 2404000F */ addiu $a0, $zero, 0xf
/* 376874 E0074414 44820000 */ mtc1 $v0, $f0
/* 376878 E0074418 00000000 */ nop
/* 37687C E007441C 46800020 */ cvt.s.w $f0, $f0
/* 376880 E0074420 0C080138 */ jal func_E02004E0
/* 376884 E0074424 E6000044 */ swc1 $f0, 0x44($s0)
/* 376888 E0074428 44820000 */ mtc1 $v0, $f0
/* 37688C E007442C 00000000 */ nop
/* 376890 E0074430 46800020 */ cvt.s.w $f0, $f0
/* 376894 E0074434 240200FF */ addiu $v0, $zero, 0xff
/* 376898 E0074438 E6000048 */ swc1 $f0, 0x48($s0)
/* 37689C E007443C AE000014 */ sw $zero, 0x14($s0)
/* 3768A0 E0074440 AE02002C */ sw $v0, 0x2c($s0)
.LE0074444:
/* 3768A4 E0074444 C610FFF8 */ lwc1 $f16, -8($s0)
/* 3768A8 E0074448 C60A0004 */ lwc1 $f10, 4($s0)
/* 3768AC E007444C 46105281 */ sub.s $f10, $f10, $f16
/* 3768B0 E0074450 460052A1 */ cvt.d.s $f10, $f10
/* 3768B4 E0074454 463A5282 */ mul.d $f10, $f10, $f26
/* 3768B8 E0074458 00000000 */ nop
/* 3768BC E007445C C60EFFFC */ lwc1 $f14, -4($s0)
/* 3768C0 E0074460 C60C0008 */ lwc1 $f12, 8($s0)
/* 3768C4 E0074464 460E6301 */ sub.s $f12, $f12, $f14
/* 3768C8 E0074468 46006321 */ cvt.d.s $f12, $f12
/* 3768CC E007446C 463A6302 */ mul.d $f12, $f12, $f26
/* 3768D0 E0074470 00000000 */ nop
/* 3768D4 E0074474 C6060000 */ lwc1 $f6, ($s0)
/* 3768D8 E0074478 C608000C */ lwc1 $f8, 0xc($s0)
/* 3768DC E007447C 46064201 */ sub.s $f8, $f8, $f6
/* 3768E0 E0074480 8E020010 */ lw $v0, 0x10($s0)
/* 3768E4 E0074484 46004221 */ cvt.d.s $f8, $f8
/* 3768E8 E0074488 463A4202 */ mul.d $f8, $f8, $f26
/* 3768EC E007448C 00000000 */ nop
/* 3768F0 E0074490 C6000014 */ lwc1 $f0, 0x14($s0)
/* 3768F4 E0074494 3C014080 */ lui $at, 0x4080
/* 3768F8 E0074498 44811000 */ mtc1 $at, $f2
/* 3768FC E007449C C614FFE4 */ lwc1 $f20, -0x1c($s0)
/* 376900 E00744A0 C612FFE8 */ lwc1 $f18, -0x18($s0)
/* 376904 E00744A4 C604FFEC */ lwc1 $f4, -0x14($s0)
/* 376908 E00744A8 00021080 */ sll $v0, $v0, 2
/* 37690C E00744AC 00531021 */ addu $v0, $v0, $s3
/* 376910 E00744B0 46020000 */ add.s $f0, $f0, $f2
/* 376914 E00744B4 C4560000 */ lwc1 $f22, ($v0)
/* 376918 E00744B8 C6020044 */ lwc1 $f2, 0x44($s0)
/* 37691C E00744BC 4616B580 */ add.s $f22, $f22, $f22
/* 376920 E00744C0 E6000014 */ swc1 $f0, 0x14($s0)
/* 376924 E00744C4 46008006 */ mov.s $f0, $f16
/* 376928 E00744C8 4600A500 */ add.s $f20, $f20, $f0
/* 37692C E00744CC 460010A1 */ cvt.d.s $f2, $f2
/* 376930 E00744D0 46007006 */ mov.s $f0, $f14
/* 376934 E00744D4 46009480 */ add.s $f18, $f18, $f0
/* 376938 E00744D8 46003006 */ mov.s $f0, $f6
/* 37693C E00744DC 46008421 */ cvt.d.s $f16, $f16
/* 376940 E00744E0 46002100 */ add.s $f4, $f4, $f0
/* 376944 E00744E4 460073A1 */ cvt.d.s $f14, $f14
/* 376948 E00744E8 460031A1 */ cvt.d.s $f6, $f6
/* 37694C E00744EC E604FFEC */ swc1 $f4, -0x14($s0)
/* 376950 E00744F0 3C01E007 */ lui $at, 0xe007
/* 376954 E00744F4 D4244C00 */ ldc1 $f4, 0x4c00($at)
/* 376958 E00744F8 C6000048 */ lwc1 $f0, 0x48($s0)
/* 37695C E00744FC 46241080 */ add.d $f2, $f2, $f4
/* 376960 E0074500 3C01E007 */ lui $at, 0xe007
/* 376964 E0074504 D4244C08 */ ldc1 $f4, 0x4c08($at)
/* 376968 E0074508 46000021 */ cvt.d.s $f0, $f0
/* 37696C E007450C E6160040 */ swc1 $f22, 0x40($s0)
/* 376970 E0074510 46240000 */ add.d $f0, $f0, $f4
/* 376974 E0074514 E614FFE4 */ swc1 $f20, -0x1c($s0)
/* 376978 E0074518 E612FFE8 */ swc1 $f18, -0x18($s0)
/* 37697C E007451C 462A8400 */ add.d $f16, $f16, $f10
/* 376980 E0074520 462010A0 */ cvt.s.d $f2, $f2
/* 376984 E0074524 E6020044 */ swc1 $f2, 0x44($s0)
/* 376988 E0074528 462C7380 */ add.d $f14, $f14, $f12
/* 37698C E007452C 46200020 */ cvt.s.d $f0, $f0
/* 376990 E0074530 E6000048 */ swc1 $f0, 0x48($s0)
/* 376994 E0074534 46283180 */ add.d $f6, $f6, $f8
/* 376998 E0074538 46208420 */ cvt.s.d $f16, $f16
/* 37699C E007453C 462073A0 */ cvt.s.d $f14, $f14
/* 3769A0 E0074540 462031A0 */ cvt.s.d $f6, $f6
/* 3769A4 E0074544 E610FFF8 */ swc1 $f16, -8($s0)
/* 3769A8 E0074548 E60EFFFC */ swc1 $f14, -4($s0)
/* 3769AC E007454C E6060000 */ swc1 $f6, ($s0)
/* 3769B0 E0074550 26310001 */ addiu $s1, $s1, 1
.LE0074554:
/* 3769B4 E0074554 8E420008 */ lw $v0, 8($s2)
/* 3769B8 E0074558 0222102A */ slt $v0, $s1, $v0
/* 3769BC E007455C 1440FF5A */ bnez $v0, .LE00742C8
/* 3769C0 E0074560 2610006C */ addiu $s0, $s0, 0x6c
.LE0074564:
/* 3769C4 E0074564 8FBF0028 */ lw $ra, 0x28($sp)
/* 3769C8 E0074568 8FB30024 */ lw $s3, 0x24($sp)
/* 3769CC E007456C 8FB20020 */ lw $s2, 0x20($sp)
/* 3769D0 E0074570 8FB1001C */ lw $s1, 0x1c($sp)
/* 3769D4 E0074574 8FB00018 */ lw $s0, 0x18($sp)
/* 3769D8 E0074578 D7BE0058 */ ldc1 $f30, 0x58($sp)
/* 3769DC E007457C D7BC0050 */ ldc1 $f28, 0x50($sp)
/* 3769E0 E0074580 D7BA0048 */ ldc1 $f26, 0x48($sp)
/* 3769E4 E0074584 D7B80040 */ ldc1 $f24, 0x40($sp)
/* 3769E8 E0074588 D7B60038 */ ldc1 $f22, 0x38($sp)
/* 3769EC E007458C D7B40030 */ ldc1 $f20, 0x30($sp)
/* 3769F0 E0074590 03E00008 */ jr $ra
/* 3769F4 E0074594 27BD0060 */ addiu $sp, $sp, 0x60