// File: /workspace/github_c_makefile_star2_O3/Tarsnap[P]spiped/perftests/standalone-enc/standalone_pce.c
// Function: pce_init
static int
pce_init(void * cookie, uint8_t * buf, size_t buflen)
{
	struct pce * pce = cookie;
	uint8_t kbuf[64];
	size_t i;

	/* Set up encryption key. */
	memset(kbuf, 0, 64);
	if ((pce->k = mkkeypair(kbuf)) == NULL)
		goto err0;

	/* Set the input. */
	for (i = 0; i < buflen; i++)
		buf[i] = (uint8_t)(i & 0xff);

	/* Success! */
	return (0);

err0:
	/* Failure! */
	return (-1);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x50, %rsp
movq %rdx, %r14
movq %rsi, %rbx
movq %rdi, %r15
pxor %xmm0, %xmm0
leaq 0x10(%rsp), %rdi
movdqa %xmm0, 0x30(%rdi)
movdqa %xmm0, 0x20(%rdi)
movdqa %xmm0, 0x10(%rdi)
movdqa %xmm0, (%rdi)
callq 0x59c4
movq %rax, (%r15)
testq %rax, %rax
je 0x4583
testq %r14, %r14
je 0x457f
leaq 0xf(%r14), %rax
andq $-0x10, %rax
decq %r14
movq %r14, %xmm0
pshufd $0x44, %xmm0, %xmm0     # xmm0 = xmm0[0,1,0,1]
movdqa %xmm0, (%rsp)
movdqa 0xb18e(%rip), %xmm1     # 0xf1d0
movdqa 0xb196(%rip), %xmm2     # 0xf1e0
movdqa 0xb19e(%rip), %xmm3     # 0xf1f0
movdqa 0xb1a6(%rip), %xmm4     # 0xf200
movdqa 0xb1ae(%rip), %xmm5     # 0xf210
movdqa 0xb1b6(%rip), %xmm6     # 0xf220
movdqa 0xb1be(%rip), %xmm7     # 0xf230
movdqa 0xb1c5(%rip), %xmm8     # 0xf240
xorl %ecx, %ecx
movdqa 0xb1ca(%rip), %xmm9     # 0xf250
pcmpeqd %xmm10, %xmm10
movdqa (%rsp), %xmm12
pxor %xmm9, %xmm12
movdqa %xmm8, %xmm13
pxor %xmm9, %xmm13
movdqa %xmm13, %xmm15
pcmpgtd %xmm12, %xmm15
pshufd $0xa0, %xmm15, %xmm14   # xmm14 = xmm15[0,0,2,2]
pshuflw $0xe8, %xmm14, %xmm0    # xmm0 = xmm14[0,2,2,3,4,5,6,7]
pcmpeqd %xmm12, %xmm13
pshufd $0xf5, %xmm13, %xmm13   # xmm13 = xmm13[1,1,3,3]
pshuflw $0xe8, %xmm13, %xmm11   # xmm11 = xmm13[0,2,2,3,4,5,6,7]
pand %xmm0, %xmm11
pshufd $0xf5, %xmm15, %xmm15   # xmm15 = xmm15[1,1,3,3]
pshuflw $0xe8, %xmm15, %xmm0    # xmm0 = xmm15[0,2,2,3,4,5,6,7]
por %xmm11, %xmm0
pxor %xmm10, %xmm0
packssdw %xmm0, %xmm0
movd %xmm0, %edx
testb $0x1, %dl
je 0x40f2
movb %cl, (%rbx,%rcx)
pand %xmm14, %xmm13
por %xmm15, %xmm13
packssdw %xmm13, %xmm13
pxor %xmm10, %xmm13
packssdw %xmm13, %xmm13
packsswb %xmm13, %xmm13
movd %xmm13, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x4124
leal 0x1(%rcx), %edx
movb %dl, 0x1(%rbx,%rcx)
movdqa %xmm7, %xmm0
pxor %xmm9, %xmm0
movdqa %xmm0, %xmm11
pcmpgtd %xmm12, %xmm11
pshufd $0xa0, %xmm11, %xmm13   # xmm13 = xmm11[0,0,2,2]
pcmpeqd %xmm12, %xmm0
pshufd $0xf5, %xmm0, %xmm14    # xmm14 = xmm0[1,1,3,3]
movdqa %xmm14, %xmm0
pand %xmm13, %xmm0
pshufd $0xf5, %xmm11, %xmm15   # xmm15 = xmm11[1,1,3,3]
por %xmm15, %xmm0
packssdw %xmm0, %xmm0
pxor %xmm10, %xmm0
packssdw %xmm0, %xmm0
packsswb %xmm0, %xmm0
movd %xmm0, %edx
shrl $0x10, %edx
testb $0x1, %dl
je 0x4181
leal 0x2(%rcx), %edx
movb %dl, 0x2(%rbx,%rcx)
pshufhw $0x84, %xmm13, %xmm0    # xmm0 = xmm13[0,1,2,3,4,5,4,6]
pshufhw $0x84, %xmm14, %xmm11   # xmm11 = xmm14[0,1,2,3,4,5,4,6]
pand %xmm0, %xmm11
pshufhw $0x84, %xmm15, %xmm0    # xmm0 = xmm15[0,1,2,3,4,5,4,6]
por %xmm11, %xmm0
pxor %xmm10, %xmm0
packssdw %xmm0, %xmm0
packsswb %xmm0, %xmm0
movd %xmm0, %edx
shrl $0x18, %edx
testb $0x1, %dl
je 0x41bd
leal 0x3(%rcx), %edx
movb %dl, 0x3(%rbx,%rcx)
movdqa %xmm6, %xmm0
pxor %xmm9, %xmm0
movdqa %xmm0, %xmm11
pcmpgtd %xmm12, %xmm11
pshufd $0xa0, %xmm11, %xmm14   # xmm14 = xmm11[0,0,2,2]
pshuflw $0xe8, %xmm14, %xmm15   # xmm15 = xmm14[0,2,2,3,4,5,6,7]
pcmpeqd %xmm12, %xmm0
pshufd $0xf5, %xmm0, %xmm13    # xmm13 = xmm0[1,1,3,3]
pshuflw $0xe8, %xmm13, %xmm0    # xmm0 = xmm13[0,2,2,3,4,5,6,7]
pand %xmm15, %xmm0
pshufd $0xf5, %xmm11, %xmm15   # xmm15 = xmm11[1,1,3,3]
pshuflw $0xe8, %xmm15, %xmm11   # xmm11 = xmm15[0,2,2,3,4,5,6,7]
por %xmm0, %xmm11
pxor %xmm10, %xmm11
packssdw %xmm11, %xmm0
packsswb %xmm0, %xmm0
pextrw $0x2, %xmm0, %edx
testb $0x1, %dl
je 0x4222
leal 0x4(%rcx), %edx
movb %dl, 0x4(%rbx,%rcx)
pand %xmm14, %xmm13
por %xmm15, %xmm13
packssdw %xmm13, %xmm13
pxor %xmm10, %xmm13
packssdw %xmm13, %xmm0
packsswb %xmm0, %xmm0
pextrw $0x2, %xmm0, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x4253
leal 0x5(%rcx), %edx
movb %dl, 0x5(%rbx,%rcx)
movdqa %xmm5, %xmm0
pxor %xmm9, %xmm0
movdqa %xmm0, %xmm11
pcmpgtd %xmm12, %xmm11
pshufd $0xa0, %xmm11, %xmm13   # xmm13 = xmm11[0,0,2,2]
pcmpeqd %xmm12, %xmm0
pshufd $0xf5, %xmm0, %xmm14    # xmm14 = xmm0[1,1,3,3]
movdqa %xmm14, %xmm0
pand %xmm13, %xmm0
pshufd $0xf5, %xmm11, %xmm15   # xmm15 = xmm11[1,1,3,3]
por %xmm15, %xmm0
packssdw %xmm0, %xmm0
pxor %xmm10, %xmm0
packssdw %xmm0, %xmm0
packsswb %xmm0, %xmm0
pextrw $0x3, %xmm0, %edx
testb $0x1, %dl
je 0x42ae
leal 0x6(%rcx), %edx
movb %dl, 0x6(%rbx,%rcx)
pshufhw $0x84, %xmm13, %xmm0    # xmm0 = xmm13[0,1,2,3,4,5,4,6]
pshufhw $0x84, %xmm14, %xmm11   # xmm11 = xmm14[0,1,2,3,4,5,4,6]
pand %xmm0, %xmm11
pshufhw $0x84, %xmm15, %xmm0    # xmm0 = xmm15[0,1,2,3,4,5,4,6]
por %xmm11, %xmm0
pxor %xmm10, %xmm0
packssdw %xmm0, %xmm0
packsswb %xmm0, %xmm0
pextrw $0x3, %xmm0, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x42eb
leal 0x7(%rcx), %edx
movb %dl, 0x7(%rbx,%rcx)
movdqa %xmm4, %xmm0
pxor %xmm9, %xmm0
movdqa %xmm0, %xmm11
pcmpgtd %xmm12, %xmm11
pshufd $0xa0, %xmm11, %xmm14   # xmm14 = xmm11[0,0,2,2]
pshuflw $0xe8, %xmm14, %xmm15   # xmm15 = xmm14[0,2,2,3,4,5,6,7]
pcmpeqd %xmm12, %xmm0
pshufd $0xf5, %xmm0, %xmm13    # xmm13 = xmm0[1,1,3,3]
pshuflw $0xe8, %xmm13, %xmm0    # xmm0 = xmm13[0,2,2,3,4,5,6,7]
pand %xmm15, %xmm0
pshufd $0xf5, %xmm11, %xmm15   # xmm15 = xmm11[1,1,3,3]
pshuflw $0xe8, %xmm15, %xmm11   # xmm11 = xmm15[0,2,2,3,4,5,6,7]
por %xmm0, %xmm11
pxor %xmm10, %xmm11
packssdw %xmm11, %xmm11
packsswb %xmm11, %xmm0
pextrw $0x4, %xmm0, %edx
testb $0x1, %dl
je 0x4351
leal 0x8(%rcx), %edx
movb %dl, 0x8(%rbx,%rcx)
pand %xmm14, %xmm13
por %xmm15, %xmm13
packssdw %xmm13, %xmm13
pxor %xmm10, %xmm13
packssdw %xmm13, %xmm13
packsswb %xmm13, %xmm0
pextrw $0x4, %xmm0, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x4383
leal 0x9(%rcx), %edx
movb %dl, 0x9(%rbx,%rcx)
movdqa %xmm3, %xmm0
pxor %xmm9, %xmm0
movdqa %xmm0, %xmm11
pcmpgtd %xmm12, %xmm11
pshufd $0xa0, %xmm11, %xmm13   # xmm13 = xmm11[0,0,2,2]
pcmpeqd %xmm12, %xmm0
pshufd $0xf5, %xmm0, %xmm14    # xmm14 = xmm0[1,1,3,3]
movdqa %xmm14, %xmm0
pand %xmm13, %xmm0
pshufd $0xf5, %xmm11, %xmm15   # xmm15 = xmm11[1,1,3,3]
por %xmm15, %xmm0
packssdw %xmm0, %xmm0
pxor %xmm10, %xmm0
packssdw %xmm0, %xmm0
packsswb %xmm0, %xmm0
pextrw $0x5, %xmm0, %edx
testb $0x1, %dl
je 0x43de
leal 0xa(%rcx), %edx
movb %dl, 0xa(%rbx,%rcx)
pshufhw $0x84, %xmm13, %xmm0    # xmm0 = xmm13[0,1,2,3,4,5,4,6]
pshufhw $0x84, %xmm14, %xmm11   # xmm11 = xmm14[0,1,2,3,4,5,4,6]
pand %xmm0, %xmm11
pshufhw $0x84, %xmm15, %xmm0    # xmm0 = xmm15[0,1,2,3,4,5,4,6]
por %xmm11, %xmm0
pxor %xmm10, %xmm0
packssdw %xmm0, %xmm0
packsswb %xmm0, %xmm0
pextrw $0x5, %xmm0, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x441b
leal 0xb(%rcx), %edx
movb %dl, 0xb(%rbx,%rcx)
movdqa %xmm2, %xmm0
pxor %xmm9, %xmm0
movdqa %xmm0, %xmm11
pcmpgtd %xmm12, %xmm11
pshufd $0xa0, %xmm11, %xmm14   # xmm14 = xmm11[0,0,2,2]
pshuflw $0xe8, %xmm14, %xmm15   # xmm15 = xmm14[0,2,2,3,4,5,6,7]
pcmpeqd %xmm12, %xmm0
pshufd $0xf5, %xmm0, %xmm13    # xmm13 = xmm0[1,1,3,3]
pshuflw $0xe8, %xmm13, %xmm0    # xmm0 = xmm13[0,2,2,3,4,5,6,7]
pand %xmm15, %xmm0
pshufd $0xf5, %xmm11, %xmm15   # xmm15 = xmm11[1,1,3,3]
pshuflw $0xe8, %xmm15, %xmm11   # xmm11 = xmm15[0,2,2,3,4,5,6,7]
por %xmm0, %xmm11
pxor %xmm10, %xmm11
packssdw %xmm11, %xmm0
packsswb %xmm0, %xmm0
pextrw $0x6, %xmm0, %edx
testb $0x1, %dl
je 0x4480
leal 0xc(%rcx), %edx
movb %dl, 0xc(%rbx,%rcx)
pand %xmm14, %xmm13
por %xmm15, %xmm13
packssdw %xmm13, %xmm13
pxor %xmm10, %xmm13
packssdw %xmm13, %xmm0
packsswb %xmm0, %xmm0
pextrw $0x6, %xmm0, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x44b1
leal 0xd(%rcx), %edx
movb %dl, 0xd(%rbx,%rcx)
movdqa %xmm1, %xmm0
pxor %xmm9, %xmm0
movdqa %xmm0, %xmm11
pcmpgtd %xmm12, %xmm11
pshufd $0xa0, %xmm11, %xmm13   # xmm13 = xmm11[0,0,2,2]
pcmpeqd %xmm12, %xmm0
pshufd $0xf5, %xmm0, %xmm12    # xmm12 = xmm0[1,1,3,3]
movdqa %xmm12, %xmm0
pand %xmm13, %xmm0
pshufd $0xf5, %xmm11, %xmm14   # xmm14 = xmm11[1,1,3,3]
por %xmm14, %xmm0
packssdw %xmm0, %xmm0
pxor %xmm10, %xmm0
packssdw %xmm0, %xmm0
packsswb %xmm0, %xmm0
pextrw $0x7, %xmm0, %edx
testb $0x1, %dl
je 0x450c
leal 0xe(%rcx), %edx
movb %dl, 0xe(%rbx,%rcx)
pshufhw $0x84, %xmm13, %xmm0    # xmm0 = xmm13[0,1,2,3,4,5,4,6]
pshufhw $0x84, %xmm12, %xmm11   # xmm11 = xmm12[0,1,2,3,4,5,4,6]
pand %xmm0, %xmm11
pshufhw $0x84, %xmm14, %xmm0    # xmm0 = xmm14[0,1,2,3,4,5,4,6]
por %xmm11, %xmm0
pxor %xmm10, %xmm0
packssdw %xmm0, %xmm0
packsswb %xmm0, %xmm0
pextrw $0x7, %xmm0, %edx
shrl $0x8, %edx
testb $0x1, %dl
je 0x4549
leal 0xf(%rcx), %edx
movb %dl, 0xf(%rbx,%rcx)
addq $0x10, %rcx
movdqa 0xad0b(%rip), %xmm0     # 0xf260
paddq %xmm0, %xmm8
paddq %xmm0, %xmm7
paddq %xmm0, %xmm6
paddq %xmm0, %xmm5
paddq %xmm0, %xmm4
paddq %xmm0, %xmm3
paddq %xmm0, %xmm2
paddq %xmm0, %xmm1
cmpq %rcx, %rax
jne 0x408b
xorl %eax, %eax
jmp 0x4588
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x50, %rsp
popq %rbx
popq %r14
popq %r15
retq