donut-decomp/asm/libnw4r_snd/snd_TaskThread.s

172 lines
8.3 KiB
ArmAsm
Raw Permalink Normal View History

2022-10-16 16:05:58 +00:00
.include "macros.inc"
.section .text, "ax" # 0x80006A00 - 0x80406260 ; 0x003FF860
2022-10-16 16:31:36 +00:00
.global __ct__Q44nw4r3snd6detail10TaskThreadFv
__ct__Q44nw4r3snd6detail10TaskThreadFv:
2022-10-16 16:05:58 +00:00
/* 801199B0 001157F0 38 00 00 00 */ li r0, 0x0
/* 801199B4 001157F4 90 03 03 18 */ stw r0, 0x318(r3)
/* 801199B8 001157F8 98 03 03 1C */ stb r0, 0x31c(r3)
/* 801199BC 001157FC 98 03 03 1D */ stb r0, 0x31d(r3)
/* 801199C0 00115800 4E 80 00 20 */ blr
/* 801199C4 00115804 00 00 00 00 */ .4byte 0x00000000
/* 801199C8 00115808 00 00 00 00 */ .4byte 0x00000000
/* 801199CC 0011580C 00 00 00 00 */ .4byte 0x00000000
2022-10-16 16:31:36 +00:00
.global __dt__Q44nw4r3snd6detail10TaskThreadFv
__dt__Q44nw4r3snd6detail10TaskThreadFv:
2022-10-16 16:05:58 +00:00
/* 801199D0 00115810 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 801199D4 00115814 7C 08 02 A6 */ mflr r0
/* 801199D8 00115818 2C 03 00 00 */ cmpwi r3, 0x0
/* 801199DC 0011581C 90 01 00 14 */ stw r0, 0x14(r1)
/* 801199E0 00115820 93 E1 00 0C */ stw r31, 0xc(r1)
/* 801199E4 00115824 7C 9F 23 78 */ mr r31, r4
/* 801199E8 00115828 93 C1 00 08 */ stw r30, 0x8(r1)
/* 801199EC 0011582C 7C 7E 1B 78 */ mr r30, r3
/* 801199F0 00115830 41 82 00 44 */ beq lbl_80119A34
/* 801199F4 00115834 88 03 03 1D */ lbz r0, 0x31d(r3)
/* 801199F8 00115838 2C 00 00 00 */ cmpwi r0, 0x0
/* 801199FC 0011583C 41 82 00 28 */ beq lbl_80119A24
/* 80119A00 00115840 38 00 00 01 */ li r0, 0x1
/* 80119A04 00115844 98 03 03 1C */ stb r0, 0x31c(r3)
2022-10-16 16:31:36 +00:00
/* 80119A08 00115848 4B FF F8 59 */ bl GetInstance__Q44nw4r3snd6detail11TaskManagerFv
/* 80119A0C 0011584C 4B FF FF 55 */ bl CancelWaitTask__Q44nw4r3snd6detail11TaskManagerFv
2022-10-16 16:05:58 +00:00
/* 80119A10 00115850 7F C3 F3 78 */ mr r3, r30
/* 80119A14 00115854 38 80 00 00 */ li r4, 0x0
2022-10-16 16:31:36 +00:00
/* 80119A18 00115858 4B F0 B8 79 */ bl OSJoinThread
2022-10-16 16:05:58 +00:00
/* 80119A1C 0011585C 38 00 00 00 */ li r0, 0x0
/* 80119A20 00115860 98 1E 03 1D */ stb r0, 0x31d(r30)
.global lbl_80119A24
lbl_80119A24:
/* 80119A24 00115864 2C 1F 00 00 */ cmpwi r31, 0x0
/* 80119A28 00115868 40 81 00 0C */ ble lbl_80119A34
/* 80119A2C 0011586C 7F C3 F3 78 */ mr r3, r30
2022-10-16 16:31:36 +00:00
/* 80119A30 00115870 48 0A 5C E5 */ bl __dl__FPv
2022-10-16 16:05:58 +00:00
.global lbl_80119A34
lbl_80119A34:
/* 80119A34 00115874 7F C3 F3 78 */ mr r3, r30
/* 80119A38 00115878 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 80119A3C 0011587C 83 C1 00 08 */ lwz r30, 0x8(r1)
/* 80119A40 00115880 80 01 00 14 */ lwz r0, 0x14(r1)
/* 80119A44 00115884 7C 08 03 A6 */ mtlr r0
/* 80119A48 00115888 38 21 00 10 */ addi r1, r1, 0x10
/* 80119A4C 0011588C 4E 80 00 20 */ blr
2022-10-16 16:31:36 +00:00
.global Create__Q44nw4r3snd6detail10TaskThreadFlPvUl
Create__Q44nw4r3snd6detail10TaskThreadFlPvUl:
2022-10-16 16:05:58 +00:00
/* 80119A50 00115890 94 21 FF E0 */ stwu r1, -0x20(r1)
/* 80119A54 00115894 7C 08 02 A6 */ mflr r0
/* 80119A58 00115898 90 01 00 24 */ stw r0, 0x24(r1)
/* 80119A5C 0011589C 93 E1 00 1C */ stw r31, 0x1c(r1)
/* 80119A60 001158A0 7C DF 33 78 */ mr r31, r6
/* 80119A64 001158A4 93 C1 00 18 */ stw r30, 0x18(r1)
/* 80119A68 001158A8 7C BE 2B 78 */ mr r30, r5
/* 80119A6C 001158AC 93 A1 00 14 */ stw r29, 0x14(r1)
/* 80119A70 001158B0 7C 9D 23 78 */ mr r29, r4
/* 80119A74 001158B4 93 81 00 10 */ stw r28, 0x10(r1)
/* 80119A78 001158B8 7C 7C 1B 78 */ mr r28, r3
/* 80119A7C 001158BC 88 03 03 1D */ lbz r0, 0x31d(r3)
/* 80119A80 001158C0 2C 00 00 00 */ cmpwi r0, 0x0
/* 80119A84 001158C4 41 82 00 28 */ beq lbl_80119AAC
/* 80119A88 001158C8 38 00 00 01 */ li r0, 0x1
/* 80119A8C 001158CC 98 03 03 1C */ stb r0, 0x31c(r3)
2022-10-16 16:31:36 +00:00
/* 80119A90 001158D0 4B FF F7 D1 */ bl GetInstance__Q44nw4r3snd6detail11TaskManagerFv
/* 80119A94 001158D4 4B FF FE CD */ bl CancelWaitTask__Q44nw4r3snd6detail11TaskManagerFv
2022-10-16 16:05:58 +00:00
/* 80119A98 001158D8 7F 83 E3 78 */ mr r3, r28
/* 80119A9C 001158DC 38 80 00 00 */ li r4, 0x0
2022-10-16 16:31:36 +00:00
/* 80119AA0 001158E0 4B F0 B7 F1 */ bl OSJoinThread
2022-10-16 16:05:58 +00:00
/* 80119AA4 001158E4 38 00 00 00 */ li r0, 0x0
/* 80119AA8 001158E8 98 1C 03 1D */ stb r0, 0x31d(r28)
.global lbl_80119AAC
lbl_80119AAC:
2022-10-16 16:31:36 +00:00
/* 80119AAC 001158EC 3C 80 80 12 */ lis r4, ThreadFunc__Q44nw4r3snd6detail10TaskThreadFPv@ha
2022-10-16 16:05:58 +00:00
/* 80119AB0 001158F0 7F 83 E3 78 */ mr r3, r28
/* 80119AB4 001158F4 7F 85 E3 78 */ mr r5, r28
/* 80119AB8 001158F8 7F E7 FB 78 */ mr r7, r31
/* 80119ABC 001158FC 7F A8 EB 78 */ mr r8, r29
2022-10-16 16:31:36 +00:00
/* 80119AC0 00115900 38 84 9B 80 */ addi r4, r4, ThreadFunc__Q44nw4r3snd6detail10TaskThreadFPv@l
2022-10-16 16:05:58 +00:00
/* 80119AC4 00115904 7C DE FA 14 */ add r6, r30, r31
/* 80119AC8 00115908 39 20 00 00 */ li r9, 0x0
2022-10-16 16:31:36 +00:00
/* 80119ACC 0011590C 4B F0 B2 85 */ bl OSCreateThread
2022-10-16 16:05:58 +00:00
/* 80119AD0 00115910 2C 03 00 00 */ cmpwi r3, 0x0
/* 80119AD4 00115914 40 82 00 0C */ bne lbl_80119AE0
/* 80119AD8 00115918 38 60 00 00 */ li r3, 0x0
/* 80119ADC 0011591C 48 00 00 24 */ b lbl_80119B00
.global lbl_80119AE0
lbl_80119AE0:
/* 80119AE0 00115920 38 80 00 00 */ li r4, 0x0
/* 80119AE4 00115924 38 00 00 01 */ li r0, 0x1
/* 80119AE8 00115928 93 DC 03 18 */ stw r30, 0x318(r28)
/* 80119AEC 0011592C 7F 83 E3 78 */ mr r3, r28
/* 80119AF0 00115930 98 9C 03 1C */ stb r4, 0x31c(r28)
/* 80119AF4 00115934 98 1C 03 1D */ stb r0, 0x31d(r28)
2022-10-16 16:31:36 +00:00
/* 80119AF8 00115938 4B F0 B8 E9 */ bl OSResumeThread
2022-10-16 16:05:58 +00:00
/* 80119AFC 0011593C 38 60 00 01 */ li r3, 0x1
.global lbl_80119B00
lbl_80119B00:
/* 80119B00 00115940 80 01 00 24 */ lwz r0, 0x24(r1)
/* 80119B04 00115944 83 E1 00 1C */ lwz r31, 0x1c(r1)
/* 80119B08 00115948 83 C1 00 18 */ lwz r30, 0x18(r1)
/* 80119B0C 0011594C 83 A1 00 14 */ lwz r29, 0x14(r1)
/* 80119B10 00115950 83 81 00 10 */ lwz r28, 0x10(r1)
/* 80119B14 00115954 7C 08 03 A6 */ mtlr r0
/* 80119B18 00115958 38 21 00 20 */ addi r1, r1, 0x20
/* 80119B1C 0011595C 4E 80 00 20 */ blr
2022-10-16 16:31:36 +00:00
.global Destroy__Q44nw4r3snd6detail10TaskThreadFv
Destroy__Q44nw4r3snd6detail10TaskThreadFv:
2022-10-16 16:05:58 +00:00
/* 80119B20 00115960 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 80119B24 00115964 7C 08 02 A6 */ mflr r0
/* 80119B28 00115968 90 01 00 14 */ stw r0, 0x14(r1)
/* 80119B2C 0011596C 93 E1 00 0C */ stw r31, 0xc(r1)
/* 80119B30 00115970 7C 7F 1B 78 */ mr r31, r3
/* 80119B34 00115974 88 03 03 1D */ lbz r0, 0x31d(r3)
/* 80119B38 00115978 2C 00 00 00 */ cmpwi r0, 0x0
/* 80119B3C 0011597C 41 82 00 28 */ beq lbl_80119B64
/* 80119B40 00115980 38 00 00 01 */ li r0, 0x1
/* 80119B44 00115984 98 03 03 1C */ stb r0, 0x31c(r3)
2022-10-16 16:31:36 +00:00
/* 80119B48 00115988 4B FF F7 19 */ bl GetInstance__Q44nw4r3snd6detail11TaskManagerFv
/* 80119B4C 0011598C 4B FF FE 15 */ bl CancelWaitTask__Q44nw4r3snd6detail11TaskManagerFv
2022-10-16 16:05:58 +00:00
/* 80119B50 00115990 7F E3 FB 78 */ mr r3, r31
/* 80119B54 00115994 38 80 00 00 */ li r4, 0x0
2022-10-16 16:31:36 +00:00
/* 80119B58 00115998 4B F0 B7 39 */ bl OSJoinThread
2022-10-16 16:05:58 +00:00
/* 80119B5C 0011599C 38 00 00 00 */ li r0, 0x0
/* 80119B60 001159A0 98 1F 03 1D */ stb r0, 0x31d(r31)
.global lbl_80119B64
lbl_80119B64:
/* 80119B64 001159A4 80 01 00 14 */ lwz r0, 0x14(r1)
/* 80119B68 001159A8 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 80119B6C 001159AC 7C 08 03 A6 */ mtlr r0
/* 80119B70 001159B0 38 21 00 10 */ addi r1, r1, 0x10
/* 80119B74 001159B4 4E 80 00 20 */ blr
/* 80119B78 001159B8 00 00 00 00 */ .4byte 0x00000000
/* 80119B7C 001159BC 00 00 00 00 */ .4byte 0x00000000
2022-10-16 16:31:36 +00:00
.global ThreadFunc__Q44nw4r3snd6detail10TaskThreadFPv
ThreadFunc__Q44nw4r3snd6detail10TaskThreadFPv:
2022-10-16 16:05:58 +00:00
/* 80119B80 001159C0 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 80119B84 001159C4 7C 08 02 A6 */ mflr r0
/* 80119B88 001159C8 90 01 00 14 */ stw r0, 0x14(r1)
/* 80119B8C 001159CC 93 E1 00 0C */ stw r31, 0xc(r1)
/* 80119B90 001159D0 7C 7F 1B 78 */ mr r31, r3
/* 80119B94 001159D4 48 00 00 20 */ b lbl_80119BB4
.global lbl_80119B98
lbl_80119B98:
2022-10-16 16:31:36 +00:00
/* 80119B98 001159D8 4B FF F6 C9 */ bl GetInstance__Q44nw4r3snd6detail11TaskManagerFv
/* 80119B9C 001159DC 4B FF FD 55 */ bl WaitTask__Q44nw4r3snd6detail11TaskManagerFv
2022-10-16 16:05:58 +00:00
/* 80119BA0 001159E0 88 1F 03 1C */ lbz r0, 0x31c(r31)
/* 80119BA4 001159E4 2C 00 00 00 */ cmpwi r0, 0x0
/* 80119BA8 001159E8 40 82 00 18 */ bne lbl_80119BC0
2022-10-16 16:31:36 +00:00
/* 80119BAC 001159EC 4B FF F6 B5 */ bl GetInstance__Q44nw4r3snd6detail11TaskManagerFv
/* 80119BB0 001159F0 4B FF FA D1 */ bl ExecuteTask__Q44nw4r3snd6detail11TaskManagerFv
2022-10-16 16:05:58 +00:00
.global lbl_80119BB4
lbl_80119BB4:
/* 80119BB4 001159F4 88 1F 03 1C */ lbz r0, 0x31c(r31)
/* 80119BB8 001159F8 2C 00 00 00 */ cmpwi r0, 0x0
/* 80119BBC 001159FC 41 82 FF DC */ beq lbl_80119B98
.global lbl_80119BC0
lbl_80119BC0:
/* 80119BC0 00115A00 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 80119BC4 00115A04 38 60 00 00 */ li r3, 0x0
/* 80119BC8 00115A08 80 01 00 14 */ lwz r0, 0x14(r1)
/* 80119BCC 00115A0C 7C 08 03 A6 */ mtlr r0
/* 80119BD0 00115A10 38 21 00 10 */ addi r1, r1, 0x10
/* 80119BD4 00115A14 4E 80 00 20 */ blr
/* 80119BD8 00115A18 00 00 00 00 */ .4byte 0x00000000
/* 80119BDC 00115A1C 00 00 00 00 */ .4byte 0x00000000