#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 */
typedef int /*<<< orphan*/ arr2;

/* Variables and functions */
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ scanf(char *, ...);
int main() {
  unsigned char array_size = 201, x, n;
  printf("Enter array size(max: 200):\n");
  do
    scanf("%d", &array_size);
  while (array_size > 200);
  int arr1[array_size];
  for (x = 1; x <= array_size; x++) {
    printf("Enter array[%d", x);
    printf("]:\n");
    scanf("%d", &arr1[x]);
  }
  printf("Original array: [");
  for (x = 1; x <= array_size; x++) {
    printf(" %d", arr1[x]);
  }
  printf("]\n");
  for (n = 1; n <= array_size; n++)
    for (x = 1; x <= array_size - 1; x++) {
      if (arr1[x] > arr1[x + 1]) {
        arr1[x] = arr1[x] + arr1[x + 1];
        arr1[x + 1] = arr1[x] - arr1[x + 1];
        arr1[x] = arr1[x] - arr1[x + 1];
      }
    }
  printf("Sorted array: [");
  for (x = 1; x <= array_size; x++) {
    printf(" %d", arr1[x]);
  }
  printf("]\n");
  n = 0;
  for (x = 1; x <= array_size - 1; x++)
    if (arr1[x] == arr1[x + 1])
      n++;
  int arr2[array_size - n];
  arr2[1] = arr1[1];
  n = 2;
  for (x = 2; x <= array_size; x++)
    if (arr1[x] != arr1[x - 1]) {
      arr2[n] = arr1[x];
      n++;
    }
  printf("Final array: [");
  for (x = 1; x <= sizeof(arr2) / sizeof(int); x++) {
    printf(" %d", arr2[x]);
  }
  printf("]\n");
  printf("3-rd min element: ");
  if ((sizeof(arr2) / sizeof(int)) >= 3)
    printf("%d\n", arr2[3]);
  else
    printf("not exist!\n");
  printf("4-th max element: ");
  if ((sizeof(arr2) / sizeof(int)) >= 4)
    printf("%d\n", arr2[sizeof(arr2) / sizeof(int) - 3]);
  else
    printf("not exist!\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movl   $0x0,-0x4(%rbp)
movb   $0xc9,-0x5(%rbp)
lea    0xec6(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xefb(%rip),%rdi
lea    -0x5(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
movzbl -0x5(%rbp),%eax
cmp    $0xc8,%eax
jg     1141 <main+0x21>
movzbl -0x5(%rbp),%edx
mov    %edx,%eax
mov    %rsp,%rcx
mov    %rcx,-0x10(%rbp)
mov    %edx,%ecx
lea    0xf(,%rcx,4),%edx
mov    %edx,%ecx
and    $0xfffffff0,%ecx
mov    %ecx,%edx
mov    %rsp,%rcx
sub    %rdx,%rcx
mov    %rcx,-0x28(%rbp)
mov    %rcx,%rsp
mov    %rax,-0x18(%rbp)
movb   $0x1,-0x6(%rbp)
movzbl -0x6(%rbp),%eax
movzbl -0x5(%rbp),%ecx
cmp    %ecx,%eax
jg     11ee <main+0xce>
movzbl -0x6(%rbp),%esi
lea    0xe6e(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xe6f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x28(%rbp),%rsi
movzbl -0x6(%rbp),%eax
shl    $0x2,%rax
add    %rax,%rsi
lea    0xe69(%rip),%rdi
mov    $0x0,%al
call   1040 <scanf@plt>
mov    -0x6(%rbp),%al
add    $0x1,%al
mov    %al,-0x6(%rbp)
jmp    1194 <main+0x74>
lea    0xe3b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movb   $0x1,-0x6(%rbp)
movzbl -0x6(%rbp),%eax
movzbl -0x5(%rbp),%ecx
cmp    %ecx,%eax
jg     1236 <main+0x116>
mov    -0x28(%rbp),%rax
movzbl -0x6(%rbp),%ecx
mov    (%rax,%rcx,4),%esi
lea    0xe20(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x6(%rbp),%al
add    $0x1,%al
mov    %al,-0x6(%rbp)
jmp    1200 <main+0xe0>
lea    0xe09(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movb   $0x1,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
movzbl -0x5(%rbp),%ecx
cmp    %ecx,%eax
jg     130c <main+0x1ec>
movb   $0x1,-0x6(%rbp)
movzbl -0x6(%rbp),%eax
movzbl -0x5(%rbp),%ecx
sub    $0x1,%ecx
cmp    %ecx,%eax
jg     12fa <main+0x1da>
mov    -0x28(%rbp),%rcx
movzbl -0x6(%rbp),%eax
mov    (%rcx,%rax,4),%eax
movzbl -0x6(%rbp),%edx
add    $0x1,%edx
movslq %edx,%rdx
cmp    (%rcx,%rdx,4),%eax
jle    12e8 <main+0x1c8>
mov    -0x28(%rbp),%rax
movzbl -0x6(%rbp),%ecx
mov    (%rax,%rcx,4),%edx
movzbl -0x6(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
add    (%rax,%rcx,4),%edx
movzbl -0x6(%rbp),%ecx
mov    %edx,(%rax,%rcx,4)
movzbl -0x6(%rbp),%ecx
mov    (%rax,%rcx,4),%edx
movzbl -0x6(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
sub    (%rax,%rcx,4),%edx
movzbl -0x6(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
mov    %edx,(%rax,%rcx,4)
movzbl -0x6(%rbp),%ecx
mov    (%rax,%rcx,4),%edx
movzbl -0x6(%rbp),%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
sub    (%rax,%rcx,4),%edx
movzbl -0x6(%rbp),%ecx
mov    %edx,(%rax,%rcx,4)
jmp    12ed <main+0x1cd>
mov    -0x6(%rbp),%al
add    $0x1,%al
mov    %al,-0x6(%rbp)
jmp    125c <main+0x13c>
jmp    12ff <main+0x1df>
mov    -0x7(%rbp),%al
add    $0x1,%al
mov    %al,-0x7(%rbp)
jmp    1248 <main+0x128>
lea    0xd36(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movb   $0x1,-0x6(%rbp)
movzbl -0x6(%rbp),%eax
movzbl -0x5(%rbp),%ecx
cmp    %ecx,%eax
jg     1354 <main+0x234>
mov    -0x28(%rbp),%rax
movzbl -0x6(%rbp),%ecx
mov    (%rax,%rcx,4),%esi
lea    0xd02(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x6(%rbp),%al
add    $0x1,%al
mov    %al,-0x6(%rbp)
jmp    131e <main+0x1fe>
lea    0xceb(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movb   $0x0,-0x7(%rbp)
movb   $0x1,-0x6(%rbp)
movzbl -0x6(%rbp),%eax
movzbl -0x5(%rbp),%ecx
sub    $0x1,%ecx
cmp    %ecx,%eax
jg     13b5 <main+0x295>
mov    -0x28(%rbp),%rcx
movzbl -0x6(%rbp),%eax
mov    (%rcx,%rax,4),%eax
movzbl -0x6(%rbp),%edx
add    $0x1,%edx
movslq %edx,%rdx
cmp    (%rcx,%rdx,4),%eax
jne    13a3 <main+0x283>
mov    -0x7(%rbp),%al
add    $0x1,%al
mov    %al,-0x7(%rbp)
jmp    13a8 <main+0x288>
mov    -0x6(%rbp),%al
add    $0x1,%al
mov    %al,-0x6(%rbp)
jmp    136a <main+0x24a>
mov    -0x28(%rbp),%rcx
movzbl -0x5(%rbp),%eax
movzbl -0x7(%rbp),%edx
sub    %edx,%eax
mov    %eax,%edx
mov    %rdx,-0x38(%rbp)
lea    0xf(,%rdx,4),%rsi
and    $0xfffffffffffffff0,%rsi
mov    %rsp,%rax
sub    %rsi,%rax
mov    %rax,-0x30(%rbp)
mov    %rax,%rsp
mov    %rdx,-0x20(%rbp)
mov    0x4(%rcx),%ecx
mov    %ecx,0x4(%rax)
movb   $0x2,-0x7(%rbp)
movb   $0x2,-0x6(%rbp)
movzbl -0x6(%rbp),%eax
movzbl -0x5(%rbp),%ecx
cmp    %ecx,%eax
jg     1452 <main+0x332>
mov    -0x28(%rbp),%rcx
movzbl -0x6(%rbp),%eax
mov    (%rcx,%rax,4),%eax
movzbl -0x6(%rbp),%edx
sub    $0x1,%edx
movslq %edx,%rdx
cmp    (%rcx,%rdx,4),%eax
je     1440 <main+0x320>
mov    -0x30(%rbp),%rax
mov    -0x28(%rbp),%rcx
movzbl -0x6(%rbp),%edx
mov    (%rcx,%rdx,4),%edx
movzbl -0x7(%rbp),%ecx
mov    %edx,(%rax,%rcx,4)
mov    -0x7(%rbp),%al
add    $0x1,%al
mov    %al,-0x7(%rbp)
jmp    1445 <main+0x325>
mov    -0x6(%rbp),%al
add    $0x1,%al
mov    %al,-0x6(%rbp)
jmp    13f4 <main+0x2d4>
lea    0xc00(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movb   $0x1,-0x6(%rbp)
mov    -0x38(%rbp),%rcx
movzbl -0x6(%rbp),%eax
shl    $0x2,%rcx
shr    $0x2,%rcx
cmp    %rcx,%rax
ja     14a3 <main+0x383>
mov    -0x30(%rbp),%rax
movzbl -0x6(%rbp),%ecx
mov    (%rax,%rcx,4),%esi
lea    0xbb3(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x6(%rbp),%al
add    $0x1,%al
mov    %al,-0x6(%rbp)
jmp    1464 <main+0x344>
lea    0xb9c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xbb0(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x38(%rbp),%rax
shl    $0x2,%rax
shr    $0x2,%rax
cmp    $0x3,%rax
jb     14ef <main+0x3cf>
mov    -0x30(%rbp),%rax
mov    0xc(%rax),%esi
lea    0xb98(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    14fd <main+0x3dd>
lea    0xb89(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xb87(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x38(%rbp),%rax
shl    $0x2,%rax
shr    $0x2,%rax
cmp    $0x4,%rax
jb     154b <main+0x42b>
mov    -0x30(%rbp),%rax
mov    -0x38(%rbp),%rcx
shl    $0x2,%rcx
shr    $0x2,%rcx
sub    $0x3,%rcx
mov    (%rax,%rcx,4),%esi
lea    0xb3c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1559 <main+0x439>
lea    0xb2d(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,%rsp
mov    -0x4(%rbp),%eax
mov    %rbp,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
movb   $0xc9,-0x29(%rbp)
lea    0xf22(%rip),%rdi
call   1030 <puts@plt>
lea    0xeca(%rip),%r14
lea    -0x29(%rbp),%rbx
nopl   0x0(%rax)
mov    %r14,%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
movzbl -0x29(%rbp),%eax
cmp    $0xc8,%rax
ja     1160 <main+0x30>
mov    %rsp,-0x38(%rbp)
lea    0xf(,%rax,4),%eax
and    $0xfffffff0,%eax
mov    %rsp,%r13
sub    %rax,%r13
mov    %r13,%rsp
cmpb   $0x0,-0x29(%rbp)
je     11e4 <main+0xb4>
mov    $0x1,%bl
lea    0xe61(%rip),%r14
lea    0xef1(%rip),%r15
lea    0xe75(%rip),%r12
nopl   (%rax)
movzbl %bl,%ebx
mov    %r14,%rdi
mov    %ebx,%esi
xor    %eax,%eax
call   1040 <printf@plt>
mov    %r15,%rdi
call   1030 <puts@plt>
lea    0x0(,%rbx,4),%rsi
add    %r13,%rsi
mov    %r12,%rdi
xor    %eax,%eax
call   1050 <scanf@plt>
add    $0x1,%bl
cmp    -0x29(%rbp),%bl
jbe    11b0 <main+0x80>
lea    0xe24(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmpb   $0x0,-0x29(%rbp)
je     122a <main+0xfa>
mov    $0x1,%bl
lea    0xe20(%rip),%r14
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
movzbl %bl,%ebx
mov    0x0(%r13,%rbx,4),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%bl
cmp    -0x29(%rbp),%bl
jbe    1210 <main+0xe0>
lea    0xe59(%rip),%rdi
call   1030 <puts@plt>
movzbl -0x29(%rbp),%r9d
test   %r9,%r9
je     12f3 <main+0x1c3>
lea    -0x1(%r9),%r8
mov    %r8,%rdx
and    $0xfffffffffffffffe,%rdx
neg    %rdx
mov    $0x1,%sil
jmp    126e <main+0x13e>
nopw   0x0(%rax,%rax,1)
lea    0x1(%rsi),%eax
cmp    %r9b,%sil
mov    %eax,%esi
je     12f3 <main+0x1c3>
cmp    $0x1,%r9b
je     1260 <main+0x130>
mov    0x4(%r13),%eax
mov    $0x1,%ecx
cmp    $0x2,%r9b
jne    12a0 <main+0x170>
test   $0x1,%r8b
je     1260 <main+0x130>
mov    0x4(%r13,%rcx,4),%edi
cmp    %edi,%eax
jle    1260 <main+0x130>
mov    %eax,0x4(%r13,%rcx,4)
mov    %edi,0x0(%r13,%rcx,4)
jmp    1260 <main+0x130>
xchg   %ax,%ax
mov    $0x1,%ebx
jmp    12c7 <main+0x197>
nopw   0x0(%rax,%rax,1)
mov    %eax,0x8(%r13,%rbx,4)
mov    %edi,0x4(%r13,%rbx,4)
lea    (%rdx,%rcx,1),%rdi
mov    %rcx,%rbx
cmp    $0x1,%rdi
je     1283 <main+0x153>
mov    0x4(%r13,%rbx,4),%ecx
cmp    %ecx,%eax
jle    12e0 <main+0x1b0>
mov    %eax,0x4(%r13,%rbx,4)
mov    %ecx,0x0(%r13,%rbx,4)
jmp    12e2 <main+0x1b2>
nopl   0x0(%rax)
mov    %ecx,%eax
lea    0x2(%rbx),%rcx
mov    0x8(%r13,%rbx,4),%edi
cmp    %edi,%eax
jg     12b0 <main+0x180>
mov    %edi,%eax
jmp    12ba <main+0x18a>
lea    0xd2b(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmpb   $0x0,-0x29(%rbp)
je     132a <main+0x1fa>
mov    $0x1,%bl
lea    0xd11(%rip),%r14
movzbl %bl,%ebx
mov    0x0(%r13,%rbx,4),%esi
mov    %r14,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%bl
cmp    -0x29(%rbp),%bl
jbe    1310 <main+0x1e0>
lea    0xd59(%rip),%rdi
call   1030 <puts@plt>
movzbl -0x29(%rbp),%r14d
cmp    $0x1,%r14
jbe    135b <main+0x22b>
mov    0x4(%r13),%edi
lea    -0x1(%r14),%rcx
cmp    $0x8,%rcx
jae    1386 <main+0x256>
mov    $0x1,%eax
xor    %esi,%esi
jmp    1420 <main+0x2f0>
lea    0xf(,%r14,4),%eax
and    $0xfffffff0,%eax
mov    %rsp,%rcx
mov    %rcx,%r15
sub    %rax,%r15
mov    %r15,%rsp
mov    0x4(%r13),%edx
neg    %rax
mov    %edx,0x4(%rcx,%rax,1)
mov    -0x38(%rbp),%r13
jmp    1506 <main+0x3d6>
mov    %rcx,%rdx
and    $0xfffffffffffffff8,%rdx
lea    0x1(%rdx),%rax
movd   %edi,%xmm0
pshufd $0x0,%xmm0,%xmm2
pxor   %xmm0,%xmm0
xor    %esi,%esi
pxor   %xmm1,%xmm1
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movups 0x8(%r13,%rsi,4),%xmm3
shufps $0x3,%xmm3,%xmm2
shufps $0x98,%xmm3,%xmm2
pcmpeqd %xmm3,%xmm2
packssdw %xmm2,%xmm2
packsswb %xmm2,%xmm2
psubb  %xmm2,%xmm0
movups 0x18(%r13,%rsi,4),%xmm2
shufps $0x3,%xmm2,%xmm3
shufps $0x98,%xmm2,%xmm3
pcmpeqd %xmm2,%xmm3
packssdw %xmm3,%xmm3
packsswb %xmm3,%xmm3
psubb  %xmm3,%xmm1
add    $0x8,%rsi
cmp    %rsi,%rdx
jne    13b0 <main+0x280>
paddb  %xmm0,%xmm1
pxor   %xmm0,%xmm0
punpckldq %xmm0,%xmm1
psadbw %xmm0,%xmm1
movd   %xmm1,%esi
cmp    %rdx,%rcx
je     1438 <main+0x308>
pshufd $0xff,%xmm2,%xmm0
movd   %xmm0,%edi
nopw   0x0(%rax,%rax,1)
mov    0x4(%r13,%rax,4),%ecx
add    $0x1,%rax
cmp    %ecx,%edi
sete   %dl
add    %dl,%sil
mov    %ecx,%edi
cmp    %rax,%r14
jne    1420 <main+0x2f0>
movzbl %sil,%ecx
mov    %r14d,%eax
sub    %ecx,%eax
lea    0xf(,%rax,4),%rcx
and    $0xfffffffffffffff0,%rcx
mov    %rsp,%rsi
mov    %rsi,%r15
sub    %rcx,%r15
mov    %r15,%rsp
mov    0x4(%r13),%edx
neg    %rcx
mov    %edx,0x4(%rsi,%rcx,1)
cmp    $0x2,%r14b
jb     1486 <main+0x356>
add    $0x1,%r14b
movzbl %r14b,%r8d
cmp    $0x3,%r8b
jne    148f <main+0x35f>
mov    $0x2,%sil
mov    $0x2,%edi
test   $0x1,%r8b
jne    14ee <main+0x3be>
mov    %rax,%r14
mov    -0x38(%rbp),%r13
jmp    1506 <main+0x3d6>
lea    -0x2(%r8),%rbx
and    $0xfffffffffffffffe,%rbx
neg    %rbx
mov    $0x2,%sil
mov    $0x2,%edi
jmp    14c2 <main+0x392>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
lea    (%rbx,%rdi,1),%rcx
add    $0x2,%rcx
add    $0x2,%rdi
cmp    $0x2,%rcx
je     1480 <main+0x350>
mov    0x0(%r13,%rdi,4),%ecx
cmp    %edx,%ecx
je     14d7 <main+0x3a7>
movzbl %sil,%esi
mov    %ecx,(%r15,%rsi,4)
add    $0x1,%sil
mov    0x4(%r13,%rdi,4),%edx
cmp    %ecx,%edx
je     14b0 <main+0x380>
movzbl %sil,%esi
mov    %edx,(%r15,%rsi,4)
add    $0x1,%sil
jmp    14b0 <main+0x380>
mov    0x0(%r13,%rdi,4),%ecx
cmp    %edx,%ecx
mov    -0x38(%rbp),%r13
je     1503 <main+0x3d3>
movzbl %sil,%edx
mov    %ecx,(%r15,%rdx,4)
mov    %rax,%r14
lea    0xb28(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
test   %r14,%r14
je     154b <main+0x41b>
mov    $0x1,%ebx
lea    0xafc(%rip),%r12
cs nopw 0x0(%rax,%rax,1)
nop
mov    (%r15,%rbx,4),%esi
mov    %r12,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
add    $0x1,%ebx
movzbl %bl,%ebx
cmp    %rbx,%r14
jae    1530 <main+0x400>
jmp    154e <main+0x41e>
xor    %r14d,%r14d
lea    0xb35(%rip),%rdi
call   1030 <puts@plt>
lea    0xae3(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    $0x2,%r14d
jbe    15a9 <main+0x479>
mov    0xc(%r15),%esi
lea    0xade(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xad4(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
cmp    $0x3,%r14d
je     15c3 <main+0x493>
mov    -0xc(%r15,%r14,4),%esi
lea    0xab7(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
jmp    15cf <main+0x49f>
lea    0xadc(%rip),%rdi
call   1030 <puts@plt>
lea    0xa9f(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xac2(%rip),%rdi
call   1030 <puts@plt>
mov    %r13,%rsp
xor    %eax,%eax
lea    -0x28(%rbp),%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

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

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