#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 ssize_t;
typedef int /*<<< orphan*/ fpos_t;
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int EXIT_FAILURE;
int EXIT_SUCCESS;
double fabs(double);
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
int /*<<< orphan*/ fgetpos(int /*<<< orphan*/ *, int /*<<< orphan*/ *);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, ...);
int /*<<< orphan*/ free(char *);
int fscanf(int /*<<< orphan*/ *, char *, double *, double *, ...);
int /*<<< orphan*/ fsetpos(int /*<<< orphan*/ *, int /*<<< orphan*/ *);
int getline(char **, size_t *, int /*<<< orphan*/ *);
int /*<<< orphan*/ rewind(int /*<<< orphan*/ *);
int /*<<< orphan*/ stdout;
int main(int argc, char **argv) {
  FILE *node1, *node2, *reference;
  char *line;
  size_t len;
  ssize_t read;
  fpos_t start_node1, start_node2;
  int counter, counter1, counter2, counter3;
  double time1, time2, time3, temp1, temp2, temp3, temp4;
  double tmp, max_node1, max_node2, time_node1, time_node2;
  if (argc != 4) {
    fprintf(stdout, "Usage: \"%s node1.txt node2.txt reference.txt\"\n",
            argv[0]);
    return EXIT_FAILURE;
  }
  node1 = fopen(argv[1], "r");
  if (node1 == NULL) {
    fprintf(stdout, "Unable to open file %s\n", argv[1]);
    return EXIT_FAILURE;
  }
  for (line = NULL, len = 0, counter = 0; counter != 3; counter++)
    read = getline(&line, &len, node1);
  free(line);
  fgetpos(node1, &start_node1);
  node2 = fopen(argv[2], "r");
  if (node2 == NULL) {
    fprintf(stdout, "Unable to open file %s\n", argv[2]);
    fclose(node1);
    return EXIT_FAILURE;
  }
  for (line = NULL, len = 0, counter = 0; counter != 3; counter++)
    read = getline(&line, &len, node2);
  free(line);
  fgetpos(node2, &start_node2);
  reference = fopen(argv[3], "r");
  if (reference == NULL) {
    fprintf(stdout, "Unable to open file %s\n", argv[3]);
    fclose(node1);
    fclose(node2);
    return EXIT_FAILURE;
  }
  fsetpos(node1, &start_node1);
  for (line = NULL, len = 0, counter1 = 0;
       (read = getline(&line, &len, node1)) != -1; counter1++)
    ;
  free(line);
  fsetpos(node1, &start_node1);
  fsetpos(node2, &start_node2);
  for (line = NULL, len = 0, counter2 = 0;
       (read = getline(&line, &len, node2)) != -1; counter2++)
    ;
  free(line);
  fsetpos(node2, &start_node2);
  for (line = NULL, len = 0, counter3 = 0;
       (read = getline(&line, &len, reference)) != -1; counter3++)
    ;
  free(line);
  rewind(reference);
  if (counter1 != counter2 || counter2 != counter3) {
    fprintf(stdout, "Files %s:%d, %s:%d and %s:%d have different # lines\n",
            argv[1], counter1, argv[2], counter2, argv[3], counter3);
    goto error;
  }
  max_node1 = 0.0;
  max_node2 = 0.0;
  time_node1 = 0.0;
  time_node2 = 0.0;
  for (counter = 0; counter != counter1; counter++) {
    if (fscanf(node1, "%lf %lf\n", &time1, &temp1) != 2) {
      fprintf(stdout, "Error reading line %d from %s\n", counter + 1, argv[1]);
      break;
    }
    if (fscanf(node2, "%lf %lf\n", &time2, &temp2) != 2) {
      fprintf(stdout, "Error reading line %d from %s\n", counter + 1, argv[2]);
      break;
    }
    if (fscanf(reference, "%lf %lf %lf\n", &time3, &temp3, &temp4) != 3) {
      fprintf(stdout, "Error reading line %d from %s\n", counter + 1, argv[3]);
      break;
    }
    if (time1 != time2 || time2 != time3) {
      fprintf(stdout, "Time mismatch at line %d (%.3f %.3f %.3f)\n",
              counter + 1, time1, time2, time3);
      break;
    }
    tmp = fabs(temp1 - temp3);
    if (tmp > max_node1) {
      max_node1 = tmp;
      time_node1 = time1;
    }
    tmp = fabs(temp2 - temp4);
    if (tmp > max_node2) {
      max_node2 = tmp;
      time_node2 = time1;
    }
  }
  if (counter == counter1)
    fprintf(stdout, "%.3f (@%.3f) \t%.3f (@%.3f)\n", max_node1, time_node1,
            max_node2, time_node2);
  fclose(node1);
  fclose(node2);
  fclose(reference);
  return EXIT_SUCCESS;
error:
  fclose(node1);
  fclose(node2);
  fclose(reference);
  return EXIT_FAILURE;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0xd0,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x4,-0x8(%rbp)
je     11e2 <main+0x52>
mov    0x2e1e(%rip),%rax
mov    (%rax),%edi
mov    -0x10(%rbp),%rax
mov    (%rax),%rdx
lea    0xe46(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
mov    0x2e08(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
jmp    1814 <main+0x684>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xe4e(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,-0x18(%rbp)
cmpq   $0x0,-0x18(%rbp)
jne    1235 <main+0xa5>
mov    0x2dcc(%rip),%rax
mov    (%rax),%edi
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdx
lea    0xe24(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
mov    0x2db5(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
jmp    1814 <main+0x684>
movq   $0x0,-0x30(%rbp)
movq   $0x0,-0x38(%rbp)
movl   $0x0,-0x48(%rbp)
cmpl   $0x3,-0x48(%rbp)
je     1278 <main+0xe8>
mov    -0x18(%rbp),%rdx
lea    -0x30(%rbp),%rdi
lea    -0x38(%rbp),%rsi
call   10b0 <getline@plt>
mov    %eax,-0x3c(%rbp)
mov    -0x48(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x48(%rbp)
jmp    124c <main+0xbc>
mov    -0x30(%rbp),%rdi
call   1030 <free@plt>
mov    -0x18(%rbp),%rdi
lea    -0x40(%rbp),%rsi
call   1050 <fgetpos@plt>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
lea    0xda2(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,-0x20(%rbp)
cmpq   $0x0,-0x20(%rbp)
jne    12ea <main+0x15a>
mov    0x2d20(%rip),%rax
mov    (%rax),%edi
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdx
lea    0xd78(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
mov    -0x18(%rbp),%rdi
call   1040 <fclose@plt>
mov    0x2d00(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
jmp    1814 <main+0x684>
movq   $0x0,-0x30(%rbp)
movq   $0x0,-0x38(%rbp)
movl   $0x0,-0x48(%rbp)
cmpl   $0x3,-0x48(%rbp)
je     132d <main+0x19d>
mov    -0x20(%rbp),%rdx
lea    -0x30(%rbp),%rdi
lea    -0x38(%rbp),%rsi
call   10b0 <getline@plt>
mov    %eax,-0x3c(%rbp)
mov    -0x48(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x48(%rbp)
jmp    1301 <main+0x171>
mov    -0x30(%rbp),%rdi
call   1030 <free@plt>
mov    -0x20(%rbp),%rdi
lea    -0x44(%rbp),%rsi
call   1050 <fgetpos@plt>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rdi
lea    0xced(%rip),%rsi
call   1090 <fopen@plt>
mov    %rax,-0x28(%rbp)
cmpq   $0x0,-0x28(%rbp)
jne    13a8 <main+0x218>
mov    0x2c6b(%rip),%rax
mov    (%rax),%edi
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rdx
lea    0xcc3(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
mov    -0x18(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x20(%rbp),%rdi
call   1040 <fclose@plt>
mov    0x2c42(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
jmp    1814 <main+0x684>
mov    -0x18(%rbp),%rdi
lea    -0x40(%rbp),%rsi
call   10a0 <fsetpos@plt>
movq   $0x0,-0x30(%rbp)
movq   $0x0,-0x38(%rbp)
movl   $0x0,-0x4c(%rbp)
mov    -0x18(%rbp),%rdx
lea    -0x30(%rbp),%rdi
lea    -0x38(%rbp),%rsi
call   10b0 <getline@plt>
mov    %eax,-0x3c(%rbp)
cmp    $0xffffffff,%eax
je     13fc <main+0x26c>
jmp    13ee <main+0x25e>
mov    -0x4c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4c(%rbp)
jmp    13cc <main+0x23c>
mov    -0x30(%rbp),%rdi
call   1030 <free@plt>
mov    -0x18(%rbp),%rdi
lea    -0x40(%rbp),%rsi
call   10a0 <fsetpos@plt>
mov    -0x20(%rbp),%rdi
lea    -0x44(%rbp),%rsi
call   10a0 <fsetpos@plt>
movq   $0x0,-0x30(%rbp)
movq   $0x0,-0x38(%rbp)
movl   $0x0,-0x50(%rbp)
mov    -0x20(%rbp),%rdx
lea    -0x30(%rbp),%rdi
lea    -0x38(%rbp),%rsi
call   10b0 <getline@plt>
mov    %eax,-0x3c(%rbp)
cmp    $0xffffffff,%eax
je     1466 <main+0x2d6>
jmp    1458 <main+0x2c8>
mov    -0x50(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x50(%rbp)
jmp    1436 <main+0x2a6>
mov    -0x30(%rbp),%rdi
call   1030 <free@plt>
mov    -0x20(%rbp),%rdi
lea    -0x44(%rbp),%rsi
call   10a0 <fsetpos@plt>
movq   $0x0,-0x30(%rbp)
movq   $0x0,-0x38(%rbp)
movl   $0x0,-0x54(%rbp)
mov    -0x28(%rbp),%rdx
lea    -0x30(%rbp),%rdi
lea    -0x38(%rbp),%rsi
call   10b0 <getline@plt>
mov    %eax,-0x3c(%rbp)
cmp    $0xffffffff,%eax
je     14c3 <main+0x333>
jmp    14b5 <main+0x325>
mov    -0x54(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x54(%rbp)
jmp    1493 <main+0x303>
mov    -0x30(%rbp),%rdi
call   1030 <free@plt>
mov    -0x28(%rbp),%rdi
call   1060 <rewind@plt>
mov    -0x4c(%rbp),%eax
cmp    -0x50(%rbp),%eax
jne    14ed <main+0x35d>
mov    -0x50(%rbp),%eax
cmp    -0x54(%rbp),%eax
je     1533 <main+0x3a3>
mov    0x2ae4(%rip),%rax
mov    (%rax),%edi
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdx
mov    -0x4c(%rbp),%ecx
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%r8
mov    -0x50(%rbp),%r9d
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%r10
mov    -0x54(%rbp),%eax
lea    0xb3a(%rip),%rsi
mov    %r10,(%rsp)
mov    %eax,0x8(%rsp)
mov    $0x0,%al
call   1080 <fprintf@plt>
jmp    17ed <main+0x65d>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xa8(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
xorps  %xmm0,%xmm0
movsd  %xmm0,-0xb8(%rbp)
ff
movl   $0x0,-0x48(%rbp)
mov    -0x48(%rbp),%eax
cmp    -0x4c(%rbp),%eax
je     177e <main+0x5ee>
mov    -0x18(%rbp),%rdi
lea    0xb34(%rip),%rsi
lea    -0x60(%rbp),%rdx
lea    -0x78(%rbp),%rcx
mov    $0x0,%al
call   1070 <fscanf@plt>
cmp    $0x2,%eax
je     15bf <main+0x42f>
mov    0x2a3c(%rip),%rax
mov    (%rax),%edi
mov    -0x48(%rbp),%edx
add    $0x1,%edx
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rcx
lea    0xadb(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
jmp    177e <main+0x5ee>
mov    -0x20(%rbp),%rdi
lea    0xae7(%rip),%rsi
lea    -0x68(%rbp),%rdx
lea    -0x80(%rbp),%rcx
mov    $0x0,%al
call   1070 <fscanf@plt>
cmp    $0x2,%eax
je     160c <main+0x47c>
mov    0x29ef(%rip),%rax
mov    (%rax),%edi
mov    -0x48(%rbp),%edx
add    $0x1,%edx
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rcx
lea    0xa8e(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
jmp    177e <main+0x5ee>
mov    -0x28(%rbp),%rdi
lea    0xa96(%rip),%rsi
lea    -0x70(%rbp),%rdx
lea    -0x88(%rbp),%rcx
lea    -0x90(%rbp),%r8
mov    $0x0,%al
call   1070 <fscanf@plt>
cmp    $0x3,%eax
je     1663 <main+0x4d3>
mov    0x2998(%rip),%rax
mov    (%rax),%edi
mov    -0x48(%rbp),%edx
add    $0x1,%edx
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rcx
lea    0xa37(%rip),%rsi
mov    $0x0,%al
call   1080 <fprintf@plt>
jmp    177e <main+0x5ee>
movsd  -0x60(%rbp),%xmm0
ucomisd -0x68(%rbp),%xmm0
jne    1694 <main+0x504>
jp     1694 <main+0x504>
movsd  -0x68(%rbp),%xmm0
ucomisd -0x70(%rbp),%xmm0
jne    1694 <main+0x504>
jp     1694 <main+0x504>
jmp    16c5 <main+0x535>
mov    0x293d(%rip),%rax
mov    (%rax),%edi
mov    -0x48(%rbp),%edx
add    $0x1,%edx
movsd  -0x60(%rbp),%xmm0
movsd  -0x68(%rbp),%xmm1
movsd  -0x70(%rbp),%xmm2
lea    0xa01(%rip),%rsi
mov    $0x3,%al
call   1080 <fprintf@plt>
jmp    177e <main+0x5ee>
movsd  -0x78(%rbp),%xmm0
subsd  -0x88(%rbp),%xmm0
ff
movaps 0x927(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
ucomisd -0xa0(%rbp),%xmm0
ff
jbe    1718 <main+0x588>
movsd  -0x98(%rbp),%xmm0
ff
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0x60(%rbp),%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
movsd  -0x80(%rbp),%xmm0
subsd  -0x90(%rbp),%xmm0
ff
movaps 0x8d4(%rip),%xmm1
pand   %xmm1,%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0x98(%rbp),%xmm0
ff
ucomisd -0xa8(%rbp),%xmm0
ff
jbe    176b <main+0x5db>
movsd  -0x98(%rbp),%xmm0
ff
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0x60(%rbp),%xmm0
movsd  %xmm0,-0xb8(%rbp)
ff
jmp    1770 <main+0x5e0>
mov    -0x48(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x48(%rbp)
jmp    1566 <main+0x3d6>
mov    -0x48(%rbp),%eax
cmp    -0x4c(%rbp),%eax
jne    17c1 <main+0x631>
mov    0x2847(%rip),%rax
mov    (%rax),%edi
movsd  -0xa0(%rbp),%xmm0
ff
movsd  -0xb0(%rbp),%xmm1
ff
movsd  -0xa8(%rbp),%xmm2
ff
movsd  -0xb8(%rbp),%xmm3
ff
lea    0x92b(%rip),%rsi
mov    $0x4,%al
call   1080 <fprintf@plt>
mov    -0x18(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x20(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x28(%rbp),%rdi
call   1040 <fclose@plt>
mov    0x27ed(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
jmp    1814 <main+0x684>
mov    -0x18(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x20(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x28(%rbp),%rdi
call   1040 <fclose@plt>
mov    0x27d1(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0xd0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0xb8,%rsp
mov    %rsi,%rbx
cmp    $0x4,%edi
jne    1586 <main+0x3f6>
mov    0x8(%rbx),%rdi
lea    0xe87(%rip),%rsi
call   1090 <fopen@plt>
test   %rax,%rax
je     159b <main+0x40b>
mov    %rax,%r12
movq   $0x0,(%rsp)
movq   $0x0,0x8(%rsp)
mov    %rsp,%r14
lea    0x8(%rsp),%rbp
mov    %r14,%rdi
mov    %rbp,%rsi
mov    %rax,%rdx
call   10b0 <getline@plt>
mov    %r14,%rdi
mov    %rbp,%rsi
mov    %r12,%rdx
call   10b0 <getline@plt>
mov    %r14,%rdi
mov    %rbp,%rsi
mov    %r12,%rdx
call   10b0 <getline@plt>
mov    (%rsp),%rdi
call   1030 <free@plt>
lea    0x14(%rsp),%rsi
mov    %r12,%rdi
call   1050 <fgetpos@plt>
mov    0x10(%rbx),%rdi
lea    0xe12(%rip),%rsi
call   1090 <fopen@plt>
test   %rax,%rax
je     15bb <main+0x42b>
mov    %rax,%r14
movq   $0x0,(%rsp)
movq   $0x0,0x8(%rsp)
mov    %rsp,%r15
lea    0x8(%rsp),%rbp
mov    %r15,%rdi
mov    %rbp,%rsi
mov    %rax,%rdx
call   10b0 <getline@plt>
mov    %r15,%rdi
mov    %rbp,%rsi
mov    %r14,%rdx
call   10b0 <getline@plt>
mov    %r15,%rdi
mov    %rbp,%rsi
mov    %r14,%rdx
call   10b0 <getline@plt>
mov    (%rsp),%rdi
call   1030 <free@plt>
lea    0x10(%rsp),%rsi
mov    %r14,%rdi
call   1050 <fgetpos@plt>
mov    0x18(%rbx),%rdi
lea    0xd9d(%rip),%rsi
call   1090 <fopen@plt>
test   %rax,%rax
je     15d8 <main+0x448>
mov    %rax,0x30(%rsp)
mov    %rbx,0x18(%rsp)
lea    0x14(%rsp),%rsi
mov    %r12,%rdi
call   10a0 <fsetpos@plt>
movq   $0x0,(%rsp)
movq   $0x0,0x8(%rsp)
xor    %ecx,%ecx
mov    %rsp,%r15
lea    0x8(%rsp),%rbp
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    %ecx,%ebx
mov    %r15,%rdi
mov    %rbp,%rsi
mov    %r12,%rdx
call   10b0 <getline@plt>
lea    0x1(%rbx),%ecx
cmp    $0xffffffff,%eax
jne    12f0 <main+0x160>
mov    (%rsp),%rdi
call   1030 <free@plt>
lea    0x14(%rsp),%rsi
mov    %r12,0x28(%rsp)
mov    %r12,%rdi
call   10a0 <fsetpos@plt>
lea    0x10(%rsp),%rsi
mov    %r14,%rdi
call   10a0 <fsetpos@plt>
movq   $0x0,(%rsp)
movq   $0x0,0x8(%rsp)
mov    $0xffffffff,%ebp
mov    %rsp,%r15
lea    0x8(%rsp),%r12
xchg   %ax,%ax
mov    %r15,%rdi
mov    %r12,%rsi
mov    %r14,%rdx
call   10b0 <getline@plt>
add    $0x1,%ebp
cmp    $0xffffffff,%eax
jne    1350 <main+0x1c0>
mov    (%rsp),%rdi
call   1030 <free@plt>
lea    0x10(%rsp),%rsi
mov    %r14,0x20(%rsp)
mov    %r14,%rdi
call   10a0 <fsetpos@plt>
movq   $0x0,(%rsp)
movq   $0x0,0x8(%rsp)
mov    $0xffffffff,%r14d
mov    %rsp,%r15
lea    0x8(%rsp),%r13
mov    0x30(%rsp),%r12
cs nopw 0x0(%rax,%rax,1)
nop
mov    %r15,%rdi
mov    %r13,%rsi
mov    %r12,%rdx
call   10b0 <getline@plt>
add    $0x1,%r14d
cmp    $0xffffffff,%eax
jne    13b0 <main+0x220>
mov    (%rsp),%rdi
call   1030 <free@plt>
mov    %r12,%rdi
call   1060 <rewind@plt>
cmp    %ebp,%ebx
jne    1600 <main+0x470>
cmp    %r14d,%ebp
jne    1600 <main+0x470>
test   %ebx,%ebx
je     166a <main+0x4da>
xorpd  %xmm3,%xmm3
mov    $0xffffffff,%ebp
lea    0xcb0(%rip),%r15
xorpd  %xmm1,%xmm1
xorpd  %xmm4,%xmm4
xorpd  %xmm5,%xmm5
mov    0x20(%rsp),%r14
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
movapd %xmm5,0x70(%rsp)
movapd %xmm4,0x80(%rsp)
movapd %xmm1,0x90(%rsp)
movapd %xmm3,0xa0(%rsp)
mov    0x28(%rsp),%rdi
mov    %r15,%rsi
lea    0x68(%rsp),%rdx
lea    0x50(%rsp),%rcx
xor    %eax,%eax
call   1070 <fscanf@plt>
cmp    $0x2,%eax
jne    1698 <main+0x508>
mov    %r14,%rdi
mov    %r15,%r13
mov    %r15,%rsi
lea    0x60(%rsp),%rdx
lea    0x48(%rsp),%rcx
xor    %eax,%eax
call   1070 <fscanf@plt>
cmp    $0x2,%eax
jne    16ae <main+0x51e>
mov    %r12,%rdi
lea    0xc1d(%rip),%rsi
lea    0x58(%rsp),%rdx
lea    0x40(%rsp),%rcx
lea    0x38(%rsp),%r8
xor    %eax,%eax
call   1070 <fscanf@plt>
cmp    $0x3,%eax
jne    16c4 <main+0x534>
movsd  0x68(%rsp),%xmm3
movsd  0x60(%rsp),%xmm1
ucomisd %xmm1,%xmm3
movsd  0x58(%rsp),%xmm2
jne    16ea <main+0x55a>
jp     16ea <main+0x55a>
ucomisd %xmm2,%xmm1
jne    16ea <main+0x55a>
jp     16ea <main+0x55a>
movsd  0x50(%rsp),%xmm1
subsd  0x40(%rsp),%xmm1
movapd 0xb0b(%rip),%xmm2
andpd  %xmm2,%xmm1
movapd %xmm1,%xmm0
movapd 0x70(%rsp),%xmm4
maxsd  %xmm4,%xmm0
cmpltsd %xmm1,%xmm4
movapd %xmm4,%xmm1
andpd  %xmm3,%xmm1
andnpd 0x90(%rsp),%xmm4
orpd   %xmm1,%xmm4
movapd %xmm4,%xmm1
movsd  0x48(%rsp),%xmm4
subsd  0x38(%rsp),%xmm4
andpd  %xmm2,%xmm4
movapd %xmm4,%xmm2
movapd 0x80(%rsp),%xmm5
maxsd  %xmm5,%xmm2
cmpltsd %xmm4,%xmm5
andpd  %xmm5,%xmm3
andnpd 0xa0(%rsp),%xmm5
orpd   %xmm3,%xmm5
movapd %xmm5,%xmm3
lea    (%rbx,%rbp,1),%eax
add    $0xffffffff,%eax
mov    %ebp,%ecx
add    $0xffffffff,%ecx
mov    %ecx,%ebp
movapd %xmm2,%xmm4
movapd %xmm0,%xmm5
cmp    $0xffffffff,%eax
mov    %r13,%r15
jne    1420 <main+0x290>
jmp    167f <main+0x4ef>
mov    0x2a4b(%rip),%rax
mov    (%rax),%edi
mov    (%rbx),%rdx
lea    0xa77(%rip),%rsi
jmp    15af <main+0x41f>
mov    0x2a36(%rip),%rax
mov    (%rax),%edi
mov    0x8(%rbx),%rdx
lea    0xa92(%rip),%rsi
xor    %eax,%eax
call   1080 <fprintf@plt>
jmp    164f <main+0x4bf>
mov    0x2a16(%rip),%rax
mov    (%rax),%edi
mov    0x10(%rbx),%rdx
lea    0xa72(%rip),%rsi
xor    %eax,%eax
call   1080 <fprintf@plt>
jmp    1647 <main+0x4b7>
mov    0x29f9(%rip),%rax
mov    (%rax),%edi
mov    0x18(%rbx),%rdx
lea    0xa55(%rip),%rsi
xor    %eax,%eax
call   1080 <fprintf@plt>
mov    %r12,%rdi
call   1040 <fclose@plt>
mov    %r14,%rdi
jmp    164a <main+0x4ba>
mov    0x29d1(%rip),%rax
mov    (%rax),%edi
mov    0x18(%rsp),%r10
mov    0x8(%r10),%rdx
mov    0x10(%r10),%r8
lea    0xa3c(%rip),%rsi
mov    %ebx,%ecx
mov    %ebp,%r9d
xor    %eax,%eax
push   %r14
push   0x18(%r10)
call   1080 <fprintf@plt>
add    $0x10,%rsp
mov    0x28(%rsp),%rdi
call   1040 <fclose@plt>
mov    0x20(%rsp),%rdi
call   1040 <fclose@plt>
mov    %r12,%rdi
call   1040 <fclose@plt>
mov    0x298a(%rip),%rax
mov    (%rax),%eax
add    $0xb8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
xorpd  %xmm0,%xmm0
xorpd  %xmm2,%xmm2
xorpd  %xmm1,%xmm1
xorpd  %xmm3,%xmm3
mov    0x20(%rsp),%r14
mov    0x2952(%rip),%rax
mov    (%rax),%edi
lea    0xa56(%rip),%rsi
mov    $0x4,%al
call   1080 <fprintf@plt>
jmp    1709 <main+0x579>
mov    0x2939(%rip),%rax
mov    (%rax),%edi
neg    %ebp
mov    0x18(%rsp),%rax
mov    0x8(%rax),%rcx
jmp    16d8 <main+0x548>
mov    0x2923(%rip),%rax
mov    (%rax),%edi
neg    %ebp
mov    0x18(%rsp),%rax
mov    0x10(%rax),%rcx
jmp    16d8 <main+0x548>
mov    0x290d(%rip),%rax
mov    (%rax),%edi
neg    %ebp
mov    0x18(%rsp),%rax
mov    0x18(%rax),%rcx
lea    0x9af(%rip),%rsi
mov    %ebp,%edx
xor    %eax,%eax
call   1080 <fprintf@plt>
jmp    1709 <main+0x579>
mov    0x28e7(%rip),%rax
mov    (%rax),%edi
neg    %ebp
lea    0x9be(%rip),%rsi
mov    %ebp,%edx
movapd %xmm3,%xmm0
mov    $0x3,%al
call   1080 <fprintf@plt>
mov    0x28(%rsp),%rdi
call   1040 <fclose@plt>
mov    %r14,%rdi
call   1040 <fclose@plt>
mov    %r12,%rdi
call   1040 <fclose@plt>
mov    0x28a6(%rip),%rax
jmp    1656 <main+0x4c6>

LLVM IR (-O0):
@stdout = global i32 0
@.str = [47 x i8] c"Usage: \22%s node1.txt node2.txt reference.txt\22\0A\00"
@EXIT_FAILURE = global i32 0
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [24 x i8] c"Unable to open file %s\0A\00"
@.str.3 = [53 x i8] c"Files %s:%d, %s:%d and %s:%d have different # lines\0A\00"
@.str.4 = [9 x i8] c"%lf %lf\0A\00"
@.str.5 = [31 x i8] c"Error reading line %d from %s\0A\00"
@.str.6 = [13 x i8] c"%lf %lf %lf\0A\00"
@.str.7 = [43 x i8] c"Time mismatch at line %d (%.3f %.3f %.3f)\0A\00"
@.str.8 = [28 x i8] c"%.3f (@%.3f) \09%.3f (@%.3f)\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 i8*
%10 = alloca i64
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
%17 = alloca i32
%18 = alloca double
%19 = alloca double
%20 = alloca double
%21 = alloca double
%22 = alloca double
%23 = alloca double
%24 = alloca double
%25 = alloca double
%26 = alloca double
%27 = alloca double
%28 = alloca double
%29 = alloca double
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%30 = load i32, i32* %4
%31 = icmp ne i32 %30, 4
br i1 %31, label %32, label %39
32: ; preds = %2
%33 = load i32, i32* @stdout
%34 = load i8**, i8*** %5
%35 = getelementptr inbounds i8*, i8** %34, i64 0
%36 = load i8*, i8** %35
%37 = call i32 (i32, i8*, ...) @fprintf(i32 %33, i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str, i64 0, i64 0), i8* %36)
%38 = load i32, i32* @EXIT_FAILURE
store i32 %38, i32* %3
br label %291
39: ; preds = %2
%40 = load i8**, i8*** %5
%41 = getelementptr inbounds i8*, i8** %40, i64 1
%42 = load i8*, i8** %41
%43 = call i32* @fopen(i8* %42, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %43, i32** %6
%44 = load i32*, i32** %6
%45 = icmp eq i32* %44, null
br i1 %45, label %46, label %53
46: ; preds = %39
%47 = load i32, i32* @stdout
%48 = load i8**, i8*** %5
%49 = getelementptr inbounds i8*, i8** %48, i64 1
%50 = load i8*, i8** %49
%51 = call i32 (i32, i8*, ...) @fprintf(i32 %47, i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.2, i64 0, i64 0), i8* %50)
%52 = load i32, i32* @EXIT_FAILURE
store i32 %52, i32* %3
br label %291
53: ; preds = %39
store i8* null, i8** %9
store i64 0, i64* %10
store i32 0, i32* %14
br label %54
54: ; preds = %60, %53
%55 = load i32, i32* %14
%56 = icmp ne i32 %55, 3
br i1 %56, label %57, label %63
57: ; preds = %54
%58 = load i32*, i32** %6
%59 = call i32 @getline(i8** %9, i64* %10, i32* %58)
store i32 %59, i32* %11
br label %60
60: ; preds = %57
%61 = load i32, i32* %14
%62 = add nsw i32 %61, 1
store i32 %62, i32* %14
br label %54
63: ; preds = %54
%64 = load i8*, i8** %9
%65 = call i32 @free(i8* %64)
%66 = load i32*, i32** %6
%67 = call i32 @fgetpos(i32* %66, i32* %12)
%68 = load i8**, i8*** %5
%69 = getelementptr inbounds i8*, i8** %68, i64 2
%70 = load i8*, i8** %69
%71 = call i32* @fopen(i8* %70, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %71, i32** %7
%72 = load i32*, i32** %7
%73 = icmp eq i32* %72, null
br i1 %73, label %74, label %83
74: ; preds = %63
%75 = load i32, i32* @stdout
%76 = load i8**, i8*** %5
%77 = getelementptr inbounds i8*, i8** %76, i64 2
%78 = load i8*, i8** %77
%79 = call i32 (i32, i8*, ...) @fprintf(i32 %75, i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.2, i64 0, i64 0), i8* %78)
%80 = load i32*, i32** %6
%81 = call i32 @fclose(i32* %80)
%82 = load i32, i32* @EXIT_FAILURE
store i32 %82, i32* %3
br label %291
83: ; preds = %63
store i8* null, i8** %9
store i64 0, i64* %10
store i32 0, i32* %14
br label %84
84: ; preds = %90, %83
%85 = load i32, i32* %14
%86 = icmp ne i32 %85, 3
br i1 %86, label %87, label %93
87: ; preds = %84
%88 = load i32*, i32** %7
%89 = call i32 @getline(i8** %9, i64* %10, i32* %88)
store i32 %89, i32* %11
br label %90
90: ; preds = %87
%91 = load i32, i32* %14
%92 = add nsw i32 %91, 1
store i32 %92, i32* %14
br label %84
93: ; preds = %84
%94 = load i8*, i8** %9
%95 = call i32 @free(i8* %94)
%96 = load i32*, i32** %7
%97 = call i32 @fgetpos(i32* %96, i32* %13)
%98 = load i8**, i8*** %5
%99 = getelementptr inbounds i8*, i8** %98, i64 3
%100 = load i8*, i8** %99
%101 = call i32* @fopen(i8* %100, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
store i32* %101, i32** %8
%102 = load i32*, i32** %8
%103 = icmp eq i32* %102, null
br i1 %103, label %104, label %115
104: ; preds = %93
%105 = load i32, i32* @stdout
%106 = load i8**, i8*** %5
%107 = getelementptr inbounds i8*, i8** %106, i64 3
%108 = load i8*, i8** %107
%109 = call i32 (i32, i8*, ...) @fprintf(i32 %105, i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.2, i64 0, i64 0), i8* %108)
%110 = load i32*, i32** %6
%111 = call i32 @fclose(i32* %110)
%112 = load i32*, i32** %7
%113 = call i32 @fclose(i32* %112)
%114 = load i32, i32* @EXIT_FAILURE
store i32 %114, i32* %3
br label %291
115: ; preds = %93
%116 = load i32*, i32** %6
%117 = call i32 @fsetpos(i32* %116, i32* %12)
store i8* null, i8** %9
store i64 0, i64* %10
store i32 0, i32* %15
br label %118
118: ; preds = %123, %115
%119 = load i32*, i32** %6
%120 = call i32 @getline(i8** %9, i64* %10, i32* %119)
store i32 %120, i32* %11
%121 = icmp ne i32 %120, -1
br i1 %121, label %122, label %126
122: ; preds = %118
br label %123
123: ; preds = %122
%124 = load i32, i32* %15
%125 = add nsw i32 %124, 1
store i32 %125, i32* %15
br label %118
126: ; preds = %118
%127 = load i8*, i8** %9
%128 = call i32 @free(i8* %127)
%129 = load i32*, i32** %6
%130 = call i32 @fsetpos(i32* %129, i32* %12)
%131 = load i32*, i32** %7
%132 = call i32 @fsetpos(i32* %131, i32* %13)
store i8* null, i8** %9
store i64 0, i64* %10
store i32 0, i32* %16
br label %133
133: ; preds = %138, %126
%134 = load i32*, i32** %7
%135 = call i32 @getline(i8** %9, i64* %10, i32* %134)
store i32 %135, i32* %11
%136 = icmp ne i32 %135, -1
br i1 %136, label %137, label %141
137: ; preds = %133
br label %138
138: ; preds = %137
%139 = load i32, i32* %16
%140 = add nsw i32 %139, 1
store i32 %140, i32* %16
br label %133
141: ; preds = %133
%142 = load i8*, i8** %9
%143 = call i32 @free(i8* %142)
%144 = load i32*, i32** %7
%145 = call i32 @fsetpos(i32* %144, i32* %13)
store i8* null, i8** %9
store i64 0, i64* %10
store i32 0, i32* %17
br label %146
146: ; preds = %151, %141
%147 = load i32*, i32** %8
%148 = call i32 @getline(i8** %9, i64* %10, i32* %147)
store i32 %148, i32* %11
%149 = icmp ne i32 %148, -1
br i1 %149, label %150, label %154
150: ; preds = %146
br label %151
151: ; preds = %150
%152 = load i32, i32* %17
%153 = add nsw i32 %152, 1
store i32 %153, i32* %17
br label %146
154: ; preds = %146
%155 = load i8*, i8** %9
%156 = call i32 @free(i8* %155)
%157 = load i32*, i32** %8
%158 = call i32 @rewind(i32* %157)
%159 = load i32, i32* %15
%160 = load i32, i32* %16
%161 = icmp ne i32 %159, %160
br i1 %161, label %166, label %162
162: ; preds = %154
%163 = load i32, i32* %16
%164 = load i32, i32* %17
%165 = icmp ne i32 %163, %164
br i1 %165, label %166, label %181
166: ; preds = %162, %154
%167 = load i32, i32* @stdout
%168 = load i8**, i8*** %5
%169 = getelementptr inbounds i8*, i8** %168, i64 1
%170 = load i8*, i8** %169
%171 = load i32, i32* %15
%172 = load i8**, i8*** %5
%173 = getelementptr inbounds i8*, i8** %172, i64 2
%174 = load i8*, i8** %173
%175 = load i32, i32* %16
%176 = load i8**, i8*** %5
%177 = getelementptr inbounds i8*, i8** %176, i64 3
%178 = load i8*, i8** %177
%179 = load i32, i32* %17
%180 = call i32 (i32, i8*, ...) @fprintf(i32 %167, i8* getelementptr inbounds ([53 x i8], [53 x i8]* @.str.3, i64 0, i64 0), i8* %170, i32 %171, i8* %174, i32 %175, i8* %178, i32 %179)
br label %283
181: ; preds = %162
store double 0.000000e+00, double* %26
store double 0.000000e+00, double* %27
store double 0.000000e+00, double* %28
store double 0.000000e+00, double* %29
store i32 0, i32* %14
br label %182
182: ; preds = %261, %181
%183 = load i32, i32* %14
%184 = load i32, i32* %15
%185 = icmp ne i32 %183, %184
br i1 %185, label %186, label %264
186: ; preds = %182
%187 = load i32*, i32** %6
%188 = call i32 (i32*, i8*, double*, double*, ...) @fscanf(i32* %187, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.4, i64 0, i64 0), double* %18, double* %21)
%189 = icmp ne i32 %188, 2
br i1 %189, label %190, label %198
190: ; preds = %186
%191 = load i32, i32* @stdout
%192 = load i32, i32* %14
%193 = add nsw i32 %192, 1
%194 = load i8**, i8*** %5
%195 = getelementptr inbounds i8*, i8** %194, i64 1
%196 = load i8*, i8** %195
%197 = call i32 (i32, i8*, ...) @fprintf(i32 %191, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.5, i64 0, i64 0), i32 %193, i8* %196)
br label %264
198: ; preds = %186
%199 = load i32*, i32** %7
%200 = call i32 (i32*, i8*, double*, double*, ...) @fscanf(i32* %199, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.4, i64 0, i64 0), double* %19, double* %22)
%201 = icmp ne i32 %200, 2
br i1 %201, label %202, label %210
202: ; preds = %198
%203 = load i32, i32* @stdout
%204 = load i32, i32* %14
%205 = add nsw i32 %204, 1
%206 = load i8**, i8*** %5
%207 = getelementptr inbounds i8*, i8** %206, i64 2
%208 = load i8*, i8** %207
%209 = call i32 (i32, i8*, ...) @fprintf(i32 %203, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.5, i64 0, i64 0), i32 %205, i8* %208)
br label %264
210: ; preds = %198
%211 = load i32*, i32** %8
%212 = call i32 (i32*, i8*, double*, double*, ...) @fscanf(i32* %211, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.6, i64 0, i64 0), double* %20, double* %23, double* %24)
%213 = icmp ne i32 %212, 3
br i1 %213, label %214, label %222
214: ; preds = %210
%215 = load i32, i32* @stdout
%216 = load i32, i32* %14
%217 = add nsw i32 %216, 1
%218 = load i8**, i8*** %5
%219 = getelementptr inbounds i8*, i8** %218, i64 3
%220 = load i8*, i8** %219
%221 = call i32 (i32, i8*, ...) @fprintf(i32 %215, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.5, i64 0, i64 0), i32 %217, i8* %220)
br label %264
222: ; preds = %210
%223 = load double, double* %18
%224 = load double, double* %19
%225 = fcmp une double %223, %224
br i1 %225, label %230, label %226
226: ; preds = %222
%227 = load double, double* %19
%228 = load double, double* %20
%229 = fcmp une double %227, %228
br i1 %229, label %230, label %238
230: ; preds = %226, %222
%231 = load i32, i32* @stdout
%232 = load i32, i32* %14
%233 = add nsw i32 %232, 1
%234 = load double, double* %18
%235 = load double, double* %19
%236 = load double, double* %20
%237 = call i32 (i32, i8*, ...) @fprintf(i32 %231, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.7, i64 0, i64 0), i32 %233, double %234, double %235, double %236)
br label %264
238: ; preds = %226
%239 = load double, double* %21
%240 = load double, double* %23
%241 = fsub double %239, %240
%242 = call double @llvm.fabs.f64(double %241)
store double %242, double* %25
%243 = load double, double* %25
%244 = load double, double* %26
%245 = fcmp ogt double %243, %244
br i1 %245, label %246, label %249
246: ; preds = %238
%247 = load double, double* %25
store double %247, double* %26
%248 = load double, double* %18
store double %248, double* %28
br label %249
249: ; preds = %246, %238
%250 = load double, double* %22
%251 = load double, double* %24
%252 = fsub double %250, %251
%253 = call double @llvm.fabs.f64(double %252)
store double %253, double* %25
%254 = load double, double* %25
%255 = load double, double* %27
%256 = fcmp ogt double %254, %255
br i1 %256, label %257, label %260
257: ; preds = %249
%258 = load double, double* %25
store double %258, double* %27
%259 = load double, double* %18
store double %259, double* %29
br label %260
260: ; preds = %257, %249
br label %261
261: ; preds = %260
%262 = load i32, i32* %14
%263 = add nsw i32 %262, 1
store i32 %263, i32* %14
br label %182
264: ; preds = %230, %214, %202, %190, %182
%265 = load i32, i32* %14
%266 = load i32, i32* %15
%267 = icmp eq i32 %265, %266
br i1 %267, label %268, label %275
268: ; preds = %264
%269 = load i32, i32* @stdout
%270 = load double, double* %26
%271 = load double, double* %28
%272 = load double, double* %27
%273 = load double, double* %29
%274 = call i32 (i32, i8*, ...) @fprintf(i32 %269, i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.8, i64 0, i64 0), double %270, double %271, double %272, double %273)
br label %275
275: ; preds = %268, %264
%276 = load i32*, i32** %6
%277 = call i32 @fclose(i32* %276)
%278 = load i32*, i32** %7
%279 = call i32 @fclose(i32* %278)
%280 = load i32*, i32** %8
%281 = call i32 @fclose(i32* %280)
%282 = load i32, i32* @EXIT_SUCCESS
store i32 %282, i32* %3
br label %291
283: ; preds = %166
%284 = load i32*, i32** %6
%285 = call i32 @fclose(i32* %284)
%286 = load i32*, i32** %7
%287 = call i32 @fclose(i32* %286)
%288 = load i32*, i32** %8
%289 = call i32 @fclose(i32* %288)
%290 = load i32, i32* @EXIT_FAILURE
store i32 %290, i32* %3
br label %291
291: ; preds = %283, %275, %104, %74, %46, %32
%292 = load i32, i32* %3
ret i32 %292
}

LLVM IR (-O2):
@stdout = global i32 0
@.str = [47 x i8] c"Usage: \22%s node1.txt node2.txt reference.txt\22\0A\00"
@EXIT_FAILURE = global i32 0
@.str.1 = [2 x i8] c"r\00"
@.str.2 = [24 x i8] c"Unable to open file %s\0A\00"
@.str.3 = [53 x i8] c"Files %s:%d, %s:%d and %s:%d have different # lines\0A\00"
@.str.4 = [9 x i8] c"%lf %lf\0A\00"
@.str.5 = [31 x i8] c"Error reading line %d from %s\0A\00"
@.str.6 = [13 x i8] c"%lf %lf %lf\0A\00"
@.str.7 = [43 x i8] c"Time mismatch at line %d (%.3f %.3f %.3f)\0A\00"
@.str.8 = [28 x i8] c"%.3f (@%.3f) \09%.3f (@%.3f)\0A\00"
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = alloca i8*
%4 = alloca i64
%5 = alloca i32
%6 = alloca i32
%7 = alloca double
%8 = alloca double
%9 = alloca double
%10 = alloca double
%11 = alloca double
%12 = alloca double
%13 = alloca double
%14 = bitcast i8** %3 to i8*
%15 = bitcast i64* %4 to i8*
%16 = bitcast i32* %5 to i8*
%17 = bitcast i32* %6 to i8*
%18 = bitcast double* %7 to i8*
%19 = bitcast double* %8 to i8*
%20 = bitcast double* %9 to i8*
%21 = bitcast double* %10 to i8*
%22 = bitcast double* %11 to i8*
%23 = bitcast double* %12 to i8*
%24 = bitcast double* %13 to i8*
%25 = icmp eq i32 %0, 4
br i1 %25, label %30, label %26
26: ; preds = %2
%27 = load i32, i32* @stdout
%28 = load i8*, i8** %1
%29 = tail call i32 (i32, i8*, ...) @fprintf(i32 %27, i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str, i64 0, i64 0), i8* %28)
br label %184
30: ; preds = %2
%31 = getelementptr inbounds i8*, i8** %1, i64 1
%32 = load i8*, i8** %31
%33 = tail call i32* @fopen(i8* %32, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%34 = icmp eq i32* %33, null
br i1 %34, label %35, label %39
35: ; preds = %30
%36 = load i32, i32* @stdout
%37 = load i8*, i8** %31
%38 = tail call i32 (i32, i8*, ...) @fprintf(i32 %36, i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.2, i64 0, i64 0), i8* %37)
br label %184
39: ; preds = %30
store i8* null, i8** %3
store i64 0, i64* %4
%40 = call i32 @getline(i8** %3, i64* %4, i32* %33)
%41 = call i32 @getline(i8** %3, i64* %4, i32* %33)
%42 = call i32 @getline(i8** %3, i64* %4, i32* %33)
%43 = load i8*, i8** %3
%44 = call i32 @free(i8* %43)
%45 = call i32 @fgetpos(i32* %33, i32* %5)
%46 = getelementptr inbounds i8*, i8** %1, i64 2
%47 = load i8*, i8** %46
%48 = call i32* @fopen(i8* %47, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%49 = icmp eq i32* %48, null
br i1 %49, label %50, label %55
50: ; preds = %39
%51 = load i32, i32* @stdout
%52 = load i8*, i8** %46
%53 = call i32 (i32, i8*, ...) @fprintf(i32 %51, i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.2, i64 0, i64 0), i8* %52)
%54 = call i32 @fclose(i32* %33)
br label %184
55: ; preds = %39
store i8* null, i8** %3
store i64 0, i64* %4
%56 = call i32 @getline(i8** %3, i64* %4, i32* %48)
%57 = call i32 @getline(i8** %3, i64* %4, i32* %48)
%58 = call i32 @getline(i8** %3, i64* %4, i32* %48)
%59 = load i8*, i8** %3
%60 = call i32 @free(i8* %59)
%61 = call i32 @fgetpos(i32* %48, i32* %6)
%62 = getelementptr inbounds i8*, i8** %1, i64 3
%63 = load i8*, i8** %62
%64 = call i32* @fopen(i8* %63, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%65 = icmp eq i32* %64, null
br i1 %65, label %66, label %72
66: ; preds = %55
%67 = load i32, i32* @stdout
%68 = load i8*, i8** %62
%69 = call i32 (i32, i8*, ...) @fprintf(i32 %67, i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.2, i64 0, i64 0), i8* %68)
%70 = call i32 @fclose(i32* %33)
%71 = call i32 @fclose(i32* %48)
br label %184
72: ; preds = %55
%73 = call i32 @fsetpos(i32* %33, i32* %5)
store i8* null, i8** %3
store i64 0, i64* %4
br label %74
74: ; preds = %74, %72
%75 = phi i32 [ 0, %72 ], [ %78, %74 ]
%76 = call i32 @getline(i8** %3, i64* %4, i32* %33)
%77 = icmp eq i32 %76, -1
%78 = add nuw nsw i32 %75, 1
br i1 %77, label %79, label %74
79: ; preds = %74
%80 = load i8*, i8** %3
%81 = call i32 @free(i8* %80)
%82 = call i32 @fsetpos(i32* %33, i32* %5)
%83 = call i32 @fsetpos(i32* %48, i32* %6)
store i8* null, i8** %3
store i64 0, i64* %4
br label %84
84: ; preds = %84, %79
%85 = phi i32 [ 0, %79 ], [ %88, %84 ]
%86 = call i32 @getline(i8** %3, i64* %4, i32* %48)
%87 = icmp eq i32 %86, -1
%88 = add nuw nsw i32 %85, 1
br i1 %87, label %89, label %84
89: ; preds = %84
%90 = load i8*, i8** %3
%91 = call i32 @free(i8* %90)
%92 = call i32 @fsetpos(i32* %48, i32* %6)
store i8* null, i8** %3
store i64 0, i64* %4
br label %93
93: ; preds = %93, %89
%94 = phi i32 [ 0, %89 ], [ %97, %93 ]
%95 = call i32 @getline(i8** %3, i64* %4, i32* %64)
%96 = icmp eq i32 %95, -1
%97 = add nuw nsw i32 %94, 1
br i1 %96, label %98, label %93
98: ; preds = %93
%99 = load i8*, i8** %3
%100 = call i32 @free(i8* %99)
%101 = call i32 @rewind(i32* %64)
%102 = icmp eq i32 %75, %85
%103 = icmp eq i32 %85, %94
%104 = select i1 %102, i1 %103, i1 false
br i1 %104, label %105, label %107
105: ; preds = %98
%106 = icmp eq i32 %75, 0
br i1 %106, label %173, label %116
107: ; preds = %98
%108 = load i32, i32* @stdout
%109 = load i8*, i8** %31
%110 = load i8*, i8** %46
%111 = load i8*, i8** %62
%112 = call i32 (i32, i8*, ...) @fprintf(i32 %108, i8* getelementptr inbounds ([53 x i8], [53 x i8]* @.str.3, i64 0, i64 0), i8* %109, i32 %75, i8* %110, i32 %85, i8* %111, i32 %94)
%113 = call i32 @fclose(i32* %33)
%114 = call i32 @fclose(i32* %48)
%115 = call i32 @fclose(i32* %64)
br label %184
116: ; preds = %105, %156
%117 = phi double [ %170, %156 ], [ 0.000000e+00, %105 ]
%118 = phi double [ %163, %156 ], [ 0.000000e+00, %105 ]
%119 = phi double [ %169, %156 ], [ 0.000000e+00, %105 ]
%120 = phi double [ %162, %156 ], [ 0.000000e+00, %105 ]
%121 = phi i32 [ %171, %156 ], [ 0, %105 ]
%122 = call i32 (i32*, i8*, double*, double*, ...) @fscanf(i32* %33, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.4, i64 0, i64 0), double* %7, double* %10)
%123 = icmp eq i32 %122, 2
br i1 %123, label %129, label %124
124: ; preds = %116
%125 = load i32, i32* @stdout
%126 = add nuw nsw i32 %121, 1
%127 = load i8*, i8** %31
%128 = call i32 (i32, i8*, ...) @fprintf(i32 %125, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.5, i64 0, i64 0), i32 %126, i8* %127)
br label %180
129: ; preds = %116
%130 = call i32 (i32*, i8*, double*, double*, ...) @fscanf(i32* %48, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.4, i64 0, i64 0), double* %8, double* %11)
%131 = icmp eq i32 %130, 2
br i1 %131, label %137, label %132
132: ; preds = %129
%133 = load i32, i32* @stdout
%134 = add nuw nsw i32 %121, 1
%135 = load i8*, i8** %46
%136 = call i32 (i32, i8*, ...) @fprintf(i32 %133, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.5, i64 0, i64 0), i32 %134, i8* %135)
br label %180
137: ; preds = %129
%138 = call i32 (i32*, i8*, double*, double*, ...) @fscanf(i32* %64, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.6, i64 0, i64 0), double* %9, double* %12, double* %13)
%139 = icmp eq i32 %138, 3
br i1 %139, label %145, label %140
140: ; preds = %137
%141 = load i32, i32* @stdout
%142 = add nuw nsw i32 %121, 1
%143 = load i8*, i8** %62
%144 = call i32 (i32, i8*, ...) @fprintf(i32 %141, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.5, i64 0, i64 0), i32 %142, i8* %143)
br label %180
145: ; preds = %137
%146 = load double, double* %7
%147 = load double, double* %8
%148 = fcmp une double %146, %147
%149 = load double, double* %9
%150 = fcmp une double %147, %149
%151 = select i1 %148, i1 true, i1 %150
br i1 %151, label %152, label %156
152: ; preds = %145
%153 = load i32, i32* @stdout
%154 = add nuw nsw i32 %121, 1
%155 = call i32 (i32, i8*, ...) @fprintf(i32 %153, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.7, i64 0, i64 0), i32 %154, double %146, double %147, double %149)
br label %180
156: ; preds = %145
%157 = load double, double* %10
%158 = load double, double* %12
%159 = fsub double %157, %158
%160 = call double @llvm.fabs.f64(double %159)
%161 = fcmp ogt double %160, %120
%162 = select i1 %161, double %160, double %120
%163 = select i1 %161, double %146, double %118
%164 = load double, double* %11
%165 = load double, double* %13
%166 = fsub double %164, %165
%167 = call double @llvm.fabs.f64(double %166)
%168 = fcmp ogt double %167, %119
%169 = select i1 %168, double %167, double %119
%170 = select i1 %168, double %146, double %117
%171 = add nuw nsw i32 %121, 1
%172 = icmp eq i32 %171, %75
br i1 %172, label %173, label %116
173: ; preds = %156, %105
%174 = phi double [ 0.000000e+00, %105 ], [ %162, %156 ]
%175 = phi double [ 0.000000e+00, %105 ], [ %169, %156 ]
%176 = phi double [ 0.000000e+00, %105 ], [ %163, %156 ]
%177 = phi double [ 0.000000e+00, %105 ], [ %170, %156 ]
%178 = load i32, i32* @stdout
%179 = call i32 (i32, i8*, ...) @fprintf(i32 %178, i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.8, i64 0, i64 0), double %174, double %176, double %175, double %177)
br label %180
180: ; preds = %124, %132, %140, %152, %173
%181 = call i32 @fclose(i32* %33)
%182 = call i32 @fclose(i32* %48)
%183 = call i32 @fclose(i32* %64)
br label %184
184: ; preds = %107, %180, %66, %50, %35, %26
%185 = phi i32* [ @EXIT_FAILURE, %26 ], [ @EXIT_FAILURE, %35 ], [ @EXIT_FAILURE, %50 ], [ @EXIT_FAILURE, %66 ], [ @EXIT_FAILURE, %107 ], [ @EXIT_SUCCESS, %180 ]
%186 = load i32, i32* %185
ret i32 %186
}