#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*/ FILE;

/* Variables and functions */
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
int /*<<< orphan*/ fgets(char *, int, int /*<<< orphan*/ *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, char *, int, int,
                           char *);
int /*<<< orphan*/ free(char *);
scalar_t__ malloc(int);
int /*<<< orphan*/ sscanf(char *, char *, char *, ...);
int /*<<< orphan*/ strncmp(char *, char *, int);
main() {
  int i = 0, j = 0, k = 0, n = 0, p = 0, l = 0, flag = 0, end_atom = 0,
      line_length = 1000, res_atom_number = 0, lig_atom_number = 0,
      all_active[250000], active[250000], lig_atoms[250000], res_atoms[250000];
  float radius = 0, dist = 0, res_coordx, res_coordy, res_coordz, lig_coordx,
        lig_coordy, lig_coordz, res_numb1, res_numb2, res_numb3, res_numb4,
        lig_numb1, lig_numb2, lig_numb3, lig_numb4;
  char res_buf[line_length], lig_buf[line_length], res_word[15], lig_word[15],
      *res_name[250000], *lig_name[250000];
  for (j = 0; j < 250000; j++) {
    res_name[j] = (char *)malloc(15);
    lig_name[j] = (char *)malloc(15);
  }
  FILE *protein, *ligand, *numb_act, *fopen();
  ligand = fopen("input_ligand.ammp", "r");
  protein = fopen("protein.ammp", "r");
  numb_act = fopen("active.ammp", "w");
  for (i = 0; i < 250000; i++) {
    fgets(lig_buf, line_length, ligand);
    sscanf(lig_buf, "%s", lig_word);
    if (!strncmp(lig_word, "bond", 4))
      break;
    if (!strncmp(lig_word, "mompar", 6)) {
      fgets(lig_buf, line_length, ligand);
      sscanf(lig_buf, "%s", lig_word);
    }
    if (!strncmp(lig_word, "inactive", 8)) {
      fgets(lig_buf, line_length, ligand);
      sscanf(lig_buf, "%s", lig_word);
    }
    if (!strncmp(lig_word, "atom", 4)) {
      sscanf(lig_buf, "%s %f %f %f %i %s %f %f %f %f", lig_word, &lig_coordx,
             &lig_coordy, &lig_coordz, &lig_atom_number, lig_name[k],
             &lig_numb1, &lig_numb2, &lig_numb3, &lig_numb4);
      lig_atoms[l] = lig_atom_number;
      l++;
    }
  }
  for (j = 0; j < 250000; j++) {
    fgets(res_buf, line_length, protein);
    sscanf(res_buf, "%s", res_word);
    if (!strncmp(res_word, "bond", 4))
      break;
    if (!strncmp(res_word, "mompar", 6)) {
      fgets(res_buf, line_length, protein);
      sscanf(res_buf, "%s", res_word);
    }
    if (!strncmp(res_word, "atom", 4)) {
      sscanf(res_buf, "%s %f %f %f %i %s %f %f %f %f", res_word, &res_coordx,
             &res_coordy, &res_coordz, &res_atom_number, res_name[i],
             &res_numb1, &res_numb2, &res_numb3, &res_numb4);
      res_atoms[p] = res_atom_number;
      p++;
    }
  }
  for (j = 0; j < l; j++)
    fprintf(numb_act, "%s %i %i%s\n", "active", lig_atoms[j], lig_atoms[j],
            ";");
  for (i = 0; i < 250000; ++i) {
    free(res_name[i]);
    free(lig_name[i]);
  }
  fclose(protein);
  fclose(ligand);
  fclose(numb_act);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %rbx
sub    $0x7a12e8,%rsp
movl   $0x0,-0x1c(%rbp)
movl   $0x0,-0x20(%rbp)
movl   $0x0,-0x24(%rbp)
movl   $0x0,-0x28(%rbp)
movl   $0x0,-0x2c(%rbp)
movl   $0x0,-0x30(%rbp)
movl   $0x0,-0x34(%rbp)
movl   $0x0,-0x38(%rbp)
movl   $0x0,-0x3c(%rbp)
movl   $0x3e8,-0x40(%rbp)
movl   $0x0,-0x44(%rbp)
movl   $0x0,-0x48(%rbp)
movl   $0x0,-0x3d0954(%rbp)
movl   $0x0,-0x3d0958(%rbp)
mov    -0x40(%rbp),%eax
mov    %rsp,%rcx
mov    %rcx,-0x3d0998(%rbp)
mov    %rax,%rdx
add    $0xf,%rdx
and    $0xfffffffffffffff0,%rdx
mov    %rsp,%rcx
sub    %rdx,%rcx
mov    %rcx,-0x7a12f8(%rbp)
mov    %rcx,%rsp
mov    %rax,-0x3d09a0(%rbp)
mov    -0x40(%rbp),%eax
mov    %rax,%rdx
add    $0xf,%rdx
and    $0xfffffffffffffff0,%rdx
mov    %rsp,%rcx
sub    %rdx,%rcx
mov    %rcx,-0x7a12f0(%rbp)
mov    %rcx,%rsp
mov    %rax,-0x3d09a8(%rbp)
movl   $0x0,-0x24(%rbp)
cmpl   $0x3d090,-0x24(%rbp)
jge    12a0 <main+0x120>
mov    $0xf,%edi
call   1080 <malloc@plt>
mov    %rax,%rcx
movslq -0x24(%rbp),%rax
mov    %rcx,-0x5b8e50(%rbp,%rax,8)
ff
mov    $0xf,%edi
call   1080 <malloc@plt>
mov    %rax,%rcx
movslq -0x24(%rbp),%rax
mov    %rcx,-0x7a12d0(%rbp,%rax,8)
ff
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
jmp    1253 <main+0xd3>
lea    0xd59(%rip),%rdi
lea    0xd8c(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,-0x7a12e0(%rbp)
lea    0xd51(%rip),%rdi
lea    0xd72(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,-0x7a12d8(%rbp)
lea    0xd44(%rip),%rdi
lea    0xd49(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,-0x7a12e8(%rbp)
movl   $0x0,-0x20(%rbp)
cmpl   $0x3d090,-0x20(%rbp)
jge    14cd <main+0x34d>
mov    -0x7a12f0(%rbp),%rdi
mov    -0x40(%rbp),%esi
mov    -0x7a12e0(%rbp),%rdx
call   1060 <fgets@plt>
mov    -0x7a12f0(%rbp),%rdi
lea    -0x3d09c6(%rbp),%rdx
lea    0xd00(%rip),%rsi
mov    $0x0,%al
call   1090 <sscanf@plt>
lea    -0x3d09c6(%rbp),%rdi
lea    0xcee(%rip),%rsi
mov    $0x4,%edx
call   1040 <strncmp@plt>
cmp    $0x0,%eax
jne    135a <main+0x1da>
jmp    14cd <main+0x34d>
lea    -0x3d09c6(%rbp),%rdi
lea    0xccd(%rip),%rsi
mov    $0x6,%edx
call   1040 <strncmp@plt>
cmp    $0x0,%eax
jne    13ad <main+0x22d>
mov    -0x7a12f0(%rbp),%rdi
mov    -0x40(%rbp),%esi
mov    -0x7a12e0(%rbp),%rdx
call   1060 <fgets@plt>
mov    -0x7a12f0(%rbp),%rdi
lea    -0x3d09c6(%rbp),%rdx
lea    0xc87(%rip),%rsi
mov    $0x0,%al
call   1090 <sscanf@plt>
lea    -0x3d09c6(%rbp),%rdi
lea    0xc81(%rip),%rsi
mov    $0x8,%edx
call   1040 <strncmp@plt>
cmp    $0x0,%eax
jne    1400 <main+0x280>
mov    -0x7a12f0(%rbp),%rdi
mov    -0x40(%rbp),%esi
mov    -0x7a12e0(%rbp),%rdx
call   1060 <fgets@plt>
mov    -0x7a12f0(%rbp),%rdi
lea    -0x3d09c6(%rbp),%rdx
lea    0xc34(%rip),%rsi
mov    $0x0,%al
call   1090 <sscanf@plt>
lea    -0x3d09c6(%rbp),%rdi
lea    0xc37(%rip),%rsi
mov    $0x4,%edx
call   1040 <strncmp@plt>
cmp    $0x0,%eax
jne    14ba <main+0x33a>
mov    -0x7a12f0(%rbp),%rdi
lea    -0x3d09c6(%rbp),%rdx
movslq -0x28(%rbp),%rax
mov    -0x7a12d0(%rbp,%rax,8),%r14
ff
lea    0xc08(%rip),%rsi
lea    -0x3d0968(%rbp),%rcx
lea    -0x3d096c(%rbp),%r8
lea    -0x3d0970(%rbp),%r9
lea    -0x48(%rbp),%r15
lea    -0x3d0984(%rbp),%rbx
lea    -0x3d0988(%rbp),%r11
lea    -0x3d098c(%rbp),%r10
lea    -0x3d0990(%rbp),%rax
sub    $0x30,%rsp
mov    %r15,(%rsp)
mov    %r14,0x8(%rsp)
mov    %rbx,0x10(%rsp)
mov    %r11,0x18(%rsp)
mov    %r10,0x20(%rsp)
mov    %rax,0x28(%rsp)
mov    $0x0,%al
call   1090 <sscanf@plt>
add    $0x30,%rsp
mov    -0x48(%rbp),%ecx
movslq -0x34(%rbp),%rax
mov    %ecx,-0x2dc710(%rbp,%rax,4)
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    14bf <main+0x33f>
mov    -0x20(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x20(%rbp)
jmp    12f5 <main+0x175>
movl   $0x0,-0x24(%rbp)
cmpl   $0x3d090,-0x24(%rbp)
jge    1659 <main+0x4d9>
mov    -0x7a12f8(%rbp),%rdi
mov    -0x40(%rbp),%esi
mov    -0x7a12d8(%rbp),%rdx
call   1060 <fgets@plt>
mov    -0x7a12f8(%rbp),%rdi
lea    -0x3d09b7(%rbp),%rdx
lea    0xb21(%rip),%rsi
mov    $0x0,%al
call   1090 <sscanf@plt>
lea    -0x3d09b7(%rbp),%rdi
lea    0xb0f(%rip),%rsi
mov    $0x4,%edx
call   1040 <strncmp@plt>
cmp    $0x0,%eax
jne    1539 <main+0x3b9>
jmp    1659 <main+0x4d9>
lea    -0x3d09b7(%rbp),%rdi
lea    0xaee(%rip),%rsi
mov    $0x6,%edx
call   1040 <strncmp@plt>
cmp    $0x0,%eax
jne    158c <main+0x40c>
mov    -0x7a12f8(%rbp),%rdi
mov    -0x40(%rbp),%esi
mov    -0x7a12d8(%rbp),%rdx
call   1060 <fgets@plt>
mov    -0x7a12f8(%rbp),%rdi
lea    -0x3d09b7(%rbp),%rdx
lea    0xaa8(%rip),%rsi
mov    $0x0,%al
call   1090 <sscanf@plt>
lea    -0x3d09b7(%rbp),%rdi
lea    0xaab(%rip),%rsi
mov    $0x4,%edx
call   1040 <strncmp@plt>
cmp    $0x0,%eax
jne    1646 <main+0x4c6>
mov    -0x7a12f8(%rbp),%rdi
lea    -0x3d09b7(%rbp),%rdx
movslq -0x20(%rbp),%rax
mov    -0x5b8e50(%rbp,%rax,8),%r14
ff
lea    0xa7c(%rip),%rsi
lea    -0x3d095c(%rbp),%rcx
lea    -0x3d0960(%rbp),%r8
lea    -0x3d0964(%rbp),%r9
lea    -0x44(%rbp),%r15
lea    -0x3d0974(%rbp),%rbx
lea    -0x3d0978(%rbp),%r11
lea    -0x3d097c(%rbp),%r10
lea    -0x3d0980(%rbp),%rax
sub    $0x30,%rsp
mov    %r15,(%rsp)
mov    %r14,0x8(%rsp)
mov    %rbx,0x10(%rsp)
mov    %r11,0x18(%rsp)
mov    %r10,0x20(%rsp)
mov    %rax,0x28(%rsp)
mov    $0x0,%al
call   1090 <sscanf@plt>
add    $0x30,%rsp
mov    -0x44(%rbp),%ecx
movslq -0x30(%rbp),%rax
mov    %ecx,-0x3d0950(%rbp,%rax,4)
mov    -0x30(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x30(%rbp)
jmp    164b <main+0x4cb>
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
jmp    14d4 <main+0x354>
movl   $0x0,-0x24(%rbp)
mov    -0x24(%rbp),%eax
cmp    -0x34(%rbp),%eax
jge    16b2 <main+0x532>
mov    -0x7a12e8(%rbp),%rdi
movslq -0x24(%rbp),%rax
mov    -0x2dc710(%rbp,%rax,4),%ecx
movslq -0x24(%rbp),%rax
mov    -0x2dc710(%rbp,%rax,4),%r8d
ff
lea    0x9d7(%rip),%rsi
lea    0x9a6(%rip),%rdx
lea    0x9d5(%rip),%r9
call   1070 <fprintf@plt>
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
jmp    1660 <main+0x4e0>
movl   $0x0,-0x20(%rbp)
cmpl   $0x3d090,-0x20(%rbp)
jge    16f6 <main+0x576>
movslq -0x20(%rbp),%rax
mov    -0x5b8e50(%rbp,%rax,8),%rdi
ff
call   1030 <free@plt>
movslq -0x20(%rbp),%rax
mov    -0x7a12d0(%rbp,%rax,8),%rdi
ff
call   1030 <free@plt>
mov    -0x20(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x20(%rbp)
jmp    16b9 <main+0x539>
mov    -0x7a12d8(%rbp),%rdi
call   1050 <fclose@plt>
mov    -0x7a12e0(%rbp),%rdi
call   1050 <fclose@plt>
mov    -0x7a12e8(%rbp),%rdi
call   1050 <fclose@plt>
mov    -0x3d0998(%rbp),%rax
mov    %rax,%rsp
mov    -0x1c(%rbp),%eax
lea    -0x18(%rbp),%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x4c53c8,%rsp
mov    %rsp,0x38(%rsp)
movl   $0x0,0x1c(%rsp)
movl   $0x0,0x4(%rsp)
xor    %ebx,%ebx
nopl   0x0(%rax,%rax,1)
mov    $0xf,%edi
call   1080 <malloc@plt>
mov    %rax,0x880(%rsp,%rbx,8)
mov    $0xf,%edi
call   1080 <malloc@plt>
mov    %rax,0x2dcf40(%rsp,%rbx,8)
add    $0x1,%rbx
cmp    $0x3d090,%rbx
jne    11b0 <main+0x30>
lea    0xe18(%rip),%rdi
lea    0xe4b(%rip),%rbx
mov    %rbx,%rsi
call   10a0 <fopen@plt>
mov    %rax,%r13
lea    0xe11(%rip),%rdi
mov    %rbx,%rsi
call   10a0 <fopen@plt>
mov    %rax,0x10(%rsp)
lea    0xe0a(%rip),%rdi
lea    0xe0f(%rip),%rsi
call   10a0 <fopen@plt>
mov    %rax,0x20(%rsp)
mov    0x2dcf40(%rsp),%rax
mov    %rax,0x28(%rsp)
lea    0xa0(%rsp),%r15
lea    0xdeb(%rip),%r14
lea    0x82(%rsp),%r12
xor    %ebp,%ebp
xor    %eax,%eax
mov    %rax,0x8(%rsp)
jmp    126f <main+0xef>
cs nopw 0x0(%rax,%rax,1)
nop
add    $0x1,%ebp
cmp    $0x3d090,%ebp
je     13a0 <main+0x220>
mov    %r15,%rdi
mov    $0x3e8,%esi
mov    %r13,%rdx
call   1060 <fgets@plt>
mov    %r15,%rdi
mov    %r14,%rsi
mov    %r12,%rdx
xor    %eax,%eax
call   1090 <sscanf@plt>
mov    %r12,%rdi
lea    0xd97(%rip),%rsi
mov    $0x4,%edx
call   1040 <strncmp@plt>
test   %eax,%eax
je     13a5 <main+0x225>
mov    %r12,%rdi
lea    0xd80(%rip),%rsi
mov    $0x6,%edx
call   1040 <strncmp@plt>
test   %eax,%eax
jne    12e3 <main+0x163>
mov    %r15,%rdi
mov    $0x3e8,%esi
mov    %r13,%rdx
call   1060 <fgets@plt>
mov    %r15,%rdi
mov    %r14,%rsi
mov    %r12,%rdx
xor    %eax,%eax
call   1090 <sscanf@plt>
mov    %r12,%rdi
lea    0xd4f(%rip),%rsi
mov    $0x8,%edx
call   1040 <strncmp@plt>
test   %eax,%eax
jne    131b <main+0x19b>
mov    %r15,%rdi
mov    $0x3e8,%esi
mov    %r13,%rdx
call   1060 <fgets@plt>
mov    %r15,%rdi
mov    %r14,%rsi
mov    %r12,%rdx
xor    %eax,%eax
call   1090 <sscanf@plt>
mov    %r12,%rdi
lea    0xd20(%rip),%rsi
mov    $0x4,%edx
call   1040 <strncmp@plt>
test   %eax,%eax
jne    1260 <main+0xe0>
mov    %r15,%rdi
lea    0xd09(%rip),%rsi
mov    %r12,%rdx
lea    0x70(%rsp),%rcx
lea    0x6c(%rsp),%r8
lea    0x68(%rsp),%r9
xor    %eax,%eax
lea    0x48(%rsp),%rbx
push   %rbx
lea    0x54(%rsp),%rbx
push   %rbx
lea    0x60(%rsp),%rbx
push   %rbx
lea    0x6c(%rsp),%rbx
push   %rbx
push   0x48(%rsp)
lea    0x2c(%rsp),%rbx
push   %rbx
call   1090 <sscanf@plt>
add    $0x30,%rsp
mov    0x4(%rsp),%eax
mov    0x8(%rsp),%rcx
movslq %ecx,%rcx
mov    %eax,0x1e8d00(%rsp,%rcx,4)
add    $0x1,%ecx
mov    %rcx,0x8(%rsp)
jmp    1260 <main+0xe0>
mov    $0x3d090,%ebp
mov    %r13,0x30(%rsp)
mov    %ebp,%eax
mov    %rax,0x40(%rsp)
mov    $0x3d090,%r15d
lea    0x490(%rsp),%r14
lea    0xc67(%rip),%r12
lea    0x91(%rsp),%rbp
lea    0xc5b(%rip),%r13
jmp    13ea <main+0x26a>
nopw   0x0(%rax,%rax,1)
add    $0xffffffff,%r15d
je     14d0 <main+0x350>
mov    %r14,%rdi
mov    $0x3e8,%esi
mov    0x10(%rsp),%rdx
call   1060 <fgets@plt>
mov    %r14,%rdi
mov    %r12,%rsi
mov    %rbp,%rdx
xor    %eax,%eax
call   1090 <sscanf@plt>
mov    %rbp,%rdi
mov    %r13,%rsi
mov    $0x4,%edx
call   1040 <strncmp@plt>
test   %eax,%eax
je     14d0 <main+0x350>
mov    %rbp,%rdi
lea    0xc07(%rip),%rsi
mov    $0x6,%edx
call   1040 <strncmp@plt>
test   %eax,%eax
jne    145e <main+0x2de>
mov    %r14,%rdi
mov    $0x3e8,%esi
mov    0x10(%rsp),%rdx
call   1060 <fgets@plt>
mov    %r14,%rdi
mov    %r12,%rsi
mov    %rbp,%rdx
xor    %eax,%eax
call   1090 <sscanf@plt>
mov    %rbp,%rdi
lea    0xbdd(%rip),%rsi
mov    $0x4,%edx
call   1040 <strncmp@plt>
test   %eax,%eax
jne    13e0 <main+0x260>
mov    %r14,%rdi
lea    0xbc6(%rip),%rsi
mov    %rbp,%rdx
lea    0x7c(%rsp),%rcx
lea    0x78(%rsp),%r8
lea    0x74(%rsp),%r9
xor    %eax,%eax
lea    0x58(%rsp),%rbx
push   %rbx
lea    0x64(%rsp),%rbx
push   %rbx
lea    0x70(%rsp),%rbx
push   %rbx
lea    0x7c(%rsp),%rbx
push   %rbx
mov    0x60(%rsp),%rbx
push   0x8a0(%rsp,%rbx,8)
lea    0x44(%rsp),%rbx
push   %rbx
call   1090 <sscanf@plt>
add    $0x30,%rsp
jmp    13e0 <main+0x260>
mov    0x8(%rsp),%rax
test   %eax,%eax
mov    0x20(%rsp),%r13
jle    1524 <main+0x3a4>
mov    %eax,%ebp
xor    %ebx,%ebx
lea    0xb7f(%rip),%r14
lea    0xb4e(%rip),%r15
lea    0xb7d(%rip),%r12
nopw   0x0(%rax,%rax,1)
mov    0x1e8d00(%rsp,%rbx,4),%ecx
mov    %r13,%rdi
mov    %r14,%rsi
mov    %r15,%rdx
mov    %ecx,%r8d
mov    %r12,%r9
call   1070 <fprintf@plt>
add    $0x1,%rbx
cmp    %rbx,%rbp
jne    1500 <main+0x380>
mov    0x880(%rsp),%rdi
call   1030 <free@plt>
mov    0x28(%rsp),%rdi
call   1030 <free@plt>
mov    $0x1,%ebp
mov    0x2dcf40(%rsp,%rbp,8),%rbx
mov    0x880(%rsp,%rbp,8),%rdi
call   1030 <free@plt>
mov    %rbx,%rdi
call   1030 <free@plt>
add    $0x1,%rbp
cmp    $0x3d090,%rbp
jne    1540 <main+0x3c0>
mov    0x10(%rsp),%rdi
call   1050 <fclose@plt>
mov    0x30(%rsp),%rdi
call   1050 <fclose@plt>
mov    0x20(%rsp),%rdi
call   1050 <fclose@plt>
mov    0x38(%rsp),%rsp
xor    %eax,%eax
add    $0x4c53c8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [18 x i8] c"input_ligand.ammp\00"
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [13 x i8] c"protein.ammp\00"
@.str.3 = [12 x i8] c"active.ammp\00"
@.str.4 = [2 x i8] c"w\00"
@.str.5 = [3 x i8] c"%s\00"
@.str.6 = [5 x i8] c"bond\00"
@.str.7 = [7 x i8] c"mompar\00"
@.str.8 = [9 x i8] c"inactive\00"
@.str.9 = [5 x i8] c"atom\00"
@.str.10 = [30 x i8] c"%s %f %f %f %i %s %f %f %f %f\00"
@.str.11 = [12 x i8] c"%s %i %i%s\0A\00"
@.str.12 = [7 x i8] c"active\00"
@.str.13 = [2 x i8] c";\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%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 [250000 x i32]
%14 = alloca [250000 x i32]
%15 = alloca [250000 x i32]
%16 = alloca [250000 x i32]
%17 = alloca float
%18 = alloca float
%19 = alloca float
%20 = alloca float
%21 = alloca float
%22 = alloca float
%23 = alloca float
%24 = alloca float
%25 = alloca float
%26 = alloca float
%27 = alloca float
%28 = alloca float
%29 = alloca float
%30 = alloca float
%31 = alloca float
%32 = alloca float
%33 = alloca i8*
%34 = alloca i64
%35 = alloca i64
%36 = alloca [15 x i8]
%37 = alloca [15 x i8]
%38 = alloca [250000 x i8*]
%39 = alloca [250000 x i8*]
%40 = alloca i32*
%41 = alloca i32*
%42 = alloca i32*
store i32 0, i32* %1
store i32 0, i32* %2
store i32 0, i32* %3
store i32 0, i32* %4
store i32 0, i32* %5
store i32 0, i32* %6
store i32 0, i32* %7
store i32 0, i32* %8
store i32 0, i32* %9
store i32 1000, i32* %10
store i32 0, i32* %11
store i32 0, i32* %12
store float 0.000000e+00, float* %17
store float 0.000000e+00, float* %18
%43 = load i32, i32* %10
%44 = zext i32 %43 to i64
%45 = call i8* @llvm.stacksave()
store i8* %45, i8** %33
%46 = alloca i8, i64 %44
store i64 %44, i64* %34
%47 = load i32, i32* %10
%48 = zext i32 %47 to i64
%49 = alloca i8, i64 %48
store i64 %48, i64* %35
store i32 0, i32* %3
br label %50
50: ; preds = %64, %0
%51 = load i32, i32* %3
%52 = icmp slt i32 %51, 250000
br i1 %52, label %53, label %67
53: ; preds = %50
%54 = call i64 @malloc(i32 15)
%55 = inttoptr i64 %54 to i8*
%56 = load i32, i32* %3
%57 = sext i32 %56 to i64
%58 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %38, i64 0, i64 %57
store i8* %55, i8** %58
%59 = call i64 @malloc(i32 15)
%60 = inttoptr i64 %59 to i8*
%61 = load i32, i32* %3
%62 = sext i32 %61 to i64
%63 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %39, i64 0, i64 %62
store i8* %60, i8** %63
br label %64
64: ; preds = %53
%65 = load i32, i32* %3
%66 = add nsw i32 %65, 1
store i32 %66, i32* %3
br label %50
67: ; preds = %50
%68 = call i32* @fopen(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %68, i32** %41
%69 = call i32* @fopen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %69, i32** %40
%70 = call i32* @fopen(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
store i32* %70, i32** %42
store i32 0, i32* %2
br label %71
71: ; preds = %122, %67
%72 = load i32, i32* %2
%73 = icmp slt i32 %72, 250000
br i1 %73, label %74, label %125
74: ; preds = %71
%75 = load i32, i32* %10
%76 = load i32*, i32** %41
%77 = call i32 @fgets(i8* %49, i32 %75, i32* %76)
%78 = getelementptr inbounds [15 x i8], [15 x i8]* %37, i64 0, i64 0
%79 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %49, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8* %78)
%80 = getelementptr inbounds [15 x i8], [15 x i8]* %37, i64 0, i64 0
%81 = call i32 @strncmp(i8* %80, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.6, i64 0, i64 0), i32 4)
%82 = icmp ne i32 %81, 0
br i1 %82, label %84, label %83
83: ; preds = %74
br label %125
84: ; preds = %74
%85 = getelementptr inbounds [15 x i8], [15 x i8]* %37, i64 0, i64 0
%86 = call i32 @strncmp(i8* %85, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.7, i64 0, i64 0), i32 6)
%87 = icmp ne i32 %86, 0
br i1 %87, label %94, label %88
88: ; preds = %84
%89 = load i32, i32* %10
%90 = load i32*, i32** %41
%91 = call i32 @fgets(i8* %49, i32 %89, i32* %90)
%92 = getelementptr inbounds [15 x i8], [15 x i8]* %37, i64 0, i64 0
%93 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %49, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8* %92)
br label %94
94: ; preds = %88, %84
%95 = getelementptr inbounds [15 x i8], [15 x i8]* %37, i64 0, i64 0
%96 = call i32 @strncmp(i8* %95, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.8, i64 0, i64 0), i32 8)
%97 = icmp ne i32 %96, 0
br i1 %97, label %104, label %98
98: ; preds = %94
%99 = load i32, i32* %10
%100 = load i32*, i32** %41
%101 = call i32 @fgets(i8* %49, i32 %99, i32* %100)
%102 = getelementptr inbounds [15 x i8], [15 x i8]* %37, i64 0, i64 0
%103 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %49, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8* %102)
br label %104
104: ; preds = %98, %94
%105 = getelementptr inbounds [15 x i8], [15 x i8]* %37, i64 0, i64 0
%106 = call i32 @strncmp(i8* %105, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i32 4)
%107 = icmp ne i32 %106, 0
br i1 %107, label %121, label %108
108: ; preds = %104
%109 = getelementptr inbounds [15 x i8], [15 x i8]* %37, i64 0, i64 0
%110 = load i32, i32* %4
%111 = sext i32 %110 to i64
%112 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %39, i64 0, i64 %111
%113 = load i8*, i8** %112
%114 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %49, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.10, i64 0, i64 0), i8* %109, float* %22, float* %23, float* %24, i32* %12, i8* %113, float* %29, float* %30, float* %31, float* %32)
%115 = load i32, i32* %12
%116 = load i32, i32* %7
%117 = sext i32 %116 to i64
%118 = getelementptr inbounds [250000 x i32], [250000 x i32]* %15, i64 0, i64 %117
store i32 %115, i32* %118
%119 = load i32, i32* %7
%120 = add nsw i32 %119, 1
store i32 %120, i32* %7
br label %121
121: ; preds = %108, %104
br label %122
122: ; preds = %121
%123 = load i32, i32* %2
%124 = add nsw i32 %123, 1
store i32 %124, i32* %2
br label %71
125: ; preds = %83, %71
store i32 0, i32* %3
br label %126
126: ; preds = %167, %125
%127 = load i32, i32* %3
%128 = icmp slt i32 %127, 250000
br i1 %128, label %129, label %170
129: ; preds = %126
%130 = load i32, i32* %10
%131 = load i32*, i32** %40
%132 = call i32 @fgets(i8* %46, i32 %130, i32* %131)
%133 = getelementptr inbounds [15 x i8], [15 x i8]* %36, i64 0, i64 0
%134 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %46, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8* %133)
%135 = getelementptr inbounds [15 x i8], [15 x i8]* %36, i64 0, i64 0
%136 = call i32 @strncmp(i8* %135, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.6, i64 0, i64 0), i32 4)
%137 = icmp ne i32 %136, 0
br i1 %137, label %139, label %138
138: ; preds = %129
br label %170
139: ; preds = %129
%140 = getelementptr inbounds [15 x i8], [15 x i8]* %36, i64 0, i64 0
%141 = call i32 @strncmp(i8* %140, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.7, i64 0, i64 0), i32 6)
%142 = icmp ne i32 %141, 0
br i1 %142, label %149, label %143
143: ; preds = %139
%144 = load i32, i32* %10
%145 = load i32*, i32** %40
%146 = call i32 @fgets(i8* %46, i32 %144, i32* %145)
%147 = getelementptr inbounds [15 x i8], [15 x i8]* %36, i64 0, i64 0
%148 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %46, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8* %147)
br label %149
149: ; preds = %143, %139
%150 = getelementptr inbounds [15 x i8], [15 x i8]* %36, i64 0, i64 0
%151 = call i32 @strncmp(i8* %150, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i32 4)
%152 = icmp ne i32 %151, 0
br i1 %152, label %166, label %153
153: ; preds = %149
%154 = getelementptr inbounds [15 x i8], [15 x i8]* %36, i64 0, i64 0
%155 = load i32, i32* %2
%156 = sext i32 %155 to i64
%157 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %38, i64 0, i64 %156
%158 = load i8*, i8** %157
%159 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %46, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.10, i64 0, i64 0), i8* %154, float* %19, float* %20, float* %21, i32* %11, i8* %158, float* %25, float* %26, float* %27, float* %28)
%160 = load i32, i32* %11
%161 = load i32, i32* %6
%162 = sext i32 %161 to i64
%163 = getelementptr inbounds [250000 x i32], [250000 x i32]* %16, i64 0, i64 %162
store i32 %160, i32* %163
%164 = load i32, i32* %6
%165 = add nsw i32 %164, 1
store i32 %165, i32* %6
br label %166
166: ; preds = %153, %149
br label %167
167: ; preds = %166
%168 = load i32, i32* %3
%169 = add nsw i32 %168, 1
store i32 %169, i32* %3
br label %126
170: ; preds = %138, %126
store i32 0, i32* %3
br label %171
171: ; preds = %186, %170
%172 = load i32, i32* %3
%173 = load i32, i32* %7
%174 = icmp slt i32 %172, %173
br i1 %174, label %175, label %189
175: ; preds = %171
%176 = load i32*, i32** %42
%177 = load i32, i32* %3
%178 = sext i32 %177 to i64
%179 = getelementptr inbounds [250000 x i32], [250000 x i32]* %15, i64 0, i64 %178
%180 = load i32, i32* %179
%181 = load i32, i32* %3
%182 = sext i32 %181 to i64
%183 = getelementptr inbounds [250000 x i32], [250000 x i32]* %15, i64 0, i64 %182
%184 = load i32, i32* %183
%185 = call i32 @fprintf(i32* %176, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.11, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.12, i64 0, i64 0), i32 %180, i32 %184, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.13, i64 0, i64 0))
br label %186
186: ; preds = %175
%187 = load i32, i32* %3
%188 = add nsw i32 %187, 1
store i32 %188, i32* %3
br label %171
189: ; preds = %171
store i32 0, i32* %2
br label %190
190: ; preds = %204, %189
%191 = load i32, i32* %2
%192 = icmp slt i32 %191, 250000
br i1 %192, label %193, label %207
193: ; preds = %190
%194 = load i32, i32* %2
%195 = sext i32 %194 to i64
%196 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %38, i64 0, i64 %195
%197 = load i8*, i8** %196
%198 = call i32 @free(i8* %197)
%199 = load i32, i32* %2
%200 = sext i32 %199 to i64
%201 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %39, i64 0, i64 %200
%202 = load i8*, i8** %201
%203 = call i32 @free(i8* %202)
br label %204
204: ; preds = %193
%205 = load i32, i32* %2
%206 = add nsw i32 %205, 1
store i32 %206, i32* %2
br label %190
207: ; preds = %190
%208 = load i32*, i32** %40
%209 = call i32 @fclose(i32* %208)
%210 = load i32*, i32** %41
%211 = call i32 @fclose(i32* %210)
%212 = load i32*, i32** %42
%213 = call i32 @fclose(i32* %212)
%214 = load i8*, i8** %33
%215 = load i32, i32* %1
ret i32 %215
}

LLVM IR (-O2):
@.str = [18 x i8] c"input_ligand.ammp\00"
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [13 x i8] c"protein.ammp\00"
@.str.3 = [12 x i8] c"active.ammp\00"
@.str.4 = [2 x i8] c"w\00"
@.str.5 = [3 x i8] c"%s\00"
@.str.6 = [5 x i8] c"bond\00"
@.str.7 = [7 x i8] c"mompar\00"
@.str.8 = [9 x i8] c"inactive\00"
@.str.9 = [5 x i8] c"atom\00"
@.str.10 = [30 x i8] c"%s %f %f %f %i %s %f %f %f %f\00"
@.str.11 = [12 x i8] c"%s %i %i%s\0A\00"
@.str.12 = [7 x i8] c"active\00"
@.str.13 = [2 x i8] c";\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca [250000 x i32]
%4 = alloca float
%5 = alloca float
%6 = alloca float
%7 = alloca float
%8 = alloca float
%9 = alloca float
%10 = alloca float
%11 = alloca float
%12 = alloca float
%13 = alloca float
%14 = alloca float
%15 = alloca float
%16 = alloca float
%17 = alloca float
%18 = alloca [15 x i8]
%19 = alloca [15 x i8]
%20 = alloca [250000 x i8*]
%21 = alloca [250000 x i8*]
%22 = bitcast i32* %1 to i8*
store i32 0, i32* %1
%23 = bitcast i32* %2 to i8*
store i32 0, i32* %2
%24 = bitcast [250000 x i32]* %3 to i8*
%25 = bitcast float* %4 to i8*
%26 = bitcast float* %5 to i8*
%27 = bitcast float* %6 to i8*
%28 = bitcast float* %7 to i8*
%29 = bitcast float* %8 to i8*
%30 = bitcast float* %9 to i8*
%31 = bitcast float* %10 to i8*
%32 = bitcast float* %11 to i8*
%33 = bitcast float* %12 to i8*
%34 = bitcast float* %13 to i8*
%35 = bitcast float* %14 to i8*
%36 = bitcast float* %15 to i8*
%37 = bitcast float* %16 to i8*
%38 = bitcast float* %17 to i8*
%39 = tail call i8* @llvm.stacksave()
%40 = alloca [1000 x i8]
%41 = alloca [1000 x i8]
%42 = getelementptr inbounds [1000 x i8], [1000 x i8]* %41, i64 0, i64 0
%43 = getelementptr inbounds [15 x i8], [15 x i8]* %18, i64 0, i64 0
%44 = getelementptr inbounds [15 x i8], [15 x i8]* %19, i64 0, i64 0
%45 = bitcast [250000 x i8*]* %20 to i8*
%46 = bitcast [250000 x i8*]* %21 to i8*
br label %47
47: ; preds = %0, %47
%48 = phi i64 [ 0, %0 ], [ %55, %47 ]
%49 = tail call i64 @malloc(i32 15)
%50 = inttoptr i64 %49 to i8*
%51 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %20, i64 0, i64 %48
store i8* %50, i8** %51
%52 = tail call i64 @malloc(i32 15)
%53 = inttoptr i64 %52 to i8*
%54 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %21, i64 0, i64 %48
store i8* %53, i8** %54
%55 = add nuw nsw i64 %48, 1
%56 = icmp eq i64 %55, 250000
br i1 %56, label %57, label %47
57: ; preds = %47
%58 = getelementptr inbounds [1000 x i8], [1000 x i8]* %40, i64 0, i64 0
%59 = tail call i32* @fopen(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%60 = tail call i32* @fopen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%61 = tail call i32* @fopen(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
%62 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %21, i64 0, i64 0
%63 = load i8*, i8** %62
br label %64
64: ; preds = %57, %92
%65 = phi i32 [ 0, %57 ], [ %94, %92 ]
%66 = phi i32 [ 0, %57 ], [ %93, %92 ]
%67 = call i32 @fgets(i8* %42, i32 1000, i32* %59)
%68 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %42, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8* %44)
%69 = call i32 @strncmp(i8* %44, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.6, i64 0, i64 0), i32 4)
%70 = icmp eq i32 %69, 0
br i1 %70, label %96, label %71
71: ; preds = %64
%72 = call i32 @strncmp(i8* %44, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.7, i64 0, i64 0), i32 6)
%73 = icmp eq i32 %72, 0
br i1 %73, label %74, label %77
74: ; preds = %71
%75 = call i32 @fgets(i8* %42, i32 1000, i32* %59)
%76 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %42, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8* %44)
br label %77
77: ; preds = %74, %71
%78 = call i32 @strncmp(i8* %44, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.8, i64 0, i64 0), i32 8)
%79 = icmp eq i32 %78, 0
br i1 %79, label %80, label %83
80: ; preds = %77
%81 = call i32 @fgets(i8* %42, i32 1000, i32* %59)
%82 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %42, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8* %44)
br label %83
83: ; preds = %80, %77
%84 = call i32 @strncmp(i8* %44, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i32 4)
%85 = icmp eq i32 %84, 0
br i1 %85, label %86, label %92
86: ; preds = %83
%87 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %42, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.10, i64 0, i64 0), i8* %44, float* %7, float* %8, float* %9, i32* %2, i8* %63, float* %14, float* %15, float* %16, float* %17)
%88 = load i32, i32* %2
%89 = sext i32 %66 to i64
%90 = getelementptr inbounds [250000 x i32], [250000 x i32]* %3, i64 0, i64 %89
store i32 %88, i32* %90
%91 = add nsw i32 %66, 1
br label %92
92: ; preds = %83, %86
%93 = phi i32 [ %66, %83 ], [ %91, %86 ]
%94 = add nuw nsw i32 %65, 1
%95 = icmp eq i32 %94, 250000
br i1 %95, label %96, label %64
96: ; preds = %64, %92
%97 = phi i32 [ %66, %64 ], [ %93, %92 ]
%98 = phi i32 [ %65, %64 ], [ 250000, %92 ]
%99 = zext i32 %98 to i64
%100 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %20, i64 0, i64 %99
br label %101
101: ; preds = %96, %119
%102 = phi i32 [ 0, %96 ], [ %120, %119 ]
%103 = call i32 @fgets(i8* %58, i32 1000, i32* %60)
%104 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %58, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8* %43)
%105 = call i32 @strncmp(i8* %43, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.6, i64 0, i64 0), i32 4)
%106 = icmp eq i32 %105, 0
br i1 %106, label %122, label %107
107: ; preds = %101
%108 = call i32 @strncmp(i8* %43, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.7, i64 0, i64 0), i32 6)
%109 = icmp eq i32 %108, 0
br i1 %109, label %110, label %113
110: ; preds = %107
%111 = call i32 @fgets(i8* %58, i32 1000, i32* %60)
%112 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %58, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8* %43)
br label %113
113: ; preds = %110, %107
%114 = call i32 @strncmp(i8* %43, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i64 0, i64 0), i32 4)
%115 = icmp eq i32 %114, 0
br i1 %115, label %116, label %119
116: ; preds = %113
%117 = load i8*, i8** %100
%118 = call i32 (i8*, i8*, i8*, ...) @sscanf(i8* %58, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.10, i64 0, i64 0), i8* %43, float* %4, float* %5, float* %6, i32* %1, i8* %117, float* %10, float* %11, float* %12, float* %13)
br label %119
119: ; preds = %113, %116
%120 = add nuw nsw i32 %102, 1
%121 = icmp eq i32 %120, 250000
br i1 %121, label %122, label %101
122: ; preds = %101, %119
%123 = icmp sgt i32 %97, 0
br i1 %123, label %124, label %126
124: ; preds = %122
%125 = zext i32 %97 to i64
br label %131
126: ; preds = %131, %122
%127 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %20, i64 0, i64 0
%128 = load i8*, i8** %127
%129 = call i32 @free(i8* %128)
%130 = call i32 @free(i8* %63)
br label %138
131: ; preds = %124, %131
%132 = phi i64 [ 0, %124 ], [ %136, %131 ]
%133 = getelementptr inbounds [250000 x i32], [250000 x i32]* %3, i64 0, i64 %132
%134 = load i32, i32* %133
%135 = call i32 @fprintf(i32* %61, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.11, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.12, i64 0, i64 0), i32 %134, i32 %134, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.13, i64 0, i64 0))
%136 = add nuw nsw i64 %132, 1
%137 = icmp eq i64 %136, %125
br i1 %137, label %126, label %131
138: ; preds = %126, %138
%139 = phi i64 [ 1, %126 ], [ %146, %138 ]
%140 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %21, i64 0, i64 %139
%141 = load i8*, i8** %140
%142 = getelementptr inbounds [250000 x i8*], [250000 x i8*]* %20, i64 0, i64 %139
%143 = load i8*, i8** %142
%144 = call i32 @free(i8* %143)
%145 = call i32 @free(i8* %141)
%146 = add nuw nsw i64 %139, 1
%147 = icmp eq i64 %146, 250000
br i1 %147, label %148, label %138
148: ; preds = %138
%149 = call i32 @fclose(i32* %60)
%150 = call i32 @fclose(i32* %59)
%151 = call i32 @fclose(i32* %61)
ret i32 0
}