Function at 0x140004690
Capabilities:
Get thread local storage value

Disassembly:
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rax, [rdx + 0xf]
mov rbx, rcx
mov rdi, rax
and rdi, 0xfffffffffffffff0
cmp rdi, 0xfc0
jle 0x140003ec0
lea rsi, [rdx + 0x20]
cmp rsi, 0x3f000000
jg 0x140003f30
mov rdx, rsi
call fcn.140003760
cmp qword [rbx + 0x28a8], 0
mov rdi, rax
lea rbp, [rdi + 0x20]
je 0x140003fd9
lea rdx, [rbx + 0x28a8]
lea r9, [rbp + rsi]
mov r8, rbp
mov rcx, rbx
call fcn.140003cf0
mov rdi, qword [rdi + 8]
add rdi, qword [rbx + 0x2098]
mov rax, rbp
mov qword [rbx + 0x2098], rdi
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
sar rax, 4
lea rsi, [rax + 2]
mov rdx, qword [rcx + rsi*8]
test rdx, rdx
je 0x140004020
mov rbp, qword [rdx + 0x20]
test rbp, rbp
je 0x1400040c0
mov rax, qword [rbp]
mov qword [rdx + 0x20], rax
mov rax, qword [rdx + 0x28]
sub rax, rdi
mov qword [rdx + 0x28], rax
cmp rax, rdi
jge 0x140003e9c
mov rax, qword [rbx + rsi*8]
mov rcx, qword [rdx + 0x10]
cmp rdx, rax
je 0x140004071
mov rax, qword [rdx + 0x18]
mov qword [rax + 0x10], rcx
test rcx, rcx
je 0x140003f20
mov rax, qword [rdx + 0x18]
mov qword [rcx + 0x18], rax
mov rax, rdx
jmp 0x140004086
mov r9d, 4
mov r8d, 0x3000
mov rdx, rsi
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rdi, rax
test rax, rax
je 0x1400040d5
mov rbp, rax
pxor xmm0, xmm0
add qword [rbx + 0x2080], rsi
mov r12, rax
sar rbp, 0x15
mov qword [rax + 8], rsi
sar r12, 0xc
mov qword [rax], 1
movups xmmword [rax + 0x10], xmm0
movzx eax, bpl
lea r13, [rbx + rax*8]
mov rax, qword [r13 + 0x20a8]
test rax, rax
jne 0x140003fa4
jmp 0x140004098
mov rax, qword [rax]
test rax, rax
je 0x140004098
cmp rbp, qword [rax + 8]
jne 0x140003f98
mov rcx, r12
mov edx, 1
lea rbp, [rdi + 0x20]
and ecx, 0x1ff
mov r8, rcx
shl rdx, cl
sar r8, 6
or qword [rax + r8*8 + 0x10], rdx
cmp qword [rbx + 0x28a8], 0
jne 0x140003e81
cmp qword [rbx + 0x28d8], 0
lea rax, [rbx + 0x28d8]
je 0x140004000
mov qword [rbx + 0x28a8], rax
jmp 0x140003e81
movq xmm0, rax
mov qword [rbx + 0x28a8], rax
punpcklqdq xmm0, xmm0
movups xmmword [rbx + 0x28d8], xmm0
jmp 0x140003e81
mov edx, 0x1000
call fcn.140003760
mov edx, 0xfc0
pxor xmm0, xmm0
sub rdx, rdi
movups xmmword [rax + 0x10], xmm0
mov qword [rax + 0x20], 0
mov qword [rax + 8], rdi
mov qword [rax + 0x30], rdi
mov qword [rax + 0x28], rdx
mov rdx, qword [rbx + rsi*8]
mov qword [rax + 0x10], rdx
test rdx, rdx
je 0x14000405f
mov qword [rdx + 0x18], rax
mov qword [rbx + rsi*8], rax
lea rbp, [rax + 0x40]
cmp rdi, qword [rax + 0x28]
jle 0x140003e9c
mov rdx, qword [rax + 0x10]
mov qword [rbx + rsi*8], rdx
test rdx, rdx
je 0x140004086
mov qword [rdx + 0x18], 0
pxor xmm0, xmm0
movups xmmword [rax + 0x10], xmm0
jmp 0x140003e9c
mov edx, 0x50
mov rcx, rbx
call fcn.140002e90
mov rdx, qword [r13 + 0x20a8]
mov qword [rax], rdx
mov qword [r13 + 0x20a8], rax
mov qword [rax + 8], rbp
jmp 0x140003faa
mov rax, qword [rdx + 0x30]
lea rbp, [rdx + rax + 0x40]
add rax, rdi
mov qword [rdx + 0x30], rax
jmp 0x140003eea
call fcn.140002e50
nop
nop dword [rax + rax]
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x28
lea rax, [rdx + 0x1f]
mov rbx, rcx
mov rdi, rax
and rdi, 0xfffffffffffffff0
cmp rdi, 0xfc0
jle 0x140004180
lea rsi, [rdx + 0x30]
cmp rsi, 0x3f000000
jg 0x1400041f0
mov rdx, rsi
call fcn.140003760
cmp qword [rbx + 0x28a8], 0
mov rdi, rax
lea rbp, [rdi + 0x20]
je 0x140004299
lea rdx, [rbx + 0x28a8]
mov r8, rbp
mov rcx, rbx
mov r12, rbp
lea r9, [rbp + rsi]
call fcn.140003cf0
mov rdi, qword [rdi + 8]
add rdi, qword [rbx + 0x2098]
lea rax, [r12 + 0x10]
mov qword [rbx + 0x2098], rdi
mov qword [rbp + 8], 1
add rsp, 0x28
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
ret
sar rax, 4
lea rsi, [rax + 2]
mov rdx, qword [rcx + rsi*8]
test rdx, rdx
je 0x1400042e0
mov rbp, qword [rdx + 0x20]
test rbp, rbp
je 0x140004390
mov rax, qword [rbp]
mov r12, rbp
mov qword [rdx + 0x20], rax
mov rax, qword [rdx + 0x28]
sub rax, rdi
mov qword [rdx + 0x28], rax
cmp rdi, rax
jle 0x14000414f
mov rax, qword [rbx + rsi*8]
mov rcx, qword [rdx + 0x10]
cmp rdx, rax
je 0x140004334
mov rax, qword [rdx + 0x18]
mov qword [rax + 0x10], rcx
test rcx, rcx
je 0x1400041e3
mov rax, qword [rdx + 0x18]
mov qword [rcx + 0x18], rax
mov rax, rdx
jmp 0x140004349
mov r9d, 4
mov r8d, 0x3000
mov rdx, rsi
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rdi, rax
test rax, rax
je 0x1400043a8
mov rbp, rax
pxor xmm0, xmm0
add qword [rbx + 0x2080], rsi
mov r12, rax
sar rbp, 0x15
mov qword [rax + 8], rsi
sar r12, 0xc
mov qword [rax], 1
movups xmmword [rax + 0x10], xmm0
movzx eax, bpl
lea r13, [rbx + rax*8]
mov rax, qword [r13 + 0x20a8]
test rax, rax
jne 0x140004264
jmp 0x140004360
mov rax, qword [rax]
test rax, rax
je 0x140004360
cmp rbp, qword [rax + 8]
jne 0x140004258
mov rcx, r12
mov edx, 1
lea rbp, [rdi + 0x20]
and ecx, 0x1ff
mov r8, rcx
shl rdx, cl
sar r8, 6
or qword [rax + r8*8 + 0x10], rdx
cmp qword [rbx + 0x28a8], 0
jne 0x140004131
cmp qword [rbx + 0x28d8], 0
lea rax, [rbx + 0x28d8]
je 0x1400042c0
mov qword [rbx + 0x28a8], rax
jmp 0x140004131
movq xmm0, rax
mov qword [rbx + 0x28a8], rax
punpcklqdq xmm0, xmm0
movups xmmword [rbx + 0x28d8], xmm0
jmp 0x140004131
mov edx, 0x1000
call fcn.140003760
mov edx, 0xfc0
pxor xmm0, xmm0
sub rdx, rdi
movups xmmword [rax + 0x10], xmm0
mov qword [rax + 0x20], 0
mov qword [rax + 8], rdi
mov qword [rax + 0x30], rdi
mov qword [rax + 0x28], rdx
mov rdx, qword [rbx + rsi*8]
mov qword [rax + 0x10], rdx
test rdx, rdx
je 0x14000431f
mov qword [rdx + 0x18], rax
lea rbp, [rax + 0x40]
mov qword [rbx + rsi*8], rax
mov r12, rbp
cmp rdi, qword [rax + 0x28]
jle 0x14000414f
mov rdx, qword [rax + 0x10]
mov qword [rbx + rsi*8], rdx
test rdx, rdx
je 0x140004349
mov qword [rdx + 0x18], 0
pxor xmm0, xmm0
movups xmmword [rax + 0x10], xmm0
jmp 0x14000414f
mov edx, 0x50
mov rcx, rbx
call fcn.140002e90
mov rdx, qword [r13 + 0x20a8]
mov qword [rax], rdx
mov qword [r13 + 0x20a8], rax
mov qword [rax + 8], rbp
jmp 0x14000426a
mov rax, qword [rdx + 0x30]
lea r12, [rdx + rax + 0x40]
add rax, rdi
mov qword [rdx + 0x30], rax
mov rbp, r12
jmp 0x1400041ad
call fcn.140002e50
nop
nop
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x20
lea rax, [rdx + 0x1f]
mov rbx, rcx
mov rdi, rdx
mov rsi, rax
and rsi, 0xfffffffffffffff0
cmp rsi, 0xfc0
jle 0x140004460
lea r12, [rdx + 0x30]
cmp r12, 0x3f000000
jg 0x1400044d0
mov rdx, r12
call fcn.140003760
cmp qword [rbx + 0x28a8], 0
mov rsi, rax
lea r13, [rsi + 0x20]
je 0x140004579
lea rdx, [rbx + 0x28a8]
mov r8, r13
mov rcx, rbx
mov rbp, r13
lea r9, [r13 + r12]
call fcn.140003cf0
mov rsi, qword [rsi + 8]
add rsi, qword [rbx + 0x2098]
add rbp, 0x10
mov r8, rdi
xor edx, edx
mov qword [rbx + 0x2098], rsi
mov rcx, rbp
mov qword [r13 + 8], 1
call sub.msvcrt.dll_memset
add rsp, 0x20
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
sar rax, 4
lea r12, [rax + 2]
mov rdx, qword [rcx + r12*8]
test rdx, rdx
je 0x1400045c0
mov r13, qword [rdx + 0x20]
test r13, r13
je 0x140004670
mov rax, qword [r13]
mov rbp, r13
mov qword [rdx + 0x20], rax
mov rax, qword [rdx + 0x28]
sub rax, rsi
mov qword [rdx + 0x28], rax
cmp rsi, rax
jle 0x140004428
mov rax, qword [rbx + r12*8]
mov rcx, qword [rdx + 0x10]
cmp rdx, rax
je 0x140004614
mov rax, qword [rdx + 0x18]
mov qword [rax + 0x10], rcx
test rcx, rcx
je 0x1400044c3
mov rax, qword [rdx + 0x18]
mov qword [rcx + 0x18], rax
mov rax, rdx
jmp 0x140004629
mov r9d, 4
mov r8d, 0x3000
mov rdx, r12
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov rsi, rax
test rax, rax
je 0x140004688
mov rbp, rax
pxor xmm0, xmm0
add qword [rbx + 0x2080], r12
mov r13, rax
sar rbp, 0x15
mov qword [rax + 8], r12
sar r13, 0xc
mov qword [rax], 1
movups xmmword [rax + 0x10], xmm0
movzx eax, bpl
lea r14, [rbx + rax*8]
mov rax, qword [r14 + 0x20a8]
test rax, rax
jne 0x140004544
jmp 0x140004640
mov rax, qword [rax]
test rax, rax
je 0x140004640
cmp rbp, qword [rax + 8]
jne 0x140004538
mov rcx, r13
mov edx, 1
lea r13, [rsi + 0x20]
and ecx, 0x1ff
mov r8, rcx
shl rdx, cl
sar r8, 6
or qword [rax + r8*8 + 0x10], rdx
cmp qword [rbx + 0x28a8], 0
jne 0x14000440a
cmp qword [rbx + 0x28d8], 0
lea rax, [rbx + 0x28d8]
je 0x1400045a0
mov qword [rbx + 0x28a8], rax
jmp 0x14000440a
movq xmm0, rax
mov qword [rbx + 0x28a8], rax
punpcklqdq xmm0, xmm0
movups xmmword [rbx + 0x28d8], xmm0
jmp 0x14000440a
mov edx, 0x1000
call fcn.140003760
mov edx, 0xfc0
pxor xmm0, xmm0
sub rdx, rsi
movups xmmword [rax + 0x10], xmm0
mov qword [rax + 0x20], 0
mov qword [rax + 8], rsi
mov qword [rax + 0x30], rsi
mov qword [rax + 0x28], rdx
mov rdx, qword [rbx + r12*8]
mov qword [rax + 0x10], rdx
test rdx, rdx
je 0x1400045ff
mov qword [rdx + 0x18], rax
lea r13, [rax + 0x40]
mov qword [rbx + r12*8], rax
mov rbp, r13
cmp rsi, qword [rax + 0x28]
jle 0x140004428
mov rdx, qword [rax + 0x10]
mov qword [rbx + r12*8], rdx
test rdx, rdx
je 0x140004629
mov qword [rdx + 0x18], 0
pxor xmm0, xmm0
movups xmmword [rax + 0x10], xmm0
jmp 0x140004428
mov edx, 0x50
mov rcx, rbx
call fcn.140002e90
mov rdx, qword [r14 + 0x20a8]
mov qword [rax], rdx
mov qword [r14 + 0x20a8], rax
mov qword [rax + 8], rbp
jmp 0x14000454a
mov rax, qword [rdx + 0x30]
lea rbp, [rdx + rax + 0x40]
add rax, rsi
mov qword [rdx + 0x30], rax
mov r13, rbp
jmp 0x14000448d
call fcn.140002e50
nop
nop
push rdi
push rsi
push rbx
sub rsp, 0x20
mov ebx, dword [0x1400b8628]
mov rsi, rcx
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, ebx
mov edi, eax
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov ecx, edi
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_SetLastError]
lea rdx, [rsi + 0x10]
lea rcx, [rbx + 0xa0]
call fcn.140003e30
mov r8, rsi
xor edx, edx
mov qword [rax + 8], 1
lea rcx, [rax + 0x10]
call sub.msvcrt.dll_memset
add rsp, 0x20
pop rbx
pop rsi
pop rdi
ret