#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 */
scalar_t__ EOF;
int EXIT_SUCCESS;
int /*<<< orphan*/ Indel_Process(char **, char **, int *, int *, int *, int);
scalar_t__ calloc(int, int);
char **cmatrix(int /*<<< orphan*/, int, int /*<<< orphan*/, int);
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
scalar_t__ feof(int /*<<< orphan*/ *);
int /*<<< orphan*/ fflush(int /*<<< orphan*/);
int /*<<< orphan*/ fgets(char *, int, int /*<<< orphan*/ *);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, ...);
scalar_t__ fscanf(int /*<<< orphan*/ *, char *, char *, char *, char *, char *,
                  int *, int *, int *, int *, char *, int *, float *, int *,
                  int *);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ stderr;
int /*<<< orphan*/ stdout;
int /*<<< orphan*/ strncpy(char *, char *, int);
int main(int argc, char **argv) {
  FILE *namef;
  int i, nSeq = 0;
  int n_reads, nseq = 0;
  char line[2000] = {0}, tempc1[60], RC[1];
  char *filename;
  int *hit_rcdex, *hit_locus1, *hit_locus2, *readlength;
  int *hit_read1, *hit_length;
  char **S_Name, **R_Name, **T_Name;
  float *hit_identy;
  int *hit_mask, *superlength;
  int *hit_read2;
  fflush(stdout);
  if (argc < 2) {
    printf("Usage: %s <cross_genome_ouput file>\n", argv[0]);
    exit(1);
  }
  filename = argv[1];
  if ((namef = fopen(filename, "r")) == NULL) {
    fprintf(stderr, "ERROR: can't open file %s\n", filename);
    exit(1);
  }
  while (!feof(namef)) {
    fgets(line, 2000, namef);
    if (feof(namef))
      break;
    nseq++;
  }
  fclose(namef);
  if ((hit_mask = (int *)calloc(nseq, sizeof(int))) == NULL) {
    fprintf(stderr, "Error: out of memory: calloc - hit_mask\n");
    exit(1);
  }
  if ((hit_rcdex = (int *)calloc(nseq, sizeof(int))) == NULL) {
    fprintf(stderr, "Error: out of memory: calloc - hit_rcdex\n");
    exit(1);
  }
  if ((hit_read1 = (int *)calloc(nseq, sizeof(int))) == NULL) {
    fprintf(stderr, "Error: out of memory: calloc - hit_read1\n");
    exit(1);
  }
  if ((hit_read2 = (int *)calloc(nseq, sizeof(int))) == NULL) {
    fprintf(stderr, "Error: out of memory: calloc - hit_read2\n");
    exit(1);
  }
  if ((hit_locus1 = (int *)calloc(nseq, sizeof(int))) == NULL) {
    fprintf(stderr, "Error: out of memory: calloc - hit_locus1\n");
    exit(1);
  }
  if ((hit_locus2 = (int *)calloc(nseq, sizeof(int))) == NULL) {
    fprintf(stderr, "Error: out of memory: calloc - hit_locus2\n");
    exit(1);
  }
  if ((hit_length = (int *)calloc(nseq, sizeof(int))) == NULL) {
    fprintf(stderr, "Error: out of memory: calloc - hit_length\n");
    exit(1);
  }
  if ((readlength = (int *)calloc(nseq, sizeof(int))) == NULL) {
    fprintf(stderr, "Error: out of memory: calloc - readlength\n");
    exit(1);
  }
  if ((superlength = (int *)calloc(nseq, sizeof(int))) == NULL) {
    fprintf(stderr, "Error: out of memory: calloc - superlength\n");
    exit(1);
  }
  if ((hit_identy = (float *)calloc(nseq, sizeof(float))) == NULL) {
    fprintf(stderr, "Error: out of memory: calloc - hit_identy\n");
    exit(1);
  }
  R_Name = cmatrix(0, nseq + 10, 0, 100);
  S_Name = cmatrix(0, nseq + 10, 0, 100);
  T_Name = cmatrix(0, nseq + 10, 0, 6);
  printf("reads: %d %s\n", nseq, filename);
  if ((namef = fopen(filename, "r")) == NULL) {
    fprintf(stderr, "ERROR: unable to open file %s\n", filename);
    exit(1);
  }
  i = 0;
  while (fscanf(namef, "%s %s %s %s %d %d %d %d %s %d %f %d %d", tempc1, tempc1,
                R_Name[i], S_Name[i], &hit_read1[i], &hit_read2[i],
                &hit_locus1[i], &hit_locus2[i], RC, &hit_length[i],
                &hit_identy[i], &readlength[i], &superlength[i]) != EOF) {
    if (RC[0] == 'F')
      hit_rcdex[i] = 0;
    else {
      int hit1 = hit_locus1[i];
      int hit2 = hit_locus2[i];
      hit_locus1[i] = superlength[i] - hit1 + 1;
      hit_locus2[i] = superlength[i] - hit2 + 1;
      hit_rcdex[i] = 1;
    }
    hit_mask[i] = 0;
    strncpy(T_Name[i], S_Name[i], 4);
    i++;
  }
  fclose(namef);
  n_reads = i;
  printf("reads: %d %s\n", n_reads, filename);
  Indel_Process(S_Name, R_Name, hit_mask, superlength, hit_read2, n_reads);
  nSeq = nseq;
  nseq = 0;
  if ((namef = fopen(filename, "r")) == NULL) {
    fprintf(stderr, "ERROR: unable to open file %s\n", filename);
    exit(1);
  }
  while (!feof(namef)) {
    fgets(line, 2000, namef);
    if (feof(namef))
      break;
    if (hit_mask[nseq] == 0)
      printf("%s", line);
    nseq++;
  }
  fclose(namef);
  printf("Job finished for %d reads!\n", nSeq);
  return EXIT_SUCCESS;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x918,%rsp
movl   $0x0,-0x2c(%rbp)
mov    %edi,-0x30(%rbp)
mov    %rsi,-0x38(%rbp)
movl   $0x0,-0x48(%rbp)
movl   $0x0,-0x50(%rbp)
lea    -0x820(%rbp),%rdi
xor    %esi,%esi
mov    $0x7d0,%edx
call   1070 <memset@plt>
mov    0x2da6(%rip),%rax
mov    (%rax),%edi
call   10d0 <fflush@plt>
cmpl   $0x2,-0x30(%rbp)
jge    125a <main+0x7a>
mov    -0x38(%rbp),%rax
mov    (%rax),%rsi
lea    0xdb7(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x38(%rbp),%rax
mov    0x8(%rax),%rax
mov    %rax,-0x870(%rbp)
mov    -0x870(%rbp),%rdi
lea    0xdae(%rip),%rsi
call   10f0 <fopen@plt>
mov    %rax,-0x40(%rbp)
cmp    $0x0,%rax
jne    12b2 <main+0xd2>
mov    0x2d47(%rip),%rax
mov    (%rax),%edi
mov    -0x870(%rbp),%rdx
lea    0xd86(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
jmp    12b7 <main+0xd7>
mov    -0x40(%rbp),%rdi
call   10c0 <feof@plt>
cmp    $0x0,%rax
setne  %al
xor    $0xff,%al
test   $0x1,%al
jne    12d6 <main+0xf6>
jmp    1311 <main+0x131>
lea    -0x820(%rbp),%rdi
mov    -0x40(%rbp),%rdx
mov    $0x7d0,%esi
call   1090 <fgets@plt>
mov    -0x40(%rbp),%rdi
call   10c0 <feof@plt>
cmp    $0x0,%rax
je     1303 <main+0x123>
jmp    1311 <main+0x131>
mov    -0x50(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x50(%rbp)
jmp    12b7 <main+0xd7>
mov    -0x40(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x50(%rbp),%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,-0x8c8(%rbp)
cmp    $0x0,%rax
jne    1359 <main+0x179>
mov    0x2c99(%rip),%rax
mov    (%rax),%edi
lea    0xcfa(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x50(%rbp),%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,-0x878(%rbp)
cmp    $0x0,%rax
jne    1398 <main+0x1b8>
mov    0x2c5a(%rip),%rax
mov    (%rax),%edi
lea    0xce4(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x50(%rbp),%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,-0x898(%rbp)
cmp    $0x0,%rax
jne    13d7 <main+0x1f7>
mov    0x2c1b(%rip),%rax
mov    (%rax),%edi
lea    0xccf(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x50(%rbp),%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,-0x8d8(%rbp)
cmp    $0x0,%rax
jne    1416 <main+0x236>
mov    0x2bdc(%rip),%rax
mov    (%rax),%edi
lea    0xcba(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x50(%rbp),%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,-0x880(%rbp)
cmp    $0x0,%rax
jne    1455 <main+0x275>
mov    0x2b9d(%rip),%rax
mov    (%rax),%edi
lea    0xca5(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x50(%rbp),%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,-0x888(%rbp)
cmp    $0x0,%rax
jne    1494 <main+0x2b4>
mov    0x2b5e(%rip),%rax
mov    (%rax),%edi
lea    0xc91(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x50(%rbp),%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,-0x8a0(%rbp)
cmp    $0x0,%rax
jne    14d3 <main+0x2f3>
mov    0x2b1f(%rip),%rax
mov    (%rax),%edi
lea    0xc7d(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x50(%rbp),%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,-0x890(%rbp)
cmp    $0x0,%rax
jne    1512 <main+0x332>
mov    0x2ae0(%rip),%rax
mov    (%rax),%edi
lea    0xc69(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x50(%rbp),%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,-0x8d0(%rbp)
cmp    $0x0,%rax
jne    1551 <main+0x371>
mov    0x2aa1(%rip),%rax
mov    (%rax),%edi
lea    0xc55(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x50(%rbp),%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,-0x8c0(%rbp)
cmp    $0x0,%rax
jne    1590 <main+0x3b0>
mov    0x2a62(%rip),%rax
mov    (%rax),%edi
lea    0xc42(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    -0x50(%rbp),%esi
add    $0xa,%esi
xor    %edx,%edx
mov    $0x64,%ecx
mov    %edx,%edi
call   1050 <cmatrix@plt>
mov    %rax,-0x8b0(%rbp)
mov    -0x50(%rbp),%esi
add    $0xa,%esi
xor    %edx,%edx
mov    $0x64,%ecx
mov    %edx,%edi
call   1050 <cmatrix@plt>
mov    %rax,-0x8a8(%rbp)
mov    -0x50(%rbp),%esi
add    $0xa,%esi
xor    %edx,%edx
mov    $0x6,%ecx
mov    %edx,%edi
call   1050 <cmatrix@plt>
mov    %rax,-0x8b8(%rbp)
mov    -0x50(%rbp),%esi
mov    -0x870(%rbp),%rdx
lea    0xbfa(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x870(%rbp),%rdi
lea    0xa1e(%rip),%rsi
call   10f0 <fopen@plt>
mov    %rax,-0x40(%rbp)
cmp    $0x0,%rax
jne    1642 <main+0x462>
mov    0x29b7(%rip),%rax
mov    (%rax),%edi
mov    -0x870(%rbp),%rdx
lea    0xbc9(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
movl   $0x0,-0x44(%rbp)
mov    -0x40(%rbp),%rdi
lea    -0x860(%rbp),%rdx
lea    -0x860(%rbp),%rcx
mov    -0x8b0(%rbp),%rax
movslq -0x44(%rbp),%rsi
mov    (%rax,%rsi,8),%r8
mov    -0x8a8(%rbp),%rax
movslq -0x44(%rbp),%rsi
mov    (%rax,%rsi,8),%r9
mov    -0x898(%rbp),%rax
movslq -0x44(%rbp),%rsi
shl    $0x2,%rsi
add    %rsi,%rax
mov    %rax,-0x8f0(%rbp)
mov    -0x8d8(%rbp),%r13
movslq -0x44(%rbp),%rax
shl    $0x2,%rax
add    %rax,%r13
mov    -0x880(%rbp),%r12
movslq -0x44(%rbp),%rax
shl    $0x2,%rax
add    %rax,%r12
mov    -0x888(%rbp),%r15
movslq -0x44(%rbp),%rax
shl    $0x2,%rax
add    %rax,%r15
lea    -0x861(%rbp),%r14
mov    -0x8a0(%rbp),%rbx
movslq -0x44(%rbp),%rax
shl    $0x2,%rax
add    %rax,%rbx
mov    -0x8c0(%rbp),%r11
movslq -0x44(%rbp),%rax
shl    $0x2,%rax
add    %rax,%r11
mov    -0x890(%rbp),%r10
movslq -0x44(%rbp),%rax
shl    $0x2,%rax
add    %rax,%r10
mov    -0x8d0(%rbp),%rsi
movslq -0x44(%rbp),%rax
shl    $0x2,%rax
add    %rax,%rsi
mov    -0x8f0(%rbp),%rax
mov    %rsi,-0x8e8(%rbp)
lea    0xaed(%rip),%rsi
mov    %rax,(%rsp)
mov    -0x8e8(%rbp),%rax
mov    %r13,0x8(%rsp)
mov    %r12,0x10(%rsp)
mov    %r15,0x18(%rsp)
mov    %r14,0x20(%rsp)
mov    %rbx,0x28(%rsp)
mov    %r11,0x30(%rsp)
mov    %r10,0x38(%rsp)
mov    %rax,0x40(%rsp)
call   1080 <fscanf@plt>
mov    0x287d(%rip),%rcx
cmp    (%rcx),%rax
je     1867 <main+0x687>
movsbl -0x861(%rbp),%eax
cmp    $0x46,%eax
jne    179b <main+0x5bb>
mov    -0x878(%rbp),%rax
movslq -0x44(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
jmp    181f <main+0x63f>
mov    -0x880(%rbp),%rax
movslq -0x44(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x8dc(%rbp)
mov    -0x888(%rbp),%rax
movslq -0x44(%rbp),%rcx
mov    (%rax,%rcx,4),%eax
mov    %eax,-0x8e0(%rbp)
mov    -0x8d0(%rbp),%rax
movslq -0x44(%rbp),%rcx
mov    (%rax,%rcx,4),%edx
sub    -0x8dc(%rbp),%edx
add    $0x1,%edx
mov    -0x880(%rbp),%rax
movslq -0x44(%rbp),%rcx
mov    %edx,(%rax,%rcx,4)
mov    -0x8d0(%rbp),%rax
movslq -0x44(%rbp),%rcx
mov    (%rax,%rcx,4),%edx
sub    -0x8e0(%rbp),%edx
add    $0x1,%edx
mov    -0x888(%rbp),%rax
movslq -0x44(%rbp),%rcx
mov    %edx,(%rax,%rcx,4)
mov    -0x878(%rbp),%rax
movslq -0x44(%rbp),%rcx
movl   $0x1,(%rax,%rcx,4)
mov    -0x8c8(%rbp),%rax
movslq -0x44(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
mov    -0x8b8(%rbp),%rax
movslq -0x44(%rbp),%rcx
mov    (%rax,%rcx,8),%rdi
mov    -0x8a8(%rbp),%rax
movslq -0x44(%rbp),%rcx
mov    (%rax,%rcx,8),%rsi
mov    $0x4,%edx
call   1030 <strncpy@plt>
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    1649 <main+0x469>
mov    -0x40(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x44(%rbp),%eax
mov    %eax,-0x4c(%rbp)
mov    -0x4c(%rbp),%esi
mov    -0x870(%rbp),%rdx
lea    0x965(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x8a8(%rbp),%rdi
mov    -0x8b0(%rbp),%rsi
mov    -0x8c8(%rbp),%rdx
mov    -0x8d0(%rbp),%rcx
mov    -0x8d8(%rbp),%r8
mov    -0x4c(%rbp),%r9d
call   10e0 <Indel_Process@plt>
mov    -0x50(%rbp),%eax
mov    %eax,-0x48(%rbp)
movl   $0x0,-0x50(%rbp)
mov    -0x870(%rbp),%rdi
lea    0x750(%rip),%rsi
call   10f0 <fopen@plt>
mov    %rax,-0x40(%rbp)
cmp    $0x0,%rax
jne    1910 <main+0x730>
mov    0x26e9(%rip),%rax
mov    (%rax),%edi
mov    -0x870(%rbp),%rdx
lea    0x8fb(%rip),%rsi
mov    $0x0,%al
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
jmp    1915 <main+0x735>
mov    -0x40(%rbp),%rdi
call   10c0 <feof@plt>
cmp    $0x0,%rax
setne  %al
xor    $0xff,%al
test   $0x1,%al
jne    1934 <main+0x754>
jmp    1999 <main+0x7b9>
lea    -0x820(%rbp),%rdi
mov    -0x40(%rbp),%rdx
mov    $0x7d0,%esi
call   1090 <fgets@plt>
mov    -0x40(%rbp),%rdi
call   10c0 <feof@plt>
cmp    $0x0,%rax
je     1961 <main+0x781>
jmp    1999 <main+0x7b9>
mov    -0x8c8(%rbp),%rax
movslq -0x50(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    198b <main+0x7ab>
lea    -0x820(%rbp),%rsi
lea    0x8bc(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    -0x50(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x50(%rbp)
jmp    1915 <main+0x735>
mov    -0x40(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x48(%rbp),%esi
lea    0x897(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    0x260e(%rip),%rax
mov    (%rax),%eax
add    $0x918,%rsp
pop    %rbx
pop    %r12
pop    %r13
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    $0x8a8,%rsp
mov    %rsi,%rbx
mov    %edi,%ebp
lea    0xd0(%rsp),%rdi
mov    $0x7d0,%edx
xor    %esi,%esi
call   1070 <memset@plt>
mov    0x2dbf(%rip),%rax
mov    (%rax),%edi
call   10d0 <fflush@plt>
cmp    $0x1,%ebp
jle    1656 <main+0x476>
mov    0x8(%rbx),%r15
lea    0xdf9(%rip),%rsi
mov    %r15,%rdi
call   10f0 <fopen@plt>
test   %rax,%rax
je     1671 <main+0x491>
mov    %rax,%rbx
mov    %rax,%rdi
call   10c0 <feof@plt>
xor    %r12d,%r12d
test   %rax,%rax
jne    128e <main+0xae>
xor    %r12d,%r12d
lea    0xd0(%rsp),%r14
nopl   0x0(%rax,%rax,1)
mov    %r14,%rdi
mov    $0x7d0,%esi
mov    %rbx,%rdx
call   1090 <fgets@plt>
mov    %rbx,%rdi
call   10c0 <feof@plt>
test   %rax,%rax
jne    128e <main+0xae>
add    $0x1,%r12d
mov    %rbx,%rdi
call   10c0 <feof@plt>
test   %rax,%rax
je     1260 <main+0x80>
mov    %rbx,%rdi
call   1040 <fclose@plt>
mov    %r12d,%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
test   %rax,%rax
je     1689 <main+0x4a9>
mov    %rax,%r14
mov    %r12d,%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,0x58(%rsp)
test   %rax,%rax
je     169e <main+0x4be>
mov    %r12d,%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,0x88(%rsp)
test   %rax,%rax
je     16b3 <main+0x4d3>
mov    %r12d,%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,0x40(%rsp)
test   %rax,%rax
je     16c5 <main+0x4e5>
mov    %r12d,%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,0x80(%rsp)
test   %rax,%rax
je     16d7 <main+0x4f7>
mov    %r12d,%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,0x78(%rsp)
test   %rax,%rax
je     16e9 <main+0x509>
mov    %r12d,%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,0x70(%rsp)
test   %rax,%rax
je     16fb <main+0x51b>
mov    %r12d,%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,0x68(%rsp)
test   %rax,%rax
je     170d <main+0x52d>
mov    %r12d,%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,0x38(%rsp)
test   %rax,%rax
je     171f <main+0x53f>
mov    %r12d,%edi
mov    $0x4,%esi
call   10a0 <calloc@plt>
mov    %rax,0x60(%rsp)
test   %rax,%rax
je     1731 <main+0x551>
lea    0xa(%r12),%ebx
xor    %edi,%edi
mov    %ebx,%esi
xor    %edx,%edx
mov    $0x64,%ecx
call   1050 <cmatrix@plt>
mov    %rax,0x30(%rsp)
xor    %edi,%edi
mov    %ebx,%esi
xor    %edx,%edx
mov    $0x64,%ecx
call   1050 <cmatrix@plt>
mov    %rax,%rbp
xor    %edi,%edi
mov    %ebx,%esi
xor    %edx,%edx
mov    $0x6,%ecx
call   1050 <cmatrix@plt>
mov    %rax,0x50(%rsp)
lea    0xdfb(%rip),%rdi
mov    %r12d,%esi
mov    %r15,%rdx
xor    %eax,%eax
call   1060 <printf@plt>
lea    0xc20(%rip),%rsi
mov    %r15,0x10(%rsp)
mov    %r15,%rdi
call   10f0 <fopen@plt>
mov    %rax,0x28(%rsp)
test   %rax,%rax
je     1752 <main+0x572>
xor    %eax,%eax
mov    %rax,0x8(%rsp)
mov    %r14,0x20(%rsp)
mov    %r12,0x48(%rsp)
xor    %ebx,%ebx
mov    %rbp,0x18(%rsp)
jmp    1482 <main+0x2a2>
nopw   0x0(%rax,%rax,1)
mov    0x58(%rsp),%rcx
mov    %eax,(%rcx,%rbx,1)
mov    0x20(%rsp),%rax
movl   $0x0,(%rax,%rbx,1)
mov    0x50(%rsp),%rax
mov    (%rax,%rbx,2),%rdi
mov    0x18(%rsp),%rbp
mov    0x0(%rbp,%rbx,2),%rsi
mov    $0x4,%edx
call   1030 <strncpy@plt>
mov    0x8(%rsp),%rax
add    $0x1,%eax
mov    %rax,0x8(%rsp)
add    $0x4,%rbx
mov    0x30(%rsp),%rax
mov    (%rax,%rbx,2),%r8
mov    0x0(%rbp,%rbx,2),%r9
mov    0x88(%rsp),%rax
lea    (%rax,%rbx,1),%r10
mov    0x40(%rsp),%rax
lea    (%rax,%rbx,1),%r11
mov    0x80(%rsp),%rax
lea    (%rax,%rbx,1),%r15
mov    0x78(%rsp),%rax
lea    (%rax,%rbx,1),%rbp
mov    0x70(%rsp),%rax
add    %rbx,%rax
mov    0x60(%rsp),%rcx
lea    (%rcx,%rbx,1),%r14
mov    0x68(%rsp),%rcx
lea    (%rcx,%rbx,1),%r13
mov    0x38(%rsp),%rcx
lea    (%rcx,%rbx,1),%r12
sub    $0x8,%rsp
mov    0x30(%rsp),%rdi
lea    0xd2c(%rip),%rsi
lea    0x98(%rsp),%rcx
mov    %rcx,%rdx
push   %r12
push   %r13
push   %r14
push   %rax
lea    0x2f(%rsp),%rax
push   %rax
push   %rbp
push   %r15
push   %r11
push   %r10
call   1080 <fscanf@plt>
add    $0x50,%rsp
mov    0x2acc(%rip),%rcx
cmp    (%rcx),%rax
je     1554 <main+0x374>
xor    %eax,%eax
cmpb   $0x46,0x7(%rsp)
je     1440 <main+0x260>
mov    (%r12),%eax
sub    (%r15),%eax
mov    0x0(%rbp),%ecx
add    $0x1,%eax
mov    %eax,(%r15)
mov    (%r12),%eax
sub    %ecx,%eax
add    $0x1,%eax
mov    %eax,0x0(%rbp)
mov    $0x1,%eax
jmp    1440 <main+0x260>
mov    0x28(%rsp),%rdi
call   1040 <fclose@plt>
lea    0xc87(%rip),%rdi
mov    0x8(%rsp),%rbp
mov    %ebp,%esi
mov    0x10(%rsp),%r14
mov    %r14,%rdx
xor    %eax,%eax
call   1060 <printf@plt>
mov    0x18(%rsp),%rdi
mov    0x30(%rsp),%rsi
mov    0x20(%rsp),%rbx
mov    %rbx,%rdx
mov    0x38(%rsp),%rcx
mov    0x40(%rsp),%r8
mov    %ebp,%r9d
call   10e0 <Indel_Process@plt>
lea    0xa7f(%rip),%rsi
mov    %r14,%rdi
call   10f0 <fopen@plt>
test   %rax,%rax
je     1769 <main+0x589>
mov    %rax,%rbp
mov    %rax,%rdi
call   10c0 <feof@plt>
test   %rax,%rax
je     15fd <main+0x41d>
mov    %rbp,%rdi
call   1040 <fclose@plt>
lea    0xc6d(%rip),%rdi
mov    0x48(%rsp),%rsi
xor    %eax,%eax
call   1060 <printf@plt>
mov    0x29df(%rip),%rax
mov    (%rax),%eax
add    $0x8a8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
lea    0xd0(%rsp),%r14
lea    0xc34(%rip),%r15
jmp    1621 <main+0x441>
xchg   %ax,%ax
mov    %rbp,%rdi
call   10c0 <feof@plt>
add    $0x4,%rbx
test   %rax,%rax
jne    15c7 <main+0x3e7>
mov    %r14,%rdi
mov    $0x7d0,%esi
mov    %rbp,%rdx
call   1090 <fgets@plt>
mov    %rbp,%rdi
call   10c0 <feof@plt>
test   %rax,%rax
jne    15c7 <main+0x3e7>
cmpl   $0x0,(%rbx)
jne    1610 <main+0x430>
mov    %r15,%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1060 <printf@plt>
jmp    1610 <main+0x430>
mov    (%rbx),%rsi
lea    0x9a0(%rip),%rdi
xor    %eax,%eax
call   1060 <printf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    0x2960(%rip),%rax
mov    (%rax),%edi
lea    0x9a6(%rip),%rsi
mov    %r15,%rdx
jmp    177c <main+0x59c>
mov    0x2948(%rip),%rax
mov    (%rax),%edi
lea    0x9a9(%rip),%rsi
jmp    1741 <main+0x561>
mov    0x2933(%rip),%rax
mov    (%rax),%edi
lea    0x9bd(%rip),%rsi
jmp    1741 <main+0x561>
mov    0x291e(%rip),%rax
mov    (%rax),%edi
lea    0x9d2(%rip),%rsi
jmp    1741 <main+0x561>
mov    0x290c(%rip),%rax
mov    (%rax),%edi
lea    0x9ea(%rip),%rsi
jmp    1741 <main+0x561>
mov    0x28fa(%rip),%rax
mov    (%rax),%edi
lea    0xa02(%rip),%rsi
jmp    1741 <main+0x561>
mov    0x28e8(%rip),%rax
mov    (%rax),%edi
lea    0xa1b(%rip),%rsi
jmp    1741 <main+0x561>
mov    0x28d6(%rip),%rax
mov    (%rax),%edi
lea    0xa34(%rip),%rsi
jmp    1741 <main+0x561>
mov    0x28c4(%rip),%rax
mov    (%rax),%edi
lea    0xa4d(%rip),%rsi
jmp    1741 <main+0x561>
mov    0x28b2(%rip),%rax
mov    (%rax),%edi
lea    0xa66(%rip),%rsi
jmp    1741 <main+0x561>
mov    0x28a0(%rip),%rax
mov    (%rax),%edi
lea    0xa80(%rip),%rsi
xor    %eax,%eax
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>
mov    0x287f(%rip),%rax
mov    (%rax),%edi
lea    0xa98(%rip),%rsi
mov    0x10(%rsp),%rdx
jmp    177c <main+0x59c>
mov    0x2868(%rip),%rax
mov    (%rax),%edi
lea    0xa81(%rip),%rsi
mov    %r14,%rdx
xor    %eax,%eax
call   10b0 <fprintf@plt>
mov    $0x1,%edi
call   1100 <exit@plt>

LLVM IR (-O0):
@stdout = global i32 0
@.str = [37 x i8] c"Usage: %s <cross_genome_ouput file>\0A\00"
@.str.1 = [2 x i8] c"r\00"
@stderr = global i32 0
@.str.2 = [27 x i8] c"ERROR: can't open file %s\0A\00"
@.str.3 = [41 x i8] c"Error: out of memory: calloc - hit_mask\0A\00"
@.str.4 = [42 x i8] c"Error: out of memory: calloc - hit_rcdex\0A\00"
@.str.5 = [42 x i8] c"Error: out of memory: calloc - hit_read1\0A\00"
@.str.6 = [42 x i8] c"Error: out of memory: calloc - hit_read2\0A\00"
@.str.7 = [43 x i8] c"Error: out of memory: calloc - hit_locus1\0A\00"
@.str.8 = [43 x i8] c"Error: out of memory: calloc - hit_locus2\0A\00"
@.str.9 = [43 x i8] c"Error: out of memory: calloc - hit_length\0A\00"
@.str.10 = [43 x i8] c"Error: out of memory: calloc - readlength\0A\00"
@.str.11 = [44 x i8] c"Error: out of memory: calloc - superlength\0A\00"
@.str.12 = [43 x i8] c"Error: out of memory: calloc - hit_identy\0A\00"
@.str.13 = [14 x i8] c"reads: %d %s\0A\00"
@.str.14 = [31 x i8] c"ERROR: unable to open file %s\0A\00"
@.str.15 = [39 x i8] c"%s %s %s %s %d %d %d %d %s %d %f %d %d\00"
@EOF = global i64 0
@.str.16 = [3 x i8] c"%s\00"
@.str.17 = [28 x i8] c"Job finished for %d reads!\0A\00"
@EXIT_SUCCESS = global i32 0
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 [2000 x i8]
%12 = alloca [60 x i8]
%13 = alloca [1 x i8]
%14 = alloca i8*
%15 = alloca i32*
%16 = alloca i32*
%17 = alloca i32*
%18 = alloca i32*
%19 = alloca i32*
%20 = alloca i32*
%21 = alloca i8**
%22 = alloca i8**
%23 = alloca i8**
%24 = alloca float*
%25 = alloca i32*
%26 = alloca i32*
%27 = alloca i32*
%28 = alloca i32
%29 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 0, i32* %8
store i32 0, i32* %10
%30 = bitcast [2000 x i8]* %11 to i8*
%31 = load i32, i32* @stdout
%32 = call i32 @fflush(i32 %31)
%33 = load i32, i32* %4
%34 = icmp slt i32 %33, 2
br i1 %34, label %35, label %41
35: ; preds = %2
%36 = load i8**, i8*** %5
%37 = getelementptr inbounds i8*, i8** %36, i64 0
%38 = load i8*, i8** %37
%39 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0), i8* %38)
%40 = call i32 @exit(i32 1)
unreachable
41: ; preds = %2
%42 = load i8**, i8*** %5
%43 = getelementptr inbounds i8*, i8** %42, i64 1
%44 = load i8*, i8** %43
store i8* %44, i8** %14
%45 = load i8*, i8** %14
%46 = call i32* @fopen(i8* %45, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %46, i32** %6
%47 = icmp eq i32* %46, null
br i1 %47, label %48, label %53
48: ; preds = %41
%49 = load i32, i32* @stderr
%50 = load i8*, i8** %14
%51 = call i32 (i32, i8*, ...) @fprintf(i32 %49, i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.2, i64 0, i64 0), i8* %50)
%52 = call i32 @exit(i32 1)
unreachable
53: ; preds = %41
br label %54
54: ; preds = %67, %53
%55 = load i32*, i32** %6
%56 = call i64 @feof(i32* %55)
%57 = icmp ne i64 %56, 0
%58 = xor i1 %57, true
br i1 %58, label %59, label %70
59: ; preds = %54
%60 = getelementptr inbounds [2000 x i8], [2000 x i8]* %11, i64 0, i64 0
%61 = load i32*, i32** %6
%62 = call i32 @fgets(i8* %60, i32 2000, i32* %61)
%63 = load i32*, i32** %6
%64 = call i64 @feof(i32* %63)
%65 = icmp ne i64 %64, 0
br i1 %65, label %66, label %67
66: ; preds = %59
br label %70
67: ; preds = %59
%68 = load i32, i32* %10
%69 = add nsw i32 %68, 1
store i32 %69, i32* %10
br label %54
70: ; preds = %66, %54
%71 = load i32*, i32** %6
%72 = call i32 @fclose(i32* %71)
%73 = load i32, i32* %10
%74 = call i64 @calloc(i32 %73, i32 4)
%75 = inttoptr i64 %74 to i32*
store i32* %75, i32** %25
%76 = icmp eq i32* %75, null
br i1 %76, label %77, label %81
77: ; preds = %70
%78 = load i32, i32* @stderr
%79 = call i32 (i32, i8*, ...) @fprintf(i32 %78, i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.3, i64 0, i64 0))
%80 = call i32 @exit(i32 1)
unreachable
81: ; preds = %70
%82 = load i32, i32* %10
%83 = call i64 @calloc(i32 %82, i32 4)
%84 = inttoptr i64 %83 to i32*
store i32* %84, i32** %15
%85 = icmp eq i32* %84, null
br i1 %85, label %86, label %90
86: ; preds = %81
%87 = load i32, i32* @stderr
%88 = call i32 (i32, i8*, ...) @fprintf(i32 %87, i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.4, i64 0, i64 0))
%89 = call i32 @exit(i32 1)
unreachable
90: ; preds = %81
%91 = load i32, i32* %10
%92 = call i64 @calloc(i32 %91, i32 4)
%93 = inttoptr i64 %92 to i32*
store i32* %93, i32** %19
%94 = icmp eq i32* %93, null
br i1 %94, label %95, label %99
95: ; preds = %90
%96 = load i32, i32* @stderr
%97 = call i32 (i32, i8*, ...) @fprintf(i32 %96, i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.5, i64 0, i64 0))
%98 = call i32 @exit(i32 1)
unreachable
99: ; preds = %90
%100 = load i32, i32* %10
%101 = call i64 @calloc(i32 %100, i32 4)
%102 = inttoptr i64 %101 to i32*
store i32* %102, i32** %27
%103 = icmp eq i32* %102, null
br i1 %103, label %104, label %108
104: ; preds = %99
%105 = load i32, i32* @stderr
%106 = call i32 (i32, i8*, ...) @fprintf(i32 %105, i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.6, i64 0, i64 0))
%107 = call i32 @exit(i32 1)
unreachable
108: ; preds = %99
%109 = load i32, i32* %10
%110 = call i64 @calloc(i32 %109, i32 4)
%111 = inttoptr i64 %110 to i32*
store i32* %111, i32** %16
%112 = icmp eq i32* %111, null
br i1 %112, label %113, label %117
113: ; preds = %108
%114 = load i32, i32* @stderr
%115 = call i32 (i32, i8*, ...) @fprintf(i32 %114, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.7, i64 0, i64 0))
%116 = call i32 @exit(i32 1)
unreachable
117: ; preds = %108
%118 = load i32, i32* %10
%119 = call i64 @calloc(i32 %118, i32 4)
%120 = inttoptr i64 %119 to i32*
store i32* %120, i32** %17
%121 = icmp eq i32* %120, null
br i1 %121, label %122, label %126
122: ; preds = %117
%123 = load i32, i32* @stderr
%124 = call i32 (i32, i8*, ...) @fprintf(i32 %123, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.8, i64 0, i64 0))
%125 = call i32 @exit(i32 1)
unreachable
126: ; preds = %117
%127 = load i32, i32* %10
%128 = call i64 @calloc(i32 %127, i32 4)
%129 = inttoptr i64 %128 to i32*
store i32* %129, i32** %20
%130 = icmp eq i32* %129, null
br i1 %130, label %131, label %135
131: ; preds = %126
%132 = load i32, i32* @stderr
%133 = call i32 (i32, i8*, ...) @fprintf(i32 %132, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.9, i64 0, i64 0))
%134 = call i32 @exit(i32 1)
unreachable
135: ; preds = %126
%136 = load i32, i32* %10
%137 = call i64 @calloc(i32 %136, i32 4)
%138 = inttoptr i64 %137 to i32*
store i32* %138, i32** %18
%139 = icmp eq i32* %138, null
br i1 %139, label %140, label %144
140: ; preds = %135
%141 = load i32, i32* @stderr
%142 = call i32 (i32, i8*, ...) @fprintf(i32 %141, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.10, i64 0, i64 0))
%143 = call i32 @exit(i32 1)
unreachable
144: ; preds = %135
%145 = load i32, i32* %10
%146 = call i64 @calloc(i32 %145, i32 4)
%147 = inttoptr i64 %146 to i32*
store i32* %147, i32** %26
%148 = icmp eq i32* %147, null
br i1 %148, label %149, label %153
149: ; preds = %144
%150 = load i32, i32* @stderr
%151 = call i32 (i32, i8*, ...) @fprintf(i32 %150, i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.11, i64 0, i64 0))
%152 = call i32 @exit(i32 1)
unreachable
153: ; preds = %144
%154 = load i32, i32* %10
%155 = call i64 @calloc(i32 %154, i32 4)
%156 = inttoptr i64 %155 to float*
store float* %156, float** %24
%157 = icmp eq float* %156, null
br i1 %157, label %158, label %162
158: ; preds = %153
%159 = load i32, i32* @stderr
%160 = call i32 (i32, i8*, ...) @fprintf(i32 %159, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.12, i64 0, i64 0))
%161 = call i32 @exit(i32 1)
unreachable
162: ; preds = %153
%163 = load i32, i32* %10
%164 = add nsw i32 %163, 10
%165 = call i8** @cmatrix(i32 0, i32 %164, i32 0, i32 100)
store i8** %165, i8*** %22
%166 = load i32, i32* %10
%167 = add nsw i32 %166, 10
%168 = call i8** @cmatrix(i32 0, i32 %167, i32 0, i32 100)
store i8** %168, i8*** %21
%169 = load i32, i32* %10
%170 = add nsw i32 %169, 10
%171 = call i8** @cmatrix(i32 0, i32 %170, i32 0, i32 6)
store i8** %171, i8*** %23
%172 = load i32, i32* %10
%173 = load i8*, i8** %14
%174 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.13, i64 0, i64 0), i32 %172, i8* %173)
%175 = load i8*, i8** %14
%176 = call i32* @fopen(i8* %175, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %176, i32** %6
%177 = icmp eq i32* %176, null
br i1 %177, label %178, label %183
178: ; preds = %162
%179 = load i32, i32* @stderr
%180 = load i8*, i8** %14
%181 = call i32 (i32, i8*, ...) @fprintf(i32 %179, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.14, i64 0, i64 0), i8* %180)
%182 = call i32 @exit(i32 1)
unreachable
183: ; preds = %162
store i32 0, i32* %7
br label %184
184: ; preds = %283, %183
%185 = load i32*, i32** %6
%186 = getelementptr inbounds [60 x i8], [60 x i8]* %12, i64 0, i64 0
%187 = getelementptr inbounds [60 x i8], [60 x i8]* %12, i64 0, i64 0
%188 = load i8**, i8*** %22
%189 = load i32, i32* %7
%190 = sext i32 %189 to i64
%191 = getelementptr inbounds i8*, i8** %188, i64 %190
%192 = load i8*, i8** %191
%193 = load i8**, i8*** %21
%194 = load i32, i32* %7
%195 = sext i32 %194 to i64
%196 = getelementptr inbounds i8*, i8** %193, i64 %195
%197 = load i8*, i8** %196
%198 = load i32*, i32** %19
%199 = load i32, i32* %7
%200 = sext i32 %199 to i64
%201 = getelementptr inbounds i32, i32* %198, i64 %200
%202 = load i32*, i32** %27
%203 = load i32, i32* %7
%204 = sext i32 %203 to i64
%205 = getelementptr inbounds i32, i32* %202, i64 %204
%206 = load i32*, i32** %16
%207 = load i32, i32* %7
%208 = sext i32 %207 to i64
%209 = getelementptr inbounds i32, i32* %206, i64 %208
%210 = load i32*, i32** %17
%211 = load i32, i32* %7
%212 = sext i32 %211 to i64
%213 = getelementptr inbounds i32, i32* %210, i64 %212
%214 = getelementptr inbounds [1 x i8], [1 x i8]* %13, i64 0, i64 0
%215 = load i32*, i32** %20
%216 = load i32, i32* %7
%217 = sext i32 %216 to i64
%218 = getelementptr inbounds i32, i32* %215, i64 %217
%219 = load float*, float** %24
%220 = load i32, i32* %7
%221 = sext i32 %220 to i64
%222 = getelementptr inbounds float, float* %219, i64 %221
%223 = load i32*, i32** %18
%224 = load i32, i32* %7
%225 = sext i32 %224 to i64
%226 = getelementptr inbounds i32, i32* %223, i64 %225
%227 = load i32*, i32** %26
%228 = load i32, i32* %7
%229 = sext i32 %228 to i64
%230 = getelementptr inbounds i32, i32* %227, i64 %229
%231 = call i64 @fscanf(i32* %185, i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.15, i64 0, i64 0), i8* %186, i8* %187, i8* %192, i8* %197, i32* %201, i32* %205, i32* %209, i32* %213, i8* %214, i32* %218, float* %222, i32* %226, i32* %230)
%232 = load i64, i64* @EOF
%233 = icmp ne i64 %231, %232
br i1 %233, label %234, label %301
234: ; preds = %184
%235 = getelementptr inbounds [1 x i8], [1 x i8]* %13, i64 0, i64 0
%236 = load i8, i8* %235
%237 = sext i8 %236 to i32
%238 = icmp eq i32 %237, 70
br i1 %238, label %239, label %244
239: ; preds = %234
%240 = load i32*, i32** %15
%241 = load i32, i32* %7
%242 = sext i32 %241 to i64
%243 = getelementptr inbounds i32, i32* %240, i64 %242
store i32 0, i32* %243
br label %283
244: ; preds = %234
%245 = load i32*, i32** %16
%246 = load i32, i32* %7
%247 = sext i32 %246 to i64
%248 = getelementptr inbounds i32, i32* %245, i64 %247
%249 = load i32, i32* %248
store i32 %249, i32* %28
%250 = load i32*, i32** %17
%251 = load i32, i32* %7
%252 = sext i32 %251 to i64
%253 = getelementptr inbounds i32, i32* %250, i64 %252
%254 = load i32, i32* %253
store i32 %254, i32* %29
%255 = load i32*, i32** %26
%256 = load i32, i32* %7
%257 = sext i32 %256 to i64
%258 = getelementptr inbounds i32, i32* %255, i64 %257
%259 = load i32, i32* %258
%260 = load i32, i32* %28
%261 = sub nsw i32 %259, %260
%262 = add nsw i32 %261, 1
%263 = load i32*, i32** %16
%264 = load i32, i32* %7
%265 = sext i32 %264 to i64
%266 = getelementptr inbounds i32, i32* %263, i64 %265
store i32 %262, i32* %266
%267 = load i32*, i32** %26
%268 = load i32, i32* %7
%269 = sext i32 %268 to i64
%270 = getelementptr inbounds i32, i32* %267, i64 %269
%271 = load i32, i32* %270
%272 = load i32, i32* %29
%273 = sub nsw i32 %271, %272
%274 = add nsw i32 %273, 1
%275 = load i32*, i32** %17
%276 = load i32, i32* %7
%277 = sext i32 %276 to i64
%278 = getelementptr inbounds i32, i32* %275, i64 %277
store i32 %274, i32* %278
%279 = load i32*, i32** %15
%280 = load i32, i32* %7
%281 = sext i32 %280 to i64
%282 = getelementptr inbounds i32, i32* %279, i64 %281
store i32 1, i32* %282
br label %283
283: ; preds = %244, %239
%284 = load i32*, i32** %25
%285 = load i32, i32* %7
%286 = sext i32 %285 to i64
%287 = getelementptr inbounds i32, i32* %284, i64 %286
store i32 0, i32* %287
%288 = load i8**, i8*** %23
%289 = load i32, i32* %7
%290 = sext i32 %289 to i64
%291 = getelementptr inbounds i8*, i8** %288, i64 %290
%292 = load i8*, i8** %291
%293 = load i8**, i8*** %21
%294 = load i32, i32* %7
%295 = sext i32 %294 to i64
%296 = getelementptr inbounds i8*, i8** %293, i64 %295
%297 = load i8*, i8** %296
%298 = call i32 @strncpy(i8* %292, i8* %297, i32 4)
%299 = load i32, i32* %7
%300 = add nsw i32 %299, 1
store i32 %300, i32* %7
br label %184
301: ; preds = %184
%302 = load i32*, i32** %6
%303 = call i32 @fclose(i32* %302)
%304 = load i32, i32* %7
store i32 %304, i32* %9
%305 = load i32, i32* %9
%306 = load i8*, i8** %14
%307 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.13, i64 0, i64 0), i32 %305, i8* %306)
%308 = load i8**, i8*** %21
%309 = load i8**, i8*** %22
%310 = load i32*, i32** %25
%311 = load i32*, i32** %26
%312 = load i32*, i32** %27
%313 = load i32, i32* %9
%314 = call i32 @Indel_Process(i8** %308, i8** %309, i32* %310, i32* %311, i32* %312, i32 %313)
%315 = load i32, i32* %10
store i32 %315, i32* %8
store i32 0, i32* %10
%316 = load i8*, i8** %14
%317 = call i32* @fopen(i8* %316, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %317, i32** %6
%318 = icmp eq i32* %317, null
br i1 %318, label %319, label %324
319: ; preds = %301
%320 = load i32, i32* @stderr
%321 = load i8*, i8** %14
%322 = call i32 (i32, i8*, ...) @fprintf(i32 %320, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.14, i64 0, i64 0), i8* %321)
%323 = call i32 @exit(i32 1)
unreachable
324: ; preds = %301
br label %325
325: ; preds = %348, %324
%326 = load i32*, i32** %6
%327 = call i64 @feof(i32* %326)
%328 = icmp ne i64 %327, 0
%329 = xor i1 %328, true
br i1 %329, label %330, label %351
330: ; preds = %325
%331 = getelementptr inbounds [2000 x i8], [2000 x i8]* %11, i64 0, i64 0
%332 = load i32*, i32** %6
%333 = call i32 @fgets(i8* %331, i32 2000, i32* %332)
%334 = load i32*, i32** %6
%335 = call i64 @feof(i32* %334)
%336 = icmp ne i64 %335, 0
br i1 %336, label %337, label %338
337: ; preds = %330
br label %351
338: ; preds = %330
%339 = load i32*, i32** %25
%340 = load i32, i32* %10
%341 = sext i32 %340 to i64
%342 = getelementptr inbounds i32, i32* %339, i64 %341
%343 = load i32, i32* %342
%344 = icmp eq i32 %343, 0
br i1 %344, label %345, label %348
345: ; preds = %338
%346 = getelementptr inbounds [2000 x i8], [2000 x i8]* %11, i64 0, i64 0
%347 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.16, i64 0, i64 0), i8* %346)
br label %348
348: ; preds = %345, %338
%349 = load i32, i32* %10
%350 = add nsw i32 %349, 1
store i32 %350, i32* %10
br label %325
351: ; preds = %337, %325
%352 = load i32*, i32** %6
%353 = call i32 @fclose(i32* %352)
%354 = load i32, i32* %8
%355 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.17, i64 0, i64 0), i32 %354)
%356 = load i32, i32* @EXIT_SUCCESS
ret i32 %356
}

LLVM IR (-O2):
@stdout = global i32 0
@.str = [37 x i8] c"Usage: %s <cross_genome_ouput file>\0A\00"
@.str.1 = [2 x i8] c"r\00"
@stderr = global i32 0
@.str.2 = [27 x i8] c"ERROR: can't open file %s\0A\00"
@.str.3 = [41 x i8] c"Error: out of memory: calloc - hit_mask\0A\00"
@.str.4 = [42 x i8] c"Error: out of memory: calloc - hit_rcdex\0A\00"
@.str.5 = [42 x i8] c"Error: out of memory: calloc - hit_read1\0A\00"
@.str.6 = [42 x i8] c"Error: out of memory: calloc - hit_read2\0A\00"
@.str.7 = [43 x i8] c"Error: out of memory: calloc - hit_locus1\0A\00"
@.str.8 = [43 x i8] c"Error: out of memory: calloc - hit_locus2\0A\00"
@.str.9 = [43 x i8] c"Error: out of memory: calloc - hit_length\0A\00"
@.str.10 = [43 x i8] c"Error: out of memory: calloc - readlength\0A\00"
@.str.11 = [44 x i8] c"Error: out of memory: calloc - superlength\0A\00"
@.str.12 = [43 x i8] c"Error: out of memory: calloc - hit_identy\0A\00"
@.str.13 = [14 x i8] c"reads: %d %s\0A\00"
@.str.14 = [31 x i8] c"ERROR: unable to open file %s\0A\00"
@.str.15 = [39 x i8] c"%s %s %s %s %d %d %d %d %s %d %f %d %d\00"
@EOF = global i64 0
@.str.16 = [3 x i8] c"%s\00"
@.str.17 = [28 x i8] c"Job finished for %d reads!\0A\00"
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = alloca [2000 x i8]
%4 = alloca [60 x i8]
%5 = alloca [1 x i8]
%6 = getelementptr inbounds [2000 x i8], [2000 x i8]* %3, i64 0, i64 0
%7 = getelementptr inbounds [60 x i8], [60 x i8]* %4, i64 0, i64 0
%8 = getelementptr inbounds [1 x i8], [1 x i8]* %5, i64 0, i64 0
%9 = load i32, i32* @stdout
%10 = tail call i32 @fflush(i32 %9)
%11 = icmp slt i32 %0, 2
br i1 %11, label %12, label %16
12: ; preds = %2
%13 = load i8*, i8** %1
%14 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0), i8* %13)
%15 = tail call i32 @exit(i32 1)
unreachable
16: ; preds = %2
%17 = getelementptr inbounds i8*, i8** %1, i64 1
%18 = load i8*, i8** %17
%19 = tail call i32* @fopen(i8* %18, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%20 = icmp eq i32* %19, null
br i1 %20, label %24, label %21
21: ; preds = %16
%22 = call i64 @feof(i32* %19)
%23 = icmp eq i64 %22, 0
br i1 %23, label %28, label %37
24: ; preds = %16
%25 = load i32, i32* @stderr
%26 = tail call i32 (i32, i8*, ...) @fprintf(i32 %25, i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.2, i64 0, i64 0), i8* %18)
%27 = tail call i32 @exit(i32 1)
unreachable
28: ; preds = %21, %33
%29 = phi i32 [ %34, %33 ], [ 0, %21 ]
%30 = call i32 @fgets(i8* %6, i32 2000, i32* %19)
%31 = call i64 @feof(i32* %19)
%32 = icmp eq i64 %31, 0
br i1 %32, label %33, label %37
33: ; preds = %28
%34 = add nuw nsw i32 %29, 1
%35 = call i64 @feof(i32* %19)
%36 = icmp eq i64 %35, 0
br i1 %36, label %28, label %37
37: ; preds = %33, %28, %21
%38 = phi i32 [ 0, %21 ], [ %29, %28 ], [ %34, %33 ]
%39 = call i32 @fclose(i32* %19)
%40 = call i64 @calloc(i32 %38, i32 4)
%41 = inttoptr i64 %40 to i32*
%42 = icmp eq i64 %40, 0
br i1 %42, label %43, label %47
43: ; preds = %37
%44 = load i32, i32* @stderr
%45 = call i32 (i32, i8*, ...) @fprintf(i32 %44, i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.3, i64 0, i64 0))
%46 = call i32 @exit(i32 1)
unreachable
47: ; preds = %37
%48 = call i64 @calloc(i32 %38, i32 4)
%49 = inttoptr i64 %48 to i32*
%50 = icmp eq i64 %48, 0
br i1 %50, label %51, label %55
51: ; preds = %47
%52 = load i32, i32* @stderr
%53 = call i32 (i32, i8*, ...) @fprintf(i32 %52, i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.4, i64 0, i64 0))
%54 = call i32 @exit(i32 1)
unreachable
55: ; preds = %47
%56 = call i64 @calloc(i32 %38, i32 4)
%57 = inttoptr i64 %56 to i32*
%58 = icmp eq i64 %56, 0
br i1 %58, label %59, label %63
59: ; preds = %55
%60 = load i32, i32* @stderr
%61 = call i32 (i32, i8*, ...) @fprintf(i32 %60, i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.5, i64 0, i64 0))
%62 = call i32 @exit(i32 1)
unreachable
63: ; preds = %55
%64 = call i64 @calloc(i32 %38, i32 4)
%65 = inttoptr i64 %64 to i32*
%66 = icmp eq i64 %64, 0
br i1 %66, label %67, label %71
67: ; preds = %63
%68 = load i32, i32* @stderr
%69 = call i32 (i32, i8*, ...) @fprintf(i32 %68, i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.6, i64 0, i64 0))
%70 = call i32 @exit(i32 1)
unreachable
71: ; preds = %63
%72 = call i64 @calloc(i32 %38, i32 4)
%73 = inttoptr i64 %72 to i32*
%74 = icmp eq i64 %72, 0
br i1 %74, label %75, label %79
75: ; preds = %71
%76 = load i32, i32* @stderr
%77 = call i32 (i32, i8*, ...) @fprintf(i32 %76, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.7, i64 0, i64 0))
%78 = call i32 @exit(i32 1)
unreachable
79: ; preds = %71
%80 = call i64 @calloc(i32 %38, i32 4)
%81 = inttoptr i64 %80 to i32*
%82 = icmp eq i64 %80, 0
br i1 %82, label %83, label %87
83: ; preds = %79
%84 = load i32, i32* @stderr
%85 = call i32 (i32, i8*, ...) @fprintf(i32 %84, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.8, i64 0, i64 0))
%86 = call i32 @exit(i32 1)
unreachable
87: ; preds = %79
%88 = call i64 @calloc(i32 %38, i32 4)
%89 = inttoptr i64 %88 to i32*
%90 = icmp eq i64 %88, 0
br i1 %90, label %91, label %95
91: ; preds = %87
%92 = load i32, i32* @stderr
%93 = call i32 (i32, i8*, ...) @fprintf(i32 %92, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.9, i64 0, i64 0))
%94 = call i32 @exit(i32 1)
unreachable
95: ; preds = %87
%96 = call i64 @calloc(i32 %38, i32 4)
%97 = inttoptr i64 %96 to i32*
%98 = icmp eq i64 %96, 0
br i1 %98, label %99, label %103
99: ; preds = %95
%100 = load i32, i32* @stderr
%101 = call i32 (i32, i8*, ...) @fprintf(i32 %100, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.10, i64 0, i64 0))
%102 = call i32 @exit(i32 1)
unreachable
103: ; preds = %95
%104 = call i64 @calloc(i32 %38, i32 4)
%105 = inttoptr i64 %104 to i32*
%106 = icmp eq i64 %104, 0
br i1 %106, label %107, label %111
107: ; preds = %103
%108 = load i32, i32* @stderr
%109 = call i32 (i32, i8*, ...) @fprintf(i32 %108, i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.11, i64 0, i64 0))
%110 = call i32 @exit(i32 1)
unreachable
111: ; preds = %103
%112 = call i64 @calloc(i32 %38, i32 4)
%113 = inttoptr i64 %112 to float*
%114 = icmp eq i64 %112, 0
br i1 %114, label %115, label %119
115: ; preds = %111
%116 = load i32, i32* @stderr
%117 = call i32 (i32, i8*, ...) @fprintf(i32 %116, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.12, i64 0, i64 0))
%118 = call i32 @exit(i32 1)
unreachable
119: ; preds = %111
%120 = add nuw nsw i32 %38, 10
%121 = call i8** @cmatrix(i32 0, i32 %120, i32 0, i32 100)
%122 = call i8** @cmatrix(i32 0, i32 %120, i32 0, i32 100)
%123 = call i8** @cmatrix(i32 0, i32 %120, i32 0, i32 6)
%124 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str.13, i64 0, i64 0), i32 %38, i8* %18)
%125 = call i32* @fopen(i8* %18, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%126 = icmp eq i32* %125, null
br i1 %126, label %127, label %131
127: ; preds = %119
%128 = load i32, i32* @stderr
%129 = call i32 (i32, i8*, ...) @fprintf(i32 %128, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.14, i64 0, i64 0), i8* %18)
%130 = call i32 @exit(i32 1)
unreachable
131: ; preds = %119, %160
%132 = phi i64 [ %168, %160 ], [ 0, %119 ]
%133 = getelementptr inbounds i8*, i8** %121, i64 %132
%134 = load i8*, i8** %133
%135 = getelementptr inbounds i8*, i8** %122, i64 %132
%136 = load i8*, i8** %135
%137 = getelementptr inbounds i32, i32* %57, i64 %132
%138 = getelementptr inbounds i32, i32* %65, i64 %132
%139 = getelementptr inbounds i32, i32* %73, i64 %132
%140 = getelementptr inbounds i32, i32* %81, i64 %132
%141 = getelementptr inbounds i32, i32* %89, i64 %132
%142 = getelementptr inbounds float, float* %113, i64 %132
%143 = getelementptr inbounds i32, i32* %97, i64 %132
%144 = getelementptr inbounds i32, i32* %105, i64 %132
%145 = call i64 @fscanf(i32* %125, i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.15, i64 0, i64 0), i8* %7, i8* %7, i8* %134, i8* %136, i32* %137, i32* %138, i32* %139, i32* %140, i8* %8, i32* %141, float* %142, i32* %143, i32* %144)
%146 = load i64, i64* @EOF
%147 = icmp eq i64 %145, %146
br i1 %147, label %169, label %148
148: ; preds = %131
%149 = load i8, i8* %8
%150 = icmp eq i8 %149, 70
br i1 %150, label %160, label %151
151: ; preds = %148
%152 = load i32, i32* %139
%153 = load i32, i32* %140
%154 = load i32, i32* %144
%155 = sub i32 1, %152
%156 = add i32 %155, %154
store i32 %156, i32* %139
%157 = load i32, i32* %144
%158 = sub i32 1, %153
%159 = add i32 %158, %157
store i32 %159, i32* %140
br label %160
160: ; preds = %148, %151
%161 = phi i32 [ 1, %151 ], [ 0, %148 ]
%162 = getelementptr inbounds i32, i32* %49, i64 %132
store i32 %161, i32* %162
%163 = getelementptr inbounds i32, i32* %41, i64 %132
store i32 0, i32* %163
%164 = getelementptr inbounds i8*, i8** %123, i64 %132
%165 = load i8*, i8** %164
%166 = load i8*, i8** %135
%167 = call i32 @strncpy(i8* %165, i8* %166, i32 4)
%168 = add nuw i64 %132, 1
br label %131
169: ; preds = %131
%170 = trunc i64 %132 to i32
%171 = call i32 @fclose(i32* %125)
%172 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str.13, i64 0, i64 0), i32 %170, i8* %18)
%173 = call i32 @Indel_Process(i8** %122, i8** %121, i32* %41, i32* %105, i32* %65, i32 %170)
%174 = call i32* @fopen(i8* %18, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%175 = icmp eq i32* %174, null
br i1 %175, label %179, label %176
176: ; preds = %169
%177 = call i64 @feof(i32* %174)
%178 = icmp eq i64 %177, 0
br i1 %178, label %183, label %198
179: ; preds = %169
%180 = load i32, i32* @stderr
%181 = call i32 (i32, i8*, ...) @fprintf(i32 %180, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.14, i64 0, i64 0), i8* %18)
%182 = call i32 @exit(i32 1)
unreachable
183: ; preds = %176, %194
%184 = phi i64 [ %195, %194 ], [ 0, %176 ]
%185 = call i32 @fgets(i8* %6, i32 2000, i32* %174)
%186 = call i64 @feof(i32* %174)
%187 = icmp eq i64 %186, 0
br i1 %187, label %188, label %198
188: ; preds = %183
%189 = getelementptr inbounds i32, i32* %41, i64 %184
%190 = load i32, i32* %189
%191 = icmp eq i32 %190, 0
br i1 %191, label %192, label %194
192: ; preds = %188
%193 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @.str.16, i64 0, i64 0), i8* %6)
br label %194
194: ; preds = %192, %188
%195 = add nuw i64 %184, 1
%196 = call i64 @feof(i32* %174)
%197 = icmp eq i64 %196, 0
br i1 %197, label %183, label %198
198: ; preds = %194, %183, %176
%199 = call i32 @fclose(i32* %174)
%200 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([28 x i8], [28 x i8]* @.str.17, i64 0, i64 0), i32 %38)
%201 = load i32, i32* @EXIT_SUCCESS
ret i32 %201
}