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

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x104
mov al, byte [0x6f1058]
mov edx, 0x6f1058
mov edi, ecx
xor ecx, ecx
lea ebx, [ebp - 0xa0]
lea esi, [ebp - 0x110]
imul edx, edx, 0x9e3779b9
mov dword [ebp - 0x18], edx
nop
test al, 1
jne 0x552cca
test al, 2
jne 0x5531f8
test al, 4
jne 0x5529fb
mov edx, eax
and dl, 0xf9
or dl, 4
lock cmpxchg byte [0x6f1058], dl
jne 0x5529d0
jmp 0x552ccf
test al, 8
jne 0x552a17
cmp ecx, 9
jbe 0x552b0b
mov edx, eax
or dl, 8
lock cmpxchg byte [0x6f1058], dl
jne 0x5529d0
mov byte [ebp - 0x88], 2
mov eax, dword [0x605024]
test eax, eax
jne 0x552a31
mov ecx, 0x605024
call fcn.005dcc80
push eax
call sub.KERNEL32.dll_TlsGetValue
cmp eax, 1
jbe 0x552a46
cmp byte [eax + 0x18], 2
jne 0x552b2a
mov eax, dword [0x605024]
test eax, eax
jne 0x552a59
mov ecx, 0x605024
call fcn.005dcc80
push eax
call sub.KERNEL32.dll_TlsGetValue
cmp eax, 1
je 0x552b2f
test eax, eax
mov ebx, eax
jne 0x552ac2
mov eax, dword [0x6f1130]
test eax, eax
jne 0x552a89
call sub.KERNEL32.dll_GetProcessHeap
test eax, eax
je 0x553280
mov dword [0x6f1130], eax
push 0x20
push 0
push eax
call sub.KERNEL32.dll_HeapAlloc
test eax, eax
je 0x553280
mov byte [eax + 0x18], 2
mov dword [eax + 0x1c], 0x605024
mov ebx, eax
mov eax, dword [0x605024]
test eax, eax
jne 0x552abb
mov ecx, 0x605024
call fcn.005dcc80
push ebx
push eax
call sub.KERNEL32.dll_TlsSetValue
mov ecx, esi
call fcn.00553350
movsd xmm0, qword [ebp - 0x110]
movsd xmm1, qword [ebp - 0x108]
mov al, byte [ebx + 0x18]
mov dword [ebp - 0x10], ebx
movsd qword [ebx], xmm0
movsd qword [ebx + 8], xmm1
cmp al, 2
movsd xmm0, qword [ebp - 0x100]
movsd qword [ebx + 0x10], xmm0
mov ecx, dword [ebp - 0xf8]
mov dword [ebx + 0x18], ecx
je 0x552b39
lock dec dword [0x6f1084]
jmp 0x552b39
lea ebx, [ecx + 1]
cmp ecx, 3
jae 0x552c24
mov eax, 1
mov ecx, ebx
shl eax, cl
pause
dec eax
jne 0x552b20
jmp 0x552cb8
mov dword [ebp - 0x10], eax
jmp 0x552b39
mov ecx, ebx
call fcn.00553350
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0x1c], edi
nop dword [eax]
mov edi, dword [0x6f1088]
test edi, edi
je 0x552b9f
movzx eax, byte [edi + 8]
mov ebx, dword [ebp - 0x18]
mov edx, dword [edi + 4]
xor ecx, ecx
sub cl, al
shr ebx, cl
cmp ebx, edx
jae 0x5531e7
mov esi, dword [edi]
shl ebx, 6
xor eax, eax
mov ecx, 1
lock cmpxchg dword [esi + ebx + 0x18], ecx
lea edx, [esi + ebx + 0x18]
jne 0x552ba8
mov eax, dword [0x6f1088]
cmp edi, eax
je 0x552bbe
mov eax, 0xffffffff
lock xadd dword [edx], eax
cmp eax, 4
jb 0x552b40
and eax, 2
jne 0x552b40
mov ecx, edx
call fcn.00553ba0
jmp 0x552b40
call fcn.00553580
mov edi, eax
jmp 0x552b4a
mov ecx, edx
mov dword [ebp - 0x20], edx
call fcn.00553a40
mov edx, dword [ebp - 0x20]
mov eax, dword [0x6f1088]
cmp edi, eax
jne 0x552b83
mov al, byte [0x6f1058]
cmp al, 0xc
jne 0x552bfa
mov ecx, dword [ebp - 0x10]
mov eax, 0x6f1058
mov byte [ecx + 0x18], 0
mov dword [ecx + 0xc], 0
mov dword [ecx + 8], eax
mov dword [ecx + 0x14], 0
mov dword [ecx], 1
cmp dword [esi + ebx + 0x1c], 0
je 0x552c30
mov eax, dword [esi + ebx + 0x20]
add eax, 0xc
jmp 0x552c34
mov eax, 0xffffffff
lea edi, [ebp - 0x110]
lock xadd dword [edx], eax
cmp eax, 4
jb 0x552ca1
and eax, 2
jne 0x552ca1
mov ecx, edx
call fcn.00553ba0
jmp 0x552ca1
push 0
call sub.KERNEL32.dll_Sleep
jmp 0x552cb8
lea eax, [esi + ebx + 0x1c]
mov ecx, dword [ebp - 0x10]
mov dword [eax], ecx
mov dword [esi + ebx + 0x20], ecx
mov eax, 0xffffffff
mov ebx, ecx
lock xadd dword [edx], eax
cmp eax, 4
jb 0x552c52
and eax, 2
je 0x552c81
mov esi, dword [ebx + 4]
lea edi, [ebp - 0x110]
cmp dword [esi], 1
jne 0x552c96
mov eax, dword [ebx]
test eax, eax
je 0x552ca1
mov dword [ebp - 0x110], 1
push 0xffffffffffffffff
push 4
push edi
push ebx
call dword [esi + 4]
mov eax, dword [ebx]
test eax, eax
jne 0x552c66
jmp 0x552ca1
mov ecx, edx
call fcn.00553ba0
mov esi, dword [ebx + 4]
lea edi, [ebp - 0x110]
cmp dword [esi], 1
je 0x552c60
push 0
push 0
push ebx
push dword [esi + 4]
call dword [esi + 0xc]
cmp byte [ebp - 0x88], 2
mov esi, edi
je 0x552cb3
lock dec dword [0x6f1084]
mov edi, dword [ebp - 0x1c]
xor ebx, ebx
mov al, byte [0x6f1058]
mov ecx, ebx
lea ebx, [ebp - 0xa0]
jmp 0x5529d0
jmp 0x5531c1
mov ecx, dword [edi]
xor edx, edx
call fcn.00465d50
mov al, 1
xchg byte [0x6f1058], al
test al, 8
je 0x5531c1
mov eax, 0x6f1058
imul eax, eax, 0x9e3779b9
mov dword [ebp - 0x18], eax
nop word cs:[eax + eax]
mov ebx, dword [0x6f1088]
test ebx, ebx
je 0x552d5a
mov esi, dword [ebp - 0x18]
mov edx, dword [ebx + 4]
xor ecx, ecx
sub cl, byte [ebx + 8]
shr esi, cl
cmp esi, edx
jae 0x5531d6
mov edi, dword [ebx]
shl esi, 6
xor eax, eax
mov edx, 1
lock cmpxchg dword [edi + esi + 0x18], edx
lea ecx, [edi + esi + 0x18]
jne 0x552d63
mov eax, dword [0x6f1088]
cmp ebx, eax
je 0x552d7a
mov eax, 0xffffffff
lock xadd dword [ecx], eax
cmp eax, 4
jb 0x552d00
and eax, 2
jne 0x552d00
call fcn.00553ba0
jmp 0x552d00
call fcn.00553580
mov ebx, eax
jmp 0x552d0a
mov dword [ebp - 0x10], ecx
mov ecx, dword [ebp - 0x10]
call fcn.00553a40
mov ecx, dword [ebp - 0x10]
mov eax, dword [0x6f1088]
cmp ebx, eax
jne 0x552d40
mov ebx, dword [edi + esi + 0x1c]
mov dword [ebp - 0xa0], 0
mov dword [ebp - 0x9c], 0
test ebx, ebx
je 0x55305b
lea eax, [edi + esi + 0x1c]
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x10], ecx
mov edi, eax
mov dword [ebp - 0x30], eax
jmp 0x552dc0
lea edi, [ebx + 0xc]
mov dword [ebp - 0x2c], ebx
test esi, esi
mov ebx, esi
je 0x55305b
mov eax, dword [ebx + 8]
mov esi, dword [ebx + 0xc]
cmp eax, 0x6f1058
jne 0x552db0
mov eax, dword [ebp - 0x30]
mov dword [edi], esi
cmp dword [eax + 4], ebx
jne 0x552de0
mov eax, dword [ebp - 0x30]
mov edx, dword [ebp - 0x2c]
mov dword [eax + 4], edx
mov dword [ebx + 0x10], 0
mov dword [ebp - 0x18], edi
mov eax, dword [ebx + 4]
cmp dword [eax], 1
mov dword [ebp - 0x20], eax
jne 0x552e30
mov dword [ebx], 0
mov dword [ebp - 0x1c], 1
mov edi, dword [ebp - 0xa0]
cmp edi, 9
jae 0x552e4e
cmp edi, 8
jne 0x552ea1
mov ecx, 8
mov eax, edi
cmp ecx, eax
je 0x552e68
jmp 0x553020
xor eax, eax
xor edx, edx
xchg dword [ebx], eax
mov dword [ebp - 0x1c], 0
cmp eax, 1
cmovne ebx, edx
mov edi, dword [ebp - 0xa0]
cmp edi, 9
jb 0x552e0d
mov eax, dword [ebp - 0x94]
cmp eax, edi
jne 0x552eb4
mov eax, dword [ebp - 0x94]
mov ecx, edi
cmp ecx, eax
jne 0x553020
inc eax
je 0x553254
xor edx, edx
cmp eax, 2
jb 0x552e84
dec eax
mov edx, 0xffffffff
bsr ecx, eax
xor ecx, 0x1f
shr edx, cl
inc edx
je 0x553254
cmp edi, 9
jb 0x552ebf
mov eax, dword [ebp - 0x98]
mov ecx, dword [ebp - 0x94]
mov dword [ebp - 0x14], edi
jmp 0x552ece
mov eax, edi
lea edx, [ebp - 0xa0]
lea ecx, [ebp - 0x98]
jmp 0x553032
mov ecx, dword [ebp - 0x98]
jmp 0x55302c
mov dword [ebp - 0x14], 8
mov ecx, edi
lea eax, [ebp - 0x98]
cmp ecx, edx
ja 0x5531ff
cmp edx, 8
jbe 0x552f4b
cmp dword [ebp - 0x14], edx
je 0x553020
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], ecx
mov eax, edx
mov ecx, 0xc
mov dword [ebp - 0x38], edx
mul ecx
jo 0x553254
mov ecx, eax
cmp edi, 9
jb 0x552fa7
mov eax, dword [ebp - 0x14]
mov edi, ecx
mov ecx, 0xc
mul ecx
mov edx, eax
mov eax, 0
seto cl
setno al
shl eax, 2
test cl, cl
jne 0x55324e
mov ecx, dword [ebp - 0x28]
mov dword [ebp - 0x14], edi
push edi
push eax
call fcn.00404ad0
add esp, 8
mov edi, dword [ebp - 0x24]
test eax, eax
jne 0x552ff9
jmp 0x55326d
cmp edi, 9
jb 0x553020
mov edi, eax
lea eax, [ecx*4]
mov dword [ebp - 0x9c], 0
lea eax, [eax + eax*2]
push eax
push edi
lea eax, [ebp - 0x98]
push eax
mov dword [ebp - 0x24], ecx
call sub.msvcrt.dll_memcpy
add esp, 0xc
mov eax, dword [ebp - 0x24]
mov ecx, 0xc
mov dword [ebp - 0xa0], eax
mov eax, dword [ebp - 0x14]
mul ecx
jo 0x553210
push edi
push 0
push dword [0x6f1130]
call sub.KERNEL32.dll_HeapFree
jmp 0x553020
mov eax, dword [0x6f1130]
test eax, eax
jne 0x552fc6
mov edi, ecx
call sub.KERNEL32.dll_GetProcessHeap
test eax, eax
je 0x553245
mov ecx, edi
mov dword [0x6f1130], eax
push ecx
push 0
push eax
mov edi, ecx
call sub.KERNEL32.dll_HeapAlloc
test eax, eax
je 0x553245
mov edi, dword [ebp - 0x24]
lea ecx, [edi*4]
lea ecx, [ecx + ecx*2]
push ecx
push dword [ebp - 0x28]
push eax
mov dword [ebp - 0x14], eax
call sub.msvcrt.dll_memcpy
mov eax, dword [ebp - 0x14]
add esp, 0xc
mov ecx, dword [ebp - 0x38]
mov dword [ebp - 0x9c], 1
mov dword [ebp - 0x98], eax
mov dword [ebp - 0x94], edi
mov dword [ebp - 0xa0], ecx
nop dword [eax + eax]
mov ecx, dword [ebp - 0x98]
mov eax, dword [ebp - 0x94]
lea edx, [ebp - 0x94]
mov edi, dword [ebp - 0x1c]
lea eax, [eax + eax*2]
mov dword [ecx + eax*4], edi
mov edi, dword [ebp - 0x20]
mov dword [ecx + eax*4 + 4], ebx
add edi, 4
mov dword [ecx + eax*4 + 8], edi
mov ecx, dword [ebp - 0x10]
mov edi, dword [ebp - 0x18]
inc dword [edx]
test esi, esi
mov ebx, esi
jne 0x552dc0
mov eax, 0xffffffff
lock xadd dword [ecx], eax
cmp eax, 4
jb 0x553072
and eax, 2
je 0x5531cc
mov ebx, dword [ebp - 0xa0]
mov ecx, dword [ebp - 0x94]
lea edx, [ebp - 0x110]
mov edi, dword [ebp - 0x98]
mov eax, dword [ebp - 0x9c]
lea esi, [ebp - 0x90]
cmp ebx, 9
mov dword [ebp - 0x110], ebx
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x18], edi
cmovae ebx, ecx
lea ecx, [ebp - 0x34]
cmovae edx, ecx
mov dword [edx], 0
mov edx, ebx
mov ecx, dword [ebp - 0x34]
mov ebx, dword [ebp - 0x110]
mov dword [ebp - 0x10c], eax
mov dword [ebp - 0x108], edi
lea edi, [ebp - 0x100]
test edx, edx
mov dword [ebp - 0x104], ecx
mov ecx, 0x16
rep movsd dword es:[edi], dword [esi]
mov dword [ebp - 0xa8], 0
mov dword [ebp - 0xa4], edx
je 0x553163
mov dword [ebp - 0x1c], edx
neg edx
mov edi, 8
mov esi, 1
mov dword [ebp - 0x20], edx
jmp 0x553124
push ecx
call dword [eax + 4]
mov eax, dword [ebp - 0x20]
add edi, 0xc
lea eax, [eax + esi + 1]
inc esi
cmp eax, 1
je 0x55315c
cmp ebx, 9
lea eax, [ebp - 0x108]
mov dword [ebp - 0xa8], esi
cmovae eax, dword [ebp - 0x18]
mov edx, dword [eax + edi - 8]
mov ecx, dword [eax + edi - 4]
mov eax, dword [eax + edi]
cmp edx, 1
je 0x553110
cmp edx, 2
je 0x553167
test ecx, ecx
je 0x553114
push 0
push 0
push ecx
push dword [eax]
call dword [eax + 4]
jmp 0x553114
mov edx, dword [ebp - 0x1c]
mov esi, edx
jmp 0x55316a
xor esi, esi
jmp 0x55316a
mov edx, dword [ebp - 0x1c]
mov edi, dword [ebp - 0x18]
lea ecx, [esi*4]
neg edx
inc esi
lea ecx, [ecx + ecx*2]
mov eax, edx
nop dword [eax]
lea edx, [eax + esi]
cmp edx, 1
je 0x5531a4
cmp ebx, 9
lea edx, [ebp - 0x108]
mov dword [ebp - 0xa8], esi
cmovae edx, edi
inc esi
cmp dword [edx + ecx], 2
lea ecx, [ecx + 0xc]
jne 0x553180
cmp ebx, 9
jb 0x5531c1
shl ebx, 2
lea eax, [ebx + ebx*2]
test eax, eax
je 0x5531c1
push edi
push 0
push dword [0x6f1130]
call sub.KERNEL32.dll_HeapFree
add esp, 0x104
pop esi
pop edi
pop ebx
pop ebp
ret
call fcn.00553ba0
jmp 0x553072
mov ecx, esi
push 0x6886e8
call fcn.0045a150
add esp, 4
ud2
mov ecx, ebx
push 0x6886e8
call fcn.0045a150
add esp, 4
ud2
call fcn.005532a0
ud2
mov ecx, str.assertion_failed:_new_cap___len_
mov edx, 0x20
push 0x6d10b0
jmp 0x553263
mov dword [ebp - 0x110], eax
mov dword [ebp - 0x10c], 0
mov ecx, str.called__Result::unwrap____on_an__Err__value
mov edx, 0x2b
push 0x6d1070
push 0x6886c4
lea eax, [ebp - 0x110]
push eax
call fcn.0045d480
add esp, 0xc
ud2
mov eax, 4
mov edx, edi
jmp 0x553275
test eax, eax
mov ecx, eax
jne 0x553275
mov ecx, str.capacity_overflow
mov edx, 0x11
push 0x6d1080
call fcn.0045aec0
add esp, 4
ud2
mov edx, dword [ebp - 0x14]
mov eax, 4
mov ecx, edx
mov edx, eax
call fcn.0040a640
ud2
mov ecx, 0x20
mov edx, 4
call fcn.0040a640
ud2