Function at 0x1400a22e0
Capabilities:
Get thread local storage value

Disassembly:
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov rsi, rcx
mov rbp, rdx
test rcx, rcx
je 0x1400a2400
lea rdi, [0x1400a63d8]
mov rcx, rdi
call fcn.14009f810
mov rcx, rsi
call fcn.14009fdf0
mov rcx, rdi
mov rbx, rax
call fcn.14009fae0
test rbx, rbx
je 0x1400a2400
mov rcx, qword [rbx + 0x28]
test rcx, rcx
je 0x1400a2400
lea rdx, [rsp + 0x2c]
call qword [sym.imp.KERNEL32.dll_GetHandleInformation]
test eax, eax
je 0x1400a2400
test byte [rbx + 0x44], 4
jne 0x1400a2410
call fcn.1400a0580
mov ecx, dword [0x1400a63e8]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
test rax, rax
je 0x1400a2430
cmp rsi, qword [rax + 0x1d8]
je 0x1400a2460
mov eax, dword [rbx + 0xbc]
mov rcx, qword [rbx + 0x28]
test eax, eax
je 0x1400a238b
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x1400a239a
mov edx, 0xffffffff
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov rcx, qword [rbx + 0x28]
mov rsi, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rsi
mov rcx, qword [rbx + 0x30]
test rcx, rcx
je 0x1400a23ae
call rsi
mov qword [rbx + 0x30], 0
test rbp, rbp
je 0x1400a2448
mov rax, qword [rbx + 8]
lea rcx, [rbx + 0x38]
mov qword [rbp], rax
call fcn.14009fc70
lea rcx, [rbx + 0x68]
call fcn.1400a3e10
cmp eax, 1
je 0x1400a2467
cmp qword [rbx + 0x1d0], 0
mov qword [rbx + 0x68], 0xffffffffffffffff
je 0x1400a2420
xor eax, eax
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov eax, 3
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov eax, 0x16
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov rcx, rbx
call fcn.1400a03e0
xor eax, eax
jmp 0x1400a23f6
call fcn.1400a0630
test rax, rax
jne 0x1400a2366
jmp 0x1400a2373
lea rcx, [rbx + 0x38]
call fcn.14009fc70
lea rcx, [rbx + 0x68]
jmp 0x1400a23d4
mov eax, 0x24
jmp 0x1400a2405
call fcn.1400a00e0
nop
nop dword [rax]
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
lea rbp, [0x1400a63d8]
mov rsi, rcx
mov rcx, rbp
mov rdi, rdx
call fcn.14009f810
mov rcx, rsi
call fcn.14009fdf0
mov rbx, rax
test rax, rax
je 0x1400a2590
mov rcx, qword [rax + 0x28]
test rcx, rcx
je 0x1400a2590
lea rdx, [rsp + 0x2c]
call qword [sym.imp.KERNEL32.dll_GetHandleInformation]
test eax, eax
je 0x1400a2590
test byte [rbx + 0x44], 4
jne 0x1400a25b0
call fcn.1400a0580
mov ecx, dword [0x1400a63e8]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
test rax, rax
je 0x1400a25f0
mov rdx, qword [rax + 0x1d8]
cmp rsi, rdx
je 0x1400a2630
mov edx, dword [rbx + 0xbc]
mov rcx, qword [rbx + 0x28]
test edx, edx
jne 0x1400a2517
xor edx, edx
call qword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
jne 0x1400a25d0
mov rcx, qword [rbx + 0x28]
mov rsi, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rsi
mov rcx, qword [rbx + 0x30]
test rcx, rcx
je 0x1400a252b
call rsi
mov qword [rbx + 0x30], 0
test rdi, rdi
je 0x1400a2608
mov rax, qword [rbx + 8]
lea rcx, [rbx + 0x38]
mov qword [rdi], rax
call fcn.14009fc70
lea rcx, [rbx + 0x68]
call fcn.1400a3e10
cmp eax, 1
je 0x1400a2642
cmp qword [rbx + 0x1d0], 0
mov qword [rbx + 0x68], 0xffffffffffffffff
je 0x1400a2620
mov rcx, rbp
call fcn.14009fae0
xor eax, eax
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov rcx, rbp
call fcn.14009fae0
mov eax, 3
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov rcx, rbp
call fcn.14009fae0
mov eax, 0x16
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
ret
mov eax, dword [rbx + 0xbc]
test eax, eax
jne 0x1400a2513
mov rcx, rbp
call fcn.14009fae0
mov eax, 0x10
jmp 0x1400a257e
call fcn.1400a0630
xor edx, edx
test rax, rax
jne 0x1400a24e5
jmp 0x1400a24ec
lea rcx, [rbx + 0x38]
call fcn.14009fc70
lea rcx, [rbx + 0x68]
jmp 0x1400a2550
mov rcx, rbx
call fcn.1400a03e0
jmp 0x1400a2574
mov rcx, rbp
call fcn.14009fae0
mov eax, 0x24
jmp 0x1400a257e
call fcn.1400a00e0
nop
nop dword [rax + rax]
push rdi
push rsi
push rbx
sub rsp, 0x30
lea rsi, [0x1400a63d8]
mov rbx, rcx
mov rcx, rsi
test rbx, rbx
je 0x1400a2748
call fcn.14009f810
mov rcx, rbx
call fcn.14009fdf0
mov rcx, rsi
mov rbx, rax
call fcn.14009fae0
mov rcx, rsi
call fcn.14009f810
test rbx, rbx
je 0x1400a274d
mov rcx, qword [rbx + 0x28]
test rcx, rcx
je 0x1400a274d
lea rdx, [rsp + 0x2c]
call qword [sym.imp.KERNEL32.dll_GetHandleInformation]
test eax, eax
je 0x1400a274d
mov eax, dword [rbx + 0x44]
test al, 4
jne 0x1400a2768
or eax, 4
mov rcx, qword [rbx + 0x28]
mov qword [rbx + 0x28], 0
mov dword [rbx + 0x44], eax
test rcx, rcx
je 0x1400a2730
mov rdi, qword [sym.imp.KERNEL32.dll_CloseHandle]
call rdi
mov eax, dword [rbx + 0xbc]
test eax, eax
je 0x1400a2730
mov rcx, qword [rbx + 0x30]
test rcx, rcx
je 0x1400a2780
call rdi
mov qword [rbx + 0x30], 0
lea rcx, [rbx + 0x38]
call fcn.14009fc70
lea rcx, [rbx + 0x68]
call fcn.1400a3e10
cmp eax, 1
je 0x1400a27a2
cmp qword [rbx + 0x1d0], 0
mov qword [rbx + 0x68], 0xffffffffffffffff
je 0x1400a2798
nop
mov rcx, rsi
call fcn.14009fae0
xor eax, eax
add rsp, 0x30
pop rbx
pop rsi
pop rdi
ret
call fcn.14009f810
mov rcx, rsi
call fcn.14009fae0
mov eax, 3
add rsp, 0x30
pop rbx
pop rsi
pop rdi
ret
mov rcx, rsi
call fcn.14009fae0
mov eax, 0x16
jmp 0x1400a273a
lea rcx, [rbx + 0x38]
call fcn.14009fc70
lea rcx, [rbx + 0x68]
jmp 0x1400a270f
mov rcx, rbx
call fcn.1400a03e0
jmp 0x1400a2730
call fcn.1400a00e0
nop
nop dword [rax + rax]
mov eax, dword [0x1400cb188]
ret