// File: /workspace/github_cpp_makefile_star2_O3/DiplIngFrankGerlach[P]MST/./aes/aes.c
// Function: InvMixColumns
void InvMixColumns(BYTE state[][4])
{
	BYTE col[4];

	// Column 1
	col[0] = state[0][0];
	col[1] = state[1][0];
	col[2] = state[2][0];
	col[3] = state[3][0];
	state[0][0] = gf_mul[col[0]][5];
	state[0][0] ^= gf_mul[col[1]][3];
	state[0][0] ^= gf_mul[col[2]][4];
	state[0][0] ^= gf_mul[col[3]][2];
	state[1][0] = gf_mul[col[0]][2];
	state[1][0] ^= gf_mul[col[1]][5];
	state[1][0] ^= gf_mul[col[2]][3];
	state[1][0] ^= gf_mul[col[3]][4];
	state[2][0] = gf_mul[col[0]][4];
	state[2][0] ^= gf_mul[col[1]][2];
	state[2][0] ^= gf_mul[col[2]][5];
	state[2][0] ^= gf_mul[col[3]][3];
	state[3][0] = gf_mul[col[0]][3];
	state[3][0] ^= gf_mul[col[1]][4];
	state[3][0] ^= gf_mul[col[2]][2];
	state[3][0] ^= gf_mul[col[3]][5];
	// Column 2
	col[0] = state[0][1];
	col[1] = state[1][1];
	col[2] = state[2][1];
	col[3] = state[3][1];
	state[0][1] = gf_mul[col[0]][5];
	state[0][1] ^= gf_mul[col[1]][3];
	state[0][1] ^= gf_mul[col[2]][4];
	state[0][1] ^= gf_mul[col[3]][2];
	state[1][1] = gf_mul[col[0]][2];
	state[1][1] ^= gf_mul[col[1]][5];
	state[1][1] ^= gf_mul[col[2]][3];
	state[1][1] ^= gf_mul[col[3]][4];
	state[2][1] = gf_mul[col[0]][4];
	state[2][1] ^= gf_mul[col[1]][2];
	state[2][1] ^= gf_mul[col[2]][5];
	state[2][1] ^= gf_mul[col[3]][3];
	state[3][1] = gf_mul[col[0]][3];
	state[3][1] ^= gf_mul[col[1]][4];
	state[3][1] ^= gf_mul[col[2]][2];
	state[3][1] ^= gf_mul[col[3]][5];
	// Column 3
	col[0] = state[0][2];
	col[1] = state[1][2];
	col[2] = state[2][2];
	col[3] = state[3][2];
	state[0][2] = gf_mul[col[0]][5];
	state[0][2] ^= gf_mul[col[1]][3];
	state[0][2] ^= gf_mul[col[2]][4];
	state[0][2] ^= gf_mul[col[3]][2];
	state[1][2] = gf_mul[col[0]][2];
	state[1][2] ^= gf_mul[col[1]][5];
	state[1][2] ^= gf_mul[col[2]][3];
	state[1][2] ^= gf_mul[col[3]][4];
	state[2][2] = gf_mul[col[0]][4];
	state[2][2] ^= gf_mul[col[1]][2];
	state[2][2] ^= gf_mul[col[2]][5];
	state[2][2] ^= gf_mul[col[3]][3];
	state[3][2] = gf_mul[col[0]][3];
	state[3][2] ^= gf_mul[col[1]][4];
	state[3][2] ^= gf_mul[col[2]][2];
	state[3][2] ^= gf_mul[col[3]][5];
	// Column 4
	col[0] = state[0][3];
	col[1] = state[1][3];
	col[2] = state[2][3];
	col[3] = state[3][3];
	state[0][3] = gf_mul[col[0]][5];
	state[0][3] ^= gf_mul[col[1]][3];
	state[0][3] ^= gf_mul[col[2]][4];
	state[0][3] ^= gf_mul[col[3]][2];
	state[1][3] = gf_mul[col[0]][2];
	state[1][3] ^= gf_mul[col[1]][5];
	state[1][3] ^= gf_mul[col[2]][3];
	state[1][3] ^= gf_mul[col[3]][4];
	state[2][3] = gf_mul[col[0]][4];
	state[2][3] ^= gf_mul[col[1]][2];
	state[2][3] ^= gf_mul[col[2]][5];
	state[2][3] ^= gf_mul[col[3]][3];
	state[3][3] = gf_mul[col[0]][3];
	state[3][3] ^= gf_mul[col[1]][4];
	state[3][3] ^= gf_mul[col[2]][2];
	state[3][3] ^= gf_mul[col[3]][5];
}

// Assembly:
movzbl (%rdi), %eax
movzbl 0x4(%rdi), %edx
movzbl 0x8(%rdi), %esi
leaq (%rax,%rax,2), %rcx
leaq 0x225e(%rip), %rax      # 0x5260
leaq (%rdx,%rdx,2), %rdx
movb 0x3(%rax,%rdx,2), %r8b
xorb 0x5(%rax,%rcx,2), %r8b
movzbl 0xc(%rdi), %r9d
leaq (%rsi,%rsi,2), %rsi
xorb 0x4(%rax,%rsi,2), %r8b
movb 0x2(%rax,%rdx,2), %r10b
leaq (%r9,%r9,2), %r9
xorb 0x2(%rax,%r9,2), %r8b
movb %r8b, (%rdi)
movb 0x5(%rax,%rdx,2), %r8b
xorb 0x2(%rax,%rcx,2), %r8b
xorb 0x3(%rax,%rsi,2), %r8b
xorb 0x4(%rax,%r9,2), %r8b
movb %r8b, 0x4(%rdi)
xorb 0x4(%rax,%rcx,2), %r10b
xorb 0x5(%rax,%rsi,2), %r10b
xorb 0x3(%rax,%r9,2), %r10b
movb %r10b, 0x8(%rdi)
movb 0x4(%rax,%rdx,2), %dl
xorb 0x3(%rax,%rcx,2), %dl
xorb 0x2(%rax,%rsi,2), %dl
xorb 0x5(%rax,%r9,2), %dl
movb %dl, 0xc(%rdi)
movzbl 0x1(%rdi), %ecx
movzbl 0x5(%rdi), %edx
movzbl 0x9(%rdi), %esi
movzbl 0xd(%rdi), %r8d
leaq (%rcx,%rcx,2), %rcx
leaq (%rdx,%rdx,2), %rdx
movb 0x2(%rax,%rdx,2), %r9b
movb 0x3(%rax,%rdx,2), %r10b
xorb 0x5(%rax,%rcx,2), %r10b
leaq (%rsi,%rsi,2), %rsi
xorb 0x4(%rax,%rsi,2), %r10b
leaq (%r8,%r8,2), %r8
xorb 0x2(%rax,%r8,2), %r10b
movb %r10b, 0x1(%rdi)
movb 0x5(%rax,%rdx,2), %r10b
xorb 0x2(%rax,%rcx,2), %r10b
xorb 0x3(%rax,%rsi,2), %r10b
xorb 0x4(%rax,%r8,2), %r10b
movb %r10b, 0x5(%rdi)
xorb 0x4(%rax,%rcx,2), %r9b
xorb 0x5(%rax,%rsi,2), %r9b
xorb 0x3(%rax,%r8,2), %r9b
movb %r9b, 0x9(%rdi)
movb 0x4(%rax,%rdx,2), %dl
xorb 0x3(%rax,%rcx,2), %dl
xorb 0x2(%rax,%rsi,2), %dl
xorb 0x5(%rax,%r8,2), %dl
movb %dl, 0xd(%rdi)
movzbl 0x2(%rdi), %ecx
movzbl 0x6(%rdi), %edx
movzbl 0xa(%rdi), %esi
leaq (%rcx,%rcx,2), %rcx
leaq (%rdx,%rdx,2), %rdx
movb 0x3(%rax,%rdx,2), %r8b
xorb 0x5(%rax,%rcx,2), %r8b
movzbl 0xe(%rdi), %r9d
leaq (%rsi,%rsi,2), %rsi
xorb 0x4(%rax,%rsi,2), %r8b
movb 0x2(%rax,%rdx,2), %r10b
leaq (%r9,%r9,2), %r9
xorb 0x2(%rax,%r9,2), %r8b
movb %r8b, 0x2(%rdi)
movb 0x5(%rax,%rdx,2), %r8b
xorb 0x2(%rax,%rcx,2), %r8b
xorb 0x3(%rax,%rsi,2), %r8b
xorb 0x4(%rax,%r9,2), %r8b
movb %r8b, 0x6(%rdi)
xorb 0x4(%rax,%rcx,2), %r10b
xorb 0x5(%rax,%rsi,2), %r10b
xorb 0x3(%rax,%r9,2), %r10b
movb %r10b, 0xa(%rdi)
movb 0x4(%rax,%rdx,2), %dl
xorb 0x3(%rax,%rcx,2), %dl
xorb 0x2(%rax,%rsi,2), %dl
xorb 0x5(%rax,%r9,2), %dl
movb %dl, 0xe(%rdi)
movzbl 0x3(%rdi), %ecx
movzbl 0x7(%rdi), %edx
movzbl 0xb(%rdi), %esi
movzbl 0xf(%rdi), %r8d
leaq (%rcx,%rcx,2), %rcx
leaq (%rdx,%rdx,2), %rdx
movb 0x2(%rax,%rdx,2), %r9b
movb 0x3(%rax,%rdx,2), %r10b
xorb 0x5(%rax,%rcx,2), %r10b
leaq (%rsi,%rsi,2), %rsi
xorb 0x4(%rax,%rsi,2), %r10b
leaq (%r8,%r8,2), %r8
xorb 0x2(%rax,%r8,2), %r10b
movb %r10b, 0x3(%rdi)
movb 0x5(%rax,%rdx,2), %r10b
xorb 0x2(%rax,%rcx,2), %r10b
xorb 0x3(%rax,%rsi,2), %r10b
xorb 0x4(%rax,%r8,2), %r10b
movb %r10b, 0x7(%rdi)
xorb 0x4(%rax,%rcx,2), %r9b
xorb 0x5(%rax,%rsi,2), %r9b
xorb 0x3(%rax,%r8,2), %r9b
movb %r9b, 0xb(%rdi)
movb 0x4(%rax,%rdx,2), %dl
xorb 0x3(%rax,%rcx,2), %dl
xorb 0x2(%rax,%rsi,2), %dl
xorb 0x5(%rax,%r8,2), %dl
movb %dl, 0xf(%rdi)
retq
nop