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

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x88
mov qword [rsp + 0x78], r9
mov qword [rsp + 0x70], r8
mov ebp, edx
mov rsi, rcx
mov rax, qword [rcx]
lea rbx, [rsp + 0x2a]
mov r14d, 2
lea r15, [0x1400490d8]
jmp 0x140017047
test bpl, bpl
je 0x1400172f9
mov rax, r12
lock cmpxchg qword [rsi], r14
je 0x140017248
mov r12, rax
or rax, rax
je 0x140017039
cmp r12, 1
je 0x140017030
cmp r12, 3
je 0x140017279
mov eax, r12d
and eax, 3
cmp eax, 2
je 0x14001707f
jmp 0x140017334
mov eax, r12d
and eax, 3
cmp eax, 2
jne 0x140017240
mov ecx, dword [0x1400490f0]
or ecx, ecx
je 0x1400171d6
dec ecx
call fcn.140046554
cmp rax, 2
jb 0x1400170b0
mov r13, rax
cmp qword [rax + 8], 0
je 0x1400170b0
add r13, 0x10
jmp 0x140017160
mov ecx, dword [0x1400490f0]
or ecx, ecx
je 0x1400171e5
dec ecx
call fcn.140046554
or rax, rax
je 0x1400170e0
push rax
nop
pop rdi
cmp rax, 1
jne 0x140017122
jmp 0x1400172d2
movzx eax, byte [0x1400bf128]
mov edx, 0x18
sub ecx, ecx
call fcn.140036e50
test rax, rax
je 0x1400172ea
mov rdi, rax
mov qword [rax], r15
mov qword [rax + 8], 0
mov ecx, dword [0x1400490f0]
test ecx, ecx
je 0x1400171f4
dec ecx
push rdi
nop
pop rdx
call fcn.14004654c
lea r13, [rdi + 0x10]
mov rcx, qword [rdi + 0x10]
cmp qword [rdi + 8], 0
mov qword [rdi + 8], 1
mov qword [rdi + 0x10], 0
je 0x140017160
test rcx, rcx
je 0x140017160
lock dec qword [rcx]
jne 0x140017160
call fcn.140017560
nop word cs:[rax + rax]
mov rdi, qword [r13]
or rdi, rdi
jne 0x140017182
sub ecx, ecx
call fcn.140016cc0
push rax
pop rdi
nop
cmp qword [r13], 0
jne 0x14001728e
mov qword [r13], rdi
lock inc qword [rdi]
jle 0x1400172d0
mov rax, r12
add rax, 0xfffffffffffffffe
mov qword [rsp + 0x28], rdi
mov byte [rsp + 0x38], 0
mov qword [rsp + 0x30], rax
mov rax, r12
lock cmpxchg qword [rsi], rbx
je 0x140017215
mov r12, rax
mov rax, qword [rsp + 0x28]
test rax, rax
je 0x140017070
lock dec qword [rax]
jne 0x140017070
mov rcx, qword [rsp + 0x28]
call fcn.140017560
jmp 0x140017070
mov rcx, r15
call fcn.1400175b0
mov ecx, eax
jmp 0x14001708f
mov rcx, r15
call fcn.1400175b0
mov ecx, eax
jmp 0x1400170c0
mov rcx, r15
call fcn.1400175b0
mov ecx, eax
jmp 0x14001711a
call fcn.140017720
movzx eax, byte [rsp + 0x38]
test al, al
je 0x140017210
mov rax, qword [rsp + 0x28]
test rax, rax
je 0x140017240
lock dec qword [rax]
jne 0x140017240
mov rcx, qword [rsp + 0x28]
call fcn.140017560
nop dword [rax + rax]
mov rax, qword [rsi]
jmp 0x140017047
cmp r12, 1
mov qword [rsp + 0x40], 3
sete byte [rsp + 0x48]
lea rdx, [rsp + 0x40]
mov rcx, qword [rsp + 0x70]
mov rax, qword [rsp + 0x78]
call qword [rax + 0x20]
mov rdx, qword [rsp + 0x40]
push rsi
pop rcx
nop
call fcn.1400173a0
nop
add rsp, 0x88
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
mov qword [rsp + 0x80], rdi
lea rax, str.reentrant_init
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x48], 1
lea rax, str.cannot_access_a_Thread_Local_Storage_value_during_or_after_destruction_rustc_25ef9e3d85d934b27d9dada2f9dd52b1dc63bb04library_std_src_threadlocal.rs
mov qword [rsp + 0x50], rax
xorps xmm0, xmm0
movups xmmword [rsp + 0x58], xmm0
lea rdx, str._rustc_25ef9e3d85d934b27d9dada2f9dd52b1dc63bb04librarycore_srccellonce.rs
lea rcx, [rsp + 0x40]
call fcn.140003e30
ud2
lea rcx, [0x1400b5c88]
lea r8, [0x1400b5ce8]
mov edx, 0x5e
call fcn.140005e10
mov ecx, 8
mov edx, 0x18
call fcn.1400032e0
lea rax, str.Once_instance_has_previously_been_poisoned
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x48], 1
lea rax, str.cannot_access_a_Thread_Local_Storage_value_during_or_after_destruction_rustc_25ef9e3d85d934b27d9dada2f9dd52b1dc63bb04library_std_src_threadlocal.rs
mov qword [rsp + 0x50], rax
xorps xmm0, xmm0
movups xmmword [rsp + 0x58], xmm0
lea rcx, [rsp + 0x40]
mov rdx, qword [rsp + 0xf0]
call fcn.140003e30
lea rcx, str.assertion_failed:_state_and_queue.addr____STATE_MASK__RUNNINGlibrary_std_src_sys_commononcequeue.rsX_v_
mov edx, 0x40
mov r8, qword [rsp + 0xf0]
call fcn.140004c80
mov rbx, rax
mov edx, 1
push rsi
nop
pop rcx
call fcn.1400173a0
jmp 0x140017397
push rbx
pop rcx
nop
call fcn.140046bd0
int3