Function at 0x1007d910
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x34
push ebx
push ebp
mov ebp, dword [esp + 0x78]
mov ecx, ebp
push esi
push edi
mov edi, dword [esp + 0x54]
mov esi, 1
shl esi, cl
sar esi, 1
mov dword [esp + 0x10], 0xffffffff
movsx eax, word [edi]
add eax, esi
sar eax, cl
mov dword [esp + 0x3c], eax
movsx eax, word [edi + 2]
add eax, esi
sar eax, cl
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x4c]
lea ebx, [eax*4]
push ebx
push 0
push dword [esp + 0x68]
call fcn.10513d40
push ebx
push 0
push dword [esp + 0x78]
call fcn.10513d40
mov ecx, dword [esp + 0x90]
add esp, 0x18
mov edx, dword [esp + 0x7c]
test ecx, ecx
jne 0x1007db03
test edx, edx
jne 0x1007db03
push ebx
push edx
push dword [esp + 0x68]
call fcn.10513d40
push ebx
push 0
push dword [esp + 0x78]
call fcn.10513d40
movsx eax, word [edi]
mov ecx, ebp
add eax, esi
add esp, 0x18
sar eax, cl
xor ebx, ebx
mov dword [esp + 0x34], eax
movsx eax, word [edi + 2]
add eax, esi
sar eax, cl
mov dword [esp + 0x38], eax
xor eax, eax
mov dword [esp + 0x78], eax
cmp dword [esp + 0x4c], eax
jle 0x1007dca6
lea eax, [ebp + 1]
mov dword [esp + 0x54], eax
mov eax, 0x10
sub eax, ebp
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x70]
mov ecx, dword [esp + 0x48]
movsx esi, word [eax + ebx*2]
mov ebp, esi
lea eax, [esi*4]
mov dword [esp + 0x20], eax
mov eax, dword [eax + ecx]
mov edi, eax
sar edi, 0x1f
xor eax, edi
sub eax, edi
neg ebp
cdq
mov ecx, edx
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], ecx
sbb ebp, ebp
mov ecx, dword [esp + 0x54]
and ebp, 2
call fcn.10511ff0
mov dword [esp + 0x18], eax
mov ecx, edx
mov eax, dword [esp + 0x68]
movsx eax, word [eax + ebp]
cdq
cmp ecx, edx
jl 0x1007dae2
jg 0x1007da44
cmp dword [esp + 0x18], eax
jb 0x1007dae2
neg esi
sbb esi, esi
and esi, 4
mov eax, dword [esp + esi + 0x34]
cdq
mov ecx, eax
mov esi, edx
add ecx, dword [esp + 0x14]
adc esi, dword [esp + 0x10]
cmp esi, 0xffffffff
jg 0x1007da75
jl 0x1007da6b
cmp ecx, 0xffff8000
jae 0x1007da75
mov ecx, 0xffff8000
or esi, 0xffffffff
jmp 0x1007da8a
test esi, esi
jl 0x1007da8a
jg 0x1007da83
cmp ecx, 0x7fff
jbe 0x1007da8a
mov ecx, 0x7fff
xor esi, esi
mov eax, dword [esp + 0x58]
push esi
push ecx
movsx eax, word [eax + ebp]
cdq
push edx
push eax
call fcn.10511b50
mov ecx, dword [esp + 0x1c]
call fcn.10511c50
test eax, eax
je 0x1007dae2
mov esi, dword [esp + 0x20]
mov ecx, eax
mov edx, dword [esp + 0x60]
xor ecx, edi
sub ecx, edi
mov dword [esi + edx], ecx
mov ecx, dword [esp + 0x68]
movsx edx, word [ecx + ebp]
mov ecx, dword [esp + 0x80]
imul edx, eax
mov eax, dword [esp + 0x64]
sar edx, cl
xor edx, edi
sub edx, edi
mov dword [esi + eax], edx
lea eax, [ebx + 1]
mov dword [esp + 0x78], eax
jmp 0x1007dae6
mov eax, dword [esp + 0x78]
inc ebx
cmp ebx, dword [esp + 0x4c]
jl 0x1007d9e1
pop edi
movzx ecx, ax
mov eax, dword [esp + 0x68]
pop esi
pop ebp
pop ebx
mov word [eax], cx
add esp, 0x34
ret
xor eax, eax
mov dword [esp + 0x54], eax
cmp dword [esp + 0x4c], eax
jle 0x1007dca1
mov ebx, 4
sub ebx, ebp
mov dword [esp + 0x20], ebx
mov ebx, 0x15
sub ebx, ebp
mov dword [esp + 0x28], ebx
nop dword [eax]
mov ebx, dword [esp + 0x70]
movsx esi, word [ebx + eax*2]
mov ebx, dword [esp + 0x48]
lea eax, [esi*4]
mov ebx, dword [eax + ebx]
mov dword [esp + 0x30], eax
test ecx, ecx
je 0x1007db53
mov cl, byte [esi + ecx]
jmp 0x1007db55
mov cl, 0x20
test edx, edx
je 0x1007db5e
mov al, byte [esi + edx]
jmp 0x1007db60
mov al, 0x20
mov ebp, dword [esp + 0x68]
mov edx, esi
neg edx
movzx eax, al
sbb edx, edx
and edx, 2
mov dword [esp + 0x24], edx
movsx edi, word [edx + ebp]
mov edx, ebx
imul eax, edi
sar edx, 0x1f
mov dword [esp + 0x2c], edx
add eax, 0x10
sar eax, 5
mov dword [esp + 0x34], eax
mov eax, edx
xor eax, ebx
sub eax, edx
cdq
mov ebx, eax
mov ebp, edx
movzx eax, cl
mov ecx, dword [esp + 0x20]
cdq
push ebp
mov dword [esp + 0x18], edx
push ebx
push dword [esp + 0x1c]
mov dword [esp + 0x24], eax
push dword [esp + 0x24]
shl edi, cl
mov eax, edi
cdq
mov dword [esp + 0x2c], eax
mov edi, edx
call fcn.10511b50
cmp edx, edi
jl 0x1007dc86
jg 0x1007dbd7
cmp eax, dword [esp + 0x1c]
jb 0x1007dc86
neg esi
sbb esi, esi
and esi, 4
mov eax, dword [esp + esi + 0x3c]
cdq
add ebx, eax
adc ebp, edx
cmp ebp, 0xffffffff
jg 0x1007dc00
jl 0x1007dbf6
cmp ebx, 0xffff8000
jae 0x1007dc00
mov ebx, 0xffff8000
or ebp, 0xffffffff
jmp 0x1007dc15
test ebp, ebp
jl 0x1007dc15
jg 0x1007dc0e
cmp ebx, 0x7fff
jbe 0x1007dc15
mov ebx, 0x7fff
xor ebp, ebp
mov ecx, dword [esp + 0x58]
mov eax, dword [esp + 0x24]
push dword [esp + 0x14]
push dword [esp + 0x1c]
movsx eax, word [eax + ecx]
cdq
push edx
push eax
call fcn.10511b50
push ebp
push ebx
push edx
push eax
call fcn.10511b50
mov ecx, dword [esp + 0x28]
call fcn.10511c50
mov edi, dword [esp + 0x2c]
mov ecx, eax
mov esi, dword [esp + 0x30]
xor ecx, edi
mov edx, dword [esp + 0x60]
sub ecx, edi
mov dword [esi + edx], ecx
mov edx, eax
imul edx, dword [esp + 0x34]
mov ecx, dword [esp + 0x80]
sar edx, cl
mov ecx, dword [esp + 0x64]
xor edx, edi
sub edx, edi
test eax, eax
mov eax, dword [esp + 0x54]
mov dword [esi + ecx], edx
mov ecx, dword [esp + 0x10]
cmovne ecx, eax
mov dword [esp + 0x10], ecx
jmp 0x1007dc8a
mov eax, dword [esp + 0x54]
mov edx, dword [esp + 0x7c]
inc eax
mov ecx, dword [esp + 0x78]
mov dword [esp + 0x54], eax
cmp eax, dword [esp + 0x4c]
jl 0x1007db30
mov eax, dword [esp + 0x10]
inc eax
pop edi
movzx ecx, ax
mov eax, dword [esp + 0x68]
pop esi
pop ebp
pop ebx
mov word [eax], cx
add esp, 0x34
ret