25 pokos!

decompiled MWCriticalSection_gc.cpp
This commit is contained in:
EpochFlame 2021-10-19 14:35:43 -04:00
parent a92a70cde6
commit 743a75d0a1
3 changed files with 10 additions and 71 deletions

View File

@ -1,33 +0,0 @@
.include "macros.inc"
.section .text, "ax" # 0x800056C0 - 0x80472F00
.global MWExitCriticalSection
MWExitCriticalSection:
/* 800C1598 000BE4D8 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800C159C 000BE4DC 7C 08 02 A6 */ mflr r0
/* 800C15A0 000BE4E0 90 01 00 14 */ stw r0, 0x14(r1)
/* 800C15A4 000BE4E4 80 63 00 00 */ lwz r3, 0(r3)
/* 800C15A8 000BE4E8 48 02 D6 B9 */ bl OSRestoreInterrupts
/* 800C15AC 000BE4EC 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800C15B0 000BE4F0 7C 08 03 A6 */ mtlr r0
/* 800C15B4 000BE4F4 38 21 00 10 */ addi r1, r1, 0x10
/* 800C15B8 000BE4F8 4E 80 00 20 */ blr
.global MWEnterCriticalSection
MWEnterCriticalSection:
/* 800C15BC 000BE4FC 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800C15C0 000BE500 7C 08 02 A6 */ mflr r0
/* 800C15C4 000BE504 90 01 00 14 */ stw r0, 0x14(r1)
/* 800C15C8 000BE508 93 E1 00 0C */ stw r31, 0xc(r1)
/* 800C15CC 000BE50C 7C 7F 1B 78 */ mr r31, r3
/* 800C15D0 000BE510 48 02 D6 69 */ bl OSDisableInterrupts
/* 800C15D4 000BE514 90 7F 00 00 */ stw r3, 0(r31)
/* 800C15D8 000BE518 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800C15DC 000BE51C 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 800C15E0 000BE520 7C 08 03 A6 */ mtlr r0
/* 800C15E4 000BE524 38 21 00 10 */ addi r1, r1, 0x10
/* 800C15E8 000BE528 4E 80 00 20 */ blr
.global MWInitializeCriticalSection
MWInitializeCriticalSection:
/* 800C15EC 000BE52C 4E 80 00 20 */ blr

View File

@ -264,7 +264,7 @@ TEXT_O_FILES:=\
$(BUILD_DIR)/asm/Dolphin/CircleBuffer.o\
$(BUILD_DIR)/asm/Dolphin/main.o\
$(BUILD_DIR)/asm/Dolphin/MWTrace.o\
$(BUILD_DIR)/asm/Dolphin/MWCriticalSection_gc.o\
$(BUILD_DIR)/src/Dolphin/MWCriticalSection_gc.o\
$(BUILD_DIR)/asm/Dolphin/__va_arg.o\
$(BUILD_DIR)/asm/Dolphin/global_destructor_chain.o\
$(BUILD_DIR)/asm/Dolphin/CPlusLibPPC.o\

View File

@ -1,4 +1,6 @@
extern "C" {
bool OSRestoreInterrupts(unsigned int);
unsigned int OSDisableInterrupts();
/*
* --INFO--
@ -15,20 +17,9 @@ void MWTerminateCriticalSection(void)
* Address: 800C1598
* Size: 000024
*/
void MWExitCriticalSection(void)
void MWExitCriticalSection(unsigned int* section)
{
/*
.loc_0x0:
stwu r1, -0x10(r1)
mflr r0
stw r0, 0x14(r1)
lwz r3, 0x0(r3)
bl 0x2D6B8
lwz r0, 0x14(r1)
mtlr r0
addi r1, r1, 0x10
blr
*/
OSRestoreInterrupts(*section);
}
/*
@ -36,23 +27,9 @@ void MWExitCriticalSection(void)
* Address: 800C15BC
* Size: 000030
*/
void MWEnterCriticalSection(void)
void MWEnterCriticalSection(unsigned int* section)
{
/*
.loc_0x0:
stwu r1, -0x10(r1)
mflr r0
stw r0, 0x14(r1)
stw r31, 0xC(r1)
mr r31, r3
bl 0x2D668
stw r3, 0x0(r31)
lwz r0, 0x14(r1)
lwz r31, 0xC(r1)
mtlr r0
addi r1, r1, 0x10
blr
*/
*section = OSDisableInterrupts();
}
/*
@ -60,10 +37,5 @@ void MWEnterCriticalSection(void)
* Address: 800C15EC
* Size: 000004
*/
void MWInitializeCriticalSection(void)
{
/*
.loc_0x0:
blr
*/
}
void MWInitializeCriticalSection(void) { }
};