#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*/ C(int *, int *, int);
int /*<<< orphan*/ R(int *, int);
int /*<<< orphan*/ T(int *, int *, int);
int /*<<< orphan*/ V(int *);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ scanf(char *, int *);
int main(int argc, char **argv) {
  int a, b, x, xmax, y, ymax, z;
  int OK = 0;
  printf("Inserire un numero: ");
  scanf("%d", &a);
  printf("Inserire un numero: ");
  scanf("%d", &b);
  printf("Inserire il valore obiettivo: ");
  scanf("%d", &z);
  if ((a <= 0) || (b <= 0) || (a == b) || (z <= 0)) {
    printf("Valore non vaido");
  } else {
    if (a > b) {
      y = b;
      x = a;
    } else {
      y = a;
      x = b;
    }
    if ((z >= x) || ((x % 2 == 0) && (y % 2 == 0) && (z % 2 != 0))) {
      printf("Valore non vaido");
    } else {
      printf("Caso: %d %d => %d \n", x, y, z);
      ymax = y;
      xmax = x;
      x = 0;
      y = 0;
      int p1 = 0, p2 = 0, i = 0;
      printf("Agisco sul secchio maggiore\n");
      while (OK == 0) {
        R(&x, xmax);
        printf("R - %d %d\n", x, y);
        i++;
        C(&x, &y, ymax);
        printf("C - %d %d\n", x, y);
        i++;
        V(&y);
        printf("V - %d %d\n", x, y);
        i++;
        if (x > ymax) {
          if (x == z) {
            OK = 1;
          } else {
            while ((x > ymax) && (OK == 0)) {
              C(&x, &y, ymax);
              printf("2C - %d %d\n", x, y);
              i++;
              V(&y);
              printf("2V - %d %d\n", x, y);
              i++;
              if (x == z) {
                i -= 2;
                OK = 1;
              }
            }
            T(&x, &y, ymax);
          }
        } else {
          T(&x, &y, ymax);
        }
        printf("T - %d %d\n", x, y);
        i++;
        if (y == z) {
          i -= 2;
          OK = 1;
        }
        if ((y > 100) || (x > 100))
          OK = 2;
        if (i > 100) {
          printf("Troppi step, Impossibile?\n");
          OK = 2;
        }
      }
      printf("Passi Maggiore: %d (valore trovato al passo C)\n", i);
      p1 = i;
      printf("Agisco sul secchio minore\n");
      y = 0;
      x = 0;
      i = 0;
      OK = 0;
      while (OK == 0) {
        R(&y, ymax);
        printf("R - %d %d\n", x, y);
        i++;
        T(&y, &x, xmax);
        printf("T - %d %d\n", x, y);
        i++;
        if ((x == z) || (y == z)) {
          OK = 1;
        } else {
          if (x == xmax) {
            V(&x);
            printf("2V - %d %d\n", x, y);
            i++;
            T(&y, &x, xmax);
            printf("2T - %d %d\n", x, y);
            i++;
          }
        }
        if (i > 100) {
          printf("Troppi step, Impossibile?\n");
          OK = 2;
        }
      }
      printf("Passi Minore: %d\n", i);
      p2 = i;
      if (p1 <= p2) {
        if (p1 == p2) {
          printf("\nGli algoritmi sono equivalenti con %d passi\n", p1);
        } else {
          printf("\nE' piu' efficente A1 (Agisco sul maggiore), %d passi\n",
                 p1);
        }
      } else {
        printf("\nE' piu' efficente A2 (Agisco sul minore), %d passi\n", p2);
      }
    }
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x0,-0x30(%rbp)
lea    0xe7c(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    0xe83(%rip),%rdi
lea    -0x14(%rbp),%rsi
call   1080 <scanf@plt>
lea    0xe5e(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    0xe65(%rip),%rdi
lea    -0x18(%rbp),%rsi
call   1080 <scanf@plt>
lea    0xe58(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    0xe47(%rip),%rdi
lea    -0x2c(%rbp),%rsi
call   1080 <scanf@plt>
cmpl   $0x0,-0x14(%rbp)
jle    1201 <main+0xa1>
cmpl   $0x0,-0x18(%rbp)
jle    1201 <main+0xa1>
mov    -0x14(%rbp),%eax
cmp    -0x18(%rbp),%eax
je     1201 <main+0xa1>
cmpl   $0x0,-0x2c(%rbp)
jg     1214 <main+0xb4>
lea    0xe2f(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    169a <main+0x53a>
mov    -0x14(%rbp),%eax
cmp    -0x18(%rbp),%eax
jle    1231 <main+0xd1>
mov    -0x18(%rbp),%eax
mov    %eax,-0x24(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x1c(%rbp)
jmp    123d <main+0xdd>
mov    -0x14(%rbp),%eax
mov    %eax,-0x24(%rbp)
mov    -0x18(%rbp),%eax
mov    %eax,-0x1c(%rbp)
mov    -0x2c(%rbp),%eax
cmp    -0x1c(%rbp),%eax
jge    1285 <main+0x125>
mov    -0x1c(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
cmp    $0x0,%edx
jne    1298 <main+0x138>
mov    -0x24(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
cmp    $0x0,%edx
jne    1298 <main+0x138>
mov    -0x2c(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
cmp    $0x0,%edx
je     1298 <main+0x138>
lea    0xdab(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    1695 <main+0x535>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
mov    -0x2c(%rbp),%ecx
lea    0xda0(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x24(%rbp),%eax
mov    %eax,-0x28(%rbp)
mov    -0x1c(%rbp),%eax
mov    %eax,-0x20(%rbp)
movl   $0x0,-0x1c(%rbp)
movl   $0x0,-0x24(%rbp)
movl   $0x0,-0x34(%rbp)
movl   $0x0,-0x38(%rbp)
movl   $0x0,-0x3c(%rbp)
lea    0xd77(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
cmpl   $0x0,-0x30(%rbp)
jne    14d7 <main+0x377>
mov    -0x20(%rbp),%esi
lea    -0x1c(%rbp),%rdi
call   1050 <R@plt>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
lea    0xd6a(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
mov    -0x28(%rbp),%edx
lea    -0x1c(%rbp),%rdi
lea    -0x24(%rbp),%rsi
call   1070 <C@plt>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
lea    0xd49(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
lea    -0x24(%rbp),%rdi
call   1040 <V@plt>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
lea    0xd2f(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
mov    -0x1c(%rbp),%eax
cmp    -0x28(%rbp),%eax
jle    144f <main+0x2ef>
mov    -0x1c(%rbp),%eax
cmp    -0x2c(%rbp),%eax
jne    1396 <main+0x236>
movl   $0x1,-0x30(%rbp)
jmp    144a <main+0x2ea>
jmp    139b <main+0x23b>
mov    -0x1c(%rbp),%ecx
xor    %eax,%eax
cmp    -0x28(%rbp),%ecx
mov    %al,-0x3d(%rbp)
jle    13b6 <main+0x256>
cmpl   $0x0,-0x30(%rbp)
sete   %al
mov    %al,-0x3d(%rbp)
mov    -0x3d(%rbp),%al
test   $0x1,%al
jne    13c6 <main+0x266>
jmp    143a <main+0x2da>
mov    -0x28(%rbp),%edx
lea    -0x1c(%rbp),%rdi
lea    -0x24(%rbp),%rsi
call   1070 <C@plt>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
lea    0xca1(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
lea    -0x24(%rbp),%rdi
call   1040 <V@plt>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
lea    0xc87(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
mov    -0x1c(%rbp),%eax
cmp    -0x2c(%rbp),%eax
jne    1435 <main+0x2d5>
mov    -0x3c(%rbp),%eax
sub    $0x2,%eax
mov    %eax,-0x3c(%rbp)
movl   $0x1,-0x30(%rbp)
jmp    139b <main+0x23b>
mov    -0x28(%rbp),%edx
lea    -0x1c(%rbp),%rdi
lea    -0x24(%rbp),%rsi
call   1030 <T@plt>
jmp    145f <main+0x2ff>
mov    -0x28(%rbp),%edx
lea    -0x1c(%rbp),%rdi
lea    -0x24(%rbp),%rsi
call   1030 <T@plt>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
lea    0xc97(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
mov    -0x24(%rbp),%eax
cmp    -0x2c(%rbp),%eax
jne    1498 <main+0x338>
mov    -0x3c(%rbp),%eax
sub    $0x2,%eax
mov    %eax,-0x3c(%rbp)
movl   $0x1,-0x30(%rbp)
cmpl   $0x64,-0x24(%rbp)
jg     14ac <main+0x34c>
cmpl   $0x64,-0x1c(%rbp)
jle    14b3 <main+0x353>
movl   $0x2,-0x30(%rbp)
cmpl   $0x64,-0x3c(%rbp)
jle    14d2 <main+0x372>
lea    0xbd8(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
movl   $0x2,-0x30(%rbp)
jmp    12ec <main+0x18c>
mov    -0x3c(%rbp),%esi
lea    0xbd6(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
mov    %eax,-0x34(%rbp)
lea    0xbf2(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
movl   $0x0,-0x24(%rbp)
movl   $0x0,-0x1c(%rbp)
movl   $0x0,-0x3c(%rbp)
movl   $0x0,-0x30(%rbp)
cmpl   $0x0,-0x30(%rbp)
jne    1624 <main+0x4c4>
mov    -0x28(%rbp),%esi
lea    -0x24(%rbp),%rdi
call   1050 <R@plt>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
lea    0xb3e(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
mov    -0x20(%rbp),%edx
lea    -0x24(%rbp),%rdi
lea    -0x1c(%rbp),%rsi
call   1030 <T@plt>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
lea    0xb9b(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
mov    -0x1c(%rbp),%eax
cmp    -0x2c(%rbp),%eax
je     1590 <main+0x430>
mov    -0x24(%rbp),%eax
cmp    -0x2c(%rbp),%eax
jne    159c <main+0x43c>
movl   $0x1,-0x30(%rbp)
jmp    1600 <main+0x4a0>
mov    -0x1c(%rbp),%eax
cmp    -0x20(%rbp),%eax
jne    15fb <main+0x49b>
lea    -0x1c(%rbp),%rdi
call   1040 <V@plt>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
lea    0xad2(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
mov    -0x20(%rbp),%edx
lea    -0x24(%rbp),%rdi
lea    -0x1c(%rbp),%rsi
call   1030 <T@plt>
mov    -0x1c(%rbp),%esi
mov    -0x24(%rbp),%edx
lea    0xb17(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
jmp    1600 <main+0x4a0>
cmpl   $0x64,-0x3c(%rbp)
jle    161f <main+0x4bf>
lea    0xa8b(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
movl   $0x2,-0x30(%rbp)
jmp    1518 <main+0x3b8>
mov    -0x3c(%rbp),%esi
lea    0xae0(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x3c(%rbp),%eax
mov    %eax,-0x38(%rbp)
mov    -0x34(%rbp),%eax
cmp    -0x38(%rbp),%eax
jg     167f <main+0x51f>
mov    -0x34(%rbp),%eax
cmp    -0x38(%rbp),%eax
jne    1669 <main+0x509>
mov    -0x34(%rbp),%esi
lea    0xac3(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    167a <main+0x51a>
mov    -0x34(%rbp),%esi
lea    0xadb(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    1690 <main+0x530>
mov    -0x38(%rbp),%esi
lea    0xafc(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    1695 <main+0x535>
jmp    169a <main+0x53a>
xor    %eax,%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
lea    0xe7b(%rip),%rbx
mov    %rbx,%rdi
xor    %eax,%eax
call   1070 <printf@plt>
lea    0xe7f(%rip),%rbp
lea    0x14(%rsp),%rsi
mov    %rbp,%rdi
call   1090 <scanf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1070 <printf@plt>
lea    0x10(%rsp),%rsi
mov    %rbp,%rdi
call   1090 <scanf@plt>
lea    0xe57(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
lea    0x8(%rsp),%rsi
mov    %rbp,%rdi
call   1090 <scanf@plt>
mov    0x14(%rsp),%eax
test   %eax,%eax
jle    1218 <main+0xa8>
mov    0x10(%rsp),%esi
test   %esi,%esi
jle    1218 <main+0xa8>
cmp    %esi,%eax
je     1218 <main+0xa8>
mov    0x8(%rsp),%ecx
test   %ecx,%ecx
jle    1218 <main+0xa8>
cmp    %esi,%eax
mov    %eax,%edx
cmova  %esi,%edx
cmova  %eax,%esi
mov    %edx,0x4(%rsp)
mov    %esi,(%rsp)
cmp    %esi,%ecx
jae    1218 <main+0xa8>
test   $0x1,%sil
jne    1237 <main+0xc7>
test   $0x1,%dl
jne    1237 <main+0xc7>
mov    %ecx,%eax
and    $0x1,%eax
je     1237 <main+0xc7>
lea    0xe18(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
xor    %eax,%eax
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
lea    0xe0a(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
mov    0x4(%rsp),%r15d
mov    (%rsp),%ebp
movl   $0x0,(%rsp)
movl   $0x0,0x4(%rsp)
lea    0xf04(%rip),%rdi
call   1030 <puts@plt>
lea    0x4(%rsp),%r13
xor    %r14d,%r14d
mov    %ebp,0xc(%rsp)
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    %rsp,%rbx
mov    %rbx,%rdi
mov    %ebp,%esi
call   1060 <R@plt>
mov    (%rsp),%esi
mov    0x4(%rsp),%edx
lea    0xdc1(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %rbx,%rdi
mov    %r13,%rsi
mov    %r15d,%edx
call   1080 <C@plt>
mov    (%rsp),%esi
mov    0x4(%rsp),%edx
lea    0xdaa(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %r13,%rdi
call   1050 <V@plt>
mov    (%rsp),%esi
mov    0x4(%rsp),%edx
lea    0xd99(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
add    $0x3,%r14d
mov    (%rsp),%eax
cmp    %r15d,%eax
jle    1380 <main+0x210>
mov    $0x1,%r12d
cmp    0x8(%rsp),%eax
je     1391 <main+0x221>
lea    0xd5e(%rip),%r12
mov    %rsp,%rbx
nopl   0x0(%rax)
mov    %r14d,%ebp
mov    %rbx,%rdi
mov    %r13,%rsi
mov    %r15d,%edx
call   1080 <C@plt>
mov    (%rsp),%esi
mov    0x4(%rsp),%edx
mov    %r12,%rdi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %r13,%rdi
call   1050 <V@plt>
mov    (%rsp),%esi
mov    0x4(%rsp),%edx
lea    0xd2b(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
lea    0x2(%rbp),%r14d
mov    (%rsp),%eax
mov    0x8(%rsp),%ecx
cmp    %ecx,%eax
cmove  %ebp,%r14d
je     1367 <main+0x1f7>
cmp    %r15d,%eax
jg     1310 <main+0x1a0>
xor    %r12d,%r12d
cmp    %ecx,%eax
sete   %r12b
mov    0xc(%rsp),%ebp
jmp    1383 <main+0x213>
cs nopw 0x0(%rax,%rax,1)
xor    %r12d,%r12d
mov    %rsp,%rdi
mov    %r13,%rsi
mov    %r15d,%edx
call   1040 <T@plt>
mov    (%rsp),%esi
mov    0x4(%rsp),%edx
lea    0xd11(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
mov    0x4(%rsp),%eax
mov    0x8(%rsp),%ecx
xor    %edx,%edx
cmp    %ecx,%eax
setne  %dl
lea    (%r14,%rdx,2),%r14d
add    $0xffffffff,%r14d
cmp    $0x65,%r14d
jge    13dd <main+0x26d>
cmp    $0x64,%eax
jg     13e9 <main+0x279>
cmpl   $0x64,(%rsp)
jg     13e9 <main+0x279>
cmp    %ecx,%eax
je     13e9 <main+0x279>
test   %r12d,%r12d
je     1280 <main+0x110>
jmp    13e9 <main+0x279>
lea    0xdb9(%rip),%rdi
call   1030 <puts@plt>
lea    0xc8f(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1070 <printf@plt>
lea    0xd82(%rip),%rdi
call   1030 <puts@plt>
movl   $0x0,0x4(%rsp)
movl   $0x0,(%rsp)
lea    0xc40(%rip),%r13
xor    %ebp,%ebp
xchg   %ax,%ax
lea    0x4(%rsp),%rbx
mov    %rbx,%rdi
mov    %r15d,%esi
call   1060 <R@plt>
mov    (%rsp),%esi
mov    0x4(%rsp),%edx
xor    %r12d,%r12d
mov    %r13,%rdi
xor    %eax,%eax
call   1070 <printf@plt>
mov    %rbx,%rdi
mov    %rsp,%rsi
mov    0xc(%rsp),%edx
call   1040 <T@plt>
mov    (%rsp),%esi
mov    0x4(%rsp),%edx
lea    0xc4f(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
lea    0x2(%rbp),%eax
mov    (%rsp),%ecx
mov    0x8(%rsp),%edx
cmp    %edx,%ecx
je     14e0 <main+0x370>
cmp    %edx,0x4(%rsp)
je     14e0 <main+0x370>
mov    %r13,%rbx
mov    $0x1,%r12b
mov    0xc(%rsp),%r13d
cmp    %r13d,%ecx
jne    14f0 <main+0x380>
mov    %rsp,%rdi
call   1050 <V@plt>
mov    (%rsp),%esi
mov    0x4(%rsp),%edx
lea    0xbd1(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
lea    0x4(%rsp),%rdi
mov    %rsp,%rsi
mov    %r13d,%edx
call   1040 <T@plt>
mov    (%rsp),%esi
mov    0x4(%rsp),%edx
lea    0xbe8(%rip),%rdi
xor    %eax,%eax
call   1070 <printf@plt>
add    $0x4,%ebp
jmp    14f2 <main+0x382>
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    %eax,%ebp
cmp    $0x65,%ebp
jl     14fa <main+0x38a>
jmp    1505 <main+0x395>
nopl   0x0(%rax)
mov    %eax,%ebp
mov    %rbx,%r13
cmp    $0x65,%ebp
jge    1505 <main+0x395>
test   %r12b,%r12b
jne    1420 <main+0x2b0>
jmp    1511 <main+0x3a1>
lea    0xc91(%rip),%rdi
call   1030 <puts@plt>
lea    0xba3(%rip),%rdi
mov    %ebp,%esi
xor    %eax,%eax
call   1070 <printf@plt>
cmp    %ebp,%r14d
jle    1531 <main+0x3c1>
lea    0xc05(%rip),%rdi
mov    %ebp,%esi
jmp    1546 <main+0x3d6>
jne    153c <main+0x3cc>
lea    0xb93(%rip),%rdi
jmp    1543 <main+0x3d3>
lea    0xbb8(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1070 <printf@plt>
jmp    1226 <main+0xb6>

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

LLVM IR (-O2):
@.str = [21 x i8] c"Inserire un numero: \00"
@.str.1 = [3 x i8] c"%d\00"
@.str.2 = [31 x i8] c"Inserire il valore obiettivo: \00"
@.str.3 = [17 x i8] c"Valore non vaido\00"
@.str.4 = [20 x i8] c"Caso: %d %d => %d \0A\00"
@.str.6 = [11 x i8] c"R - %d %d\0A\00"
@.str.7 = [11 x i8] c"C - %d %d\0A\00"
@.str.8 = [11 x i8] c"V - %d %d\0A\00"
@.str.9 = [12 x i8] c"2C - %d %d\0A\00"
@.str.10 = [12 x i8] c"2V - %d %d\0A\00"
@.str.11 = [11 x i8] c"T - %d %d\0A\00"
@.str.13 = [48 x i8] c"Passi Maggiore: %d (valore trovato al passo C)\0A\00"
@.str.15 = [12 x i8] c"2T - %d %d\0A\00"
@.str.16 = [18 x i8] c"Passi Minore: %d\0A\00"
@.str.17 = [46 x i8] c"\0AGli algoritmi sono equivalenti con %d passi\0A\00"
@.str.18 = [55 x i8] c"\0AE' piu' efficente A1 (Agisco sul maggiore), %d passi\0A\00"
@.str.19 = [53 x i8] c"\0AE' piu' efficente A2 (Agisco sul minore), %d passi\0A\00"
@str = [28 x i8] c"Agisco sul secchio maggiore\00"
@str.20 = [26 x i8] c"Agisco sul secchio minore\00"
@str.22 = [26 x i8] c"Troppi step, Impossibile?\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = bitcast i32* %3 to i8*
%9 = bitcast i32* %4 to i8*
%10 = bitcast i32* %5 to i8*
%11 = bitcast i32* %6 to i8*
%12 = bitcast i32* %7 to i8*
%13 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0))
%14 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %3)
%15 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0))
%16 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %4)
%17 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @.str.2, i64 0, i64 0))
%18 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i32* %7)
%19 = load i32, i32* %3
%20 = icmp slt i32 %19, 1
%21 = load i32, i32* %4
%22 = icmp slt i32 %21, 1
%23 = select i1 %20, i1 true, i1 %22
br i1 %23, label %29, label %24
24: ; preds = %2
%25 = icmp eq i32 %19, %21
%26 = load i32, i32* %7
%27 = icmp slt i32 %26, 1
%28 = select i1 %25, i1 true, i1 %27
br i1 %28, label %29, label %31
29: ; preds = %24, %2
%30 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str.3, i64 0, i64 0))
br label %168
31: ; preds = %24
%32 = icmp ugt i32 %19, %21
%33 = select i1 %32, i32 %21, i32 %19
store i32 %33, i32* %6
%34 = select i1 %32, i32 %19, i32 %21
store i32 %34, i32* %5
%35 = icmp ult i32 %26, %34
br i1 %35, label %36, label %45
36: ; preds = %31
%37 = and i32 %34, 1
%38 = icmp eq i32 %37, 0
br i1 %38, label %39, label %47
39: ; preds = %36
%40 = and i32 %33, 1
%41 = icmp ne i32 %40, 0
%42 = and i32 %26, 1
%43 = icmp eq i32 %42, 0
%44 = select i1 %41, i1 true, i1 %43
br i1 %44, label %47, label %45
45: ; preds = %39, %31
%46 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([17 x i8], [17 x i8]* @.str.3, i64 0, i64 0))
br label %168
47: ; preds = %39, %36
%48 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i32 %34, i32 %33, i32 %26)
%49 = load i32, i32* %6
%50 = load i32, i32* %5
store i32 0, i32* %5
store i32 0, i32* %6
%51 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([28 x i8], [28 x i8]* @str, i64 0, i64 0))
br label %52
52: ; preds = %47, %109
%53 = phi i32 [ 0, %47 ], [ %105, %109 ]
%54 = call i32 @R(i32* %5, i32 %50)
%55 = load i32, i32* %5
%56 = load i32, i32* %6
%57 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.6, i64 0, i64 0), i32 %55, i32 %56)
%58 = call i32 @C(i32* %5, i32* %6, i32 %49)
%59 = load i32, i32* %5
%60 = load i32, i32* %6
%61 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.7, i64 0, i64 0), i32 %59, i32 %60)
%62 = call i32 @V(i32* %6)
%63 = load i32, i32* %5
%64 = load i32, i32* %6
%65 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.8, i64 0, i64 0), i32 %63, i32 %64)
%66 = add nsw i32 %53, 3
%67 = load i32, i32* %5
%68 = icmp sgt i32 %67, %49
br i1 %68, label %69, label %91
69: ; preds = %52
%70 = load i32, i32* %7
%71 = icmp eq i32 %67, %70
br i1 %71, label %95, label %72
72: ; preds = %69, %72
%73 = phi i32 [ %86, %72 ], [ %66, %69 ]
%74 = call i32 @C(i32* %5, i32* %6, i32 %49)
%75 = load i32, i32* %5
%76 = load i32, i32* %6
%77 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.9, i64 0, i64 0), i32 %75, i32 %76)
%78 = call i32 @V(i32* %6)
%79 = load i32, i32* %5
%80 = load i32, i32* %6
%81 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0), i32 %79, i32 %80)
%82 = add nsw i32 %73, 2
%83 = load i32, i32* %5
%84 = load i32, i32* %7
%85 = icmp eq i32 %83, %84
%86 = select i1 %85, i32 %73, i32 %82
%87 = icmp sle i32 %83, %49
%88 = or i1 %85, %87
br i1 %88, label %89, label %72
89: ; preds = %72
%90 = zext i1 %85 to i32
br label %91
91: ; preds = %52, %89
%92 = phi i32 [ %90, %89 ], [ 0, %52 ]
%93 = phi i32 [ %86, %89 ], [ %66, %52 ]
%94 = call i32 @T(i32* %5, i32* %6, i32 %49)
br label %95
95: ; preds = %91, %69
%96 = phi i32 [ 1, %69 ], [ %92, %91 ]
%97 = phi i32 [ %66, %69 ], [ %93, %91 ]
%98 = load i32, i32* %5
%99 = load i32, i32* %6
%100 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.11, i64 0, i64 0), i32 %98, i32 %99)
%101 = load i32, i32* %6
%102 = load i32, i32* %7
%103 = icmp eq i32 %101, %102
%104 = select i1 %103, i32 -1, i32 1
%105 = add nsw i32 %104, %97
%106 = icmp sgt i32 %105, 100
br i1 %106, label %107, label %109
107: ; preds = %95
%108 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([26 x i8], [26 x i8]* @str.22, i64 0, i64 0))
br label %118
109: ; preds = %95
%110 = icmp slt i32 %101, 101
%111 = load i32, i32* %5
%112 = icmp slt i32 %111, 101
%113 = select i1 %110, i1 %112, i1 false
%114 = icmp eq i32 %96, 0
%115 = xor i1 %103, true
%116 = select i1 %113, i1 %115, i1 false
%117 = select i1 %116, i1 %114, i1 false
br i1 %117, label %52, label %118
118: ; preds = %109, %107
%119 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([48 x i8], [48 x i8]* @.str.13, i64 0, i64 0), i32 %105)
%120 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([26 x i8], [26 x i8]* @str.20, i64 0, i64 0))
store i32 0, i32* %6
store i32 0, i32* %5
br label %121
121: ; preds = %118, %156
%122 = phi i32 [ 0, %118 ], [ %152, %156 ]
%123 = call i32 @R(i32* %6, i32 %49)
%124 = load i32, i32* %5
%125 = load i32, i32* %6
%126 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.6, i64 0, i64 0), i32 %124, i32 %125)
%127 = call i32 @T(i32* %6, i32* %5, i32 %50)
%128 = load i32, i32* %5
%129 = load i32, i32* %6
%130 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.11, i64 0, i64 0), i32 %128, i32 %129)
%131 = add nsw i32 %122, 2
%132 = load i32, i32* %5
%133 = load i32, i32* %7
%134 = icmp eq i32 %132, %133
%135 = load i32, i32* %6
%136 = icmp eq i32 %135, %133
%137 = select i1 %134, i1 true, i1 %136
br i1 %137, label %150, label %138
138: ; preds = %121
%139 = icmp eq i32 %132, %50
br i1 %139, label %140, label %150
140: ; preds = %138
%141 = call i32 @V(i32* %5)
%142 = load i32, i32* %5
%143 = load i32, i32* %6
%144 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0), i32 %142, i32 %143)
%145 = call i32 @T(i32* %6, i32* %5, i32 %50)
%146 = load i32, i32* %5
%147 = load i32, i32* %6
%148 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.15, i64 0, i64 0), i32 %146, i32 %147)
%149 = add nsw i32 %122, 4
br label %150
150: ; preds = %121, %138, %140
%151 = phi i1 [ false, %121 ], [ true, %138 ], [ true, %140 ]
%152 = phi i32 [ %131, %121 ], [ %131, %138 ], [ %149, %140 ]
%153 = icmp sgt i32 %152, 100
br i1 %153, label %154, label %156
154: ; preds = %150
%155 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([26 x i8], [26 x i8]* @str.22, i64 0, i64 0))
br label %157
156: ; preds = %150
br i1 %151, label %121, label %157
157: ; preds = %156, %154
%158 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @.str.16, i64 0, i64 0), i32 %152)
%159 = icmp sgt i32 %105, %152
br i1 %159, label %166, label %160
160: ; preds = %157
%161 = icmp eq i32 %105, %152
br i1 %161, label %162, label %164
162: ; preds = %160
%163 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([46 x i8], [46 x i8]* @.str.17, i64 0, i64 0), i32 %105)
br label %168
164: ; preds = %160
%165 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([55 x i8], [55 x i8]* @.str.18, i64 0, i64 0), i32 %105)
br label %168
166: ; preds = %157
%167 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([53 x i8], [53 x i8]* @.str.19, i64 0, i64 0), i32 %152)
br label %168
168: ; preds = %166, %164, %162, %45, %29
ret i32 0
}