Function at 0x1000cf50
Capabilities:
Get thread local storage value
Resolve function by parsing pe exports
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x9bc
push ebx
push esi
mov ebx, edx
mov dword [esp + 0xc], ecx
push edi
mov dword [esp + 0x24], ebx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push dword [0x10056a08]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
push esi
mov edi, eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
test edi, edi
jne 0x1000d336
mov ecx, 0x950
call fcn.10033a20
mov esi, eax
mov dword [esp + 0x20], esi
test esi, esi
je 0x1000da68
xorps xmm0, xmm0
mov byte [esi], 0
xor eax, eax
movlpd qword [esp + 0x88], xmm0
movlpd qword [esp + 0x90], xmm0
movlpd qword [esp + 0x98], xmm0
movlpd qword [esp + 0xa0], xmm0
movlpd qword [esp + 0xa8], xmm0
movlpd qword [esp + 0xb0], xmm0
movlpd qword [esp + 0xb8], xmm0
movlpd qword [esp + 0xc0], xmm0
movlpd qword [esp + 0xc8], xmm0
movlpd qword [esp + 0xd0], xmm0
movlpd qword [esp + 0xd8], xmm0
movlpd qword [esp + 0xe0], xmm0
movlpd qword [esp + 0xf0], xmm0
movlpd qword [esp + 0xf8], xmm0
movlpd qword [esp + 0x100], xmm0
movaps xmm0, xmmword [0x1004e200]
push 0x8c
push eax
mov word [esp + 0x145], ax
mov byte [esp + 0x147], al
mov dword [esp + 0x148], eax
mov dword [esp + 0x14c], eax
mov byte [esp + 0x150], al
mov dword [esp + 0x168], eax
mov dword [esp + 0x16c], eax
mov dword [esp + 0x170], eax
mov dword [esp + 0x174], eax
lea eax, [esp + 0x178]
movups xmmword [esp + 0x110], xmm0
mov word [esp + 0x88], di
xorps xmm0, xmm0
mov byte [esp + 0x8a], 0
push eax
mov dword [esp + 0xf4], edi
mov word [esp + 0x124], 0xffff
movups xmmword [esp + 0x126], xmm0
mov word [esp + 0x146], di
movups xmmword [esp + 0x136], xmm0
mov byte [esp + 0x148], 0
movlpd qword [esp + 0x15c], xmm0
movlpd qword [esp + 0x164], xmm0
call fcn.10036180
add esp, 0xc
mov dword [esp + 0x1fc], 1
mov dword [esp + 0x200], edi
mov dword [esp + 0x204], 1
mov dword [esp + 0x208], edi
mov dword [esp + 0x20c], 1
mov dword [esp + 0x210], edi
mov dword [esp + 0x214], 1
mov dword [esp + 0x218], edi
mov dword [esp + 0x21c], 1
mov dword [esp + 0x220], edi
mov dword [esp + 0x224], 1
mov dword [esp + 0x228], edi
mov dword [esp + 0x22c], 1
mov dword [esp + 0x230], edi
mov dword [esp + 0x234], 1
mov dword [esp + 0x238], edi
mov dword [esp + 0x23c], 1
mov dword [esp + 0x240], edi
mov dword [esp + 0x244], 1
mov dword [esp + 0x248], edi
mov dword [esp + 0x24c], 1
mov dword [esp + 0x250], edi
mov dword [esp + 0x254], 1
mov dword [esp + 0x258], edi
mov dword [esp + 0x25c], 1
mov dword [esp + 0x260], edi
mov dword [esp + 0x264], 1
mov dword [esp + 0x268], edi
mov dword [esp + 0x26c], 1
mov dword [esp + 0x270], edi
mov dword [esp + 0x274], 1
mov dword [esp + 0x278], edi
mov dword [esp + 0x27c], 1
mov dword [esp + 0x280], edi
mov dword [esp + 0x284], 1
xor eax, eax
mov dword [esp + 0x288], edi
push 0x6d8
xorps xmm0, xmm0
mov word [esp + 0x2c1], ax
push eax
mov byte [esp + 0x2c7], al
mov dword [esp + 0x2e8], eax
lea eax, [esp + 0x2f0]
push eax
mov dword [esp + 0x298], 1
mov dword [esp + 0x29c], edi
mov dword [esp + 0x2a0], 1
mov dword [esp + 0x2a4], edi
mov dword [esp + 0x2a8], 1
mov dword [esp + 0x2ac], edi
mov dword [esp + 0x2b0], 1
mov dword [esp + 0x2b4], edi
mov dword [esp + 0x2b8], 1
mov dword [esp + 0x2bc], edi
mov dword [esp + 0x2c0], 1
mov dword [esp + 0x2c4], edi
mov byte [esp + 0x2c8], 6
movlpd qword [esp + 0x2cc], xmm0
movlpd qword [esp + 0x2d4], xmm0
movlpd qword [esp + 0x2dc], xmm0
movlpd qword [esp + 0x2e4], xmm0
call fcn.10036180
mov dword [esp + 0x9cc], edi
add esp, 0xc
lea edi, [esi + 8]
mov byte [esp + 0x9c4], 0
mov ecx, 0x252
lea esi, [esp + 0x80]
rep movsd dword es:[edi], dword [esi]
mov edi, dword [esp + 0x20]
push edi
push dword [0x10056a08]
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
test eax, eax
je 0x1000da77
add edi, 8
mov dword [esp + 0x28], edi
cmp byte [edi + 0x23c], 0
je 0x1000d355
mov dl, 1
mov ecx, edi
call fcn.10032cd0
mov edi, eax
mov dword [esp + 0x28], eax
mov al, byte [edi + 0x23c]
mov esi, 1
mov ecx, dword [ebp + 8]
mov byte [esp + 0x1f], al
and ecx, 0x3f
mov eax, esi
shl eax, cl
and eax, 0xfffffffe
mov dword [esp + 0x20], eax
jne 0x1000d3d0
cmp ebx, 0x1000
ja 0x1000d398
lea eax, [ebx + 7]
shr eax, 3
movzx eax, byte [eax + 0x10056040]
mov ebx, dword [eax*4 + 0x10055e80]
jmp 0x1000d4b1
cmp ebx, 0x70000000
ja 0x1000d4af
lea ecx, [ebx*2 - 1]
call fcn.10001000
mov ecx, 4
cmp eax, 7
jb 0x1000d3bd
lea ecx, [eax - 3]
shl esi, cl
dec esi
lea eax, [ebx + esi]
not esi
and eax, esi
mov dword [esp + 0x18], eax
jmp 0x1000d4b5
cmp ebx, 0x3800
ja 0x1000d442
cmp eax, 0x1000
ja 0x1000d442
dec ebx
add ebx, eax
neg eax
and ebx, eax
cmp ebx, 0x1000
ja 0x1000d404
lea eax, [ebx + 7]
shr eax, 3
movzx eax, byte [eax + 0x10056040]
mov ecx, dword [eax*4 + 0x10055e80]
jmp 0x1000d434
cmp ebx, 0x70000000
jbe 0x1000d410
xor ecx, ecx
jmp 0x1000d434
lea ecx, [ebx*2 - 1]
call fcn.10001000
mov ecx, 4
cmp eax, 7
jb 0x1000d429
lea ecx, [eax - 3]
shl esi, cl
lea ecx, [ebx - 1]
add ecx, esi
neg esi
and ecx, esi
mov dword [esp + 0x18], ecx
cmp ecx, 0x4000
jae 0x1000d451
jmp 0x1000d4b5
cmp eax, 0x70000000
ja 0x1000d4af
cmp ebx, 0x4000
ja 0x1000d458
mov ecx, 0x4000
jmp 0x1000d487
cmp ebx, 0x70000000
ja 0x1000d4af
lea ecx, [ebx*2 - 1]
call fcn.10001000
mov ecx, 4
cmp eax, 7
jb 0x1000d479
lea ecx, [eax - 3]
shl esi, cl
dec esi
lea ecx, [esi + ebx]
not esi
and ecx, esi
cmp ecx, ebx
jb 0x1000d4af
mov eax, dword [esp + 0x20]
xor edx, edx
add eax, 0xfff
and eax, 0xfffff000
add eax, 0xfffff000
add eax, dword [0x10056a18]
add eax, ecx
cmp eax, ecx
cmovb ecx, edx
mov dword [esp + 0x18], ecx
jmp 0x1000d4b5
xor ebx, ebx
mov dword [esp + 0x18], ebx
mov edx, dword [ebp + 8]
mov eax, edx
and eax, 0xfff00
je 0x1000d51f
cmp eax, 0x100
je 0x1000d50c
mov ecx, edx
shr ecx, 8
and ecx, 0xfff
sub ecx, 2
cmp ecx, 0xfffffffe
je 0x1000d51f
cmp ecx, 0xffffffff
je 0x1000d50c
mov eax, dword [0x10056a14]
mov esi, dword [eax + ecx*4]
lea ebx, [eax + ecx*4]
mov dword [esp + 0x14], esi
test esi, esi
je 0x1000da86
cmp esi, 1
jne 0x1000d512
mov ecx, edi
call fcn.10031c90
mov edx, dword [ebp + 8]
mov esi, eax
mov dword [ebx], esi
jmp 0x1000d50e
xor esi, esi
mov dword [esp + 0x14], esi
cmp byte [esp + 0x1f], 0
jne 0x1000d7cc
jmp 0x1000d534
cmp byte [esp + 0x1f], 0
jne 0x1000d7af
lea esi, [edi + 0x260]
mov dword [esp + 0x14], esi
mov ebx, dword [esp + 0x18]
cmp ebx, 0x1000
jbe 0x1000d547
mov ecx, ebx
call fcn.10001010
lea ecx, [edi + 0x940]
mov edx, 0xe
push 0
call fcn.100010c0
add esp, 4
test esi, esi
jne 0x1000d574
mov edx, dword [esp + 0x10]
mov ecx, edi
push ebx
call fcn.100016d0
add esp, 4
jmp 0x1000d739
cmp ebx, 0x1000
ja 0x1000d58f
lea eax, [ebx + 7]
shr eax, 3
movzx ebx, byte [eax + 0x10056040]
mov dword [esp + 0x20], ebx
jmp 0x1000d59c
mov ecx, ebx
call fcn.10001010
mov ebx, eax
mov dword [esp + 0x20], eax
cmp ebx, 0x24
jae 0x1000d660
lea ecx, [ebx*2 + 1]
add ecx, ebx
mov ax, word [esi + ecx*8]
lea ecx, [esi + ecx*8]
mov dword [esp + 0x24], ecx
cmp ax, word [ecx + 0x12]
je 0x1000d5e1
mov eax, dword [ecx]
mov edx, dword [esp + 0x10]
sub eax, 4
mov dword [ecx], eax
mov dword [eax], edx
movzx eax, word [ecx]
mov dx, word [ecx + 0x12]
push eax
call fcn.100010c0
add esp, 4
jmp 0x1000d739
mov esi, dword [esi]
call fcn.100010a0
mov ecx, esi
mov bl, al
call fcn.10001610
test bl, bl
je 0x1000d605
mov edx, dword [esp + 0x10]
mov ecx, edi
call fcn.10011700
jmp 0x1000d739
mov esi, dword [esp + 0x24]
mov ecx, esi
call fcn.100010b0
mov cl, byte [0x10050988]
mov edx, dword [esp + 0x14]
movzx eax, ax
shr eax, cl
mov ecx, edi
push eax
push dword [esp + 0x24]
push esi
call fcn.10030e60
mov ax, word [esi]
add esp, 0xc
cmp ax, word [esi + 0x12]
je 0x1000d739
mov eax, dword [esi]
mov ecx, esi
mov edx, dword [esp + 0x10]
sub eax, 4
mov dword [esi], eax
mov dword [eax], edx
movzx eax, word [esi]
mov dx, word [esi + 0x12]
push eax
call fcn.100010c0
add esp, 4
jmp 0x1000d739
mov ecx, dword [esi]
call fcn.10001610
cmp ebx, eax
jae 0x1000d710
mov ecx, dword [esp + 0x14]
lea eax, [ebx + ebx*2]
mov esi, dword [esi]
lea ecx, [ecx + eax*8]
add ecx, 8
mov dword [esp + 0x24], ecx
call fcn.100010a0
mov ecx, esi
mov bl, al
call fcn.10001610
test bl, bl
jne 0x1000d710
mov ebx, dword [esp + 0x24]
mov ecx, ebx
mov ax, word [ebx]
cmp ax, word [ebx + 0x12]
je 0x1000d6c2
mov eax, dword [ebx]
mov edx, dword [esp + 0x10]
sub eax, 4
mov dword [ebx], eax
mov dword [eax], edx
movzx eax, word [ebx]
mov dx, word [ebx + 0x12]
push eax
call fcn.100010c0
add esp, 4
jmp 0x1000d739
call fcn.100010b0
mov cl, byte [0x10050984]
mov edx, dword [esp + 0x14]
movzx eax, ax
shr eax, cl
mov ecx, edi
push eax
push dword [esp + 0x24]
push ebx
call fcn.10031160
mov ax, word [ebx]
add esp, 0xc
cmp ax, word [ebx + 0x12]
je 0x1000d739
mov eax, dword [ebx]
mov ecx, ebx
mov edx, dword [esp + 0x10]
sub eax, 4
mov dword [ebx], eax
mov dword [eax], edx
movzx eax, word [ebx]
mov dx, word [ebx + 0x12]
push eax
call fcn.100010c0
add esp, 4
jmp 0x1000d739
mov edx, dword [esp + 0x10]
lea eax, [edi + 0x17c]
push edx
push eax
lea eax, [esp + 0x68]
mov edx, 0x10057260
push eax
mov ecx, edi
call fcn.10001100
add esp, 0xc
mov ecx, edi
mov edx, dword [eax]
call fcn.10027a90
mov ecx, dword [esp + 0x28]
add edi, 0x250
mov ebx, dword [esp + 0x18]
mov byte [esp + 0x2c], 0
mov dword [esp + 0x30], edi
lea eax, [ecx + 0x18]
mov dword [esp + 0x34], eax
lea eax, [ecx + 0x20]
mov dword [esp + 0x38], eax
lea eax, [ecx + 0x258]
mov dword [esp + 0x3c], eax
mov ecx, ebx
mov edx, dword [edi]
xor eax, eax
mov esi, dword [edi + 4]
add ecx, edx
mov dword [edi], ecx
adc eax, esi
mov dword [edi + 4], eax
mov eax, dword [esp + 0x38]
mov ecx, dword [eax]
mov eax, dword [eax + 4]
sub ecx, edx
sbb eax, esi
xor edx, edx
cmp edx, eax
jb 0x1000da61
ja 0x1000d79b
cmp ebx, ecx
jb 0x1000da61
mov ecx, dword [esp + 0x28]
lea edx, [esp + 0x2c]
call fcn.10032540
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp byte [edi + 1], 0
je 0x1000d7b9
xor esi, esi
jmp 0x1000d7c8
cmp byte [edi], 0
jne 0x1000d7c2
xor esi, esi
jmp 0x1000d7c8
lea esi, [edi + 0x260]
mov dword [esp + 0x14], esi
mov ecx, dword [esp + 0x24]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x58], ecx
lea ecx, [esp + 0x54]
mov dword [esp + 0x5c], edx
mov edx, eax
push ecx
mov ecx, 2
mov dword [esp + 0x58], eax
call fcn.10024930
mov ebx, dword [esp + 0x1c]
add esp, 4
cmp ebx, 0x1000
jbe 0x1000d807
mov ecx, ebx
call fcn.10001010
lea ecx, [edi + 0x940]
mov edx, 0xe
push 0
call fcn.100010c0
add esp, 4
test esi, esi
jne 0x1000d834
mov edx, dword [esp + 0x10]
mov ecx, edi
push ebx
call fcn.100016d0
add esp, 4
jmp 0x1000d9f9
cmp ebx, 0x1000
ja 0x1000d84f
lea eax, [ebx + 7]
shr eax, 3
movzx ebx, byte [eax + 0x10056040]
mov dword [esp + 0x20], ebx
jmp 0x1000d85c
mov ecx, ebx
call fcn.10001010
mov ebx, eax
mov dword [esp + 0x20], eax
cmp ebx, 0x24
jae 0x1000d920
lea ecx, [ebx*2 + 1]
add ecx, ebx
mov ax, word [esi + ecx*8]
lea ecx, [esi + ecx*8]
mov dword [esp + 0x24], ecx
cmp ax, word [ecx + 0x12]
je 0x1000d8a1
mov eax, dword [ecx]
mov edx, dword [esp + 0x10]
sub eax, 4
mov dword [ecx], eax
mov dword [eax], edx
movzx eax, word [ecx]
mov dx, word [ecx + 0x12]
push eax
call fcn.100010c0
add esp, 4
jmp 0x1000d9f9
mov esi, dword [esi]
call fcn.100010a0
mov ecx, esi
mov bl, al
call fcn.10001610
test bl, bl
je 0x1000d8c5
mov edx, dword [esp + 0x10]
mov ecx, edi
call fcn.10011700
jmp 0x1000d9f9
mov esi, dword [esp + 0x24]
mov ecx, esi
call fcn.100010b0
mov cl, byte [0x10050988]
mov edx, dword [esp + 0x14]
movzx eax, ax
shr eax, cl
mov ecx, edi
push eax
push dword [esp + 0x24]
push esi
call fcn.10030e60
mov ax, word [esi]
add esp, 0xc
cmp ax, word [esi + 0x12]
je 0x1000d9f9
mov eax, dword [esi]
mov ecx, esi
mov edx, dword [esp + 0x10]
sub eax, 4
mov dword [esi], eax
mov dword [eax], edx
movzx eax, word [esi]
mov dx, word [esi + 0x12]
push eax
call fcn.100010c0
add esp, 4
jmp 0x1000d9f9
mov ecx, dword [esi]
call fcn.10001610
cmp ebx, eax
jae 0x1000d9d0
mov ecx, dword [esp + 0x14]
lea eax, [ebx + ebx*2]
mov esi, dword [esi]
lea ecx, [ecx + eax*8]
add ecx, 8
mov dword [esp + 0x24], ecx
call fcn.100010a0
mov ecx, esi
mov bl, al
call fcn.10001610
test bl, bl
jne 0x1000d9d0
mov ebx, dword [esp + 0x24]
mov ecx, ebx
mov ax, word [ebx]
cmp ax, word [ebx + 0x12]
je 0x1000d982
mov eax, dword [ebx]
mov edx, dword [esp + 0x10]
sub eax, 4
mov dword [ebx], eax
mov dword [eax], edx
movzx eax, word [ebx]
mov dx, word [ebx + 0x12]
push eax
call fcn.100010c0
add esp, 4
jmp 0x1000d9f9
call fcn.100010b0
mov cl, byte [0x10050984]
mov edx, dword [esp + 0x14]
movzx eax, ax
shr eax, cl
mov ecx, edi
push eax
push dword [esp + 0x24]
push ebx
call fcn.10031160
mov ax, word [ebx]
add esp, 0xc
cmp ax, word [ebx + 0x12]
je 0x1000d9f9
mov eax, dword [ebx]
mov ecx, ebx
mov edx, dword [esp + 0x10]
sub eax, 4
mov dword [ebx], eax
mov dword [eax], edx
movzx eax, word [ebx]
mov dx, word [ebx + 0x12]
push eax
call fcn.100010c0
add esp, 4
jmp 0x1000d9f9
mov edx, dword [esp + 0x10]
lea eax, [edi + 0x17c]
push edx
push eax
lea eax, [esp + 0x78]
mov edx, 0x10057260
push eax
mov ecx, edi
call fcn.10001100
add esp, 0xc
mov ecx, edi
mov edx, dword [eax]
call fcn.10027a90
mov ecx, dword [esp + 0x28]
add edi, 0x250
mov ebx, dword [esp + 0x18]
mov byte [esp + 0x40], 0
mov dword [esp + 0x44], edi
lea eax, [ecx + 0x18]
mov dword [esp + 0x48], eax
lea eax, [ecx + 0x20]
mov dword [esp + 0x4c], eax
lea eax, [ecx + 0x258]
mov dword [esp + 0x50], eax
mov edx, dword [edi]
mov ecx, edx
mov esi, dword [edi + 4]
add ecx, ebx
mov dword [edi], ecx
mov eax, esi
adc eax, 0
mov dword [edi + 4], eax
mov eax, dword [esp + 0x4c]
mov ecx, dword [eax]
mov eax, dword [eax + 4]
sub ecx, edx
sbb eax, esi
xor edx, edx
cmp edx, eax
jb 0x1000da61
ja 0x1000da54
cmp ebx, ecx
jb 0x1000da61
mov ecx, dword [esp + 0x28]
lea edx, [esp + 0x40]
call fcn.10032540
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, str._jemalloc_:_Error_allocating_TSD_n
call fcn.10027c00
call fcn.10038150
mov ecx, str._jemalloc_:_Error_setting_TSD_n
call fcn.10027c00
call fcn.10038150
push ecx
push str._jemalloc_:_invalid_tcache_id___u_._n
call fcn.10028f60
add esp, 8
call fcn.10038150
int3