#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ memset(int *, int, int);
int /*<<< orphan*/ printf(char *, char *);
void open_votes(int (*votes)[20 + 1], char (*cand_name)[80 + 1], int num_voter,
                int num_cand) {
  int first_alive_cand[1000 + 1];
  int votes_to_get[1000 + 1];
  int min, max, who_is_max;
  int is_all_tied, is_winner;
  int i, cand_id;
  memset(votes_to_get, 0x00, sizeof(int) * (1000 + 1));
  for (i = 1; i <= num_voter; i++) {
    first_alive_cand[i] = 1;
  }
  for (i = 1; i <= num_voter; i++) {
    cand_id = votes[i][first_alive_cand[i]];
    votes_to_get[cand_id]++;
  }
  is_all_tied = is_winner = 0;
  while (1) {
    max = 0, min = num_voter;
    for (i = 1; i <= num_cand; i++) {
      max = (votes_to_get[i] >= 0 && votes_to_get[i] > max) ? who_is_max = i,
      votes_to_get[i]                                       : max;
      min = (votes_to_get[i] >= 0 && votes_to_get[i] < min) ? votes_to_get[i]
                                                            : min;
    }
    if (max == min) {
      is_all_tied = 1;
      break;
    } else if (max * 2 > num_voter) {
      is_winner = 1;
      break;
    }
    for (i = 1; i <= num_voter; i++) {
      if (votes_to_get[votes[i][first_alive_cand[i]]] == min) {
        first_alive_cand[i]++;
        while (votes_to_get[votes[i][first_alive_cand[i]]] <= min) {
          first_alive_cand[i]++;
        }
        votes_to_get[votes[i][first_alive_cand[i]]]++;
      }
    }
    for (i = 1; i <= num_cand; i++) {
      if (votes_to_get[i] == min) {
        votes_to_get[i] = -1;
      }
    }
  }
  if (is_all_tied == 1) {
    for (i = 1; i <= num_cand; i++) {
      if (votes_to_get[i] > 0) {
        printf("%s\n", &cand_name[i][0]);
      }
    }
  } else {
    printf("%s\n", &cand_name[who_is_max][0]);
  }
  return;
}


x86 assembly (clang, -O0):
<open_votes>:
push   %rbp
mov    %rsp,%rbp
sub    $0x1fa0,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %ecx,-0x18(%rbp)
lea    -0x1f70(%rbp),%rdi
xor    %esi,%esi
mov    $0xfa4,%edx
call   1040 <memset@plt>
movl   $0x1,-0x1f88(%rbp)
mov    -0x1f88(%rbp),%eax
cmp    -0x14(%rbp),%eax
jg     118b <open_votes+0x6b>
movslq -0x1f88(%rbp),%rax
movl   $0x1,-0xfc0(%rbp,%rax,4)
mov    -0x1f88(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1f88(%rbp)
jmp    1156 <open_votes+0x36>
movl   $0x1,-0x1f88(%rbp)
mov    -0x1f88(%rbp),%eax
cmp    -0x14(%rbp),%eax
jg     11fa <open_votes+0xda>
mov    -0x8(%rbp),%rax
movslq -0x1f88(%rbp),%rcx
imul   $0x54,%rcx,%rcx
add    %rcx,%rax
movslq -0x1f88(%rbp),%rcx
movslq -0xfc0(%rbp,%rcx,4),%rcx
ff
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x1f8c(%rbp)
movslq -0x1f8c(%rbp),%rax
mov    -0x1f70(%rbp,%rax,4),%ecx
add    $0x1,%ecx
mov    %ecx,-0x1f70(%rbp,%rax,4)
mov    -0x1f88(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1f88(%rbp)
jmp    1195 <open_votes+0x75>
movl   $0x0,-0x1f84(%rbp)
movl   $0x0,-0x1f80(%rbp)
movl   $0x0,-0x1f78(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x1f74(%rbp)
movl   $0x1,-0x1f88(%rbp)
mov    -0x1f88(%rbp),%eax
cmp    -0x18(%rbp),%eax
jg     131a <open_votes+0x1fa>
movslq -0x1f88(%rbp),%rax
cmpl   $0x0,-0x1f70(%rbp,%rax,4)
jl     128e <open_votes+0x16e>
movslq -0x1f88(%rbp),%rax
mov    -0x1f70(%rbp,%rax,4),%eax
cmp    -0x1f78(%rbp),%eax
jle    128e <open_votes+0x16e>
mov    -0x1f88(%rbp),%eax
mov    %eax,-0x1f7c(%rbp)
movslq -0x1f88(%rbp),%rax
mov    -0x1f70(%rbp,%rax,4),%eax
mov    %eax,-0x1f90(%rbp)
jmp    129a <open_votes+0x17a>
mov    -0x1f78(%rbp),%eax
mov    %eax,-0x1f90(%rbp)
mov    -0x1f90(%rbp),%eax
mov    %eax,-0x1f78(%rbp)
movslq -0x1f88(%rbp),%rax
cmpl   $0x0,-0x1f70(%rbp,%rax,4)
jl     12ee <open_votes+0x1ce>
movslq -0x1f88(%rbp),%rax
mov    -0x1f70(%rbp,%rax,4),%eax
cmp    -0x1f74(%rbp),%eax
jge    12ee <open_votes+0x1ce>
movslq -0x1f88(%rbp),%rax
mov    -0x1f70(%rbp,%rax,4),%eax
mov    %eax,-0x1f94(%rbp)
jmp    12fa <open_votes+0x1da>
mov    -0x1f74(%rbp),%eax
mov    %eax,-0x1f94(%rbp)
mov    -0x1f94(%rbp),%eax
mov    %eax,-0x1f74(%rbp)
mov    -0x1f88(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1f88(%rbp)
jmp    122b <open_votes+0x10b>
mov    -0x1f78(%rbp),%eax
cmp    -0x1f74(%rbp),%eax
jne    133b <open_votes+0x21b>
movl   $0x1,-0x1f80(%rbp)
jmp    14d1 <open_votes+0x3b1>
mov    -0x1f78(%rbp),%eax
shl    $0x1,%eax
cmp    -0x14(%rbp),%eax
jle    135c <open_votes+0x23c>
movl   $0x1,-0x1f84(%rbp)
jmp    14d1 <open_votes+0x3b1>
jmp    1361 <open_votes+0x241>
movl   $0x1,-0x1f88(%rbp)
mov    -0x1f88(%rbp),%eax
cmp    -0x14(%rbp),%eax
jg     146e <open_votes+0x34e>
mov    -0x8(%rbp),%rax
movslq -0x1f88(%rbp),%rcx
imul   $0x54,%rcx,%rcx
add    %rcx,%rax
movslq -0x1f88(%rbp),%rcx
movslq -0xfc0(%rbp,%rcx,4),%rcx
ff
movslq (%rax,%rcx,4),%rax
mov    -0x1f70(%rbp,%rax,4),%eax
cmp    -0x1f74(%rbp),%eax
jne    1455 <open_votes+0x335>
movslq -0x1f88(%rbp),%rax
mov    -0xfc0(%rbp,%rax,4),%ecx
add    $0x1,%ecx
mov    %ecx,-0xfc0(%rbp,%rax,4)
mov    -0x8(%rbp),%rax
movslq -0x1f88(%rbp),%rcx
imul   $0x54,%rcx,%rcx
add    %rcx,%rax
movslq -0x1f88(%rbp),%rcx
movslq -0xfc0(%rbp,%rcx,4),%rcx
ff
movslq (%rax,%rcx,4),%rax
mov    -0x1f70(%rbp,%rax,4),%eax
cmp    -0x1f74(%rbp),%eax
jg     141f <open_votes+0x2ff>
movslq -0x1f88(%rbp),%rax
mov    -0xfc0(%rbp,%rax,4),%ecx
add    $0x1,%ecx
mov    %ecx,-0xfc0(%rbp,%rax,4)
jmp    13ca <open_votes+0x2aa>
mov    -0x8(%rbp),%rax
movslq -0x1f88(%rbp),%rcx
imul   $0x54,%rcx,%rcx
add    %rcx,%rax
movslq -0x1f88(%rbp),%rcx
movslq -0xfc0(%rbp,%rcx,4),%rcx
ff
movslq (%rax,%rcx,4),%rax
mov    -0x1f70(%rbp,%rax,4),%ecx
add    $0x1,%ecx
mov    %ecx,-0x1f70(%rbp,%rax,4)
jmp    145a <open_votes+0x33a>
mov    -0x1f88(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1f88(%rbp)
jmp    136b <open_votes+0x24b>
movl   $0x1,-0x1f88(%rbp)
mov    -0x1f88(%rbp),%eax
cmp    -0x18(%rbp),%eax
jg     14cc <open_votes+0x3ac>
movslq -0x1f88(%rbp),%rax
mov    -0x1f70(%rbp,%rax,4),%eax
cmp    -0x1f74(%rbp),%eax
jne    14b3 <open_votes+0x393>
movslq -0x1f88(%rbp),%rax
movl   $0xffffffff,-0x1f70(%rbp,%rax,4)
ff ff ff ff
jmp    14b8 <open_votes+0x398>
mov    -0x1f88(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1f88(%rbp)
jmp    1478 <open_votes+0x358>
jmp    120e <open_votes+0xee>
cmpl   $0x1,-0x1f80(%rbp)
jne    1548 <open_votes+0x428>
movl   $0x1,-0x1f88(%rbp)
mov    -0x1f88(%rbp),%eax
cmp    -0x18(%rbp),%eax
jg     1543 <open_votes+0x423>
movslq -0x1f88(%rbp),%rax
cmpl   $0x0,-0x1f70(%rbp,%rax,4)
jle    152a <open_votes+0x40a>
mov    -0x10(%rbp),%rsi
movslq -0x1f88(%rbp),%rax
imul   $0x51,%rax,%rax
add    %rax,%rsi
lea    0xadb(%rip),%rdi
call   1030 <printf@plt>
jmp    152f <open_votes+0x40f>
mov    -0x1f88(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1f88(%rbp)
jmp    14e8 <open_votes+0x3c8>
jmp    1566 <open_votes+0x446>
mov    -0x10(%rbp),%rsi
movslq -0x1f7c(%rbp),%rax
imul   $0x51,%rax,%rax
add    %rax,%rsi
lea    0xa9f(%rip),%rdi
call   1030 <printf@plt>
add    $0x1fa0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<open_votes>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x1f98,%rsp
mov    %rcx,0x18(%rsp)
mov    %edx,%ebx
mov    %rsi,%r14
mov    %rdi,%r15
lea    0x40(%rsp),%rdi
xor    %esi,%esi
mov    $0xfa4,%edx
call   1040 <memset@plt>
test   %ebx,%ebx
mov    %rbx,0x8(%rsp)
jle    12ed <open_votes+0x1cd>
mov    %ebx,%eax
lea    0x1(%rax),%rcx
mov    $0x1,%edx
cmp    $0x8,%ebx
jb     1250 <open_votes+0x130>
mov    %eax,%edx
and    $0xfffffff8,%edx
lea    -0x8(%rdx),%rdi
mov    %rdi,%rsi
shr    $0x3,%rsi
add    $0x1,%rsi
mov    %esi,%ebp
and    $0x3,%ebp
cmp    $0x18,%rdi
jae    1193 <open_votes+0x73>
xor    %edi,%edi
jmp    1202 <open_votes+0xe2>
and    $0xfffffffffffffffc,%rsi
xor    %edi,%edi
movdqa 0xe5f(%rip),%xmm0
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
movdqu %xmm0,0xff4(%rsp,%rdi,4)
movdqu %xmm0,0x1004(%rsp,%rdi,4)
movdqu %xmm0,0x1014(%rsp,%rdi,4)
movdqu %xmm0,0x1024(%rsp,%rdi,4)
movdqu %xmm0,0x1034(%rsp,%rdi,4)
movdqu %xmm0,0x1044(%rsp,%rdi,4)
movdqu %xmm0,0x1054(%rsp,%rdi,4)
movdqu %xmm0,0x1064(%rsp,%rdi,4)
add    $0x20,%rdi
add    $0xfffffffffffffffc,%rsi
jne    11b0 <open_votes+0x90>
test   %rbp,%rbp
je     1238 <open_votes+0x118>
movdqa 0xdf1(%rip),%xmm0
nop
lea    0x0(,%rdi,4),%rsi
or     $0x4,%rsi
movdqu %xmm0,0xff0(%rsp,%rsi,1)
movdqu %xmm0,0x1000(%rsp,%rsi,1)
add    $0x8,%rdi
add    $0xffffffffffffffff,%rbp
jne    1210 <open_votes+0xf0>
cmp    %rdx,%rax
mov    0x8(%rsp),%rbx
je     1264 <open_votes+0x144>
or     $0x1,%rdx
cs nopw 0x0(%rax,%rax,1)
movl   $0x1,0xff0(%rsp,%rdx,4)
add    $0x1,%rdx
cmp    %rdx,%rcx
jne    1250 <open_votes+0x130>
test   %ebx,%ebx
jle    12ed <open_votes+0x1cd>
mov    $0x1,%edx
cmp    $0x2,%ecx
je     12cc <open_votes+0x1ac>
lea    0x54(%r15),%rcx
mov    %eax,%esi
and    $0xfffffffe,%esi
neg    %rsi
mov    $0x1,%edx
nopw   0x0(%rax,%rax,1)
movslq 0xff0(%rsp,%rdx,4),%rdi
movslq (%rcx,%rdi,4),%rdi
addl   $0x1,0x40(%rsp,%rdi,4)
movslq 0xff4(%rsp,%rdx,4),%rdi
movslq 0x54(%rcx,%rdi,4),%rdi
addl   $0x1,0x40(%rsp,%rdi,4)
add    $0xa8,%rcx
lea    (%rsi,%rdx,1),%rdi
add    $0x2,%rdi
add    $0x2,%rdx
cmp    $0x1,%rdi
jne    1290 <open_votes+0x170>
test   $0x1,%al
mov    0x8(%rsp),%rbx
je     12ed <open_votes+0x1cd>
movslq 0xff0(%rsp,%rdx,4),%rax
imul   $0x54,%rdx,%rcx
add    %r15,%rcx
movslq (%rcx,%rax,4),%rax
addl   $0x1,0x40(%rsp,%rax,4)
lea    0x1(%rbx),%r12d
mov    0x18(%rsp),%r8
lea    0x1(%r8),%r13d
lea    -0x1(%r13),%r11
mov    %r11,%r9
and    $0xfffffffffffffffe,%r9
mov    %r11,%rax
mov    %r11,0x10(%rsp)
and    $0xfffffffffffffff8,%r11
lea    0x1(%r11),%rax
mov    %rax,0x20(%rsp)
mov    %r13,%rax
neg    %rax
mov    %rax,0x30(%rsp)
lea    0x58(%r15),%rax
mov    %rax,0x38(%rsp)
mov    %r14,0x28(%rsp)
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
test   %r8d,%r8d
jle    1370 <open_votes+0x250>
cmp    $0x2,%r13d
mov    0x8(%rsp),%rdi
jne    1390 <open_votes+0x270>
xor    %ebp,%ebp
mov    $0x1,%r8d
mov    %edi,%ecx
testb  $0x1,0x10(%rsp)
jne    1411 <open_votes+0x2f1>
jmp    1433 <open_votes+0x313>
nopw   0x0(%rax,%rax,1)
xor    %ebp,%ebp
mov    0x8(%rsp),%rdi
mov    %edi,%ecx
test   %edi,%edi
jne    1440 <open_votes+0x320>
jmp    1628 <open_votes+0x508>
cs nopw 0x0(%rax,%rax,1)
xor    %ebp,%ebp
mov    $0x1,%r8d
mov    %edi,%ecx
jmp    13a9 <open_votes+0x289>
nopl   0x0(%rax)
add    $0x2,%r8
cmp    %r9,%r14
je     1400 <open_votes+0x2e0>
mov    %ecx,%eax
mov    0x40(%rsp,%r8,4),%esi
cmp    %ebp,%esi
setg   %dl
cmp    %ecx,%esi
cmovl  %esi,%ecx
test   %esi,%esi
setns  %bl
cmovs  %eax,%ecx
mov    %r8d,%edi
test   %dl,%bl
jne    13ce <open_votes+0x2ae>
mov    %r10d,%edi
mov    %ebp,%esi
mov    0x44(%rsp,%r8,4),%ebp
cmp    %esi,%ebp
setg   %dl
lea    0x1(%r8),%r14
mov    %ebp,%eax
cmp    %ecx,%ebp
jl     13e4 <open_votes+0x2c4>
mov    %ecx,%eax
test   %ebp,%ebp
setns  %bl
cmovns %eax,%ecx
mov    %r14d,%r10d
test   %dl,%bl
jne    13a0 <open_votes+0x280>
mov    %edi,%r10d
mov    %esi,%ebp
jmp    13a0 <open_votes+0x280>
nopw   0x0(%rax,%rax,1)
mov    0x28(%rsp),%r14
mov    0x8(%rsp),%rdi
testb  $0x1,0x10(%rsp)
je     1433 <open_votes+0x313>
mov    0x40(%rsp,%r8,4),%eax
cmp    %ebp,%eax
setg   %dl
cmp    %ecx,%eax
mov    %ecx,%esi
cmovl  %eax,%esi
test   %eax,%eax
setns  %bl
cmovns %esi,%ecx
test   %dl,%bl
cmovne %r8d,%r10d
cmovne %eax,%ebp
cmp    %ecx,%ebp
mov    0x18(%rsp),%r8
je     163a <open_votes+0x51a>
add    %ebp,%ebp
cmp    %edi,%ebp
jg     160b <open_votes+0x4eb>
test   %edi,%edi
jle    14c0 <open_votes+0x3a0>
mov    $0x1,%ebp
mov    0x38(%rsp),%rsi
jmp    146d <open_votes+0x34d>
nopw   0x0(%rax,%rax,1)
add    $0x1,%rbp
add    $0x54,%rsi
cmp    %r12,%rbp
je     14c0 <open_votes+0x3a0>
mov    0xff0(%rsp,%rbp,4),%edi
movslq %edi,%rax
imul   $0x54,%rbp,%rdx
add    %r15,%rdx
movslq (%rdx,%rax,4),%rdx
cmp    %ecx,0x40(%rsp,%rdx,4)
jne    1460 <open_votes+0x340>
lea    (%rsi,%rax,4),%rdx
nopl   0x0(%rax)
movslq (%rdx),%rbx
mov    0x40(%rsp,%rbx,4),%eax
add    $0x1,%edi
add    $0x4,%rdx
cmp    %ecx,%eax
jle    1490 <open_votes+0x370>
mov    %edi,0xff0(%rsp,%rbp,4)
add    $0x1,%eax
mov    %eax,0x40(%rsp,%rbx,4)
jmp    1460 <open_votes+0x340>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
test   %r8d,%r8d
jle    1340 <open_votes+0x220>
mov    $0x1,%edi
cmpq   $0x8,0x10(%rsp)
jb     15b0 <open_votes+0x490>
movd   %ecx,%xmm0
pshufd $0x0,%xmm0,%xmm0
xor    %ebp,%ebp
jmp    14fd <open_votes+0x3dd>
nopw   0x0(%rax,%rax,1)
add    $0x8,%rbp
cmp    %rbp,%r11
je     15a0 <open_votes+0x480>
movdqu 0x44(%rsp,%rbp,4),%xmm1
pcmpeqd %xmm0,%xmm1
movd   %xmm1,%eax
test   $0x1,%al
je     1517 <open_votes+0x3f7>
movl   $0xffffffff,0x44(%rsp,%rbp,4)
ff
pextrw $0x2,%xmm1,%eax
test   $0x1,%al
je     1528 <open_votes+0x408>
movl   $0xffffffff,0x48(%rsp,%rbp,4)
ff
pextrw $0x4,%xmm1,%eax
test   $0x1,%al
je     1539 <open_votes+0x419>
movl   $0xffffffff,0x4c(%rsp,%rbp,4)
ff
pextrw $0x6,%xmm1,%eax
test   $0x1,%al
je     154a <open_votes+0x42a>
movl   $0xffffffff,0x50(%rsp,%rbp,4)
ff
movdqu 0x54(%rsp,%rbp,4),%xmm1
pcmpeqd %xmm0,%xmm1
movd   %xmm1,%eax
test   $0x1,%al
je     1564 <open_votes+0x444>
movl   $0xffffffff,0x54(%rsp,%rbp,4)
ff
pextrw $0x2,%xmm1,%eax
test   $0x1,%al
je     1575 <open_votes+0x455>
movl   $0xffffffff,0x58(%rsp,%rbp,4)
ff
pextrw $0x4,%xmm1,%eax
test   $0x1,%al
je     1586 <open_votes+0x466>
movl   $0xffffffff,0x5c(%rsp,%rbp,4)
ff
pextrw $0x6,%xmm1,%eax
test   $0x1,%al
je     14f0 <open_votes+0x3d0>
movl   $0xffffffff,0x60(%rsp,%rbp,4)
ff
jmp    14f0 <open_votes+0x3d0>
mov    0x20(%rsp),%rdi
cmp    %r11,0x10(%rsp)
je     1340 <open_votes+0x220>
mov    %rdi,%rsi
test   $0x1,%r13b
jne    15cb <open_votes+0x4ab>
cmp    %ecx,0x40(%rsp,%rdi,4)
jne    15c7 <open_votes+0x4a7>
movl   $0xffffffff,0x40(%rsp,%rdi,4)
ff
lea    0x1(%rdi),%rsi
not    %rdi
cmp    0x30(%rsp),%rdi
je     1340 <open_votes+0x220>
jmp    15ed <open_votes+0x4cd>
nopl   0x0(%rax,%rax,1)
add    $0x2,%rsi
cmp    %rsi,%r13
je     1340 <open_votes+0x220>
cmp    %ecx,0x40(%rsp,%rsi,4)
jne    15fb <open_votes+0x4db>
movl   $0xffffffff,0x40(%rsp,%rsi,4)
ff
cmp    %ecx,0x44(%rsp,%rsi,4)
jne    15e0 <open_votes+0x4c0>
movl   $0xffffffff,0x44(%rsp,%rsi,4)
ff
jmp    15e0 <open_votes+0x4c0>
movslq %r10d,%rax
lea    (%rax,%rax,8),%rax
lea    (%rax,%rax,8),%rax
add    %rax,%r14
lea    0x9f0(%rip),%rdi
mov    %r14,%rsi
call   1030 <printf@plt>
add    $0x1f98,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
test   %r8d,%r8d
jle    1628 <open_votes+0x508>
add    $0x51,%r14
mov    $0x1,%ebp
lea    0x9c1(%rip),%rbx
jmp    166d <open_votes+0x54d>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
add    $0x1,%rbp
add    $0x51,%r14
cmp    %rbp,%r13
je     1628 <open_votes+0x508>
cmpl   $0x0,0x40(%rsp,%rbp,4)
jle    1660 <open_votes+0x540>
mov    %rbx,%rdi
mov    %r14,%rsi
call   1030 <printf@plt>
jmp    1660 <open_votes+0x540>

LLVM IR (-O0):
@.str = [4 x i8] c"%s\0A\00"
define void @open_votes([21 x i32]* %0, [81 x i8]* %1, i32 %2, i32 %3) {
%5 = alloca [21 x i32]*
%6 = alloca [81 x i8]*
%7 = alloca i32
%8 = alloca i32
%9 = alloca [1001 x i32]
%10 = alloca [1001 x i32]
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
%17 = alloca i32
store [21 x i32]* %0, [21 x i32]** %5
store [81 x i8]* %1, [81 x i8]** %6
store i32 %2, i32* %7
store i32 %3, i32* %8
%18 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 0
%19 = call i32 @memset(i32* %18, i32 0, i32 4004)
store i32 1, i32* %16
br label %20
20: ; preds = %28, %4
%21 = load i32, i32* %16
%22 = load i32, i32* %7
%23 = icmp sle i32 %21, %22
br i1 %23, label %24, label %31
24: ; preds = %20
%25 = load i32, i32* %16
%26 = sext i32 %25 to i64
%27 = getelementptr inbounds [1001 x i32], [1001 x i32]* %9, i64 0, i64 %26
store i32 1, i32* %27
br label %28
28: ; preds = %24
%29 = load i32, i32* %16
%30 = add nsw i32 %29, 1
store i32 %30, i32* %16
br label %20
31: ; preds = %20
store i32 1, i32* %16
br label %32
32: ; preds = %53, %31
%33 = load i32, i32* %16
%34 = load i32, i32* %7
%35 = icmp sle i32 %33, %34
br i1 %35, label %36, label %56
36: ; preds = %32
%37 = load [21 x i32]*, [21 x i32]** %5
%38 = load i32, i32* %16
%39 = sext i32 %38 to i64
%40 = getelementptr inbounds [21 x i32], [21 x i32]* %37, i64 %39
%41 = load i32, i32* %16
%42 = sext i32 %41 to i64
%43 = getelementptr inbounds [1001 x i32], [1001 x i32]* %9, i64 0, i64 %42
%44 = load i32, i32* %43
%45 = sext i32 %44 to i64
%46 = getelementptr inbounds [21 x i32], [21 x i32]* %40, i64 0, i64 %45
%47 = load i32, i32* %46
store i32 %47, i32* %17
%48 = load i32, i32* %17
%49 = sext i32 %48 to i64
%50 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %49
%51 = load i32, i32* %50
%52 = add nsw i32 %51, 1
store i32 %52, i32* %50
br label %53
53: ; preds = %36
%54 = load i32, i32* %16
%55 = add nsw i32 %54, 1
store i32 %55, i32* %16
br label %32
56: ; preds = %32
store i32 0, i32* %15
store i32 0, i32* %14
br label %57
57: ; preds = %56, %213
store i32 0, i32* %12
%58 = load i32, i32* %7
store i32 %58, i32* %11
store i32 1, i32* %16
br label %59
59: ; preds = %107, %57
%60 = load i32, i32* %16
%61 = load i32, i32* %8
%62 = icmp sle i32 %60, %61
br i1 %62, label %63, label %110
63: ; preds = %59
%64 = load i32, i32* %16
%65 = sext i32 %64 to i64
%66 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %65
%67 = load i32, i32* %66
%68 = icmp sge i32 %67, 0
br i1 %68, label %69, label %82
69: ; preds = %63
%70 = load i32, i32* %16
%71 = sext i32 %70 to i64
%72 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %71
%73 = load i32, i32* %72
%74 = load i32, i32* %12
%75 = icmp sgt i32 %73, %74
br i1 %75, label %76, label %82
76: ; preds = %69
%77 = load i32, i32* %16
store i32 %77, i32* %13
%78 = load i32, i32* %16
%79 = sext i32 %78 to i64
%80 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %79
%81 = load i32, i32* %80
br label %84
82: ; preds = %69, %63
%83 = load i32, i32* %12
br label %84
84: ; preds = %82, %76
%85 = phi i32 [ %81, %76 ], [ %83, %82 ]
store i32 %85, i32* %12
%86 = load i32, i32* %16
%87 = sext i32 %86 to i64
%88 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %87
%89 = load i32, i32* %88
%90 = icmp sge i32 %89, 0
br i1 %90, label %91, label %103
91: ; preds = %84
%92 = load i32, i32* %16
%93 = sext i32 %92 to i64
%94 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %93
%95 = load i32, i32* %94
%96 = load i32, i32* %11
%97 = icmp slt i32 %95, %96
br i1 %97, label %98, label %103
98: ; preds = %91
%99 = load i32, i32* %16
%100 = sext i32 %99 to i64
%101 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %100
%102 = load i32, i32* %101
br label %105
103: ; preds = %91, %84
%104 = load i32, i32* %11
br label %105
105: ; preds = %103, %98
%106 = phi i32 [ %102, %98 ], [ %104, %103 ]
store i32 %106, i32* %11
br label %107
107: ; preds = %105
%108 = load i32, i32* %16
%109 = add nsw i32 %108, 1
store i32 %109, i32* %16
br label %59
110: ; preds = %59
%111 = load i32, i32* %12
%112 = load i32, i32* %11
%113 = icmp eq i32 %111, %112
br i1 %113, label %114, label %115
114: ; preds = %110
store i32 1, i32* %14
br label %214
115: ; preds = %110
%116 = load i32, i32* %12
%117 = mul nsw i32 %116, 2
%118 = load i32, i32* %7
%119 = icmp sgt i32 %117, %118
br i1 %119, label %120, label %121
120: ; preds = %115
store i32 1, i32* %15
br label %214
121: ; preds = %115
br label %122
122: ; preds = %121
store i32 1, i32* %16
br label %123
123: ; preds = %190, %122
%124 = load i32, i32* %16
%125 = load i32, i32* %7
%126 = icmp sle i32 %124, %125
br i1 %126, label %127, label %193
127: ; preds = %123
%128 = load [21 x i32]*, [21 x i32]** %5
%129 = load i32, i32* %16
%130 = sext i32 %129 to i64
%131 = getelementptr inbounds [21 x i32], [21 x i32]* %128, i64 %130
%132 = load i32, i32* %16
%133 = sext i32 %132 to i64
%134 = getelementptr inbounds [1001 x i32], [1001 x i32]* %9, i64 0, i64 %133
%135 = load i32, i32* %134
%136 = sext i32 %135 to i64
%137 = getelementptr inbounds [21 x i32], [21 x i32]* %131, i64 0, i64 %136
%138 = load i32, i32* %137
%139 = sext i32 %138 to i64
%140 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %139
%141 = load i32, i32* %140
%142 = load i32, i32* %11
%143 = icmp eq i32 %141, %142
br i1 %143, label %144, label %189
144: ; preds = %127
%145 = load i32, i32* %16
%146 = sext i32 %145 to i64
%147 = getelementptr inbounds [1001 x i32], [1001 x i32]* %9, i64 0, i64 %146
%148 = load i32, i32* %147
%149 = add nsw i32 %148, 1
store i32 %149, i32* %147
br label %150
150: ; preds = %167, %144
%151 = load [21 x i32]*, [21 x i32]** %5
%152 = load i32, i32* %16
%153 = sext i32 %152 to i64
%154 = getelementptr inbounds [21 x i32], [21 x i32]* %151, i64 %153
%155 = load i32, i32* %16
%156 = sext i32 %155 to i64
%157 = getelementptr inbounds [1001 x i32], [1001 x i32]* %9, i64 0, i64 %156
%158 = load i32, i32* %157
%159 = sext i32 %158 to i64
%160 = getelementptr inbounds [21 x i32], [21 x i32]* %154, i64 0, i64 %159
%161 = load i32, i32* %160
%162 = sext i32 %161 to i64
%163 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %162
%164 = load i32, i32* %163
%165 = load i32, i32* %11
%166 = icmp sle i32 %164, %165
br i1 %166, label %167, label %173
167: ; preds = %150
%168 = load i32, i32* %16
%169 = sext i32 %168 to i64
%170 = getelementptr inbounds [1001 x i32], [1001 x i32]* %9, i64 0, i64 %169
%171 = load i32, i32* %170
%172 = add nsw i32 %171, 1
store i32 %172, i32* %170
br label %150
173: ; preds = %150
%174 = load [21 x i32]*, [21 x i32]** %5
%175 = load i32, i32* %16
%176 = sext i32 %175 to i64
%177 = getelementptr inbounds [21 x i32], [21 x i32]* %174, i64 %176
%178 = load i32, i32* %16
%179 = sext i32 %178 to i64
%180 = getelementptr inbounds [1001 x i32], [1001 x i32]* %9, i64 0, i64 %179
%181 = load i32, i32* %180
%182 = sext i32 %181 to i64
%183 = getelementptr inbounds [21 x i32], [21 x i32]* %177, i64 0, i64 %182
%184 = load i32, i32* %183
%185 = sext i32 %184 to i64
%186 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %185
%187 = load i32, i32* %186
%188 = add nsw i32 %187, 1
store i32 %188, i32* %186
br label %189
189: ; preds = %173, %127
br label %190
190: ; preds = %189
%191 = load i32, i32* %16
%192 = add nsw i32 %191, 1
store i32 %192, i32* %16
br label %123
193: ; preds = %123
store i32 1, i32* %16
br label %194
194: ; preds = %210, %193
%195 = load i32, i32* %16
%196 = load i32, i32* %8
%197 = icmp sle i32 %195, %196
br i1 %197, label %198, label %213
198: ; preds = %194
%199 = load i32, i32* %16
%200 = sext i32 %199 to i64
%201 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %200
%202 = load i32, i32* %201
%203 = load i32, i32* %11
%204 = icmp eq i32 %202, %203
br i1 %204, label %205, label %209
205: ; preds = %198
%206 = load i32, i32* %16
%207 = sext i32 %206 to i64
%208 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %207
store i32 -1, i32* %208
br label %209
209: ; preds = %205, %198
br label %210
210: ; preds = %209
%211 = load i32, i32* %16
%212 = add nsw i32 %211, 1
store i32 %212, i32* %16
br label %194
213: ; preds = %194
br label %57
214: ; preds = %120, %114
%215 = load i32, i32* %14
%216 = icmp eq i32 %215, 1
br i1 %216, label %217, label %240
217: ; preds = %214
store i32 1, i32* %16
br label %218
218: ; preds = %236, %217
%219 = load i32, i32* %16
%220 = load i32, i32* %8
%221 = icmp sle i32 %219, %220
br i1 %221, label %222, label %239
222: ; preds = %218
%223 = load i32, i32* %16
%224 = sext i32 %223 to i64
%225 = getelementptr inbounds [1001 x i32], [1001 x i32]* %10, i64 0, i64 %224
%226 = load i32, i32* %225
%227 = icmp sgt i32 %226, 0
br i1 %227, label %228, label %235
228: ; preds = %222
%229 = load [81 x i8]*, [81 x i8]** %6
%230 = load i32, i32* %16
%231 = sext i32 %230 to i64
%232 = getelementptr inbounds [81 x i8], [81 x i8]* %229, i64 %231
%233 = getelementptr inbounds [81 x i8], [81 x i8]* %232, i64 0, i64 0
%234 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %233)
br label %235
235: ; preds = %228, %222
br label %236
236: ; preds = %235
%237 = load i32, i32* %16
%238 = add nsw i32 %237, 1
store i32 %238, i32* %16
br label %218
239: ; preds = %218
br label %247
240: ; preds = %214
%241 = load [81 x i8]*, [81 x i8]** %6
%242 = load i32, i32* %13
%243 = sext i32 %242 to i64
%244 = getelementptr inbounds [81 x i8], [81 x i8]* %241, i64 %243
%245 = getelementptr inbounds [81 x i8], [81 x i8]* %244, i64 0, i64 0
%246 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %245)
br label %247
247: ; preds = %240, %239
ret void
}

LLVM IR (-O2):
@.str = [4 x i8] c"%s\0A\00"
define void @open_votes([21 x i32]* nocapture %0, [81 x i8]* %1, i32 %2, i32 %3) {
%5 = alloca [1001 x i32]
%6 = alloca [1001 x i32]
%7 = bitcast [1001 x i32]* %5 to i8*
%8 = bitcast [1001 x i32]* %6 to i8*
%9 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 0
%10 = call i32 @memset(i32* %9, i32 0, i32 4004)
%11 = icmp slt i32 %2, 1
br i1 %11, label %95, label %12
12: ; preds = %4
%13 = add nuw i32 %2, 1
%14 = zext i32 %13 to i64
%15 = add nsw i64 %14, -1
%16 = icmp ult i64 %15, 8
br i1 %16, label %69, label %17
17: ; preds = %12
%18 = and i64 %15, -8
%19 = or i64 %18, 1
%20 = add nsw i64 %18, -8
%21 = lshr exact i64 %20, 3
%22 = add nuw nsw i64 %21, 1
%23 = and i64 %22, 3
%24 = icmp ult i64 %20, 24
br i1 %24, label %53, label %25
25: ; preds = %17
%26 = and i64 %22, 4611686018427387900
br label %27
27: ; preds = %27, %25
%28 = phi i64 [ 0, %25 ], [ %50, %27 ]
%29 = phi i64 [ 0, %25 ], [ %51, %27 ]
%30 = or i64 %28, 1
%31 = getelementptr inbounds [1001 x i32], [1001 x i32]* %5, i64 0, i64 %30
%32 = bitcast i32* %31 to <4 x i32>*
store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, <4 x i32>* %32
%33 = getelementptr inbounds i32, i32* %31, i64 4
%34 = bitcast i32* %33 to <4 x i32>*
store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, <4 x i32>* %34
%35 = or i64 %28, 9
%36 = getelementptr inbounds [1001 x i32], [1001 x i32]* %5, i64 0, i64 %35
%37 = bitcast i32* %36 to <4 x i32>*
store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, <4 x i32>* %37
%38 = getelementptr inbounds i32, i32* %36, i64 4
%39 = bitcast i32* %38 to <4 x i32>*
store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, <4 x i32>* %39
%40 = or i64 %28, 17
%41 = getelementptr inbounds [1001 x i32], [1001 x i32]* %5, i64 0, i64 %40
%42 = bitcast i32* %41 to <4 x i32>*
store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, <4 x i32>* %42
%43 = getelementptr inbounds i32, i32* %41, i64 4
%44 = bitcast i32* %43 to <4 x i32>*
store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, <4 x i32>* %44
%45 = or i64 %28, 25
%46 = getelementptr inbounds [1001 x i32], [1001 x i32]* %5, i64 0, i64 %45
%47 = bitcast i32* %46 to <4 x i32>*
store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, <4 x i32>* %47
%48 = getelementptr inbounds i32, i32* %46, i64 4
%49 = bitcast i32* %48 to <4 x i32>*
store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, <4 x i32>* %49
%50 = add nuw i64 %28, 32
%51 = add i64 %29, 4
%52 = icmp eq i64 %51, %26
br i1 %52, label %53, label %27
53: ; preds = %27, %17
%54 = phi i64 [ 0, %17 ], [ %50, %27 ]
%55 = icmp eq i64 %23, 0
br i1 %55, label %67, label %56
56: ; preds = %53, %56
%57 = phi i64 [ %64, %56 ], [ %54, %53 ]
%58 = phi i64 [ %65, %56 ], [ 0, %53 ]
%59 = or i64 %57, 1
%60 = getelementptr inbounds [1001 x i32], [1001 x i32]* %5, i64 0, i64 %59
%61 = bitcast i32* %60 to <4 x i32>*
store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, <4 x i32>* %61
%62 = getelementptr inbounds i32, i32* %60, i64 4
%63 = bitcast i32* %62 to <4 x i32>*
store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, <4 x i32>* %63
%64 = add nuw i64 %57, 8
%65 = add i64 %58, 1
%66 = icmp eq i64 %65, %23
br i1 %66, label %67, label %56
67: ; preds = %56, %53
%68 = icmp eq i64 %15, %18
br i1 %68, label %71, label %69
69: ; preds = %12, %67
%70 = phi i64 [ 1, %12 ], [ %19, %67 ]
br label %77
71: ; preds = %77, %67
br i1 %11, label %95, label %72
72: ; preds = %71
%73 = and i64 %15, 1
%74 = icmp eq i32 %13, 2
br i1 %74, label %82, label %75
75: ; preds = %72
%76 = and i64 %15, -2
br label %116
77: ; preds = %69, %77
%78 = phi i64 [ %80, %77 ], [ %70, %69 ]
%79 = getelementptr inbounds [1001 x i32], [1001 x i32]* %5, i64 0, i64 %78
store i32 1, i32* %79
%80 = add nuw nsw i64 %78, 1
%81 = icmp eq i64 %80, %14
br i1 %81, label %71, label %77
82: ; preds = %116, %72
%83 = phi i64 [ 1, %72 ], [ %138, %116 ]
%84 = icmp eq i64 %73, 0
br i1 %84, label %95, label %85
85: ; preds = %82
%86 = getelementptr inbounds [1001 x i32], [1001 x i32]* %5, i64 0, i64 %83
%87 = load i32, i32* %86
%88 = sext i32 %87 to i64
%89 = getelementptr inbounds [21 x i32], [21 x i32]* %0, i64 %83, i64 %88
%90 = load i32, i32* %89
%91 = sext i32 %90 to i64
%92 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %91
%93 = load i32, i32* %92
%94 = add nsw i32 %93, 1
store i32 %94, i32* %92
br label %95
95: ; preds = %85, %82, %71, %4
%96 = add i32 %2, 1
%97 = icmp slt i32 %3, 1
%98 = add i32 %3, 1
%99 = zext i32 %98 to i64
%100 = icmp eq i32 %2, 0
%101 = zext i32 %96 to i64
%102 = zext i32 %98 to i64
%103 = add nsw i64 %99, -1
%104 = add nsw i64 %99, -1
%105 = and i64 %104, 1
%106 = icmp eq i32 %98, 2
%107 = and i64 %104, -2
%108 = icmp eq i64 %105, 0
%109 = icmp ult i64 %103, 8
%110 = and i64 %103, -8
%111 = or i64 %110, 1
%112 = icmp eq i64 %103, %110
%113 = and i64 %99, 1
%114 = icmp eq i64 %113, 0
%115 = sub nsw i64 0, %99
br label %141
116: ; preds = %116, %75
%117 = phi i64 [ 1, %75 ], [ %138, %116 ]
%118 = phi i64 [ 0, %75 ], [ %139, %116 ]
%119 = getelementptr inbounds [1001 x i32], [1001 x i32]* %5, i64 0, i64 %117
%120 = load i32, i32* %119
%121 = sext i32 %120 to i64
%122 = getelementptr inbounds [21 x i32], [21 x i32]* %0, i64 %117, i64 %121
%123 = load i32, i32* %122
%124 = sext i32 %123 to i64
%125 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %124
%126 = load i32, i32* %125
%127 = add nsw i32 %126, 1
store i32 %127, i32* %125
%128 = add nuw nsw i64 %117, 1
%129 = getelementptr inbounds [1001 x i32], [1001 x i32]* %5, i64 0, i64 %128
%130 = load i32, i32* %129
%131 = sext i32 %130 to i64
%132 = getelementptr inbounds [21 x i32], [21 x i32]* %0, i64 %128, i64 %131
%133 = load i32, i32* %132
%134 = sext i32 %133 to i64
%135 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %134
%136 = load i32, i32* %135
%137 = add nsw i32 %136, 1
store i32 %137, i32* %135
%138 = add nuw nsw i64 %117, 2
%139 = add i64 %118, 2
%140 = icmp eq i64 %139, %76
br i1 %140, label %82, label %116
141: ; preds = %272, %95
%142 = phi i32 [ undef, %95 ], [ %207, %272 ]
br i1 %97, label %201, label %143
143: ; preds = %141
br i1 %106, label %176, label %144
144: ; preds = %143, %144
%145 = phi i64 [ %173, %144 ], [ 1, %143 ]
%146 = phi i32 [ %172, %144 ], [ %2, %143 ]
%147 = phi i32 [ %168, %144 ], [ %142, %143 ]
%148 = phi i32 [ %169, %144 ], [ 0, %143 ]
%149 = phi i64 [ %174, %144 ], [ 0, %143 ]
%150 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %145
%151 = load i32, i32* %150
%152 = icmp sgt i32 %151, -1
%153 = icmp sgt i32 %151, %148
%154 = select i1 %152, i1 %153, i1 false
%155 = trunc i64 %145 to i32
%156 = select i1 %154, i32 %155, i32 %147
%157 = select i1 %154, i32 %151, i32 %148
%158 = icmp slt i32 %151, %146
%159 = select i1 %152, i1 %158, i1 false
%160 = select i1 %159, i32 %151, i32 %146
%161 = add nuw nsw i64 %145, 1
%162 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %161
%163 = load i32, i32* %162
%164 = icmp sgt i32 %163, -1
%165 = icmp sgt i32 %163, %157
%166 = select i1 %164, i1 %165, i1 false
%167 = trunc i64 %161 to i32
%168 = select i1 %166, i32 %167, i32 %156
%169 = select i1 %166, i32 %163, i32 %157
%170 = icmp slt i32 %163, %160
%171 = select i1 %164, i1 %170, i1 false
%172 = select i1 %171, i32 %163, i32 %160
%173 = add nuw nsw i64 %145, 2
%174 = add i64 %149, 2
%175 = icmp eq i64 %174, %107
br i1 %175, label %176, label %144
176: ; preds = %144, %143
%177 = phi i32 [ undef, %143 ], [ %168, %144 ]
%178 = phi i32 [ undef, %143 ], [ %169, %144 ]
%179 = phi i32 [ undef, %143 ], [ %172, %144 ]
%180 = phi i64 [ 1, %143 ], [ %173, %144 ]
%181 = phi i32 [ %2, %143 ], [ %172, %144 ]
%182 = phi i32 [ %142, %143 ], [ %168, %144 ]
%183 = phi i32 [ 0, %143 ], [ %169, %144 ]
br i1 %108, label %196, label %184
184: ; preds = %176
%185 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %180
%186 = load i32, i32* %185
%187 = icmp sgt i32 %186, -1
%188 = icmp sgt i32 %186, %183
%189 = select i1 %187, i1 %188, i1 false
%190 = trunc i64 %180 to i32
%191 = select i1 %189, i32 %190, i32 %182
%192 = select i1 %189, i32 %186, i32 %183
%193 = icmp slt i32 %186, %181
%194 = select i1 %187, i1 %193, i1 false
%195 = select i1 %194, i32 %186, i32 %181
br label %196
196: ; preds = %176, %184
%197 = phi i32 [ %177, %176 ], [ %191, %184 ]
%198 = phi i32 [ %178, %176 ], [ %192, %184 ]
%199 = phi i32 [ %179, %176 ], [ %195, %184 ]
%200 = icmp eq i32 %198, %199
br i1 %200, label %202, label %205
201: ; preds = %141
br i1 %100, label %344, label %205
202: ; preds = %196
br i1 %97, label %344, label %203
203: ; preds = %202
%204 = zext i32 %98 to i64
br label %329
205: ; preds = %201, %196
%206 = phi i32 [ %2, %201 ], [ %199, %196 ]
%207 = phi i32 [ %142, %201 ], [ %197, %196 ]
%208 = phi i32 [ 0, %201 ], [ %198, %196 ]
%209 = shl nsw i32 %208, 1
%210 = icmp sgt i32 %209, %2
br i1 %210, label %340, label %211
211: ; preds = %205
br i1 %11, label %212, label %286
212: ; preds = %311, %211
br i1 %97, label %272, label %213
213: ; preds = %212
br i1 %109, label %273, label %214
214: ; preds = %213
%215 = insertelement <4 x i32> poison, i32 %206, i64 0
%216 = shufflevector <4 x i32> %215, <4 x i32> poison, <4 x i32> zeroinitializer
%217 = insertelement <4 x i32> poison, i32 %206, i64 0
%218 = shufflevector <4 x i32> %217, <4 x i32> poison, <4 x i32> zeroinitializer
br label %219
219: ; preds = %268, %214
%220 = phi i64 [ 0, %214 ], [ %269, %268 ]
%221 = or i64 %220, 1
%222 = or i64 %220, 5
%223 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %221
%224 = bitcast i32* %223 to <4 x i32>*
%225 = load <4 x i32>, <4 x i32>* %224
%226 = getelementptr inbounds i32, i32* %223, i64 4
%227 = bitcast i32* %226 to <4 x i32>*
%228 = load <4 x i32>, <4 x i32>* %227
%229 = icmp eq <4 x i32> %225, %216
%230 = icmp eq <4 x i32> %228, %218
%231 = extractelement <4 x i1> %229, i64 0
br i1 %231, label %232, label %234
232: ; preds = %219
%233 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %221
store i32 -1, i32* %233
br label %234
234: ; preds = %232, %219
%235 = extractelement <4 x i1> %229, i64 1
br i1 %235, label %236, label %239
236: ; preds = %234
%237 = or i64 %220, 2
%238 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %237
store i32 -1, i32* %238
br label %239
239: ; preds = %236, %234
%240 = extractelement <4 x i1> %229, i64 2
br i1 %240, label %241, label %244
241: ; preds = %239
%242 = or i64 %220, 3
%243 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %242
store i32 -1, i32* %243
br label %244
244: ; preds = %241, %239
%245 = extractelement <4 x i1> %229, i64 3
br i1 %245, label %246, label %249
246: ; preds = %244
%247 = or i64 %220, 4
%248 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %247
store i32 -1, i32* %248
br label %249
249: ; preds = %246, %244
%250 = extractelement <4 x i1> %230, i64 0
br i1 %250, label %251, label %253
251: ; preds = %249
%252 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %222
store i32 -1, i32* %252
br label %253
253: ; preds = %251, %249
%254 = extractelement <4 x i1> %230, i64 1
br i1 %254, label %255, label %258
255: ; preds = %253
%256 = or i64 %220, 6
%257 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %256
store i32 -1, i32* %257
br label %258
258: ; preds = %255, %253
%259 = extractelement <4 x i1> %230, i64 2
br i1 %259, label %260, label %263
260: ; preds = %258
%261 = or i64 %220, 7
%262 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %261
store i32 -1, i32* %262
br label %263
263: ; preds = %260, %258
%264 = extractelement <4 x i1> %230, i64 3
br i1 %264, label %265, label %268
265: ; preds = %263
%266 = add i64 %220, 8
%267 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %266
store i32 -1, i32* %267
br label %268
268: ; preds = %265, %263
%269 = add nuw i64 %220, 8
%270 = icmp eq i64 %269, %110
br i1 %270, label %271, label %219
271: ; preds = %268
br i1 %112, label %272, label %273
272: ; preds = %283, %326, %271, %212
br label %141
273: ; preds = %213, %271
%274 = phi i64 [ 1, %213 ], [ %111, %271 ]
%275 = xor i64 %274, -1
br i1 %114, label %276, label %283
276: ; preds = %273
%277 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %274
%278 = load i32, i32* %277
%279 = icmp eq i32 %278, %206
br i1 %279, label %280, label %281
280: ; preds = %276
store i32 -1, i32* %277
br label %281
281: ; preds = %280, %276
%282 = add nuw nsw i64 %274, 1
br label %283
283: ; preds = %281, %273
%284 = phi i64 [ %274, %273 ], [ %282, %281 ]
%285 = icmp eq i64 %275, %115
br i1 %285, label %272, label %314
286: ; preds = %211, %311
%287 = phi i64 [ %312, %311 ], [ 1, %211 ]
%288 = getelementptr inbounds [1001 x i32], [1001 x i32]* %5, i64 0, i64 %287
%289 = load i32, i32* %288
%290 = sext i32 %289 to i64
%291 = getelementptr inbounds [21 x i32], [21 x i32]* %0, i64 %287, i64 %290
%292 = load i32, i32* %291
%293 = sext i32 %292 to i64
%294 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %293
%295 = load i32, i32* %294
%296 = icmp eq i32 %295, %206
br i1 %296, label %297, label %311
297: ; preds = %286, %297
%298 = phi i64 [ %299, %297 ], [ %290, %286 ]
%299 = add i64 %298, 1
%300 = getelementptr inbounds [21 x i32], [21 x i32]* %0, i64 %287, i64 %299
%301 = load i32, i32* %300
%302 = sext i32 %301 to i64
%303 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %302
%304 = load i32, i32* %303
%305 = icmp sgt i32 %304, %206
br i1 %305, label %306, label %297
306: ; preds = %297
%307 = sext i32 %301 to i64
%308 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %307
%309 = trunc i64 %299 to i32
store i32 %309, i32* %288
%310 = add nsw i32 %304, 1
store i32 %310, i32* %308
br label %311
311: ; preds = %286, %306
%312 = add nuw nsw i64 %287, 1
%313 = icmp eq i64 %312, %101
br i1 %313, label %212, label %286
314: ; preds = %283, %326
%315 = phi i64 [ %327, %326 ], [ %284, %283 ]
%316 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %315
%317 = load i32, i32* %316
%318 = icmp eq i32 %317, %206
br i1 %318, label %319, label %320
319: ; preds = %314
store i32 -1, i32* %316
br label %320
320: ; preds = %314, %319
%321 = add nuw nsw i64 %315, 1
%322 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %321
%323 = load i32, i32* %322
%324 = icmp eq i32 %323, %206
br i1 %324, label %325, label %326
325: ; preds = %320
store i32 -1, i32* %322
br label %326
326: ; preds = %325, %320
%327 = add nuw nsw i64 %315, 2
%328 = icmp eq i64 %327, %102
br i1 %328, label %272, label %314
329: ; preds = %203, %337
%330 = phi i64 [ 1, %203 ], [ %338, %337 ]
%331 = getelementptr inbounds [1001 x i32], [1001 x i32]* %6, i64 0, i64 %330
%332 = load i32, i32* %331
%333 = icmp sgt i32 %332, 0
br i1 %333, label %334, label %337
334: ; preds = %329
%335 = getelementptr inbounds [81 x i8], [81 x i8]* %1, i64 %330, i64 0
%336 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %335)
br label %337
337: ; preds = %329, %334
%338 = add nuw nsw i64 %330, 1
%339 = icmp eq i64 %338, %204
br i1 %339, label %344, label %329
340: ; preds = %205
%341 = sext i32 %207 to i64
%342 = getelementptr inbounds [81 x i8], [81 x i8]* %1, i64 %341, i64 0
%343 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %342)
br label %344
344: ; preds = %201, %337, %202, %340
ret void
}