papermario/asm/nonmatchings/code_1370_len_7d0/gfxRetrace_Callback.s

77 lines
3.4 KiB
ArmAsm
Raw Normal View History

2020-08-04 08:49:11 +02:00
.set noat # allow manual use of $at
.set noreorder # don't insert nops after branches
glabel gfxRetrace_Callback
/* 00145C 8002605C 27BDFFE0 */ addiu $sp, $sp, -0x20
/* 001460 80026060 AFB10014 */ sw $s1, 0x14($sp)
/* 001464 80026064 3C118007 */ lui $s1, 0x8007
/* 001468 80026068 26313E00 */ addiu $s1, $s1, 0x3e00
/* 00146C 8002606C AFBF0018 */ sw $ra, 0x18($sp)
/* 001470 80026070 AFB00010 */ sw $s0, 0x10($sp)
/* 001474 80026074 8E230000 */ lw $v1, ($s1)
/* 001478 80026078 10600022 */ beqz $v1, .L80026104
/* 00147C 8002607C 0080802D */ daddu $s0, $a0, $zero
/* 001480 80026080 24020001 */ addiu $v0, $zero, 1
/* 001484 80026084 14620016 */ bne $v1, $v0, .L800260E0
/* 001488 80026088 00000000 */ nop
/* 00148C 8002608C 0C017CB4 */ jal nuGfxTaskAllEndWait
/* 001490 80026090 00000000 */ nop
/* 001494 80026094 16000012 */ bnez $s0, .L800260E0
/* 001498 80026098 00000000 */ nop
/* 00149C 8002609C 0C019A6C */ jal osViGetCurrentFramebuffer
/* 0014A0 800260A0 00000000 */ nop
/* 0014A4 800260A4 3C10800A */ lui $s0, 0x800a
/* 0014A8 800260A8 2610A680 */ addiu $s0, $s0, -0x5980
/* 0014AC 800260AC 0200202D */ daddu $a0, $s0, $zero
/* 0014B0 800260B0 AE020008 */ sw $v0, 8($s0)
/* 0014B4 800260B4 AE020004 */ sw $v0, 4($s0)
/* 0014B8 800260B8 AE020000 */ sw $v0, ($s0)
/* 0014BC 800260BC 3C018007 */ lui $at, 0x8007
/* 0014C0 800260C0 AC223E04 */ sw $v0, 0x3e04($at)
/* 0014C4 800260C4 0C017CBC */ jal nuGfxSetCfb
/* 0014C8 800260C8 24050003 */ addiu $a1, $zero, 3
/* 0014CC 800260CC 8E040000 */ lw $a0, ($s0)
/* 0014D0 800260D0 0C019C08 */ jal osViSwapBuffer
/* 0014D4 800260D4 00000000 */ nop
/* 0014D8 800260D8 24020002 */ addiu $v0, $zero, 2
/* 0014DC 800260DC AE220000 */ sw $v0, ($s1)
.L800260E0:
/* 0014E0 800260E0 3C038007 */ lui $v1, 0x8007
/* 0014E4 800260E4 8C633E00 */ lw $v1, 0x3e00($v1)
/* 0014E8 800260E8 24020002 */ addiu $v0, $zero, 2
/* 0014EC 800260EC 14620018 */ bne $v1, $v0, .L80026150
/* 0014F0 800260F0 00000000 */ nop
/* 0014F4 800260F4 0C009859 */ jal func_80026164
/* 0014F8 800260F8 00000000 */ nop
/* 0014FC 800260FC 08009854 */ j .L80026150
/* 001500 80026100 00000000 */ nop
.L80026104:
/* 001504 80026104 3C038007 */ lui $v1, 0x8007
/* 001508 80026108 24633E0A */ addiu $v1, $v1, 0x3e0a
/* 00150C 8002610C 94620000 */ lhu $v0, ($v1)
/* 001510 80026110 38420001 */ xori $v0, $v0, 1
/* 001514 80026114 1440000E */ bnez $v0, .L80026150
/* 001518 80026118 A4620000 */ sh $v0, ($v1)
/* 00151C 8002611C 0C0099D0 */ jal step_game_loop
/* 001520 80026120 00000000 */ nop
/* 001524 80026124 3C038007 */ lui $v1, 0x8007
/* 001528 80026128 24633E08 */ addiu $v1, $v1, 0x3e08
/* 00152C 8002612C 24020001 */ addiu $v0, $zero, 1
/* 001530 80026130 A4620000 */ sh $v0, ($v1)
/* 001534 80026134 2A020003 */ slti $v0, $s0, 3
/* 001538 80026138 10400005 */ beqz $v0, .L80026150
/* 00153C 8002613C 00000000 */ nop
/* 001540 80026140 0C009A7B */ jal func_800269EC
/* 001544 80026144 A4600000 */ sh $zero, ($v1)
/* 001548 80026148 0C009AC2 */ jal gfx_draw_frame
/* 00154C 8002614C 00000000 */ nop
.L80026150:
/* 001550 80026150 8FBF0018 */ lw $ra, 0x18($sp)
/* 001554 80026154 8FB10014 */ lw $s1, 0x14($sp)
/* 001558 80026158 8FB00010 */ lw $s0, 0x10($sp)
/* 00155C 8002615C 03E00008 */ jr $ra
/* 001560 80026160 27BD0020 */ addiu $sp, $sp, 0x20