Function at 0x14004c540
Capabilities:
Get thread local storage value

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x48
mov rdi, r9
mov rbx, r8
mov ebp, edx
mov rsi, rcx
mov rax, qword [0x140231040]
xor rax, rsp
mov qword [rsp + 0x40], rax
mov eax, dword [0x140243b20]
mov ecx, dword [0x1402403d8]
mov rdx, qword gs:[0x58]
mov rcx, qword [rdx + rcx*8]
cmp eax, dword [rcx + 4]
jg 0x14004c710
mov ecx, dword [0x14023f7d0]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
and rax, 0xfffffffffffffffc
je 0x14004c672
mov rcx, qword [0x140243b10]
shl rcx, 4
mov edx, dword [rax + rcx + 8]
cmp edx, dword [0x140243b18]
jne 0x14004c672
add rax, rcx
cmp qword [rax], 0
je 0x14004c672
mov ecx, dword [0x14023f7d0]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
and rax, 0xfffffffffffffffc
je 0x14004c66d
mov rcx, qword [0x140243b10]
shl rcx, 4
mov edx, dword [rax + rcx + 8]
cmp edx, dword [0x140243b18]
jne 0x14004c66d
add rax, rcx
mov r13, qword [rax]
lea r14, [r13 + 8]
mov rcx, qword [r13 + 8]
test rcx, rcx
je 0x14004c635
mov rax, r14
xor edx, edx
cmp qword [rcx + 0x20], rsi
setb dl
cmovae rax, rcx
mov rcx, qword [rcx + rdx*8]
test rcx, rcx
jne 0x14004c610
cmp rax, r14
je 0x14004c635
cmp qword [rax + 0x20], rsi
jbe 0x14004c835
cmp ebp, 1
je case.default.0x14004c666
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.14012d2c0
mov rcx, rsi
mov edx, ebp
mov r8, rbx
mov r9, rdi
add rsp, 0x48
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
jmp qword [sym.imp.USER32.dll_DefWindowProcW]
xor r13d, r13d
jmp 0x14004c600
mov ecx, 0x18
call fcn.14012aa30
mov r15, rax
add rax, 8
xorps xmm0, xmm0
movups xmmword [r15 + 8], xmm0
mov qword [r15], rax
mov ecx, dword [0x14023f7d0]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
and rax, 0xfffffffffffffffc
je 0x14004c70b
mov rcx, qword [0x140243b10]
shl rcx, 4
mov edx, dword [rax + rcx + 8]
cmp edx, dword [0x140243b18]
jne 0x14004c70b
add rax, rcx
mov r12, qword [rax]
mov ecx, dword [0x14023f7d0]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
and rax, 0xfffffffffffffffc
jne 0x14004c6d9
test r15, r15
je 0x14004c6fd
call fcn.14001b6e0
mov rcx, qword [0x140243b10]
shl rcx, 4
mov qword [rax + rcx], r15
mov ecx, dword [0x140243b18]
mov rdx, qword [0x140243b10]
shl rdx, 4
mov dword [rax + rdx + 8], ecx
test r12, r12
je 0x14004c5cd
jmp 0x14004c9f7
xor r12d, r12d
jmp 0x14004c6bd
lea rcx, [0x140243b20]
call fcn.14012ad90
cmp dword [0x140243b20], 0xffffffff
jne 0x14004c58f
mov qword [0x140243b18], 0
lea rcx, [0x140243b10]
mov qword [0x140243b10], 0xffffffffffffffff
lea rdx, [0x140050a90]
call fcn.140036e40
lea rcx, [0x140243b20]
call fcn.14012ad24
jmp 0x14004c58f
mov rax, qword [rbp]
mov rbx, rbp
jmp 0x14004c78b
mov dword [rsp + 0x34], ebp
mov rax, rdi
mov rdi, rbx
mov qword [rsp + 0x28], rax
mov r15, qword [rax]
mov qword [r15 + 8], rsi
mov rax, qword [r14]
mov rbx, r14
mov rbp, r14
test rax, rax
je 0x14004c7ac
mov rbp, rax
cmp qword [rax + 0x20], rsi
ja 0x14004c763
jae 0x14004c9ce
mov rax, qword [rbp + 8]
test rax, rax
jne 0x14004c790
lea rbx, [rbp + 8]
mov ecx, 0x30
call fcn.14012aa30
mov r12, rax
add rax, 0x20
je 0x14004c9d1
mov qword [rax], rsi
movabs rax, 0xfffffffc00000000
and rax, r15
cmp rax, qword [0x1402336c8]
jne 0x14004c7e4
mov rcx, r15
call fcn.1400a3490
mov qword [r12 + 0x28], r15
xorps xmm0, xmm0
movups xmmword [r12], xmm0
mov qword [r12 + 0x10], rbp
mov qword [rbx], r12
mov rax, qword [r13]
mov rax, qword [rax]
test rax, rax
je 0x14004c80c
mov qword [r13], rax
mov r12, qword [rbx]
mov rcx, qword [r13 + 8]
mov rdx, r12
call fcn.1400baa00
inc qword [r13 + 0x10]
test r15, r15
mov rax, qword [rsp + 0x28]
mov rbx, rdi
mov rdi, rax
mov ebp, dword [rsp + 0x34]
jne 0x14004c842
jmp 0x14004c63e
mov r15, qword [rax + 0x28]
test r15, r15
je 0x14004c9cb
mov qword [rsp + 0x38], 0
mov r12, qword [r15]
test r12, r12
je 0x14004c9b2
mov qword [rsp + 0x28], r13
mov eax, 1
lock xadd dword [r12], eax
test eax, eax
jle 0x14004c9b5
cmp eax, 0x7fffffff
je 0x14004c9b8
mov r8, rbx
mov r13, rsi
mov rax, qword [r15]
mov rax, qword [rax + 8]
lea rcx, [rsp + 0x38]
mov qword [rsp + 0x20], rcx
mov rcx, r12
mov ebx, ebp
mov edx, ebp
mov rsi, r8
mov r9, rdi
call qword [0x1402233e0]
mov ebp, eax
lock dec dword [r12]
je 0x14004c9be
test bpl, bpl
jne 0x14004c8cc
mov rcx, r13
mov edx, ebx
mov r8, rsi
mov r9, rdi
call qword [sym.imp.USER32.dll_DefWindowProcW]
mov qword [rsp + 0x38], rax
cmp ebx, 2
je 0x14004c8f7
mov rsi, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.14012d2c0
mov rax, rsi
add rsp, 0x48
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
mov qword [r15 + 8], 0
mov rcx, qword [r14]
test rcx, rcx
je 0x14004c9bb
mov rax, rcx
mov rdi, r14
xor edx, edx
cmp qword [rax + 0x20], r13
setb dl
cmovae rdi, rax
mov rax, qword [rax + rdx*8]
test rax, rax
jne 0x14004c911
cmp rdi, r14
je 0x14004c9bb
cmp qword [rdi + 0x20], r13
ja 0x14004c9bb
mov rdx, qword [rdi + 8]
test rdx, rdx
jne 0x14004c9a0
mov rdx, rdi
mov r8, qword [rsp + 0x28]
mov rax, qword [rdx + 0x10]
cmp qword [rax], rdx
mov rdx, rax
jne 0x14004c94b
lea rsi, [rdi + 0x20]
cmp qword [r8], rdi
jne 0x14004c963
mov qword [r8], rax
dec qword [r8 + 0x10]
mov rdx, rdi
call fcn.1400f4510
test rsi, rsi
je 0x14004c9e4
mov rcx, qword [rdi + 0x28]
movabs rax, 0xfffffffc00000000
and rax, rcx
cmp rax, qword [0x1402336c8]
jne 0x14004c993
call fcn.1400a3600
mov rcx, rdi
call fcn.14012aa6c
jmp 0x14004c8d1
mov r8, qword [rsp + 0x28]
mov rax, rdx
mov rdx, qword [rdx]
test rdx, rdx
je 0x14004c957
jmp 0x14004c9a5
int3
int3
int3
int3
mov rcx, r12
call fcn.140119860
jmp 0x14004c8b1
int3
int3
lea rcx, [0x14020310b]
lea rdx, str....._third_partylibc_srcinclude__memoryconstruct_at.h:40:_assertion___location___nullptr_failed:_null_pointer_given_to_construct_at_n
call fcn.140164a90
lea rcx, [0x14020310b]
lea rdx, str....._third_partylibc_srcinclude__memoryconstruct_at.h:66:_assertion___loc___nullptr_failed:_null_pointer_given_to_destroy_at_n
call fcn.140164a90
mov rcx, qword [r12 + 8]
call fcn.140050ac0
mov rcx, r12
call fcn.14012aa6c
jmp 0x14004c5cd
lea rax, sym.imp.USER32.dll_DefWindowProcW
jmp 0x1401ede0d
lea rax, sym.imp.USER32.dll_DestroyWindow
jmp 0x1401ede0d
push rcx
push rdx
push r8
push r9
sub rsp, 0x48
movdqa xmmword [rsp], xmm0
movdqa xmmword [rsp + 0x10], xmm1
movdqa xmmword [rsp + 0x20], xmm2
movdqa xmmword [rsp + 0x30], xmm3
mov rdx, rax
lea rcx, [0x140223530]
call fcn.14012c778
movdqa xmm0, xmmword [rsp]
movdqa xmm1, xmmword [rsp + 0x10]
movdqa xmm2, xmmword [rsp + 0x20]
movdqa xmm3, xmmword [rsp + 0x30]
add rsp, 0x48
pop r9
pop r8
pop rdx
pop rcx
jmp rax