summaryrefslogtreecommitdiff
path: root/asm
diff options
context:
space:
mode:
authorIru Cai <mytbk920423@gmail.com>2021-05-12 22:31:21 +0800
committerIru Cai <mytbk920423@gmail.com>2021-05-12 22:31:21 +0800
commitac6a16620ace0a5b70e697eb6fce42806eb33a84 (patch)
tree8044051401e4e886811dbd7f2de8b5df3e3d6f23 /asm
parent27497ad5adca4630a273087cf48246e213302fdf (diff)
downloadrich4-ac6a16620ace0a5b70e697eb6fce42806eb33a84.tar.xz
move __InitThreadData
Diffstat (limited to 'asm')
-rw-r--r--asm/rich4.asm19
-rw-r--r--asm/rich4_crt_mthread.asm21
2 files changed, 21 insertions, 19 deletions
diff --git a/asm/rich4.asm b/asm/rich4.asm
index 9ae7c0f..b5f220a 100644
--- a/asm/rich4.asm
+++ b/asm/rich4.asm
@@ -182,7 +182,6 @@ extern __NTThreadFini
global clib_free
global fcn_0045c836
global fcn_0045e8ca
-global __InitThreadData
global lib_calloc
global ref_00488f78
global ref_00488f7c
@@ -196,6 +195,7 @@ global fcn_0045c585
global ref_0046c97c
global ref_0046c9a1
global ref_0046c9c9
+global __init_stack_limits
section .text
db 0xcc
@@ -125403,23 +125403,6 @@ add esp, 4
mov ebx, esi
jmp short loc_0045c8b1 ; jmp 0x45c8b1
-__InitThreadData:
-push ebx
-mov ebx, dword [esp + 8]
-test ebx, ebx
-je short loc_0045c8ff ; je 0x45c8ff
-push 0
-push ebx
-mov dword [ebx + 0xc], 1
-call __init_stack_limits ; call 0x45a666
-add esp, 8
-call dword [cs:__imp__GetCurrentThreadId@0] ; ucall: call dword cs:[0x46238c]
-mov dword [ebx + 0xda], eax
-
-loc_0045c8ff:
-pop ebx
-ret
-
fcn_0045c901:
jmp near loc_0045c8a9 ; jmp 0x45c8a9
diff --git a/asm/rich4_crt_mthread.asm b/asm/rich4_crt_mthread.asm
index 9974ca6..d432860 100644
--- a/asm/rich4_crt_mthread.asm
+++ b/asm/rich4_crt_mthread.asm
@@ -14,7 +14,6 @@ extern __imp__GetCurrentThreadId@0
extern clib_free
extern fcn_0045c836
extern fcn_0045e8ca
-extern __InitThreadData
extern lib_calloc
extern ref_00488f78
extern ref_00488f7c
@@ -28,6 +27,7 @@ extern fcn_0045c585
extern ref_0046c97c
extern ref_0046c9a1
extern ref_0046c9c9
+extern __init_stack_limits
section .text
@@ -365,3 +365,22 @@ pop edi
pop esi
pop ebx
ret
+
+ ;; mthrdini.c
+
+__InitThreadData:
+push ebx
+mov ebx, dword [esp + 8]
+test ebx, ebx
+je short loc_0045c8ff ; je 0x45c8ff
+push 0
+push ebx
+mov dword [ebx + 0xc], 1
+call __init_stack_limits ; call 0x45a666
+add esp, 8
+call dword [cs:__imp__GetCurrentThreadId@0] ; ucall: call dword cs:[0x46238c]
+mov dword [ebx + 0xda], eax
+
+loc_0045c8ff:
+pop ebx
+ret