Function at 0x504b60
Capabilities:
Run powershell expression

Disassembly:
lea r12, [rsp - 0x40]
cmp r12, qword [r14 + 0x10]
jbe 0x504e46
push rbp
mov rbp, rsp
sub rsp, 0xb8
mov qword [rsp + 0xd8], rcx
mov qword [rsp + 0xe0], rdi
mov qword [rsp + 0xe8], rsi
mov qword [rsp + 0xf0], r8
nop word [rax + rax]
test rcx, rcx
je 0x504e2e
mov byte [rsp + 0xd0], bl
mov qword [rsp + 0xc8], rax
mov qword [rsp + 0xe0], rdi
mov qword [rsp + 0xd8], rcx
lea rdx, [rax + 0x10]
mov qword [rsp + 0x38], rdx
mov r9, rax
xor eax, eax
mov r10d, 1
lock cmpxchg dword [r9 + 0x10], r10d
sete r10b
test rsi, rsi
mov r11, rdi
cmovne rdi, r8
mov qword [rsp + 0x40], rdi
mov r8, rcx
cmovne rcx, rsi
mov qword [rsp + 0x30], rcx
test r10b, r10b
jne 0x504c3d
mov rax, rdx
call fcn.00472260
mov rcx, qword [rsp + 0x30]
mov rdx, qword [rsp + 0x38]
movzx ebx, byte [rsp + 0xd0]
mov rdi, qword [rsp + 0x40]
mov r8, qword [rsp + 0xd8]
mov r9, qword [rsp + 0xc8]
mov r11, qword [rsp + 0xe0]
cmp qword [r9 + 0x30], 0
jne 0x504d47
mov qword [r9 + 0x30], r8
cmp dword [0x009d9570], 0
je 0x504c6b
mov rax, r11
call fcn.004673c0
mov qword [r11], rax
mov rsi, qword [r9 + 0x38]
mov qword [r11 + 8], rsi
mov r11, rax
mov qword [r9 + 0x38], r11
mov qword [r9 + 0x40], rcx
cmp dword [0x009d9570], 0
je 0x504c93
mov rax, r11
nop
call fcn.004673c0
mov qword [r11], rdi
mov rsi, qword [r9 + 0x48]
mov qword [r11 + 8], rsi
mov r11, rax
mov qword [r9 + 0x48], rdi
movups xmmword [rsp + 0x48], xmm15
mov rsi, qword [r9 + 0x18]
test rsi, rsi
je 0x504cc2
lea r10, [0x009d9105]
cmp rsi, r10
je 0x504cc2
mov r10, qword [r9 + 0x20]
mov qword [rsp + 0x48], rsi
mov qword [rsp + 0x50], r10
jmp 0x504cc8
movups xmmword [rsp + 0x48], xmm15
lea rsi, [0x006a69a0]
cmp qword [rsp + 0x48], rsi
jne 0x504cdd
mov r10, qword [rsp + 0x50]
jmp 0x504ce0
xor r10d, r10d
test r10, r10
je 0x504cef
mov rax, r10
call fcn.00406180
jmp 0x504d05
lea rax, [r9 + 0x18]
mov rcx, qword [0x00983d88]
mov rbx, rsi
nop dword [rax]
call fcn.0046ce60
mov rdx, qword [rsp + 0xc8]
mov rbx, qword [rdx + 0x28]
lea rdi, [rsp + 0x58]
lea rdi, [rdi - 0x20]
nop word [rax + rax]
mov qword [rsp - 0x10], rbp
lea rbp, [rsp - 0x10]
call fcn.00467a8b
mov rbp, qword [rbp]
lea rax, [0x006b6620]
lea rcx, [rsp + 0x58]
nop
call fcn.0040f620
jmp 0x504da5
nop
mov ebx, 0xffffffff
lock xadd dword [r9 + 0x10], ebx
dec ebx
test ebx, ebx
je 0x504d65
mov rax, rdx
nop dword [rax]
call fcn.00472540
add rsp, 0xb8
pop rbp
ret
mov r9, qword [rdx]
mov rax, qword [rdx + 8]
mov rdx, qword [r9 + 0x20]
xor ebx, ebx
mov rcx, qword [rsp + 0xd8]
mov rdi, qword [rsp + 0xe0]
mov rsi, qword [rsp + 0x30]
mov r8, qword [rsp + 0x40]
call rdx
lea rax, [rsp + 0x58]
nop dword [rax]
call fcn.0040f8c0
mov rdx, qword [rsp + 0x58]
test rdx, rdx
jne 0x504d6e
cmp dword [0x009d9570], 0
jne 0x504dc2
mov rdi, qword [rsp + 0xc8]
jmp 0x504dd6
mov rdi, qword [rsp + 0xc8]
mov rdx, qword [rdi + 0x28]
call fcn.004673a0
mov qword [r11], rdx
mov qword [rdi + 0x28], 0
nop
mov ebx, 0xffffffff
lock xadd dword [rdi + 0x10], ebx
dec ebx
test ebx, ebx
je 0x504e01
mov rax, qword [rsp + 0x38]
call fcn.00472540
mov rdi, qword [rsp + 0xc8]
movzx edx, byte [rsp + 0xd0]
test dl, dl
je 0x504e25
mov rax, qword [rdi]
mov rbx, qword [rdi + 8]
lea rcx, [0x0078b3d0]
nop dword [rax + rax]
call fcn.00503f20
add rsp, 0xb8
pop rbp
ret
lea rax, [0x006a5b60]
lea rbx, [0x00789190]
nop dword [rax]
call fcn.00436ea0
nop
mov qword [rsp + 8], rax
mov byte [rsp + 0x10], bl
mov qword [rsp + 0x18], rcx
mov qword [rsp + 0x20], rdi
mov qword [rsp + 0x28], rsi
mov qword [rsp + 0x30], r8
call fcn.004654a0
mov rax, qword [rsp + 8]
movzx ebx, byte [rsp + 0x10]
mov rcx, qword [rsp + 0x18]
mov rdi, qword [rsp + 0x20]
mov rsi, qword [rsp + 0x28]
mov r8, qword [rsp + 0x30]
jmp fcn.00504b60