#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 EditDistance(char *, char *, int **);
int Knapsack(int *, int *, int, int, int **);
int LCS(char *, char *, int **);
int Partition(int *, int, int **);
int /*<<< orphan*/ getchar();
scalar_t__ malloc(int);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ scanf(char *, ...);
int /*<<< orphan*/ strlen(char *);
int main() {
  char a[100], b[100];
  int *m = NULL, *a_int = NULL, *weight = NULL, *values = NULL;
  int i, j, res, dim_a, dim_b, choice, dim, s, capacity;
  while (1) {
    printf("0 -> Exit.\n");
    printf("1 -> LCS.\n");
    printf("2 -> Partition.\n");
    printf("3 -> KnapSack.\n");
    printf("4 -> EditDistance.\n");
    printf("What do you want to do? (0, 1, 2, 3, 4) ");
    scanf("%d", &choice);
    switch (choice) {
    case 1:
      printf("Insert first string for LCS: ");
      scanf("%s", a);
      getchar();
      printf("Insert second string for LCS: ");
      scanf("%s", b);
      dim_a = strlen(a) + 1;
      dim_b = strlen(b) + 1;
      res = LCS(a, b, &m);
      for (i = 0; i < dim_a; i++) {
        for (j = 0; j < dim_b; j++)
          printf("%d ", m[i * dim_b + j]);
        printf("\n");
      }
      printf("The longest common sequence is %d chars long.\n", res);
      break;
    case 2:
      printf("How many values do you want to store? ");
      scanf("%d", &dim);
      a_int = (int *)malloc(sizeof(int) * dim);
      printf("Insert values:\n");
      for (i = 0; i < dim; i++) {
        scanf("%d", &a_int[i]);
      }
      for (i = 0, s = 0; i < dim; i++)
        s += a_int[i];
      s /= 2;
      res = Partition(a_int, dim, &m);
      for (i = 0; i < dim + 1; i++) {
        for (j = 0; j < s + 1; j++)
          printf("%d ", m[i * (s + 1) + j]);
        printf("\n");
      }
      printf("%d\n", res);
      break;
    case 3:
      printf("How many elements do you want to add? ");
      scanf("%d", &dim);
      weight = (int *)malloc(sizeof(int) * dim);
      values = (int *)malloc(sizeof(int) * dim);
      printf("Insert %d couples for weight and value.\n", dim);
      for (i = 0; i < dim; i++) {
        printf("Couple %d: ", i + 1);
        scanf("%d", &weight[i]);
        scanf("%d", &values[i]);
      }
      printf("Which is the capacity? ");
      scanf("%d", &capacity);
      res = Knapsack(values, weight, dim, capacity, &m);
      for (i = 0; i < dim + 1; i++) {
        for (j = 0; j < capacity + 1; j++)
          printf("%d ", m[i * (capacity + 1) + j]);
        printf("\n");
      }
      break;
    case 4:
      printf("Insert first string for EditDistance: ");
      scanf("%s", a);
      getchar();
      printf("Insert second string for EditDistance: ");
      scanf("%s", b);
      dim_a = strlen(a) + 1;
      dim_b = strlen(b) + 1;
      res = EditDistance(a, b, &m);
      for (i = 0; i < dim_b; i++) {
        for (j = 0; j < dim_a; j++)
          printf("%d ", m[i * dim_a + j]);
        printf("\n");
      }
      printf("Edit distance between %s and %s is %d chars long.\n", a, b, res);
      break;
    default:
      return 0;
    }
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x140,%rsp
movl   $0x0,-0x4(%rbp)
movq   $0x0,-0xe8(%rbp)
movq   $0x0,-0xf0(%rbp)
movq   $0x0,-0xf8(%rbp)
movq   $0x0,-0x100(%rbp)
lea    0xe3b(%rip),%rdi
xor    %eax,%eax
mov    %al,-0x131(%rbp)
call   1060 <printf@plt>
mov    -0x131(%rbp),%al
lea    0xe2d(%rip),%rdi
call   1060 <printf@plt>
mov    -0x131(%rbp),%al
lea    0xe26(%rip),%rdi
call   1060 <printf@plt>
mov    -0x131(%rbp),%al
lea    0xe25(%rip),%rdi
call   1060 <printf@plt>
mov    -0x131(%rbp),%al
lea    0xe23(%rip),%rdi
call   1060 <printf@plt>
mov    -0x131(%rbp),%al
lea    0xe25(%rip),%rdi
call   1060 <printf@plt>
mov    -0x131(%rbp),%al
lea    0xe3c(%rip),%rdi
lea    -0x118(%rbp),%rsi
call   10a0 <scanf@plt>
mov    -0x118(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,%ecx
mov    %rcx,-0x130(%rbp)
sub    $0x3,%eax
ja     18f8 <main+0x768>
mov    -0x130(%rbp),%rax
lea    0xd82(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xdfa(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    -0x70(%rbp),%rsi
lea    0xe06(%rip),%rdi
mov    $0x0,%al
call   10a0 <scanf@plt>
mov    $0x0,%al
call   1080 <getchar@plt>
lea    0xdf4(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    -0xe0(%rbp),%rsi
lea    0xddc(%rip),%rdi
mov    $0x0,%al
call   10a0 <scanf@plt>
lea    -0x70(%rbp),%rdi
call   1050 <strlen@plt>
add    $0x1,%eax
mov    %eax,-0x110(%rbp)
lea    -0xe0(%rbp),%rdi
call   1050 <strlen@plt>
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
lea    -0x70(%rbp),%rdi
lea    -0xe0(%rbp),%rsi
lea    -0xe8(%rbp),%rdx
call   1030 <LCS@plt>
mov    %eax,-0x10c(%rbp)
movl   $0x0,-0x104(%rbp)
mov    -0x104(%rbp),%eax
cmp    -0x110(%rbp),%eax
jge    13b1 <main+0x221>
movl   $0x0,-0x108(%rbp)
mov    -0x108(%rbp),%eax
cmp    -0x114(%rbp),%eax
jge    138f <main+0x1ff>
mov    -0xe8(%rbp),%rax
mov    -0x104(%rbp),%ecx
imul   -0x114(%rbp),%ecx
add    -0x108(%rbp),%ecx
movslq %ecx,%rcx
mov    (%rax,%rcx,4),%esi
lea    0xd54(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x108(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x108(%rbp)
jmp    133b <main+0x1ab>
lea    0xc8f(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x104(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x104(%rbp)
jmp    131f <main+0x18f>
mov    -0x10c(%rbp),%esi
lea    0xd0e(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    1903 <main+0x773>
lea    0xd2a(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    0xca6(%rip),%rdi
lea    -0x11c(%rbp),%rsi
mov    $0x0,%al
call   10a0 <scanf@plt>
movslq -0x11c(%rbp),%rax
shl    $0x2,%rax
mov    %eax,%edi
call   1090 <malloc@plt>
mov    %rax,-0xf0(%rbp)
lea    0xd15(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
movl   $0x0,-0x104(%rbp)
mov    -0x104(%rbp),%eax
cmp    -0x11c(%rbp),%eax
jge    1467 <main+0x2d7>
mov    -0xf0(%rbp),%rsi
movslq -0x104(%rbp),%rax
shl    $0x2,%rax
add    %rax,%rsi
lea    0xc39(%rip),%rdi
mov    $0x0,%al
call   10a0 <scanf@plt>
mov    -0x104(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x104(%rbp)
jmp    141e <main+0x28e>
movl   $0x0,-0x104(%rbp)
movl   $0x0,-0x120(%rbp)
mov    -0x104(%rbp),%eax
cmp    -0x11c(%rbp),%eax
jge    14be <main+0x32e>
mov    -0xf0(%rbp),%rax
movslq -0x104(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
add    -0x120(%rbp),%eax
mov    %eax,-0x120(%rbp)
mov    -0x104(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x104(%rbp)
jmp    147b <main+0x2eb>
mov    -0x120(%rbp),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x120(%rbp)
mov    -0xf0(%rbp),%rdi
mov    -0x11c(%rbp),%esi
lea    -0xe8(%rbp),%rdx
call   10b0 <Partition@plt>
mov    %eax,-0x10c(%rbp)
movl   $0x0,-0x104(%rbp)
mov    -0x104(%rbp),%eax
mov    -0x11c(%rbp),%ecx
add    $0x1,%ecx
cmp    %ecx,%eax
jge    159c <main+0x40c>
movl   $0x0,-0x108(%rbp)
mov    -0x108(%rbp),%eax
mov    -0x120(%rbp),%ecx
add    $0x1,%ecx
cmp    %ecx,%eax
jge    157a <main+0x3ea>
mov    -0xe8(%rbp),%rax
mov    -0x104(%rbp),%ecx
mov    -0x120(%rbp),%edx
add    $0x1,%edx
imul   %edx,%ecx
add    -0x108(%rbp),%ecx
movslq %ecx,%rcx
mov    (%rax,%rcx,4),%esi
lea    0xb69(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x108(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x108(%rbp)
jmp    151c <main+0x38c>
lea    0xaa4(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x104(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x104(%rbp)
jmp    14fb <main+0x36b>
mov    -0x10c(%rbp),%esi
lea    0xb89(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    1903 <main+0x773>
lea    0xb7a(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    0xabb(%rip),%rdi
lea    -0x11c(%rbp),%rsi
mov    $0x0,%al
call   10a0 <scanf@plt>
movslq -0x11c(%rbp),%rax
shl    $0x2,%rax
mov    %eax,%edi
call   1090 <malloc@plt>
mov    %rax,-0xf8(%rbp)
movslq -0x11c(%rbp),%rax
shl    $0x2,%rax
mov    %eax,%edi
call   1090 <malloc@plt>
mov    %rax,-0x100(%rbp)
mov    -0x11c(%rbp),%esi
lea    0xb46(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
movl   $0x0,-0x104(%rbp)
mov    -0x104(%rbp),%eax
cmp    -0x11c(%rbp),%eax
jge    16ab <main+0x51b>
mov    -0x104(%rbp),%esi
add    $0x1,%esi
lea    0xb3c(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0xf8(%rbp),%rsi
movslq -0x104(%rbp),%rax
shl    $0x2,%rax
add    %rax,%rsi
lea    0xa18(%rip),%rdi
mov    $0x0,%al
call   10a0 <scanf@plt>
mov    -0x100(%rbp),%rsi
movslq -0x104(%rbp),%rax
shl    $0x2,%rax
add    %rax,%rsi
lea    0x9f5(%rip),%rdi
mov    $0x0,%al
call   10a0 <scanf@plt>
mov    -0x104(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x104(%rbp)
jmp    1628 <main+0x498>
lea    0xae0(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    0x9c5(%rip),%rdi
lea    -0x124(%rbp),%rsi
mov    $0x0,%al
call   10a0 <scanf@plt>
mov    -0x100(%rbp),%rdi
mov    -0xf8(%rbp),%rsi
mov    -0x11c(%rbp),%edx
mov    -0x124(%rbp),%ecx
lea    -0xe8(%rbp),%r8
call   1070 <Knapsack@plt>
mov    %eax,-0x10c(%rbp)
movl   $0x0,-0x104(%rbp)
mov    -0x104(%rbp),%eax
mov    -0x11c(%rbp),%ecx
add    $0x1,%ecx
cmp    %ecx,%eax
jge    17a5 <main+0x615>
movl   $0x0,-0x108(%rbp)
mov    -0x108(%rbp),%eax
mov    -0x124(%rbp),%ecx
add    $0x1,%ecx
cmp    %ecx,%eax
jge    1783 <main+0x5f3>
mov    -0xe8(%rbp),%rax
mov    -0x104(%rbp),%ecx
mov    -0x124(%rbp),%edx
add    $0x1,%edx
imul   %edx,%ecx
add    -0x108(%rbp),%ecx
movslq %ecx,%rcx
mov    (%rax,%rcx,4),%esi
lea    0x960(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x108(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x108(%rbp)
jmp    1725 <main+0x595>
lea    0x89b(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x104(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x104(%rbp)
jmp    1704 <main+0x574>
jmp    1903 <main+0x773>
lea    0x9f9(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    -0x70(%rbp),%rsi
lea    0x8e3(%rip),%rdi
mov    $0x0,%al
call   10a0 <scanf@plt>
mov    $0x0,%al
call   1080 <getchar@plt>
lea    0x9f9(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
lea    -0xe0(%rbp),%rsi
lea    0x8b9(%rip),%rdi
mov    $0x0,%al
call   10a0 <scanf@plt>
lea    -0x70(%rbp),%rdi
call   1050 <strlen@plt>
add    $0x1,%eax
mov    %eax,-0x110(%rbp)
lea    -0xe0(%rbp),%rdi
call   1050 <strlen@plt>
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
lea    -0x70(%rbp),%rdi
lea    -0xe0(%rbp),%rsi
lea    -0xe8(%rbp),%rdx
call   1040 <EditDistance@plt>
mov    %eax,-0x10c(%rbp)
movl   $0x0,-0x104(%rbp)
mov    -0x104(%rbp),%eax
cmp    -0x114(%rbp),%eax
jge    18d4 <main+0x744>
movl   $0x0,-0x108(%rbp)
mov    -0x108(%rbp),%eax
cmp    -0x110(%rbp),%eax
jge    18b2 <main+0x722>
mov    -0xe8(%rbp),%rax
mov    -0x104(%rbp),%ecx
imul   -0x110(%rbp),%ecx
add    -0x108(%rbp),%ecx
movslq %ecx,%rcx
mov    (%rax,%rcx,4),%esi
lea    0x831(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x108(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x108(%rbp)
jmp    185e <main+0x6ce>
lea    0x76c(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x104(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x104(%rbp)
jmp    1842 <main+0x6b2>
lea    -0x70(%rbp),%rsi
lea    -0xe0(%rbp),%rdx
mov    -0x10c(%rbp),%ecx
lea    0x90d(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    1903 <main+0x773>
xor    %eax,%eax
add    $0x140,%rsp
pop    %rbp
ret
jmp    11ce <main+0x3e>

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x118,%rsp
movq   $0x0,0x20(%rsp)
lea    0xe68(%rip),%r14
lea    0xea4(%rip),%r15
jmp    1206 <main+0x56>
nopw   0x0(%rax,%rax,1)
lea    0xfb6(%rip),%rdi
lea    0xb0(%rsp),%rsi
lea    0x40(%rsp),%rdx
mov    0x28(%rsp),%ecx
xor    %eax,%eax
call   1080 <printf@plt>
lea    0xe33(%rip),%r14
lea    0xfc3(%rip),%rdi
call   1050 <puts@plt>
lea    0xfc2(%rip),%rdi
call   1050 <puts@plt>
lea    0xfc0(%rip),%rdi
call   1050 <puts@plt>
lea    0xfc4(%rip),%rdi
call   1050 <puts@plt>
lea    0xfc7(%rip),%rdi
call   1050 <puts@plt>
lea    0xdc7(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
mov    %r14,%rdi
lea    0x3c(%rsp),%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
mov    0x3c(%rsp),%eax
add    $0xffffffff,%eax
cmp    $0x3,%eax
ja     185e <main+0x6ae>
lea    0xd8a(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xdb6(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
lea    0xdc6(%rip),%rbx
mov    %rbx,%rdi
lea    0xb0(%rsp),%r14
mov    %r14,%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
xor    %eax,%eax
call   10a0 <getchar@plt>
lea    0xda6(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
mov    %rbx,%rdi
lea    0x40(%rsp),%rbx
mov    %rbx,%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
mov    %r14,%rdi
call   1070 <strlen@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
call   1070 <strlen@plt>
mov    %rax,0x18(%rsp)
mov    %r14,%rdi
mov    %rbx,%rsi
lea    0x20(%rsp),%rdx
call   1040 <LCS@plt>
mov    %eax,0x28(%rsp)
mov    %rbp,0x10(%rsp)
test   %ebp,%ebp
js     1690 <main+0x4e0>
mov    0x18(%rsp),%rax
add    $0x1,%eax
movslq %eax,%rbx
mov    0x10(%rsp),%rax
add    $0x1,%eax
mov    %rax,0x10(%rsp)
mov    %ebx,%eax
mov    %rax,0x30(%rsp)
shl    $0x2,%rbx
xor    %ebp,%ebp
xor    %r13d,%r13d
jmp    135c <main+0x1ac>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x1,%r13
add    %rbx,%rbp
cmp    0x10(%rsp),%r13
je     1690 <main+0x4e0>
cmpl   $0x0,0x18(%rsp)
js     1340 <main+0x190>
mov    0x30(%rsp),%r12
mov    %rbp,%r14
nopl   0x0(%rax,%rax,1)
mov    0x20(%rsp),%rax
mov    (%rax,%r14,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1080 <printf@plt>
add    $0x4,%r14
add    $0xffffffffffffffff,%r12
jne    1370 <main+0x1c0>
jmp    1340 <main+0x190>
nop
xor    %r13d,%r13d
lea    0xd15(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
mov    %r14,%rdi
lea    0xc(%rsp),%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
mov    0xc(%rsp),%edi
shl    $0x2,%edi
call   10b0 <malloc@plt>
mov    %rax,%r12
lea    0xe51(%rip),%rdi
call   1050 <puts@plt>
mov    0xc(%rsp),%esi
test   %esi,%esi
jle    17ad <main+0x5fd>
mov    %r12,%rbx
xor    %ebp,%ebp
nopl   0x0(%rax)
mov    %r14,%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
add    $0x1,%rbp
movslq 0xc(%rsp),%rsi
add    $0x4,%rbx
cmp    %rsi,%rbp
jl     13e0 <main+0x230>
test   %esi,%esi
jle    17ad <main+0x5fd>
mov    %esi,%eax
cmp    $0x8,%esi
jae    16a0 <main+0x4f0>
xor    %ecx,%ecx
xor    %r13d,%r13d
jmp    17a0 <main+0x5f0>
nopl   0x0(%rax)
lea    0xcb3(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
mov    %r14,%rdi
lea    0xc(%rsp),%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
mov    0xc(%rsp),%edi
shl    $0x2,%edi
call   10b0 <malloc@plt>
mov    %rax,0x10(%rsp)
mov    0xc(%rsp),%edi
shl    $0x2,%edi
call   10b0 <malloc@plt>
mov    %rax,0x18(%rsp)
mov    0xc(%rsp),%esi
lea    0xc97(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
cmpl   $0x0,0xc(%rsp)
lea    0xcad(%rip),%rbp
jle    14cd <main+0x31d>
mov    0x10(%rsp),%rbx
mov    0x18(%rsp),%r13
xor    %r12d,%r12d
nopl   0x0(%rax)
add    $0x1,%r12
mov    %rbp,%rdi
mov    %r12d,%esi
xor    %eax,%eax
call   1080 <printf@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
mov    %r14,%rdi
mov    %r13,%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
movslq 0xc(%rsp),%rax
add    $0x4,%r13
add    $0x4,%rbx
cmp    %rax,%r12
jl     1490 <main+0x2e0>
lea    0xc62(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
mov    %r14,%rdi
lea    0x2c(%rsp),%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
mov    0xc(%rsp),%edx
mov    0x2c(%rsp),%ecx
mov    0x18(%rsp),%rdi
mov    0x10(%rsp),%rsi
lea    0x20(%rsp),%r8
call   1090 <Knapsack@plt>
cmpl   $0x0,0xc(%rsp)
js     1206 <main+0x56>
xor    %ebx,%ebx
jmp    1539 <main+0x389>
cs nopw 0x0(%rax,%rax,1)
nop
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0x1(%rbx),%eax
cmp    0xc(%rsp),%ebx
mov    %eax,%ebx
jge    1206 <main+0x56>
mov    0x2c(%rsp),%eax
test   %eax,%eax
js     1520 <main+0x370>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
add    $0x1,%eax
mov    0x20(%rsp),%rcx
imul   %ebx,%eax
cltq
add    %rbp,%rax
mov    (%rcx,%rax,4),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1080 <printf@plt>
mov    0x2c(%rsp),%eax
add    $0x1,%rbp
lea    -0x1(%rbp),%ecx
cmp    %eax,%ecx
jl     1550 <main+0x3a0>
jmp    1520 <main+0x370>
xchg   %ax,%ax
lea    0xbc7(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
lea    0xac5(%rip),%rbx
mov    %rbx,%rdi
lea    0xb0(%rsp),%r14
mov    %r14,%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
xor    %eax,%eax
call   10a0 <getchar@plt>
lea    0xbbd(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
mov    %rbx,%rdi
lea    0x40(%rsp),%rbx
mov    %rbx,%rsi
xor    %eax,%eax
call   10c0 <scanf@plt>
mov    %r14,%rdi
call   1070 <strlen@plt>
mov    %rax,0x18(%rsp)
mov    %rbx,%rdi
call   1070 <strlen@plt>
mov    %eax,%ebp
mov    %r14,%rdi
mov    %rbx,%rsi
lea    0x20(%rsp),%rdx
call   1060 <EditDistance@plt>
mov    %eax,0x28(%rsp)
mov    %rbp,0x10(%rsp)
test   %ebp,%ebp
js     11e0 <main+0x30>
mov    0x18(%rsp),%rax
add    $0x1,%eax
movslq %eax,%r14
mov    0x10(%rsp),%rax
add    $0x1,%eax
mov    %rax,0x10(%rsp)
mov    %r14d,%eax
mov    %rax,0x30(%rsp)
shl    $0x2,%r14
xor    %r13d,%r13d
xor    %r12d,%r12d
jmp    165c <main+0x4ac>
cs nopw 0x0(%rax,%rax,1)
nop
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x1,%r12
add    %r14,%r13
cmp    0x10(%rsp),%r12
je     11e0 <main+0x30>
cmpl   $0x0,0x18(%rsp)
js     1640 <main+0x490>
mov    0x30(%rsp),%rbp
mov    %r13,%rbx
nopl   0x0(%rax,%rax,1)
mov    0x20(%rsp),%rax
mov    (%rax,%rbx,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1080 <printf@plt>
add    $0x4,%rbx
add    $0xffffffffffffffff,%rbp
jne    1670 <main+0x4c0>
jmp    1640 <main+0x490>
xchg   %ax,%ax
lea    0x9e9(%rip),%rdi
mov    0x28(%rsp),%esi
jmp    184b <main+0x69b>
mov    %eax,%ecx
and    $0xfffffff8,%ecx
lea    -0x8(%rcx),%rdi
mov    %rdi,%rdx
shr    $0x3,%rdx
add    $0x1,%rdx
mov    %edx,%ebx
and    $0x3,%ebx
cmp    $0x18,%rdi
jae    16cb <main+0x51b>
pxor   %xmm0,%xmm0
xor    %edi,%edi
pxor   %xmm1,%xmm1
jmp    1741 <main+0x591>
and    $0xfffffffffffffffc,%rdx
pxor   %xmm0,%xmm0
xor    %edi,%edi
pxor   %xmm1,%xmm1
nopl   0x0(%rax)
movdqu (%r12,%rdi,4),%xmm2
paddd  %xmm0,%xmm2
movdqu 0x10(%r12,%rdi,4),%xmm0
paddd  %xmm1,%xmm0
movdqu 0x20(%r12,%rdi,4),%xmm1
movdqu 0x30(%r12,%rdi,4),%xmm3
movdqu 0x40(%r12,%rdi,4),%xmm4
paddd  %xmm1,%xmm4
paddd  %xmm2,%xmm4
movdqu 0x50(%r12,%rdi,4),%xmm2
paddd  %xmm3,%xmm2
paddd  %xmm0,%xmm2
movdqu 0x60(%r12,%rdi,4),%xmm0
paddd  %xmm4,%xmm0
movdqu 0x70(%r12,%rdi,4),%xmm1
paddd  %xmm2,%xmm1
add    $0x20,%rdi
add    $0xfffffffffffffffc,%rdx
jne    16e0 <main+0x530>
test   %rbx,%rbx
je     177c <main+0x5cc>
lea    (%r12,%rdi,4),%rdx
add    $0x10,%rdx
shl    $0x5,%rbx
xor    %edi,%edi
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movdqu -0x10(%rdx,%rdi,1),%xmm2
paddd  %xmm2,%xmm0
movdqu (%rdx,%rdi,1),%xmm2
paddd  %xmm2,%xmm1
add    $0x20,%rdi
cmp    %rdi,%rbx
jne    1760 <main+0x5b0>
paddd  %xmm1,%xmm0
pshufd $0xee,%xmm0,%xmm1
paddd  %xmm0,%xmm1
pshufd $0x55,%xmm1,%xmm0
paddd  %xmm1,%xmm0
movd   %xmm0,%r13d
cmp    %rax,%rcx
je     17ad <main+0x5fd>
nopl   0x0(%rax)
add    (%r12,%rcx,4),%r13d
add    $0x1,%rcx
cmp    %rcx,%rax
jne    17a0 <main+0x5f0>
mov    %r12,%rdi
lea    0x20(%rsp),%rdx
call   10d0 <Partition@plt>
mov    %eax,0x30(%rsp)
cmpl   $0x0,0xc(%rsp)
js     1840 <main+0x690>
mov    %r13d,%ecx
shr    $0x1f,%ecx
add    %r13d,%ecx
sar    %ecx
movslq %ecx,%rax
add    $0x1,%ecx
mov    %rcx,0x18(%rsp)
lea    0x4(,%rax,4),%rax
mov    %rax,0x10(%rsp)
xor    %r14d,%r14d
xor    %r12d,%r12d
jmp    1811 <main+0x661>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0x1(%r12),%rax
movslq 0xc(%rsp),%rcx
add    0x10(%rsp),%r14
cmp    %rcx,%r12
mov    %rax,%r12
jge    1840 <main+0x690>
cmp    $0xffffffff,%r13d
jl     17f0 <main+0x640>
mov    0x18(%rsp),%rbp
mov    %r14,%rbx
nop
mov    0x20(%rsp),%rax
mov    (%rax,%rbx,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1080 <printf@plt>
add    $0x4,%rbx
add    $0xffffffffffffffff,%rbp
jne    1820 <main+0x670>
jmp    17f0 <main+0x640>
xchg   %ax,%ax
lea    0x88f(%rip),%rdi
mov    0x30(%rsp),%esi
xor    %eax,%eax
call   1080 <printf@plt>
lea    0x7e0(%rip),%r14
jmp    1206 <main+0x56>
xor    %eax,%eax
add    $0x118,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [12 x i8] c"0 -> Exit.\0A\00"
@.str.1 = [11 x i8] c"1 -> LCS.\0A\00"
@.str.2 = [17 x i8] c"2 -> Partition.\0A\00"
@.str.3 = [16 x i8] c"3 -> KnapSack.\0A\00"
@.str.4 = [20 x i8] c"4 -> EditDistance.\0A\00"
@.str.5 = [41 x i8] c"What do you want to do? (0, 1, 2, 3, 4) \00"
@.str.6 = [3 x i8] c"%d\00"
@.str.7 = [30 x i8] c"Insert first string for LCS: \00"
@.str.8 = [3 x i8] c"%s\00"
@.str.9 = [31 x i8] c"Insert second string for LCS: \00"
@.str.10 = [4 x i8] c"%d \00"
@.str.11 = [2 x i8] c"\0A\00"
@.str.12 = [47 x i8] c"The longest common sequence is %d chars long.\0A\00"
@.str.13 = [39 x i8] c"How many values do you want to store? \00"
@.str.14 = [16 x i8] c"Insert values:\0A\00"
@.str.15 = [4 x i8] c"%d\0A\00"
@.str.16 = [39 x i8] c"How many elements do you want to add? \00"
@.str.17 = [41 x i8] c"Insert %d couples for weight and value.\0A\00"
@.str.18 = [12 x i8] c"Couple %d: \00"
@.str.19 = [24 x i8] c"Which is the capacity? \00"
@.str.20 = [39 x i8] c"Insert first string for EditDistance: \00"
@.str.21 = [40 x i8] c"Insert second string for EditDistance: \00"
@.str.22 = [51 x i8] c"Edit distance between %s and %s is %d chars long.\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [100 x i8]
%3 = alloca [100 x i8]
%4 = alloca i32*
%5 = alloca i32*
%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* %1
store i32* null, i32** %4
store i32* null, i32** %5
store i32* null, i32** %6
store i32* null, i32** %7
br label %17
17: ; preds = %0, %282
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
%19 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.1, i64 0, i64 0))
%20 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.2, i64 0, i64 0))
%21 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.3, i64 0, i64 0))
%22 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0))
%23 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.5, i64 0, i64 0))
%24 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %13)
%25 = load i32, i32* %13
switch i32 %25, label %281 [
i32 1, label %26
i32 2, label %74
i32 3, label %153
i32 4, label %231
]
26: ; preds = %17
%27 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.7, i64 0, i64 0))
%28 = getelementptr inbounds [100 x i8], [100 x i8]* %2, i64 0, i64 0
%29 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0), i8* %28)
%30 = call i32 (...) @getchar()
%31 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.9, i64 0, i64 0))
%32 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 0
%33 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0), i8* %32)
%34 = getelementptr inbounds [100 x i8], [100 x i8]* %2, i64 0, i64 0
%35 = call i32 @strlen(i8* %34)
%36 = add nsw i32 %35, 1
store i32 %36, i32* %11
%37 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 0
%38 = call i32 @strlen(i8* %37)
%39 = add nsw i32 %38, 1
store i32 %39, i32* %12
%40 = getelementptr inbounds [100 x i8], [100 x i8]* %2, i64 0, i64 0
%41 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 0
%42 = call i32 @LCS(i8* %40, i8* %41, i32** %4)
store i32 %42, i32* %10
store i32 0, i32* %8
br label %43
43: ; preds = %68, %26
%44 = load i32, i32* %8
%45 = load i32, i32* %11
%46 = icmp slt i32 %44, %45
br i1 %46, label %47, label %71
47: ; preds = %43
store i32 0, i32* %9
br label %48
48: ; preds = %63, %47
%49 = load i32, i32* %9
%50 = load i32, i32* %12
%51 = icmp slt i32 %49, %50
br i1 %51, label %52, label %66
52: ; preds = %48
%53 = load i32*, i32** %4
%54 = load i32, i32* %8
%55 = load i32, i32* %12
%56 = mul nsw i32 %54, %55
%57 = load i32, i32* %9
%58 = add nsw i32 %56, %57
%59 = sext i32 %58 to i64
%60 = getelementptr inbounds i32, i32* %53, i64 %59
%61 = load i32, i32* %60
%62 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 %61)
br label %63
63: ; preds = %52
%64 = load i32, i32* %9
%65 = add nsw i32 %64, 1
store i32 %65, i32* %9
br label %48
66: ; preds = %48
%67 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.11, i64 0, i64 0))
br label %68
68: ; preds = %66
%69 = load i32, i32* %8
%70 = add nsw i32 %69, 1
store i32 %70, i32* %8
br label %43
71: ; preds = %43
%72 = load i32, i32* %10
%73 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str.12, i64 0, i64 0), i32 %72)
br label %282
74: ; preds = %17
%75 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.13, i64 0, i64 0))
%76 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %14)
%77 = load i32, i32* %14
%78 = sext i32 %77 to i64
%79 = mul i64 4, %78
%80 = trunc i64 %79 to i32
%81 = call i64 @malloc(i32 %80)
%82 = inttoptr i64 %81 to i32*
store i32* %82, i32** %5
%83 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.14, i64 0, i64 0))
store i32 0, i32* %8
br label %84
84: ; preds = %94, %74
%85 = load i32, i32* %8
%86 = load i32, i32* %14
%87 = icmp slt i32 %85, %86
br i1 %87, label %88, label %97
88: ; preds = %84
%89 = load i32*, i32** %5
%90 = load i32, i32* %8
%91 = sext i32 %90 to i64
%92 = getelementptr inbounds i32, i32* %89, i64 %91
%93 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %92)
br label %94
94: ; preds = %88
%95 = load i32, i32* %8
%96 = add nsw i32 %95, 1
store i32 %96, i32* %8
br label %84
97: ; preds = %84
store i32 0, i32* %8
store i32 0, i32* %15
br label %98
98: ; preds = %110, %97
%99 = load i32, i32* %8
%100 = load i32, i32* %14
%101 = icmp slt i32 %99, %100
br i1 %101, label %102, label %113
102: ; preds = %98
%103 = load i32*, i32** %5
%104 = load i32, i32* %8
%105 = sext i32 %104 to i64
%106 = getelementptr inbounds i32, i32* %103, i64 %105
%107 = load i32, i32* %106
%108 = load i32, i32* %15
%109 = add nsw i32 %108, %107
store i32 %109, i32* %15
br label %110
110: ; preds = %102
%111 = load i32, i32* %8
%112 = add nsw i32 %111, 1
store i32 %112, i32* %8
br label %98
113: ; preds = %98
%114 = load i32, i32* %15
%115 = sdiv i32 %114, 2
store i32 %115, i32* %15
%116 = load i32*, i32** %5
%117 = load i32, i32* %14
%118 = call i32 @Partition(i32* %116, i32 %117, i32** %4)
store i32 %118, i32* %10
store i32 0, i32* %8
br label %119
119: ; preds = %147, %113
%120 = load i32, i32* %8
%121 = load i32, i32* %14
%122 = add nsw i32 %121, 1
%123 = icmp slt i32 %120, %122
br i1 %123, label %124, label %150
124: ; preds = %119
store i32 0, i32* %9
br label %125
125: ; preds = %142, %124
%126 = load i32, i32* %9
%127 = load i32, i32* %15
%128 = add nsw i32 %127, 1
%129 = icmp slt i32 %126, %128
br i1 %129, label %130, label %145
130: ; preds = %125
%131 = load i32*, i32** %4
%132 = load i32, i32* %8
%133 = load i32, i32* %15
%134 = add nsw i32 %133, 1
%135 = mul nsw i32 %132, %134
%136 = load i32, i32* %9
%137 = add nsw i32 %135, %136
%138 = sext i32 %137 to i64
%139 = getelementptr inbounds i32, i32* %131, i64 %138
%140 = load i32, i32* %139
%141 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 %140)
br label %142
142: ; preds = %130
%143 = load i32, i32* %9
%144 = add nsw i32 %143, 1
store i32 %144, i32* %9
br label %125
145: ; preds = %125
%146 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.11, i64 0, i64 0))
br label %147
147: ; preds = %145
%148 = load i32, i32* %8
%149 = add nsw i32 %148, 1
store i32 %149, i32* %8
br label %119
150: ; preds = %119
%151 = load i32, i32* %10
%152 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.15, i64 0, i64 0), i32 %151)
br label %282
153: ; preds = %17
%154 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.16, i64 0, i64 0))
%155 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %14)
%156 = load i32, i32* %14
%157 = sext i32 %156 to i64
%158 = mul i64 4, %157
%159 = trunc i64 %158 to i32
%160 = call i64 @malloc(i32 %159)
%161 = inttoptr i64 %160 to i32*
store i32* %161, i32** %6
%162 = load i32, i32* %14
%163 = sext i32 %162 to i64
%164 = mul i64 4, %163
%165 = trunc i64 %164 to i32
%166 = call i64 @malloc(i32 %165)
%167 = inttoptr i64 %166 to i32*
store i32* %167, i32** %7
%168 = load i32, i32* %14
%169 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.17, i64 0, i64 0), i32 %168)
store i32 0, i32* %8
br label %170
170: ; preds = %188, %153
%171 = load i32, i32* %8
%172 = load i32, i32* %14
%173 = icmp slt i32 %171, %172
br i1 %173, label %174, label %191
174: ; preds = %170
%175 = load i32, i32* %8
%176 = add nsw i32 %175, 1
%177 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.18, i64 0, i64 0), i32 %176)
%178 = load i32*, i32** %6
%179 = load i32, i32* %8
%180 = sext i32 %179 to i64
%181 = getelementptr inbounds i32, i32* %178, i64 %180
%182 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %181)
%183 = load i32*, i32** %7
%184 = load i32, i32* %8
%185 = sext i32 %184 to i64
%186 = getelementptr inbounds i32, i32* %183, i64 %185
%187 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %186)
br label %188
188: ; preds = %174
%189 = load i32, i32* %8
%190 = add nsw i32 %189, 1
store i32 %190, i32* %8
br label %170
191: ; preds = %170
%192 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.19, i64 0, i64 0))
%193 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %16)
%194 = load i32*, i32** %7
%195 = load i32*, i32** %6
%196 = load i32, i32* %14
%197 = load i32, i32* %16
%198 = call i32 @Knapsack(i32* %194, i32* %195, i32 %196, i32 %197, i32** %4)
store i32 %198, i32* %10
store i32 0, i32* %8
br label %199
199: ; preds = %227, %191
%200 = load i32, i32* %8
%201 = load i32, i32* %14
%202 = add nsw i32 %201, 1
%203 = icmp slt i32 %200, %202
br i1 %203, label %204, label %230
204: ; preds = %199
store i32 0, i32* %9
br label %205
205: ; preds = %222, %204
%206 = load i32, i32* %9
%207 = load i32, i32* %16
%208 = add nsw i32 %207, 1
%209 = icmp slt i32 %206, %208
br i1 %209, label %210, label %225
210: ; preds = %205
%211 = load i32*, i32** %4
%212 = load i32, i32* %8
%213 = load i32, i32* %16
%214 = add nsw i32 %213, 1
%215 = mul nsw i32 %212, %214
%216 = load i32, i32* %9
%217 = add nsw i32 %215, %216
%218 = sext i32 %217 to i64
%219 = getelementptr inbounds i32, i32* %211, i64 %218
%220 = load i32, i32* %219
%221 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 %220)
br label %222
222: ; preds = %210
%223 = load i32, i32* %9
%224 = add nsw i32 %223, 1
store i32 %224, i32* %9
br label %205
225: ; preds = %205
%226 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.11, i64 0, i64 0))
br label %227
227: ; preds = %225
%228 = load i32, i32* %8
%229 = add nsw i32 %228, 1
store i32 %229, i32* %8
br label %199
230: ; preds = %199
br label %282
231: ; preds = %17
%232 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.20, i64 0, i64 0))
%233 = getelementptr inbounds [100 x i8], [100 x i8]* %2, i64 0, i64 0
%234 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0), i8* %233)
%235 = call i32 (...) @getchar()
%236 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.21, i64 0, i64 0))
%237 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 0
%238 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0), i8* %237)
%239 = getelementptr inbounds [100 x i8], [100 x i8]* %2, i64 0, i64 0
%240 = call i32 @strlen(i8* %239)
%241 = add nsw i32 %240, 1
store i32 %241, i32* %11
%242 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 0
%243 = call i32 @strlen(i8* %242)
%244 = add nsw i32 %243, 1
store i32 %244, i32* %12
%245 = getelementptr inbounds [100 x i8], [100 x i8]* %2, i64 0, i64 0
%246 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 0
%247 = call i32 @EditDistance(i8* %245, i8* %246, i32** %4)
store i32 %247, i32* %10
store i32 0, i32* %8
br label %248
248: ; preds = %273, %231
%249 = load i32, i32* %8
%250 = load i32, i32* %12
%251 = icmp slt i32 %249, %250
br i1 %251, label %252, label %276
252: ; preds = %248
store i32 0, i32* %9
br label %253
253: ; preds = %268, %252
%254 = load i32, i32* %9
%255 = load i32, i32* %11
%256 = icmp slt i32 %254, %255
br i1 %256, label %257, label %271
257: ; preds = %253
%258 = load i32*, i32** %4
%259 = load i32, i32* %8
%260 = load i32, i32* %11
%261 = mul nsw i32 %259, %260
%262 = load i32, i32* %9
%263 = add nsw i32 %261, %262
%264 = sext i32 %263 to i64
%265 = getelementptr inbounds i32, i32* %258, i64 %264
%266 = load i32, i32* %265
%267 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 %266)
br label %268
268: ; preds = %257
%269 = load i32, i32* %9
%270 = add nsw i32 %269, 1
store i32 %270, i32* %9
br label %253
271: ; preds = %253
%272 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.11, i64 0, i64 0))
br label %273
273: ; preds = %271
%274 = load i32, i32* %8
%275 = add nsw i32 %274, 1
store i32 %275, i32* %8
br label %248
276: ; preds = %248
%277 = getelementptr inbounds [100 x i8], [100 x i8]* %2, i64 0, i64 0
%278 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 0
%279 = load i32, i32* %10
%280 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([51 x i8], [51 x i8]* @.str.22, i64 0, i64 0), i8* %277, i8* %278, i32 %279)
br label %282
281: ; preds = %17
ret i32 0
282: ; preds = %276, %230, %150, %71
br label %17
}

LLVM IR (-O2):
@.str.5 = [41 x i8] c"What do you want to do? (0, 1, 2, 3, 4) \00"
@.str.6 = [3 x i8] c"%d\00"
@.str.7 = [30 x i8] c"Insert first string for LCS: \00"
@.str.8 = [3 x i8] c"%s\00"
@.str.9 = [31 x i8] c"Insert second string for LCS: \00"
@.str.10 = [4 x i8] c"%d \00"
@.str.12 = [47 x i8] c"The longest common sequence is %d chars long.\0A\00"
@.str.13 = [39 x i8] c"How many values do you want to store? \00"
@.str.15 = [4 x i8] c"%d\0A\00"
@.str.16 = [39 x i8] c"How many elements do you want to add? \00"
@.str.17 = [41 x i8] c"Insert %d couples for weight and value.\0A\00"
@.str.18 = [12 x i8] c"Couple %d: \00"
@.str.19 = [24 x i8] c"Which is the capacity? \00"
@.str.20 = [39 x i8] c"Insert first string for EditDistance: \00"
@.str.21 = [40 x i8] c"Insert second string for EditDistance: \00"
@.str.22 = [51 x i8] c"Edit distance between %s and %s is %d chars long.\0A\00"
@str = [11 x i8] c"0 -> Exit.\00"
@str.23 = [10 x i8] c"1 -> LCS.\00"
@str.24 = [16 x i8] c"2 -> Partition.\00"
@str.25 = [15 x i8] c"3 -> KnapSack.\00"
@str.26 = [19 x i8] c"4 -> EditDistance.\00"
@str.27 = [15 x i8] c"Insert values:\00"
define i32 @main() {
%1 = alloca [100 x i8]
%2 = alloca [100 x i8]
%3 = alloca i32*
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = getelementptr inbounds [100 x i8], [100 x i8]* %1, i64 0, i64 0
%8 = getelementptr inbounds [100 x i8], [100 x i8]* %2, i64 0, i64 0
%9 = bitcast i32** %3 to i8*
store i32* null, i32** %3
%10 = bitcast i32* %4 to i8*
%11 = bitcast i32* %5 to i8*
%12 = bitcast i32* %6 to i8*
br label %13
13: ; preds = %241, %0
%14 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @str, i64 0, i64 0))
%15 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str.23, i64 0, i64 0))
%16 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @str.24, i64 0, i64 0))
%17 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @str.25, i64 0, i64 0))
%18 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @str.26, i64 0, i64 0))
%19 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @.str.5, i64 0, i64 0))
%20 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %4)
%21 = load i32, i32* %4
switch i32 %21, label %301 [
i32 1, label %22
i32 2, label %58
i32 3, label %206
i32 4, label %265
]
22: ; preds = %13
%23 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([30 x i8], [30 x i8]* @.str.7, i64 0, i64 0))
%24 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0), i8* %7)
%25 = call i32 (...) @getchar()
%26 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @.str.9, i64 0, i64 0))
%27 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0), i8* %8)
%28 = call i32 @strlen(i8* %7)
%29 = call i32 @strlen(i8* %8)
%30 = add i32 %29, 1
%31 = call i32 @LCS(i8* %7, i8* %8, i32** %3)
%32 = icmp slt i32 %28, 0
br i1 %32, label %56, label %33
33: ; preds = %22
%34 = icmp slt i32 %29, 0
%35 = sext i32 %30 to i64
%36 = add nuw i32 %28, 1
%37 = zext i32 %36 to i64
%38 = zext i32 %30 to i64
br label %39
39: ; preds = %33, %52
%40 = phi i64 [ 0, %33 ], [ %54, %52 ]
br i1 %34, label %52, label %41
41: ; preds = %39
%42 = mul nsw i64 %40, %35
br label %43
43: ; preds = %41, %43
%44 = phi i64 [ 0, %41 ], [ %50, %43 ]
%45 = load i32*, i32** %3
%46 = add nsw i64 %44, %42
%47 = getelementptr inbounds i32, i32* %45, i64 %46
%48 = load i32, i32* %47
%49 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 %48)
%50 = add nuw nsw i64 %44, 1
%51 = icmp eq i64 %50, %38
br i1 %51, label %52, label %43
52: ; preds = %43, %39
%53 = call i32 @putchar(i32 10)
%54 = add nuw nsw i64 %40, 1
%55 = icmp eq i64 %54, %37
br i1 %55, label %56, label %39
56: ; preds = %52, %22
%57 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([47 x i8], [47 x i8]* @.str.12, i64 0, i64 0), i32 %31)
br label %241
58: ; preds = %13
%59 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @.str.13, i64 0, i64 0))
%60 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %5)
%61 = load i32, i32* %5
%62 = shl i32 %61, 2
%63 = call i64 @malloc(i32 %62)
%64 = inttoptr i64 %63 to i32*
%65 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @str.27, i64 0, i64 0))
%66 = load i32, i32* %5
%67 = icmp sgt i32 %66, 0
br i1 %67, label %157, label %173
68: ; preds = %157
%69 = icmp sgt i32 %162, 0
br i1 %69, label %70, label %173
70: ; preds = %68
%71 = zext i32 %162 to i64
%72 = icmp ult i32 %162, 8
br i1 %72, label %154, label %73
73: ; preds = %70
%74 = and i64 %71, 4294967288
%75 = add nsw i64 %74, -8
%76 = lshr exact i64 %75, 3
%77 = add nuw nsw i64 %76, 1
%78 = and i64 %77, 3
%79 = icmp ult i64 %75, 24
br i1 %79, label %125, label %80
80: ; preds = %73
%81 = and i64 %77, 4611686018427387900
br label %82
82: ; preds = %82, %80
%83 = phi i64 [ 0, %80 ], [ %122, %82 ]
%84 = phi <4 x i32> [ zeroinitializer, %80 ], [ %120, %82 ]
%85 = phi <4 x i32> [ zeroinitializer, %80 ], [ %121, %82 ]
%86 = phi i64 [ 0, %80 ], [ %123, %82 ]
%87 = getelementptr inbounds i32, i32* %64, i64 %83
%88 = bitcast i32* %87 to <4 x i32>*
%89 = load <4 x i32>, <4 x i32>* %88
%90 = getelementptr inbounds i32, i32* %87, i64 4
%91 = bitcast i32* %90 to <4 x i32>*
%92 = load <4 x i32>, <4 x i32>* %91
%93 = add <4 x i32> %89, %84
%94 = add <4 x i32> %92, %85
%95 = or i64 %83, 8
%96 = getelementptr inbounds i32, i32* %64, i64 %95
%97 = bitcast i32* %96 to <4 x i32>*
%98 = load <4 x i32>, <4 x i32>* %97
%99 = getelementptr inbounds i32, i32* %96, i64 4
%100 = bitcast i32* %99 to <4 x i32>*
%101 = load <4 x i32>, <4 x i32>* %100
%102 = add <4 x i32> %98, %93
%103 = add <4 x i32> %101, %94
%104 = or i64 %83, 16
%105 = getelementptr inbounds i32, i32* %64, i64 %104
%106 = bitcast i32* %105 to <4 x i32>*
%107 = load <4 x i32>, <4 x i32>* %106
%108 = getelementptr inbounds i32, i32* %105, i64 4
%109 = bitcast i32* %108 to <4 x i32>*
%110 = load <4 x i32>, <4 x i32>* %109
%111 = add <4 x i32> %107, %102
%112 = add <4 x i32> %110, %103
%113 = or i64 %83, 24
%114 = getelementptr inbounds i32, i32* %64, i64 %113
%115 = bitcast i32* %114 to <4 x i32>*
%116 = load <4 x i32>, <4 x i32>* %115
%117 = getelementptr inbounds i32, i32* %114, i64 4
%118 = bitcast i32* %117 to <4 x i32>*
%119 = load <4 x i32>, <4 x i32>* %118
%120 = add <4 x i32> %116, %111
%121 = add <4 x i32> %119, %112
%122 = add nuw i64 %83, 32
%123 = add i64 %86, 4
%124 = icmp eq i64 %123, %81
br i1 %124, label %125, label %82
125: ; preds = %82, %73
%126 = phi <4 x i32> [ undef, %73 ], [ %120, %82 ]
%127 = phi <4 x i32> [ undef, %73 ], [ %121, %82 ]
%128 = phi i64 [ 0, %73 ], [ %122, %82 ]
%129 = phi <4 x i32> [ zeroinitializer, %73 ], [ %120, %82 ]
%130 = phi <4 x i32> [ zeroinitializer, %73 ], [ %121, %82 ]
%131 = icmp eq i64 %78, 0
br i1 %131, label %148, label %132
132: ; preds = %125, %132
%133 = phi i64 [ %145, %132 ], [ %128, %125 ]
%134 = phi <4 x i32> [ %143, %132 ], [ %129, %125 ]
%135 = phi <4 x i32> [ %144, %132 ], [ %130, %125 ]
%136 = phi i64 [ %146, %132 ], [ 0, %125 ]
%137 = getelementptr inbounds i32, i32* %64, i64 %133
%138 = bitcast i32* %137 to <4 x i32>*
%139 = load <4 x i32>, <4 x i32>* %138
%140 = getelementptr inbounds i32, i32* %137, i64 4
%141 = bitcast i32* %140 to <4 x i32>*
%142 = load <4 x i32>, <4 x i32>* %141
%143 = add <4 x i32> %139, %134
%144 = add <4 x i32> %142, %135
%145 = add nuw i64 %133, 8
%146 = add i64 %136, 1
%147 = icmp eq i64 %146, %78
br i1 %147, label %148, label %132
148: ; preds = %132, %125
%149 = phi <4 x i32> [ %126, %125 ], [ %143, %132 ]
%150 = phi <4 x i32> [ %127, %125 ], [ %144, %132 ]
%151 = add <4 x i32> %150, %149
%152 = call i32 @llvm.vector.reduce.add.v4i32(<4 x i32> %151)
%153 = icmp eq i64 %74, %71
br i1 %153, label %173, label %154
154: ; preds = %70, %148
%155 = phi i64 [ 0, %70 ], [ %74, %148 ]
%156 = phi i32 [ 0, %70 ], [ %152, %148 ]
br label %165
157: ; preds = %58, %157
%158 = phi i64 [ %161, %157 ], [ 0, %58 ]
%159 = getelementptr inbounds i32, i32* %64, i64 %158
%160 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %159)
%161 = add nuw nsw i64 %158, 1
%162 = load i32, i32* %5
%163 = sext i32 %162 to i64
%164 = icmp slt i64 %161, %163
br i1 %164, label %157, label %68
165: ; preds = %154, %165
%166 = phi i64 [ %171, %165 ], [ %155, %154 ]
%167 = phi i32 [ %170, %165 ], [ %156, %154 ]
%168 = getelementptr inbounds i32, i32* %64, i64 %166
%169 = load i32, i32* %168
%170 = add nsw i32 %169, %167
%171 = add nuw nsw i64 %166, 1
%172 = icmp eq i64 %171, %71
br i1 %172, label %173, label %165
173: ; preds = %165, %148, %58, %68
%174 = phi i32 [ %162, %68 ], [ %66, %58 ], [ %162, %148 ], [ %162, %165 ]
%175 = phi i32 [ 0, %68 ], [ 0, %58 ], [ %152, %148 ], [ %170, %165 ]
%176 = call i32 @Partition(i32* %64, i32 %174, i32** %3)
%177 = load i32, i32* %5
%178 = icmp slt i32 %177, 0
br i1 %178, label %204, label %179
179: ; preds = %173
%180 = sdiv i32 %175, 2
%181 = icmp slt i32 %175, -1
%182 = add nsw i32 %180, 1
%183 = sext i32 %182 to i64
%184 = zext i32 %182 to i64
br label %185
185: ; preds = %179, %198
%186 = phi i64 [ 0, %179 ], [ %200, %198 ]
br i1 %181, label %198, label %187
187: ; preds = %185
%188 = mul nsw i64 %186, %183
br label %189
189: ; preds = %187, %189
%190 = phi i64 [ 0, %187 ], [ %196, %189 ]
%191 = load i32*, i32** %3
%192 = add nsw i64 %190, %188
%193 = getelementptr inbounds i32, i32* %191, i64 %192
%194 = load i32, i32* %193
%195 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 %194)
%196 = add nuw nsw i64 %190, 1
%197 = icmp eq i64 %196, %184
br i1 %197, label %198, label %189
198: ; preds = %189, %185
%199 = call i32 @putchar(i32 10)
%200 = add nuw nsw i64 %186, 1
%201 = load i32, i32* %5
%202 = sext i32 %201 to i64
%203 = icmp slt i64 %186, %202
br i1 %203, label %185, label %204
204: ; preds = %198, %173
%205 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.15, i64 0, i64 0), i32 %176)
br label %241
206: ; preds = %13
%207 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @.str.16, i64 0, i64 0))
%208 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %5)
%209 = load i32, i32* %5
%210 = shl i32 %209, 2
%211 = call i64 @malloc(i32 %210)
%212 = inttoptr i64 %211 to i32*
%213 = load i32, i32* %5
%214 = shl i32 %213, 2
%215 = call i64 @malloc(i32 %214)
%216 = inttoptr i64 %215 to i32*
%217 = load i32, i32* %5
%218 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @.str.17, i64 0, i64 0), i32 %217)
%219 = load i32, i32* %5
%220 = icmp sgt i32 %219, 0
br i1 %220, label %221, label %233
221: ; preds = %206, %221
%222 = phi i64 [ %223, %221 ], [ 0, %206 ]
%223 = add nuw nsw i64 %222, 1
%224 = trunc i64 %223 to i32
%225 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.18, i64 0, i64 0), i32 %224)
%226 = getelementptr inbounds i32, i32* %212, i64 %222
%227 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %226)
%228 = getelementptr inbounds i32, i32* %216, i64 %222
%229 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %228)
%230 = load i32, i32* %5
%231 = sext i32 %230 to i64
%232 = icmp slt i64 %223, %231
br i1 %232, label %221, label %233
233: ; preds = %221, %206
%234 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([24 x i8], [24 x i8]* @.str.19, i64 0, i64 0))
%235 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i32* %6)
%236 = load i32, i32* %5
%237 = load i32, i32* %6
%238 = call i32 @Knapsack(i32* %216, i32* %212, i32 %236, i32 %237, i32** %3)
%239 = load i32, i32* %5
%240 = icmp slt i32 %239, 0
br i1 %240, label %241, label %242
241: ; preds = %260, %233, %299, %204, %56
br label %13
242: ; preds = %233, %260
%243 = phi i32 [ %262, %260 ], [ 0, %233 ]
%244 = load i32, i32* %6
%245 = icmp slt i32 %244, 0
br i1 %245, label %260, label %246
246: ; preds = %242, %246
%247 = phi i32 [ %258, %246 ], [ %244, %242 ]
%248 = phi i32 [ %257, %246 ], [ 0, %242 ]
%249 = add nsw i32 %247, 1
%250 = load i32*, i32** %3
%251 = mul nsw i32 %249, %243
%252 = add nsw i32 %251, %248
%253 = sext i32 %252 to i64
%254 = getelementptr inbounds i32, i32* %250, i64 %253
%255 = load i32, i32* %254
%256 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 %255)
%257 = add nuw nsw i32 %248, 1
%258 = load i32, i32* %6
%259 = icmp slt i32 %248, %258
br i1 %259, label %246, label %260
260: ; preds = %246, %242
%261 = call i32 @putchar(i32 10)
%262 = add nuw nsw i32 %243, 1
%263 = load i32, i32* %5
%264 = icmp slt i32 %243, %263
br i1 %264, label %242, label %241
265: ; preds = %13
%266 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @.str.20, i64 0, i64 0))
%267 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0), i8* %7)
%268 = call i32 (...) @getchar()
%269 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([40 x i8], [40 x i8]* @.str.21, i64 0, i64 0))
%270 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0), i8* %8)
%271 = call i32 @strlen(i8* %7)
%272 = add i32 %271, 1
%273 = call i32 @strlen(i8* %8)
%274 = call i32 @EditDistance(i8* %7, i8* %8, i32** %3)
%275 = icmp slt i32 %273, 0
br i1 %275, label %299, label %276
276: ; preds = %265
%277 = icmp slt i32 %271, 0
%278 = sext i32 %272 to i64
%279 = add nuw i32 %273, 1
%280 = zext i32 %279 to i64
%281 = zext i32 %272 to i64
br label %282
282: ; preds = %276, %295
%283 = phi i64 [ 0, %276 ], [ %297, %295 ]
br i1 %277, label %295, label %284
284: ; preds = %282
%285 = mul nsw i64 %283, %278
br label %286
286: ; preds = %284, %286
%287 = phi i64 [ 0, %284 ], [ %293, %286 ]
%288 = load i32*, i32** %3
%289 = add nsw i64 %287, %285
%290 = getelementptr inbounds i32, i32* %288, i64 %289
%291 = load i32, i32* %290
%292 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.10, i64 0, i64 0), i32 %291)
%293 = add nuw nsw i64 %287, 1
%294 = icmp eq i64 %293, %281
br i1 %294, label %295, label %286
295: ; preds = %286, %282
%296 = call i32 @putchar(i32 10)
%297 = add nuw nsw i64 %283, 1
%298 = icmp eq i64 %297, %280
br i1 %298, label %299, label %282
299: ; preds = %295, %265
%300 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([51 x i8], [51 x i8]* @.str.22, i64 0, i64 0), i8* %7, i8* %8, i32 %274)
br label %241
301: ; preds = %13
ret i32 0
}