Function at 0x403c50
Capabilities:
Encode data using xor
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
push esi
push edi
push ebx
sub esp, 0x24
mov esi, eax
mov dword [esp], ecx
mov ebx, edx
push dword [ebp + 0x18]
push esi
push ebx
push dword [ebp + 0x14]
call fcn.0046b3d5
add esp, 0x10
mov edx, dword [ebp + 0x14]
cmp dword [esp], 0
lea edx, [edx + eax*4]
jne 0x403ca5
cmp ebx, 1
je 0x404276
cmp ebx, 2
je 0x404076
cmp ebx, 3
je 0x403f15
cmp ebx, 4
je 0x403ec9
jmp 0x403cc9
cmp ebx, 1
je 0x4047eb
cmp ebx, 2
je 0x4045eb
cmp ebx, 3
je 0x40448a
cmp ebx, 4
je 0x40443e
cmp dword [0x4f8d70], 0
je 0x403ebf
test esi, esi
jle 0x403ebf
cmp esi, 4
jl 0x404437
mov ecx, dword [ebp + 0x14]
and ecx, 0xf
je 0x403d00
test cl, 3
jne 0x404437
neg ecx
add ecx, 0x10
shr ecx, 2
lea edx, [ecx + 4]
cmp esi, edx
jl 0x404437
mov ebx, esi
sub ebx, ecx
and ebx, 3
neg ebx
add ebx, esi
test ecx, ecx
jbe 0x403d8f
movss xmm4, dword [0x4834b4]
xor edx, edx
movss xmm3, dword [0x4834a8]
pxor xmm2, xmm2
movss xmm1, dword [0x4834ac]
movss xmm0, dword [0x4834b0]
mov dword [esp + 0x1c], esi
mov edi, dword [ebp + 0x14]
movss xmm5, dword [edi + edx*4]
comiss xmm5, xmm4
jb 0x403d58
mov esi, 0x7fffffff
jmp 0x403d83
comiss xmm3, xmm5
jb 0x403d64
mov esi, 0x80000000
jmp 0x403d83
comiss xmm5, xmm2
jb 0x403d77
mulss xmm5, xmm1
addss xmm5, xmm0
cvttss2si esi, xmm5
jmp 0x403d83
mulss xmm5, xmm1
subss xmm5, xmm0
cvttss2si esi, xmm5
mov dword [edi + edx*4], esi
inc edx
cmp edx, ecx
jb 0x403d47
mov esi, dword [esp + 0x1c]
movups xmm3, xmmword [0x4833d0]
mov edx, dword [ebp + 0x14]
movups xmm6, xmmword [edx + ecx*4]
movaps xmm2, xmm3
movups xmm7, xmmword [0x4833b0]
pxor xmm0, xmm0
cmpleps xmm7, xmm6
cmpleps xmm0, xmm6
movaps xmm5, xmm6
pcmpeqd xmm1, xmm1
mulps xmm6, xmmword [0x4833e0]
movdqa xmm4, xmm1
cmpleps xmm5, xmmword [0x4833c0]
addps xmm2, xmm6
subps xmm6, xmm3
pxor xmm4, xmm7
pand xmm4, xmm5
por xmm5, xmm7
movdqu xmmword [esp], xmm4
movdqa xmm4, xmm1
pxor xmm4, xmm5
por xmm5, xmm0
pand xmm4, xmm0
pxor xmm5, xmm1
cvttps2dq xmm0, xmm2
cvttps2dq xmm6, xmm6
movdqu xmm1, xmmword [esp]
pand xmm0, xmm4
pand xmm7, xmmword [0x483400]
movdqa xmm2, xmm1
pand xmm1, xmmword [0x4833f0]
pandn xmm2, xmm7
por xmm1, xmm2
movdqa xmm7, xmm4
pandn xmm7, xmm1
movaps xmm1, xmm5
por xmm0, xmm7
pand xmm6, xmm5
pandn xmm1, xmm0
por xmm6, xmm1
movdqu xmmword [edx + ecx*4], xmm6
add ecx, 4
cmp ecx, ebx
jb 0x403d99
cmp ebx, esi
jae 0x403ebf
movss xmm4, dword [0x4834b4]
movss xmm3, dword [0x4834a8]
pxor xmm2, xmm2
movss xmm1, dword [0x4834ac]
movss xmm0, dword [0x4834b0]
mov ecx, dword [ebp + 0x14]
movss xmm5, dword [ecx + ebx*4]
comiss xmm5, xmm4
jb 0x403e8c
mov edx, 0x7fffffff
jmp 0x403eb7
comiss xmm3, xmm5
jb 0x403e98
mov edx, 0x80000000
jmp 0x403eb7
comiss xmm5, xmm2
jb 0x403eab
mulss xmm5, xmm1
addss xmm5, xmm0
cvttss2si edx, xmm5
jmp 0x403eb7
mulss xmm5, xmm1
subss xmm5, xmm0
cvttss2si edx, xmm5
mov dword [ecx + ebx*4], edx
inc ebx
cmp ebx, esi
jb 0x403e7b
add esp, 0x24
pop ebx
pop edi
pop esi
mov esp, ebp
pop ebp
ret
lea edi, [eax*4 - 4]
test edi, edi
jl 0x403cc9
mov dword [esp + 0x1c], esi
mov ecx, dword [ebp + 0x14]
movzx esi, byte [edi + ecx + 1]
shl esi, 8
movzx ebx, byte [edi + ecx]
or ebx, esi
movzx esi, byte [edi + ecx + 2]
shl esi, 0x10
or ebx, esi
movzx esi, byte [edi + ecx + 3]
shl esi, 0x18
or ebx, esi
mov dword [edx - 4], ebx
add edx, 0xfffffffc
add edi, 0xfffffffc
jns 0x403edf
mov esi, dword [esp + 0x1c]
jmp 0x403cc9
lea ecx, [eax + eax*2]
mov dword [esp + 0xc], ecx
add ecx, 0xfffffffd
js 0x403cc9
mov dword [esp + 0x1c], esi
neg ecx
mov ebx, dword [esp + 0xc]
add ecx, 0xfffffffd
mov esi, dword [ebp + 0x14]
mov dword [esp + 0x14], eax
mov eax, 0x55555556
mov dword [esp + 0x18], edx
lea edi, [esi + ebx]
mov dword [esp + 8], edi
lea edi, [edx - 4]
mov dword [esp], edi
imul ecx
sar ecx, 0x1f
lea ebx, [esi + ebx - 3]
sub ecx, edx
neg ebx
add ebx, edi
mov edx, dword [esp + 0x18]
mov esi, dword [esp + 0x1c]
lea eax, [ecx*4]
mov dword [esp + 4], eax
cmp ebx, eax
mov eax, dword [esp + 0x14]
jg 0x403f87
neg ebx
lea edi, [ecx + ecx*2 - 2]
cmp ebx, edi
jle 0x404022
mov edi, dword [esp + 0xc]
mov ebx, dword [ebp + 0x14]
lea ebx, [ebx + edi - 2]
neg ebx
add ebx, dword [esp]
cmp ebx, dword [esp + 4]
jg 0x403fa7
neg ebx
lea edi, [ecx + ecx*2 - 2]
cmp ebx, edi
jle 0x404022
mov edi, dword [esp + 0xc]
mov ebx, dword [ebp + 0x14]
lea ebx, [ebx + edi - 1]
mov edi, dword [esp]
sub edi, ebx
mov dword [esp], edi
cmp edi, dword [esp + 4]
jg 0x403fcc
mov ebx, edi
lea edi, [ecx + ecx*2 - 2]
neg ebx
cmp ebx, edi
jle 0x404022
mov edi, dword [esp + 4]
xor ebx, ebx
neg edi
add edx, edi
lea edi, [ecx + ecx*2]
neg edi
add dword [esp + 8], edi
mov dword [esp], ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], esi
mov ecx, dword [esp + 8]
lea edi, [ebx + ebx*2]
movzx eax, byte [ecx + edi]
movzx esi, byte [ecx + edi + 1]
shl eax, 8
shl esi, 0x10
or eax, esi
movzx esi, byte [ecx + edi + 2]
shl esi, 0x18
or eax, esi
mov dword [edx + ebx*4], eax
inc ebx
cmp ebx, dword [esp]
jb 0x403fee
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
jmp 0x403cc9
xor edi, edi
xor ebx, ebx
mov dword [esp + 0x18], edx
xor ecx, ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], esi
mov edx, dword [esp + 8]
movzx eax, byte [ecx + edx - 3]
inc edi
movzx esi, byte [ecx + edx - 2]
shl eax, 8
shl esi, 0x10
or eax, esi
movzx esi, byte [ecx + edx - 1]
add ecx, 0xfffffffd
shl esi, 0x18
or eax, esi
mov esi, dword [esp + 0x18]
mov dword [ebx + esi - 4], eax
add ebx, 0xfffffffc
cmp edi, dword [esp + 0x14]
jb 0x404038
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
jmp 0x403cc9
lea ebx, [eax + eax - 2]
test ebx, ebx
jl 0x403cc9
neg ebx
lea ecx, [ebx - 2]
shr ecx, 0x1f
lea ecx, [ecx + ebx - 2]
sar ecx, 1
neg ecx
cmp ecx, 6
jle 0x4041b2
mov edi, dword [ebp + 0x14]
mov dword [esp + 0x18], edx
lea ebx, [edi + eax*2]
mov dword [esp + 8], ebx
lea ebx, [ebx - 1]
neg ebx
lea edi, [edx - 4]
add ebx, edi
lea edx, [ecx*4]
mov dword [esp + 4], edx
mov dword [esp], edi
cmp ebx, edx
mov edx, dword [esp + 0x18]
jg 0x4040d7
lea edi, [ecx + ecx - 1]
neg ebx
cmp ebx, edi
jle 0x4041b2
mov ebx, dword [esp + 8]
lea edi, [ebx - 2]
mov ebx, dword [esp]
sub ebx, edi
mov dword [esp], ebx
cmp ebx, dword [esp + 4]
jg 0x4040fa
lea edi, [ecx + ecx - 1]
neg ebx
cmp ebx, edi
jle 0x4041b2
mov ebx, ecx
shr ebx, 1
mov dword [esp + 0x10], ebx
je 0x404265
mov edi, dword [esp + 4]
xor ebx, ebx
neg edi
add edi, edx
mov dword [esp], edi
lea edi, [ecx + ecx]
neg edi
add edi, dword [esp + 8]
mov dword [esp + 0x18], edx
mov dword [esp + 0xc], ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], esi
mov ecx, edi
mov eax, dword [esp]
mov edx, dword [esp + 0x10]
movzx edi, byte [ecx + ebx*4]
movzx esi, byte [ecx + ebx*4 + 1]
shl edi, 0x10
shl esi, 0x18
or edi, esi
mov dword [eax + ebx*8], edi
movzx edi, byte [ecx + ebx*4 + 2]
movzx esi, byte [ecx + ebx*4 + 3]
shl edi, 0x10
shl esi, 0x18
or edi, esi
mov dword [eax + ebx*8 + 4], edi
inc ebx
cmp ebx, edx
jb 0x404137
mov edx, dword [esp + 0x18]
lea ebx, [ebx + ebx + 1]
mov ecx, dword [esp + 0xc]
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
lea edi, [ebx - 1]
cmp edi, ecx
jae 0x403cc9
add ecx, ecx
neg ecx
mov edi, dword [esp + 8]
add edi, ecx
movzx ecx, byte [edi + ebx*2 - 2]
movzx edi, byte [edi + ebx*2 - 1]
shl ecx, 0x10
shl edi, 0x18
or ecx, edi
mov edi, dword [esp + 4]
neg edi
add edx, edi
mov dword [edx + ebx*4 - 4], ecx
jmp 0x403cc9
mov edi, eax
shr edi, 1
je 0x40426f
mov ecx, dword [ebp + 0x14]
xor ebx, ebx
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], edx
mov dword [esp], edi
lea ecx, [ecx + eax*2]
mov dword [esp + 4], ecx
xor ecx, ecx
mov dword [esp + 0x1c], esi
mov eax, ecx
mov edx, dword [esp + 4]
inc ebx
movzx edi, byte [ecx + edx - 2]
movzx esi, byte [ecx + edx - 1]
shl edi, 0x10
shl esi, 0x18
or edi, esi
mov esi, dword [esp + 0x18]
mov dword [eax + esi - 4], edi
movzx edi, byte [ecx + edx - 4]
movzx edx, byte [ecx + edx - 3]
add ecx, 0xfffffffc
shl edi, 0x10
shl edx, 0x18
or edi, edx
mov dword [eax + esi - 8], edi
add eax, 0xfffffff8
cmp ebx, dword [esp]
jb 0x4041db
mov edx, esi
lea ecx, [ebx + ebx + 1]
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
lea ebx, [ecx - 1]
cmp ebx, eax
jae 0x403cc9
mov ebx, dword [ebp + 0x14]
lea edi, [ecx + ecx]
neg edi
shl ecx, 2
neg ecx
lea ebx, [ebx + eax*2]
mov dword [esp + 0x14], eax
movzx eax, byte [edi + ebx]
movzx edi, byte [edi + ebx + 1]
shl eax, 0x10
shl edi, 0x18
or eax, edi
mov dword [ecx + edx], eax
mov eax, dword [esp + 0x14]
jmp 0x403cc9
mov ebx, 1
jmp 0x40417a
mov ecx, 1
jmp 0x404229
mov ecx, eax
dec ecx
js 0x403cc9
cmp eax, 6
jle 0x4043a5
mov edi, dword [ebp + 0x14]
lea ebx, [edx - 4]
lea ecx, [eax*4]
mov dword [esp], ecx
lea edi, [edi + eax - 1]
sub ebx, edi
cmp ebx, ecx
jg 0x4042ac
neg ebx
cmp ebx, eax
jle 0x4043a5
mov ecx, eax
neg ecx
dec ecx
neg ecx
dec ecx
cmp ecx, 4
jl 0x404423
mov edi, dword [esp]
neg edi
add edi, edx
mov dword [esp], edi
and edi, 0xf
je 0x4042e0
test edi, 3
jne 0x404423
neg edi
add edi, 0x10
shr edi, 2
lea ebx, [edi + 4]
cmp ecx, ebx
jl 0x404423
mov ebx, ecx
sub ebx, edi
and ebx, 3
neg ebx
add ebx, ecx
mov dword [esp + 8], ebx
test edi, edi
jbe 0x40432d
mov dword [esp + 4], ecx
xor ebx, ebx
mov dword [esp + 0x1c], esi
mov dword [esp + 0x14], eax
mov ecx, dword [esp]
mov esi, dword [ebp + 0x14]
movzx eax, byte [ebx + esi]
shl eax, 0x18
mov dword [ecx + ebx*4], eax
inc ebx
cmp ebx, edi
jb 0x404312
mov ecx, dword [esp + 4]
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], esi
pxor xmm0, xmm0
mov eax, dword [esp + 8]
mov ebx, dword [esp]
mov esi, dword [ebp + 0x14]
movd xmm1, dword [edi + esi]
punpcklbw xmm1, xmm0
punpcklwd xmm1, xmm0
pslld xmm1, 0x18
movdqu xmmword [ebx + edi*4], xmm1
add edi, 4
cmp edi, eax
jb 0x404343
mov dword [esp + 8], eax
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
cmp ecx, dword [esp + 8]
jbe 0x403cc9
mov dword [esp + 0x1c], esi
lea ebx, [eax*4]
neg ebx
mov esi, dword [esp + 8]
add edx, ebx
mov edi, dword [ebp + 0x14]
movzx ebx, byte [esi + edi]
shl ebx, 0x18
mov dword [edx + esi*4], ebx
inc esi
cmp esi, ecx
jb 0x40438d
mov esi, dword [esp + 0x1c]
jmp 0x403cc9
mov edi, eax
shr edi, 1
je 0x404430
mov ecx, dword [ebp + 0x14]
xor ebx, ebx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], esi
mov dword [esp + 4], edi
add ecx, eax
mov dword [esp], ecx
xor ecx, ecx
mov esi, ecx
mov eax, dword [esp]
movzx edi, byte [esi + eax - 1]
inc ebx
shl edi, 0x18
mov dword [ecx + edx - 4], edi
movzx edi, byte [esi + eax - 2]
add esi, 0xfffffffe
shl edi, 0x18
mov dword [ecx + edx - 8], edi
add ecx, 0xfffffff8
cmp ebx, dword [esp + 4]
jb 0x4043cc
mov eax, dword [esp + 0x14]
lea ecx, [ebx + ebx + 1]
mov esi, dword [esp + 0x1c]
lea ebx, [ecx - 1]
cmp ebx, eax
jae 0x403cc9
mov ebx, dword [ebp + 0x14]
lea edi, [ebx + eax]
sub edi, ecx
shl ecx, 2
neg ecx
movzx ebx, byte [edi]
shl ebx, 0x18
mov dword [ecx + edx], ebx
jmp 0x403cc9
mov dword [esp + 8], 0
jmp 0x40436d
mov ecx, 1
jmp 0x4043fd
xor ebx, ebx
jmp 0x403e50
lea edi, [eax*4 - 4]
test edi, edi
jl 0x403cc9
mov dword [esp + 0x1c], esi
mov ecx, dword [ebp + 0x14]
movzx ebx, byte [edi + ecx]
movzx esi, byte [edi + ecx + 1]
shl ebx, 0x18
shl esi, 0x10
or ebx, esi
movzx esi, byte [edi + ecx + 2]
shl esi, 8
or ebx, esi
movzx esi, byte [edi + ecx + 3]
or ebx, esi
mov dword [edx - 4], ebx
add edx, 0xfffffffc
add edi, 0xfffffffc
jns 0x404454
mov esi, dword [esp + 0x1c]
jmp 0x403cc9
lea ecx, [eax + eax*2]
mov dword [esp + 0xc], ecx
add ecx, 0xfffffffd
js 0x403cc9
mov dword [esp + 0x1c], esi
neg ecx
mov ebx, dword [esp + 0xc]
add ecx, 0xfffffffd
mov esi, dword [ebp + 0x14]
mov dword [esp + 0x14], eax
mov eax, 0x55555556
mov dword [esp + 0x18], edx
lea edi, [esi + ebx]
mov dword [esp + 8], edi
lea edi, [edx - 4]
mov dword [esp], edi
imul ecx
sar ecx, 0x1f
lea ebx, [esi + ebx - 3]
sub ecx, edx
neg ebx
add ebx, edi
mov edx, dword [esp + 0x18]
mov esi, dword [esp + 0x1c]
lea eax, [ecx*4]
mov dword [esp + 4], eax
cmp ebx, eax
mov eax, dword [esp + 0x14]
jg 0x4044fc
neg ebx
lea edi, [ecx + ecx*2 - 2]
cmp ebx, edi
jle 0x404597
mov edi, dword [esp + 0xc]
mov ebx, dword [ebp + 0x14]
lea ebx, [ebx + edi - 2]
neg ebx
add ebx, dword [esp]
cmp ebx, dword [esp + 4]
jg 0x40451c
neg ebx
lea edi, [ecx + ecx*2 - 2]
cmp ebx, edi
jle 0x404597
mov edi, dword [esp + 0xc]
mov ebx, dword [ebp + 0x14]
lea ebx, [ebx + edi - 1]
mov edi, dword [esp]
sub edi, ebx
mov dword [esp], edi
cmp edi, dword [esp + 4]
jg 0x404541
mov ebx, edi
lea edi, [ecx + ecx*2 - 2]
neg ebx
cmp ebx, edi
jle 0x404597
mov edi, dword [esp + 4]
xor ebx, ebx
neg edi
add edx, edi
lea edi, [ecx + ecx*2]
neg edi
add dword [esp + 8], edi
mov dword [esp], ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], esi
mov ecx, dword [esp + 8]
lea edi, [ebx + ebx*2]
movzx eax, byte [ecx + edi]
movzx esi, byte [ecx + edi + 1]
shl eax, 0x18
shl esi, 0x10
or eax, esi
movzx esi, byte [ecx + edi + 2]
shl esi, 8
or eax, esi
mov dword [edx + ebx*4], eax
inc ebx
cmp ebx, dword [esp]
jb 0x404563
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
jmp 0x403cc9
xor edi, edi
xor ebx, ebx
mov dword [esp + 0x18], edx
xor ecx, ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], esi
mov edx, dword [esp + 8]
movzx eax, byte [ecx + edx - 3]
inc edi
movzx esi, byte [ecx + edx - 2]
shl eax, 0x18
shl esi, 0x10
or eax, esi
movzx esi, byte [ecx + edx - 1]
add ecx, 0xfffffffd
shl esi, 8
or eax, esi
mov esi, dword [esp + 0x18]
mov dword [ebx + esi - 4], eax
add ebx, 0xfffffffc
cmp edi, dword [esp + 0x14]
jb 0x4045ad
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
jmp 0x403cc9
lea ebx, [eax + eax - 2]
test ebx, ebx
jl 0x403cc9
neg ebx
lea ecx, [ebx - 2]
shr ecx, 0x1f
lea ecx, [ecx + ebx - 2]
sar ecx, 1
neg ecx
cmp ecx, 6
jle 0x404727
mov edi, dword [ebp + 0x14]
mov dword [esp + 0x18], edx
lea ebx, [edi + eax*2]
mov dword [esp + 8], ebx
lea ebx, [ebx - 1]
neg ebx
lea edi, [edx - 4]
add ebx, edi
lea edx, [ecx*4]
mov dword [esp + 4], edx
mov dword [esp], edi
cmp ebx, edx
mov edx, dword [esp + 0x18]
jg 0x40464c
lea edi, [ecx + ecx - 1]
neg ebx
cmp ebx, edi
jle 0x404727
mov ebx, dword [esp + 8]
lea edi, [ebx - 2]
mov ebx, dword [esp]
sub ebx, edi
mov dword [esp], ebx
cmp ebx, dword [esp + 4]
jg 0x40466f
lea edi, [ecx + ecx - 1]
neg ebx
cmp ebx, edi
jle 0x404727
mov ebx, ecx
shr ebx, 1
mov dword [esp + 0x10], ebx
je 0x4047da
mov edi, dword [esp + 4]
xor ebx, ebx
neg edi
add edi, edx
mov dword [esp], edi
lea edi, [ecx + ecx]
neg edi
add edi, dword [esp + 8]
mov dword [esp + 0x18], edx
mov dword [esp + 0xc], ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], esi
mov ecx, edi
mov eax, dword [esp]
mov edx, dword [esp + 0x10]
movzx edi, byte [ecx + ebx*4]
movzx esi, byte [ecx + ebx*4 + 1]
shl edi, 0x18
shl esi, 0x10
or edi, esi
mov dword [eax + ebx*8], edi
movzx edi, byte [ecx + ebx*4 + 2]
movzx esi, byte [ecx + ebx*4 + 3]
shl edi, 0x18
shl esi, 0x10
or edi, esi
mov dword [eax + ebx*8 + 4], edi
inc ebx
cmp ebx, edx
jb 0x4046ac
mov edx, dword [esp + 0x18]
lea ebx, [ebx + ebx + 1]
mov ecx, dword [esp + 0xc]
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
lea edi, [ebx - 1]
cmp edi, ecx
jae 0x403cc9
add ecx, ecx
neg ecx
mov edi, dword [esp + 8]
add edi, ecx
movzx ecx, byte [edi + ebx*2 - 2]
movzx edi, byte [edi + ebx*2 - 1]
shl ecx, 0x18
shl edi, 0x10
or ecx, edi
mov edi, dword [esp + 4]
neg edi
add edx, edi
mov dword [edx + ebx*4 - 4], ecx
jmp 0x403cc9
mov edi, eax
shr edi, 1
je 0x4047e4
mov ecx, dword [ebp + 0x14]
xor ebx, ebx
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], edx
mov dword [esp], edi
lea ecx, [ecx + eax*2]
mov dword [esp + 4], ecx
xor ecx, ecx
mov dword [esp + 0x1c], esi
mov eax, ecx
mov edx, dword [esp + 4]
inc ebx
movzx edi, byte [ecx + edx - 2]
movzx esi, byte [ecx + edx - 1]
shl edi, 0x18
shl esi, 0x10
or edi, esi
mov esi, dword [esp + 0x18]
mov dword [eax + esi - 4], edi
movzx edi, byte [ecx + edx - 4]
movzx edx, byte [ecx + edx - 3]
add ecx, 0xfffffffc
shl edi, 0x18
shl edx, 0x10
or edi, edx
mov dword [eax + esi - 8], edi
add eax, 0xfffffff8
cmp ebx, dword [esp]
jb 0x404750
mov edx, esi
lea ecx, [ebx + ebx + 1]
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
lea ebx, [ecx - 1]
cmp ebx, eax
jae 0x403cc9
mov ebx, dword [ebp + 0x14]
lea edi, [ecx + ecx]
neg edi
shl ecx, 2
neg ecx
lea ebx, [ebx + eax*2]
mov dword [esp + 0x14], eax
movzx eax, byte [edi + ebx]
movzx edi, byte [edi + ebx + 1]
shl eax, 0x18
shl edi, 0x10
or eax, edi
mov dword [ecx + edx], eax
mov eax, dword [esp + 0x14]
jmp 0x403cc9
mov ebx, 1
jmp 0x4046ef
mov ecx, 1
jmp 0x40479e
mov ecx, eax
dec ecx
js 0x403cc9
cmp eax, 6
jle 0x404943
mov edi, dword [ebp + 0x14]
lea ebx, [edx - 4]
lea ecx, [eax*4]
mov dword [esp], ecx
lea edi, [edi + eax - 1]
sub ebx, edi
cmp ebx, ecx
jg 0x404821
neg ebx
cmp ebx, eax
jle 0x404943
mov ecx, eax
neg ecx
dec ecx
neg ecx
dec ecx
cmp ecx, 4
jl 0x4049dc
mov edi, dword [esp]
neg edi
add edi, edx
mov dword [esp], edi
and edi, 0xf
je 0x404855
test edi, 3
jne 0x4049dc
neg edi
add edi, 0x10
shr edi, 2
lea ebx, [edi + 4]
cmp ecx, ebx
jl 0x4049dc
mov ebx, ecx
sub ebx, edi
and ebx, 3
neg ebx
add ebx, ecx
mov dword [esp + 8], ebx
test edi, edi
jbe 0x4048aa
mov dword [esp + 4], ecx
xor ebx, ebx
mov dword [esp + 0x1c], esi
mov dword [esp + 0x14], eax
mov ecx, dword [esp]
mov esi, dword [ebp + 0x14]
movzx eax, byte [ebx + esi]
xor eax, 0xffffff80
shl eax, 0x18
add eax, 0x7f0000
mov dword [ecx + ebx*4], eax
inc ebx
cmp ebx, edi
jb 0x404887
mov ecx, dword [esp + 4]
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], esi
pxor xmm2, xmm2
movdqu xmm1, xmmword [0x483410]
movdqu xmm0, xmmword [0x483420]
mov eax, dword [esp + 8]
mov ebx, dword [esp]
mov esi, dword [ebp + 0x14]
movd xmm3, dword [edi + esi]
punpcklbw xmm3, xmm2
punpcklwd xmm3, xmm2
pxor xmm3, xmm1
pslld xmm3, 0x18
por xmm3, xmm0
movdqu xmmword [ebx + edi*4], xmm3
add edi, 4
cmp edi, eax
jb 0x4048d0
mov dword [esp + 8], eax
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
cmp ecx, dword [esp + 8]
jbe 0x403cc9
mov dword [esp + 0x1c], esi
lea ebx, [eax*4]
neg ebx
mov esi, dword [esp + 8]
add edx, ebx
mov edi, dword [ebp + 0x14]
movzx ebx, byte [esi + edi]
xor ebx, 0xffffff80
shl ebx, 0x18
add ebx, 0x7f0000
mov dword [edx + esi*4], ebx
inc esi
cmp esi, ecx
jb 0x404922
mov esi, dword [esp + 0x1c]
jmp 0x403cc9
mov edi, eax
shr edi, 1
je 0x4049e9
mov ecx, dword [ebp + 0x14]
xor ebx, ebx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], esi
mov dword [esp + 4], edi
add ecx, eax
mov dword [esp], ecx
xor ecx, ecx
mov eax, ecx
mov esi, dword [esp]
movzx edi, byte [eax + esi - 1]
inc ebx
xor edi, 0xffffff80
shl edi, 0x18
add edi, 0x7f0000
mov dword [ecx + edx - 4], edi
movzx edi, byte [eax + esi - 2]
add eax, 0xfffffffe
xor edi, 0xffffff80
shl edi, 0x18
add edi, 0x7f0000
mov dword [ecx + edx - 8], edi
add ecx, 0xfffffff8
cmp ebx, dword [esp + 4]
jb 0x40496a
mov eax, dword [esp + 0x14]
lea ecx, [ebx + ebx + 1]
mov esi, dword [esp + 0x1c]
lea ebx, [ecx - 1]
cmp ebx, eax
jae 0x403cc9
mov ebx, dword [ebp + 0x14]
lea edi, [ebx + eax]
sub edi, ecx
shl ecx, 2
neg ecx
movzx ebx, byte [edi]
xor ebx, 0xffffff80
shl ebx, 0x18
add ebx, 0x7f0000
mov dword [ecx + edx], ebx
jmp 0x403cc9
mov dword [esp + 8], 0
jmp 0x404902
mov ecx, 1
jmp 0x4049ad