Function at 0x1400165b0
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push rsi
sub rsp, 0x60
mov rax, qword [rcx]
cmp byte [rax], 0
mov byte [rax], 0
je 0x14001681d
mov byte [rsp + 0x37], 0
mov rax, qword [0x1402b4090]
cmp rax, 3
jne 0x1400167c9
cmp byte [rsp + 0x37], 0
jne 0x1400167de
mov ecx, dword [0x14004a0b8]
test ecx, ecx
je 0x1400167e4
dec ecx
call sub.KERNEL32.dll_TlsGetValue
cmp rax, 2
jb 0x14001660d
mov rsi, rax
cmp byte [rax + 8], 0
jne 0x1400166a7
mov ecx, dword [0x14004a0b8]
test ecx, ecx
je 0x1400167f7
dec ecx
call sub.KERNEL32.dll_TlsGetValue
test rax, rax
je 0x140016659
mov rsi, rax
cmp rax, 1
jne 0x1400166a1
lea rax, [0x1402abee8]
mov qword [rsp + 0x20], rax
lea rcx, str.cannot_access_a_Thread_Local_Storage_value_during_or_after_destructionlibrary_std_src_threadlocal.rs
lea r9, [0x1402aa970]
lea r8, [rsp + 0x38]
mov edx, 0x46
call fcn.140008990
movzx eax, byte [0x1402b4128]
mov ecx, 0x10
mov edx, 8
call fcn.140005290
test rax, rax
je 0x14001683c
mov rsi, rax
lea rax, [0x14004a0a0]
mov qword [rsi], rax
mov byte [rsi + 8], 0
mov ecx, dword [0x14004a0b8]
test ecx, ecx
je 0x14001680a
dec ecx
mov rdx, rsi
call fcn.140047f6c
mov word [rsi + 8], 1
add rsi, 9
mov rax, qword [0x1402b4058]
cmp rax, rsi
jne 0x1400166d9
mov eax, dword [0x1402b4088]
inc eax
jne 0x1400166f9
lea rcx, str.lock_count_overflow_in_reentrant_mutexlibrary_std_src_sync_remutex.rs
lea r8, [0x1402ac388]
mov edx, 0x26
call fcn.140008bf0
lea rcx, [0x1402b4050]
call sub.KERNEL32.dll_TryAcquireSRWLockExclusive
test al, al
je 0x1400167de
mov qword [0x1402b4058], rsi
mov eax, 1
mov dword [0x1402b4088], eax
mov qword [rsp + 0x38], 0
mov qword [rsp + 0x40], 1
mov qword [rsp + 0x48], 0
mov byte [rsp + 0x50], 0
mov byte [rsp + 0x55], 0
mov dword [rsp + 0x51], 0
cmp qword [0x1402b4060], 0
jne 0x140016835
mov qword [0x1402b4060], 0xffffffffffffffff
cmp byte [0x1402b4080], 0
jne 0x14001676e
lea rcx, [0x1402b4068]
call fcn.140016980
mov qword [rsp + 0x58], rax
test rax, rax
je 0x14001676e
lea rcx, [rsp + 0x58]
call fcn.1400153f0
cmp qword [0x1402b4068], 0
je 0x140016789
mov rcx, qword [0x1402b4070]
mov edx, 1
call fcn.1400052d0
movups xmm0, xmmword [rsp + 0x38]
movups xmm1, xmmword [rsp + 0x48]
movups xmmword [0x1402b4078], xmm1
movups xmmword [0x1402b4068], xmm0
inc qword [0x1402b4060]
dec dword [0x1402b4088]
jne 0x1400167de
mov qword [0x1402b4058], 0
lea rcx, [0x1402b4050]
call sub.KERNEL32.dll_ReleaseSRWLockExclusive
jmp 0x1400167de
lea rcx, [rsp + 0x37]
call fcn.140016910
cmp byte [rsp + 0x37], 0
je 0x1400165e5
add rsp, 0x60
pop rsi
ret
lea rcx, [0x14004a0a0]
call fcn.140015d60
mov ecx, eax
jmp 0x1400165f5
lea rcx, [0x14004a0a0]
call fcn.140015d60
mov ecx, eax
jmp 0x14001661d
lea rcx, [0x14004a0a0]
call fcn.140015d60
mov ecx, eax
jmp 0x140016699
lea rcx, str.called__Option::unwrap____on_a__None__value_rustc_07dca489ac2d933c78d3c5158e3f43beefeb02celibrarycore_srcio_borrowed_buf.rs_rustc_07dca489ac2d933c78d3c5158e3f43beefeb02celibrary_alloc_srccollections_btree_navigate.rs
lea r8, str.library_std_src_synconce.rs
mov edx, 0x2b
call fcn.140007a70
call fcn.1400081a0
ud2
mov ecx, 8
mov edx, 0x10
call fcn.1400062e0
mov rsi, rax
cmp qword [0x1402b4068], 0
je 0x140016869
mov rcx, qword [0x1402b4070]
mov edx, 1
call fcn.1400052d0
movups xmm0, xmmword [rsp + 0x38]
movups xmm1, xmmword [rsp + 0x48]
movups xmmword [0x1402b4078], xmm1
movups xmmword [0x1402b4068], xmm0
inc qword [0x1402b4060]
jmp 0x1400168c2
dec dword [0x1402b4088]
jne 0x1400168e1
mov qword [0x1402b4058], 0
lea rcx, [0x1402b4050]
call sub.KERNEL32.dll_ReleaseSRWLockExclusive
mov rcx, rsi
call fcn.140048580
cmp qword [rsp + 0x38], 0
je 0x140016900
mov rcx, qword [rsp + 0x40]
mov edx, 1
call fcn.1400052d0
call fcn.140008fe0
int3