Function at 0x18005b460
Capabilities:
Create thread

Disassembly:
mov qword [rsp + 8], rcx
push rbx
push rsi
push rdi
push r14
sub rsp, 0x98
mov rbx, rcx
xor edi, edi
mov dword [rsp + 0x30], edi
xor esi, esi
mov qword [rsp + 0x38], rsi
test rcx, rcx
jne 0x18005b490
mov eax, 0xc00000ef
jmp 0x18005b7be
mov r14, qword [rcx + 0xb0]
mov qword [rsp + 0xd8], r14
xor eax, eax
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x48], rax
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x58], rax
mov qword [rsp + 0x60], rax
mov qword [rsp + 0x68], rax
mov qword [rsp + 0x70], rax
mov qword [rsp + 0x78], rax
mov qword [rsp + 0x80], rax
mov eax, dword [rcx + 0x1f4]
cmp dword [rcx + 0x204], eax
jb 0x18005b4ee
mov dword [r14 + 0x20], 0xe8000106
xor eax, eax
jmp 0x18005b7be
call fcn.18004e7e0
mov dword [rsp + 0xc8], eax
test eax, eax
js 0x18005b7be
mov r9d, dword [rbx + 0x1f4]
cmp dword [rbx + 0x204], r9d
jb 0x18005b51f
mov dword [r14 + 0x20], 0xe8000106
jmp 0x18005b74f
xor edx, edx
mov dword [rsp + 0x34], edx
cmp edx, r9d
jae 0x18005b553
mov eax, edx
imul r8, rax, 0x38
movzx eax, byte [r8 + r14 + 0x68]
test al, 1
jne 0x18005b54f
or al, 1
mov byte [r8 + r14 + 0x68], al
lea rsi, [r14 + 0x38]
add rsi, r8
mov qword [rsp + 0x38], rsi
jmp 0x18005b553
inc edx
jmp 0x18005b521
test rsi, rsi
jne 0x18005b565
mov dword [r14 + 0x20], 0xe8000106
jmp 0x18005b74f
mov qword [rsp + 0x40], rbx
mov edi, 1
mov eax, edi
lock xadd dword [rbx + 0x1f8], eax
inc eax
mov dword [rsp + 0x48], eax
mov rsi, qword [rsp + 0x38]
mov eax, esi
sub eax, dword [rbx + 0xb0]
mov dword [rsp + 0x68], eax
lea rcx, [rsp + 0x40]
call fcn.180059190
mov dword [rsp + 0xc8], eax
test eax, eax
jns 0x18005b5b2
mov dword [r14 + 0x20], eax
mov edi, dword [rsp + 0x30]
jmp 0x18005b74f
mov eax, dword [rbx + 0x204]
lea rcx, [rax + rax*8]
movaps xmm0, xmmword [rsp + 0x40]
movups xmmword [rbx + rcx*8 + 0x280], xmm0
movaps xmm1, xmmword [rsp + 0x50]
movups xmmword [rbx + rcx*8 + 0x290], xmm1
movaps xmm0, xmmword [rsp + 0x60]
movups xmmword [rbx + rcx*8 + 0x2a0], xmm0
movaps xmm1, xmmword [rsp + 0x70]
movups xmmword [rbx + rcx*8 + 0x2b0], xmm1
movsd xmm0, qword [rsp + 0x80]
movsd qword [rbx + rcx*8 + 0x2c0], xmm0
inc dword [rbx + 0x204]
lock xadd dword [rbx + 0x200], edi
inc edi
cmp edi, 1
jne 0x18005b64c
xor edx, edx
mov rcx, qword [rbx + 0x158]
call qword [0x18009b3d0]
mov dword [rsp + 0xc8], eax
test eax, eax
jns 0x18005b64c
lock dec dword [rbx + 0x200]
mov eax, dword [rsp + 0xc8]
mov dword [r14 + 0x20], eax
mov edi, dword [rsp + 0x30]
jmp 0x18005b74a
mov eax, dword [rbx + 0x204]
dec eax
lea rcx, [rax + rax*8]
lea rdi, [rbx + 0x2c0]
lea rdi, [rdi + rcx*8]
lea rsi, [rbx + 0x2b8]
lea rsi, [rsi + rcx*8]
test rsi, rsi
jne 0x18005b680
mov dword [rsp + 0xc8], 0xc00000f1
jmp 0x18005b6c9
lea rax, [rsp + 0xd0]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 0
mov r9, rbx
lea r8, [0x18005b7d0]
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov qword [rsi], rax
test rax, rax
jne 0x18005b6ff
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ecx, ax
or ecx, 0xe8f00000
mov dword [rsp + 0xc8], ecx
jge 0x18005b70e
dec dword [rbx + 0x204]
or eax, 0xffffffff
lock xadd dword [rbx + 0x200], eax
cmp eax, 1
jne 0x18005b6ee
xor edx, edx
mov rcx, qword [rbx + 0x158]
call qword [0x18009b4d8]
mov eax, dword [rsp + 0xc8]
mov dword [r14 + 0x20], eax
mov edi, dword [rsp + 0x30]
jmp 0x18005b74a
test rdi, rdi
je 0x18005b70e
mov eax, dword [rsp + 0xd0]
mov qword [rdi], rax
cmp dword [rbx + 0x204], 1
jne 0x18005b72e
xor edx, edx
mov rcx, qword [rbx + 0x158]
call qword [0x18009b3d0]
mov edi, eax
mov dword [rsp + 0x30], eax
jmp 0x18005b732
mov edi, dword [rsp + 0x30]
mov eax, dword [rsp + 0x68]
mov dword [r14 + 0x1c], eax
mov eax, dword [rsp + 0x48]
mov dword [r14 + 0x28], eax
mov dword [r14 + 0x20], 0
mov rsi, qword [rsp + 0x38]
cmp dword [r14 + 0x20], 0
jge 0x18005b78f
test rsi, rsi
je 0x18005b75f
and byte [rsi + 0x30], 0xfe
mov rcx, qword [rsp + 0x60]
test rcx, rcx
je 0x18005b76f
call qword [0x18009b4c8]
mov rcx, qword [rsp + 0x50]
test rcx, rcx
je 0x18005b77f
call qword [0x18009b4c8]
mov rcx, qword [rsp + 0x58]
test rcx, rcx
je 0x18005b78f
call qword [0x18009b4c8]
mov rcx, rbx
call fcn.18004ed90
test edi, edi
js 0x18005b7bc
test eax, eax
cmovs edi, eax
test edi, edi
js 0x18005b7bc
cmp dword [r14 + 0x20], 0
jl 0x18005b7bc
mov edx, dword [r14 + 0x28]
mov rcx, rbx
call fcn.18004e210
test eax, eax
cmovs edi, eax
mov eax, edi
add rsp, 0x98
pop r14
pop rdi
pop rsi
pop rbx
ret