// File: /workspace/github_c_makefile_star2_O2/mjosaarinen[P]brutus/crypto_aead/aes256otrpv3/ni_p8m1/encrypt.c
// Function: AES_ecb_encrypt_PIPE
__inline__ static void AES_ecb_encrypt_PIPE(
	__m128i *blks,
	const __m128i *key)
{
	unsigned j;
	blks[0] = _mm_xor_si128(blks[0], key[0]);
	blks[1] = _mm_xor_si128(blks[1], key[0]);
	blks[2] = _mm_xor_si128(blks[2], key[0]);
	blks[3] = _mm_xor_si128(blks[3], key[0]);
#if (PIPE>=5)
	blks[4] = _mm_xor_si128(blks[4], key[0]);
#endif
#if (PIPE>=6)
	blks[5] = _mm_xor_si128(blks[5], key[0]);
#endif
#if (PIPE>=7)
	blks[6] = _mm_xor_si128(blks[6], key[0]);
#endif
#if (PIPE==8)
	blks[7] = _mm_xor_si128(blks[7], key[0]);
#endif
	for (j = 1; j<ROUND; ++j) {
		blks[0] = _mm_aesenc_si128(blks[0], key[j]);
		blks[1] = _mm_aesenc_si128(blks[1], key[j]);
		blks[2] = _mm_aesenc_si128(blks[2], key[j]);
		blks[3] = _mm_aesenc_si128(blks[3], key[j]);
#if (PIPE>=5)
		blks[4] = _mm_aesenc_si128(blks[4], key[j]);
#endif
#if (PIPE>=6)
		blks[5] = _mm_aesenc_si128(blks[5], key[j]);
#endif
#if (PIPE>=7)
		blks[6] = _mm_aesenc_si128(blks[6], key[j]);
#endif
#if (PIPE==8)
		blks[7] = _mm_aesenc_si128(blks[7], key[j]);
#endif
	}
	blks[0] = _mm_aesenclast_si128(blks[0], key[j]);
	blks[1] = _mm_aesenclast_si128(blks[1], key[j]);
	blks[2] = _mm_aesenclast_si128(blks[2], key[j]);
	blks[3] = _mm_aesenclast_si128(blks[3], key[j]);
#if (PIPE>=5)
	blks[4] = _mm_aesenclast_si128(blks[4], key[j]);
#endif
#if (PIPE>=6)
	blks[5] = _mm_aesenclast_si128(blks[5], key[j]);
#endif
#if (PIPE>=7)
	blks[6] = _mm_aesenclast_si128(blks[6], key[j]);
#endif
#if (PIPE==8)
	blks[7] = _mm_aesenclast_si128(blks[7], key[j]);
#endif
}

// Assembly:
movq 0x556c(%rip), %rax      # 0x6ff0
vmovdqa (%rax), %xmm0
vpxor (%rdi), %xmm0, %xmm0
vmovdqa %xmm0, (%rdi)
vmovdqa (%rax), %xmm1
vpxor 0x10(%rdi), %xmm1, %xmm7
vmovdqa %xmm7, 0x10(%rdi)
vpxor 0x20(%rdi), %xmm1, %xmm6
vmovdqa %xmm6, 0x20(%rdi)
vpxor 0x30(%rdi), %xmm1, %xmm5
vmovdqa %xmm5, 0x30(%rdi)
vpxor 0x40(%rdi), %xmm1, %xmm4
vmovdqa %xmm4, 0x40(%rdi)
vpxor 0x50(%rdi), %xmm1, %xmm3
vmovdqa %xmm3, 0x50(%rdi)
vpxor 0x60(%rdi), %xmm1, %xmm2
vmovdqa %xmm2, 0x60(%rdi)
vpxor 0x70(%rdi), %xmm1, %xmm1
vmovdqa %xmm1, 0x70(%rdi)
pushq $0x10
popq %rcx
cmpq $0xe0, %rcx
je 0x1b43
vaesenc (%rax,%rcx), %xmm0, %xmm0
vmovdqa %xmm0, (%rdi)
vaesenc (%rax,%rcx), %xmm7, %xmm7
vmovdqa %xmm7, 0x10(%rdi)
vaesenc (%rax,%rcx), %xmm6, %xmm6
vmovdqa %xmm6, 0x20(%rdi)
vaesenc (%rax,%rcx), %xmm5, %xmm5
vmovdqa %xmm5, 0x30(%rdi)
vaesenc (%rax,%rcx), %xmm4, %xmm4
vmovdqa %xmm4, 0x40(%rdi)
vaesenc (%rax,%rcx), %xmm3, %xmm3
vmovdqa %xmm3, 0x50(%rdi)
vaesenc (%rax,%rcx), %xmm2, %xmm2
vmovdqa %xmm2, 0x60(%rdi)
vaesenc (%rax,%rcx), %xmm1, %xmm1
vmovdqa %xmm1, 0x70(%rdi)
addq $0x10, %rcx
jmp 0x1add
vaesenclast 0xe0(%rax), %xmm0, %xmm0
vmovdqa %xmm0, (%rdi)
vaesenclast 0xe0(%rax), %xmm7, %xmm0
vmovdqa %xmm0, 0x10(%rdi)
vaesenclast 0xe0(%rax), %xmm6, %xmm0
vmovdqa %xmm0, 0x20(%rdi)
vaesenclast 0xe0(%rax), %xmm5, %xmm0
vmovdqa %xmm0, 0x30(%rdi)
vaesenclast 0xe0(%rax), %xmm4, %xmm0
vmovdqa %xmm0, 0x40(%rdi)
vaesenclast 0xe0(%rax), %xmm3, %xmm0
vmovdqa %xmm0, 0x50(%rdi)
vaesenclast 0xe0(%rax), %xmm2, %xmm0
vmovdqa %xmm0, 0x60(%rdi)
vaesenclast 0xe0(%rax), %xmm1, %xmm0
vmovdqa %xmm0, 0x70(%rdi)
retq