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

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
lea rbp, [rsp - 0x60]
sub rsp, 0x160
mov qword [rbp - 0x30], 0xfffffffffffffffe
mov qword [rsp + 0x1a0], rbx
mov rax, qword [0x1801fdc38]
xor rax, rsp
mov qword [rbp + 0x58], rax
mov r12, rdx
mov r13, rcx
mov qword [rsp + 0x50], rdx
mov ecx, dword [0x180205148]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
mov dword [rsp + 0x38], eax
lea edx, [rax + 1]
mov ecx, dword [0x180205148]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov ecx, dword [0x180209190]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rsi, rax
mov dword [rsp + 0x3c], eax
lea edx, [rax + 1]
mov ecx, dword [0x180209190]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
nop
lea ecx, [rsi + rdi]
test ecx, ecx
je 0x18007451e
jmp 0x1800747c6
cmp r12, 0xffffffffffffffff
je 0x1800747c6
test r12, r12
je 0x1800747c6
mov r8, r12
lea rdx, [rbp + 8]
mov rcx, r13
call fcn.18005b4d0
nop
lea rax, [0x18019bef0]
mov qword [rsp + 0x40], rax
lea rax, [0x18019bef2]
mov qword [rsp + 0x48], rax
lea r11, [0x18017fd18]
mov qword [rsp + 0x58], r11
lea r10, [0x18017fd1a]
mov qword [rsp + 0x60], r10
lea rcx, [rbp + 8]
mov r9, qword [rbp + 8]
mov r8, qword [rbp + 0x20]
cmp r8, 8
cmovae rcx, r9
mov rax, qword [rbp + 0x18]
lea rcx, [rcx + rax*2]
lea rdx, [rbp + 8]
cmovae rdx, r9
cmp rdx, rcx
je 0x180074625
mov rax, rdx
mov r9, r11
cmp r9, r10
je 0x1800745cb
movzx r8d, word [r9]
cmp word [rax], r8w
jne 0x1800745c0
add rax, 2
add r9, 2
cmp rax, rcx
jne 0x1800745a4
cmp r9, r10
je 0x1800745cb
add rdx, 2
jmp 0x180074595
cmp rdx, rax
je 0x180074625
movaps xmm1, xmmword [rsp + 0x40]
movdqa xmmword [rbp - 0x70], xmm1
mov qword [rsp + 0x70], rdx
mov qword [rsp + 0x78], rax
movaps xmm0, xmmword [rsp + 0x70]
movdqa xmmword [rbp - 0x40], xmm0
movdqa xmmword [rbp - 0x20], xmm1
movups xmm0, xmmword [rsp + 0x58]
movaps xmmword [rbp - 0x60], xmm0
movsd xmm1, qword [rsp + 0x68]
movsd qword [rbp - 0x50], xmm1
lea rax, [rbp - 0x70]
mov qword [rsp + 0x20], rax
lea r9, [rbp - 0x40]
lea r8, [rbp - 0x20]
lea rdx, [rbp - 0x60]
lea rcx, [rbp + 8]
call fcn.1800607d0
lea rdx, [rbp + 0x30]
mov rcx, qword [r13 + 0x50]
call fcn.18005b4a0
lea rdx, [rbp + 8]
cmp qword [rbp + 0x20], 8
cmovae rdx, qword [rbp + 8]
cmp qword [rax + 0x18], 8
jb 0x18007464a
mov rax, qword [rax]
mov rcx, rax
call fcn.180119d18
test eax, eax
sete bl
cmp qword [rbp + 0x48], 8
jb 0x180074667
mov rcx, qword [rbp + 0x30]
call fcn.1801196dc
test bl, bl
je 0x1800747b5
lea r8, [rbp + 8]
cmp qword [rbp + 0x20], 8
cmovae r8, qword [rbp + 8]
lea rdx, str.Opening_file__s
lea rcx, [rsp + 0x30]
call fcn.180058060
mov r9b, 1
mov r8, r12
lea rdx, [rbp - 0x80]
mov rcx, qword [r13 + 0x50]
call fcn.180074310
nop
lea r12, [r13 + 0x18]
mov qword [rsp + 0x40], r12
call qword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
mov ebx, eax
mov ecx, dword [r12 + 4]
cmp ecx, eax
jne 0x1800746c5
mov rdi, qword [rsp + 0x40]
inc dword [rdi]
jmp 0x1800746e3
mov rcx, qword [rsp + 0x40]
add rcx, 8
call fcn.180035b50
xchg dword [r12 + 4], ebx
mov rdi, qword [rsp + 0x40]
mov dword [rdi], 1
mov byte [rsp + 0x48], 1
lea r8, [rbp - 0x80]
lea rdx, [rsp + 0x50]
lea rcx, [rbp - 0x10]
call fcn.18005a9f0
nop
mov rdx, rax
lea rcx, [r13 + 0x30]
call fcn.18005d970
mov r8, rax
xor r9d, r9d
lea rdx, [rsp + 0x58]
lea rcx, [r13 + 0x30]
call fcn.18005d240
nop
mov rbx, qword [rbp]
test rbx, rbx
je 0x180074747
lock dec dword [rbx + 8]
jne 0x180074742
mov rax, qword [rbx]
mov rcx, rbx
call qword [rax]
lock dec dword [rbx + 0xc]
jne 0x180074742
mov rax, qword [rbx]
mov rcx, rbx
call qword [rax + 8]
mov rdi, qword [rsp + 0x40]
dec dword [rdi]
jne 0x180074787
xor eax, eax
xchg dword [r12 + 4], eax
mov rcx, qword [rsp + 0x40]
add rcx, 8
mov eax, 0x80000000
lock xadd dword [rcx], eax
bt eax, 0x1e
jb 0x180074787
cmp eax, 0x80000000
jle 0x180074787
lock bts dword [rcx], 0x1e
jb 0x180074787
call fcn.180035ad0
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_SetEvent]
nop
mov rbx, qword [rbp - 0x78]
test rbx, rbx
je 0x1800747ad
lock dec dword [rbx + 8]
jne 0x1800747ad
mov rax, qword [rbx]
mov rcx, rbx
call qword [rax]
lock dec dword [rbx + 0xc]
jne 0x1800747ad
mov rax, qword [rbx]
mov rcx, rbx
call qword [rax + 8]
mov edi, dword [rsp + 0x38]
mov esi, dword [rsp + 0x3c]
cmp qword [rbp + 0x20], 8
jb 0x1800747c6
mov rcx, qword [rbp + 8]
call fcn.1801196dc
nop
mov edx, esi
mov ecx, dword [0x180209190]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov edx, edi
mov ecx, dword [0x180205148]
call qword [sym.imp.KERNEL32.dll_TlsSetValue]
mov rcx, qword [rbp + 0x58]
xor rcx, rsp
call fcn.180119820
mov rbx, qword [rsp + 0x1a0]
add rsp, 0x160
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret