Function at 0x140034430
Capabilities:
Set 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 rax, qword [0x14017e028]
xor rax, rsp
mov qword [rsp + 0x40], rax
test rcx, rcx
je 0x1400346c2
mov rsi, rcx
mov byte [rsp + 0x3f], 0xaa
lea r14, [rcx + 0x858]
lea rbx, [rcx + 8]
mov edi, 1
xor ebp, ebp
mov r15, qword [sym.imp.KERNEL32.dll_TryAcquireSRWLockExclusive]
mov r12d, 0x40
mov rcx, rbx
call r15
test al, al
jne 0x1400344b1
mov eax, edi
test edi, edi
jle 0x140034497
pause
dec eax
jne 0x14003448f
add ebp, edi
add edi, edi
cmp edi, 0x40
cmovge edi, r12d
cmp ebp, 0x3e8
jl 0x14003447f
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_AcquireSRWLockExclusive]
mov rax, qword [r14]
mov rdi, qword [rax]
test rdi, rdi
je 0x14003468b
mov byte [rsp + 0x3f], 0
mov rcx, qword [rdi]
test rcx, rcx
je 0x1400344e5
mov rdx, rcx
not rdx
cmp qword [rdi + 8], rdx
jne 0x1400346bd
bswap rcx
prefetcht0 byte [rcx]
jmp 0x1400344e7
xor ecx, ecx
mov qword [rax], rcx
inc word [rax + 0x18]
mov rcx, rbx
call qword [sym.imp.KERNEL32.dll_ReleaseSRWLockExclusive]
lea rax, [rdi + 0x590]
mov rcx, rdi
mov dword [rcx + 8], 0
mov qword [rcx], 0
mov byte [rcx + 9], 0
add rcx, 0x10
cmp rcx, rax
jne 0x140034501
xor r12d, r12d
mov qword [rdi + 0x590], r12
mov byte [rdi + 0x598], 0
lea rbx, [rdi + 0x5a0]
xorps xmm0, xmm0
movups xmmword [rdi + 0x5a0], xmm0
movups xmmword [rdi + 0x5b0], xmm0
movups xmmword [rdi + 0x5c0], xmm0
movups xmmword [rdi + 0x5d0], xmm0
movups xmmword [rdi + 0x5e0], xmm0
mov qword [rdi + 0x5f0], r12
mov qword [rdi + 0x5f8], rsi
movups xmmword [rdi + 0x600], xmm0
mov ebp, 1
lea r14, [0x140181528]
mov r13d, 0x40
mov rcx, r14
call r15
test al, al
jne 0x1400345b9
mov eax, ebp
test ebp, ebp
jle 0x14003459a
pause
dec eax
jne 0x140034591
add r12d, ebp
add ebp, ebp
cmp ebp, 0x40
cmovge ebp, r13d
cmp r12d, 0x3e8
jl 0x140034581
lea rcx, [0x140181528]
call qword [sym.imp.KERNEL32.dll_AcquireSRWLockExclusive]
mov qword [rdi + 0x608], 0
mov rax, qword [0x140181530]
mov qword [0x140181530], rdi
mov qword [rdi + 0x600], rax
test rax, rax
je 0x1400345e5
mov qword [rax + 0x608], rdi
lea rcx, [0x140181528]
call qword [sym.imp.KERNEL32.dll_ReleaseSRWLockExclusive]
xorps xmm0, xmm0
movups xmmword [rbx + 0x40], xmm0
movups xmmword [rbx + 0x30], xmm0
movups xmmword [rbx + 0x20], xmm0
movups xmmword [rbx + 0x10], xmm0
movups xmmword [rbx], xmm0
mov qword [rbx + 0x50], 0
lea rax, [rdi + 0xa]
add rsi, 0x10
xor ecx, ecx
lea rdx, [0x140188320]
mov qword [rax - 0xa], 0
mov byte [rax - 2], 0
mov bl, byte [rcx + rdx]
mov byte [rax - 1], bl
cmp qword [rsi], 0
je 0x140034653
movzx ebp, word [rsi + 0x18]
mov word [rax], bp
inc rcx
add rax, 0x10
add rsi, 0x28
cmp rcx, 0x59
jne 0x140034621
jmp 0x14003465b
mov byte [rax - 1], 0
xor ebp, ebp
jmp 0x14003463d
mov ecx, dword [0x140188314]
mov rdx, rdi
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov rcx, qword [rsp + 0x40]
xor rcx, rsp
call fcn.14008fec0
mov rax, rdi
add rsp, 0x48
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
lea rax, [rsp + 0x3f]
mov qword [rsp + 0x28], rax
mov qword [rsp + 0x20], 0x4000
mov r9d, 0x610
mov rcx, r14
mov rdx, rsi
mov r8d, 2
call fcn.140003120
mov rdi, rax
jmp 0x1400344ee
call fcn.1400bccf0
int3