Function at 0x46f220
Capabilities:
Execute anti-debugging instructions
Get thread local storage value

Disassembly:
sub esp, 0x3c
push edi
xor edi, edi
cmp dword [esp + 0x48], edi
je 0x46f76d
mov eax, dword [0x4c6074]
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_TlsGetValue]
push esi
push eax
call ebp
mov esi, eax
mov ecx, dword [esi + 4]
cmp ecx, dword [esi + 0xc]
jae 0x46f26a
mov dword [ecx], str.LtBroadPhase
mov dword [ecx + 0xc], str.StGatherAabbs
rdtsc
mov dword [esp + 0xc], eax
mov edx, dword [esp + 0xc]
mov dword [ecx + 4], edx
add ecx, 0x10
mov dword [esi + 4], ecx
mov eax, dword [0x4c6060]
push ebx
mov ebx, dword [esp + 0x58]
mov esi, dword [ebx + 0x2fc]
push eax
mov dword [esp + 0x30], edi
mov dword [esp + 0x34], edi
mov dword [esp + 0x38], bind
call ebp
mov ecx, dword [eax + 0x20]
lea edx, [esi*8 + 0x10]
and edx, 0xfffffff0
lea edi, [ecx + edx]
cmp edi, dword [eax + 0x2c]
ja 0x46f2a9
mov dword [eax + 0x20], edi
mov eax, ecx
jmp 0x46f2b3
mov edi, dword [eax]
push edx
mov edx, dword [edi + 0x14]
mov ecx, eax
call edx
mov dword [esp + 0x2c], eax
mov dword [esp + 0x38], eax
xor eax, eax
mov dword [esp + 0x3c], eax
mov dword [esp + 0x40], eax
mov eax, dword [0x4c6060]
or esi, 0x80000000
mov dword [esp + 0x34], esi
mov esi, dword [ebx + 0x2fc]
push eax
mov dword [esp + 0x48], bind
call ebp
mov ecx, dword [eax + 0x20]
lea edx, [esi*8 + 0x10]
and edx, 0xfffffff0
lea edi, [ecx + edx]
cmp edi, dword [eax + 0x2c]
ja 0x46f301
mov dword [eax + 0x20], edi
mov eax, ecx
jmp 0x46f30b
mov edi, dword [eax]
push edx
mov edx, dword [edi + 0x14]
mov ecx, eax
call edx
mov dword [esp + 0x3c], eax
mov dword [esp + 0x48], eax
mov eax, dword [0x4c6060]
or esi, 0x80000000
push eax
mov dword [esp + 0x48], esi
call ebp
mov edx, dword [esp + 0x54]
mov ecx, dword [eax + 0x20]
shl edx, 5
add edx, 0x10
and edx, 0xfffffff0
lea esi, [ecx + edx]
cmp esi, dword [eax + 0x2c]
ja 0x46f348
mov ebx, ecx
mov dword [eax + 0x20], esi
mov dword [esp + 0x1c], ebx
jmp 0x46f358
mov esi, dword [eax]
push edx
mov edx, dword [esi + 0x14]
mov ecx, eax
call edx
mov ebx, eax
mov dword [esp + 0x1c], eax
mov eax, dword [0x4c6060]
push eax
call ebp
mov edi, dword [esp + 0x54]
mov esi, dword [eax + 0x20]
lea ecx, [edi*4 + 0x10]
and ecx, 0xfffffff0
lea edx, [esi + ecx]
cmp edx, dword [eax + 0x2c]
ja 0x46f382
mov dword [eax + 0x20], edx
mov dword [esp + 0x18], esi
jmp 0x46f392
mov edx, dword [eax]
push ecx
mov ecx, eax
mov eax, dword [edx + 0x14]
call eax
mov esi, eax
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x50]
lea ecx, [edi - 1]
test ecx, ecx
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], ecx
jl 0x46f45f
mov ecx, esi
sub ecx, eax
lea edi, [ebx + 8]
mov dword [esp + 0x24], ecx
jmp 0x46f3ba
mov ecx, dword [esp + 0x24]
mov esi, dword [eax]
mov dword [esp + 0x28], esi
lea edx, [esi + 0x24]
add esi, 0x30
mov dword [ecx + eax], edx
mov eax, dword [esi]
cmp eax, dword [esi + 0x10]
jbe 0x46f3e7
mov edx, dword [esp + 0x58]
mov eax, dword [edx + 0x6c]
push 1
lea ecx, [esp + 0x2c]
push ecx
push eax
call fcn.00456ef0
add esp, 0xc
movzx ecx, byte [esi + 0xf]
movzx edx, byte [esi + 0xd]
movzx ebx, byte [esi + 0xe]
mov eax, dword [esi + 4]
mov ebp, dword [esi]
shl edx, cl
shl ebx, cl
add edi, 0x20
sub eax, edx
mov edx, dword [esi + 8]
sub edx, ebx
movzx ebx, byte [esi + 0xc]
shl ebx, cl
mov dword [edi - 0x24], eax
mov dword [edi - 0x20], edx
sub ebp, ebx
mov dword [edi - 0x28], ebp
movzx eax, byte [esi + 0x1d]
movzx edx, byte [esi + 0x1e]
movzx ebx, byte [esi + 0x1c]
shl eax, cl
shl edx, cl
shl ebx, cl
add eax, dword [esi + 0x14]
add edx, dword [esi + 0x18]
add ebx, dword [esi + 0x10]
mov dword [edi - 0x14], eax
mov eax, dword [esp + 0x10]
mov dword [edi - 0x18], ebx
mov dword [edi - 0x10], edx
add eax, 4
sub dword [esp + 0x14], 1
mov dword [esp + 0x10], eax
jns 0x46f3b6
mov esi, dword [esp + 0x18]
mov ebx, dword [esp + 0x1c]
mov ebp, dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov eax, dword [0x4c6074]
push eax
call ebp
mov edi, eax
mov ecx, dword [edi + 4]
cmp ecx, dword [edi + 0xc]
jae 0x46f48a
mov dword [ecx], str.St3AxisSweep
rdtsc
mov dword [esp + 0x1c], eax
mov edx, dword [esp + 0x1c]
mov dword [ecx + 4], edx
add ecx, 0xc
mov dword [edi + 4], ecx
mov edi, dword [esp + 0x58]
mov ecx, dword [edi + 0x54]
cmp dword [ecx + 0x10], 0
je 0x46f49c
call fcn.0047b090
mov ecx, dword [edi + 0x54]
mov eax, dword [ecx]
mov eax, dword [eax + 0x2c]
lea edx, [esp + 0x3c]
push edx
lea edx, [esp + 0x30]
push edx
mov edx, dword [esp + 0x5c]
push edx
push ebx
push esi
call eax
mov ecx, dword [edi + 0x54]
cmp dword [ecx + 0x10], 0
je 0x46f4c5
call fcn.0047b0a0
mov ecx, dword [0x4c6060]
push ecx
call ebp
cmp esi, dword [eax + 0x28]
mov dword [eax + 0x20], esi
jne 0x46f4e0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0x18]
push esi
call eax
mov ecx, dword [0x4c6060]
push ecx
call ebp
cmp ebx, dword [eax + 0x28]
mov dword [eax + 0x20], ebx
jne 0x46f4fb
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0x18]
push ebx
call eax
mov ecx, dword [esp + 0x40]
mov edx, dword [esp + 0x30]
add ecx, edx
test ecx, ecx
jle 0x46f546
mov eax, dword [0x4c6074]
push eax
call ebp
mov esi, eax
mov ecx, dword [esi + 4]
cmp ecx, dword [esi + 0xc]
jae 0x46f534
mov dword [ecx], str.StRemoveDup
rdtsc
mov dword [esp + 0x58], eax
mov edx, dword [esp + 0x58]
mov dword [ecx + 4], edx
add ecx, 0xc
mov dword [esi + 4], ecx
lea eax, [esp + 0x3c]
push eax
lea ecx, [esp + 0x30]
push ecx
call fcn.00481340
add esp, 8
mov ebx, dword [esp + 0x5c]
test ebx, ebx
je 0x46f5b9
cmp byte [ebx], 0
jne 0x46f5b9
mov edx, dword [0x4c6074]
push edx
call ebp
mov esi, eax
mov ecx, dword [esi + 4]
cmp ecx, dword [esi + 0xc]
jae 0x46f580
mov dword [ecx], str.TtWaitForExport
rdtsc
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x5c]
mov dword [ecx + 4], eax
add ecx, 0xc
mov dword [esi + 4], ecx
nop
mov cl, byte [ebx]
cmp cl, 1
je 0x46f58e
mov dl, byte [ebx]
cmp dl, 2
jne 0x46f580
mov eax, dword [0x4c6074]
push eax
call ebp
mov esi, eax
mov ecx, dword [esi + 4]
cmp ecx, dword [esi + 0xc]
jae 0x46f5b9
mov dword [ecx], 0x4b2454
rdtsc
mov dword [esp + 0x18], eax
mov edx, dword [esp + 0x18]
mov dword [ecx + 4], edx
add ecx, 0xc
mov dword [esi + 4], ecx
mov eax, dword [esp + 0x40]
mov ecx, dword [esp + 0x30]
add eax, ecx
test eax, eax
jle 0x46f6a4
mov edx, dword [0x4c6074]
push edx
call ebp
mov esi, eax
mov ecx, dword [esi + 4]
cmp ecx, dword [esi + 0xc]
jae 0x46f5f7
mov dword [ecx], str.StRemoveAgt
rdtsc
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x14]
mov dword [ecx + 4], eax
add ecx, 0xc
mov dword [esi + 4], ecx
mov ebx, dword [esp + 0x50]
mov ecx, dword [ebx]
mov edx, dword [ecx + 0xb8]
push edx
mov ecx, edi
call fcn.00440230
mov eax, dword [esp + 0x40]
mov ecx, dword [esp + 0x3c]
push eax
push ecx
mov ecx, dword [edi + 0x58]
call fcn.00481300
mov eax, dword [esp + 0x30]
mov esi, dword [0x4c606c]
mov edx, dword [esi]
mov edx, dword [edx + 0x60]
shl eax, 0xa
push eax
lea ecx, [esp + 0x58]
push ecx
mov ecx, esi
call edx
cmp byte [eax], 0
jne 0x46f647
mov dword [esi + 4], 1
jmp 0x46f694
mov edx, dword [0x4c6074]
push edx
call ebp
mov esi, eax
mov ecx, dword [esi + 4]
cmp ecx, dword [esi + 0xc]
jae 0x46f673
mov dword [ecx], 0x4b8b78
rdtsc
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x20]
mov dword [ecx + 4], eax
add ecx, 0xc
mov dword [esi + 4], ecx
mov eax, dword [edi + 0x70]
test eax, eax
je 0x46f67f
add eax, 8
jmp 0x46f681
xor eax, eax
mov ecx, dword [esp + 0x30]
mov edx, dword [esp + 0x2c]
push eax
push ecx
mov ecx, dword [edi + 0x58]
push edx
call fcn.00481290
mov eax, dword [ebx]
mov ecx, dword [eax + 0xb8]
push ecx
mov ecx, edi
call fcn.0043f080
mov edx, dword [0x4c6074]
push edx
call ebp
mov esi, eax
mov ecx, dword [esi + 4]
cmp ecx, dword [esi + 0xc]
pop ebx
jae 0x46f6d1
mov dword [ecx], 0x4b3398
rdtsc
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x20]
mov dword [ecx + 4], eax
add ecx, 0xc
mov dword [esi + 4], ecx
mov ecx, dword [0x4c6060]
mov esi, dword [esp + 0x44]
push ecx
call ebp
cmp esi, dword [eax + 0x28]
mov dword [eax + 0x20], esi
jne 0x46f6f0
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0x18]
push esi
call eax
mov eax, dword [esp + 0x40]
test eax, eax
js 0x46f71e
mov ecx, dword [0x4c6060]
and eax, 0x3fffffff
push ecx
mov esi, eax
call ebp
mov ecx, dword [esp + 0x38]
push 0x17
lea edx, [esi*8]
push edx
push ecx
mov ecx, eax
call fcn.004023e0
mov edx, dword [0x4c6060]
mov esi, dword [esp + 0x34]
push edx
call ebp
cmp esi, dword [eax + 0x28]
mov dword [eax + 0x20], esi
jne 0x46f73d
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0x18]
push esi
call eax
mov eax, dword [esp + 0x30]
test eax, eax
js 0x46f76b
mov ecx, dword [0x4c6060]
and eax, 0x3fffffff
push ecx
mov esi, eax
call ebp
mov ecx, dword [esp + 0x28]
push 0x17
lea edx, [esi*8]
push edx
push ecx
mov ecx, eax
call fcn.004023e0
pop esi
pop ebp
pop edi
add esp, 0x3c
ret 0x10