#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 scalar_t__ uint64_t;

/* Variables and functions */
scalar_t__ RDTSC();
int alloc_matrix(int, int, double ***);
int atoi(char *);
scalar_t__ cmp_matrix(double **, double **, int, int, double);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, int, char *);
int /*<<< orphan*/ free_matrix(double **, int);
int mm_fast_many_cols(double **, double **, double **, int, int, int);
int mm_simple(double **, double **, double **, int, int, int);
int /*<<< orphan*/ printf(char *, ...);
int set_matrix(double **, int, int);
int /*<<< orphan*/ stderr;
int main(int argc, char **argv) {
  int status = 0;
  uint64_t t_start, t_simple, t_fast, t_alt;
  int k, m, n;
  double **X = NULL, **Y = NULL, **Z = NULL, **chk_Z = NULL, **alt_Z = NULL;
  if (argc != 4) {
    {
      {
        fprintf(stderr, "Line %3d of File %s \n", 23,
                "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/heads/"
                "master/OPERATORS/MM/src/driver_mm.c");
      };
      status = -1;
      goto BYE;
    };
  }
  m = atoi(argv[1]);
  if (m < 2) {
    {
      {
        fprintf(stderr, "Line %3d of File %s \n", 24,
                "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/heads/"
                "master/OPERATORS/MM/src/driver_mm.c");
      };
      status = -1;
      goto BYE;
    };
  }
  k = atoi(argv[2]);
  if (k < 2) {
    {
      {
        fprintf(stderr, "Line %3d of File %s \n", 25,
                "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/heads/"
                "master/OPERATORS/MM/src/driver_mm.c");
      };
      status = -1;
      goto BYE;
    };
  }
  n = atoi(argv[3]);
  if (n < 1) {
    {
      {
        fprintf(stderr, "Line %3d of File %s \n", 26,
                "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/heads/"
                "master/OPERATORS/MM/src/driver_mm.c");
      };
      status = -1;
      goto BYE;
    };
  }
  status = alloc_matrix(m, k, &X);
  {
    if ((status) < 0) {
      {
        {
          fprintf(stderr, "Line %3d of File %s \n", 28,
                  "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                  "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/"
                  "heads/master/OPERATORS/MM/src/driver_mm.c");
        };
        status = (status);
        goto BYE;
      }
    }
  };
  status = alloc_matrix(k, n, &Y);
  {
    if ((status) < 0) {
      {
        {
          fprintf(stderr, "Line %3d of File %s \n", 29,
                  "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                  "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/"
                  "heads/master/OPERATORS/MM/src/driver_mm.c");
        };
        status = (status);
        goto BYE;
      }
    }
  };
  status = alloc_matrix(m, n, &Z);
  {
    if ((status) < 0) {
      {
        {
          fprintf(stderr, "Line %3d of File %s \n", 30,
                  "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                  "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/"
                  "heads/master/OPERATORS/MM/src/driver_mm.c");
        };
        status = (status);
        goto BYE;
      }
    }
  };
  status = alloc_matrix(m, n, &alt_Z);
  {
    if ((status) < 0) {
      {
        {
          fprintf(stderr, "Line %3d of File %s \n", 31,
                  "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                  "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/"
                  "heads/master/OPERATORS/MM/src/driver_mm.c");
        };
        status = (status);
        goto BYE;
      }
    }
  };
  status = alloc_matrix(m, n, &chk_Z);
  {
    if ((status) < 0) {
      {
        {
          fprintf(stderr, "Line %3d of File %s \n", 32,
                  "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                  "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/"
                  "heads/master/OPERATORS/MM/src/driver_mm.c");
        };
        status = (status);
        goto BYE;
      }
    }
  };
  status = set_matrix(X, m, k);
  {
    if ((status) < 0) {
      {
        {
          fprintf(stderr, "Line %3d of File %s \n", 34,
                  "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                  "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/"
                  "heads/master/OPERATORS/MM/src/driver_mm.c");
        };
        status = (status);
        goto BYE;
      }
    }
  };
  status = set_matrix(Y, k, n);
  {
    if ((status) < 0) {
      {
        {
          fprintf(stderr, "Line %3d of File %s \n", 35,
                  "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                  "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/"
                  "heads/master/OPERATORS/MM/src/driver_mm.c");
        };
        status = (status);
        goto BYE;
      }
    }
  };
  t_start = RDTSC();
  status = mm_simple(X, Y, chk_Z, m, k, n);
  {
    if ((status) < 0) {
      {
        {
          fprintf(stderr, "Line %3d of File %s \n", 38,
                  "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                  "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/"
                  "heads/master/OPERATORS/MM/src/driver_mm.c");
        };
        status = (status);
        goto BYE;
      }
    }
  };
  t_simple = RDTSC() - t_start;
  printf("simple time = %llu \n", t_simple);
  t_start = RDTSC();
  status = mm_fast_many_cols(X, Y, Z, m, k, n);
  {
    if ((status) < 0) {
      {
        {
          fprintf(stderr, "Line %3d of File %s \n", 45,
                  "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                  "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/"
                  "heads/master/OPERATORS/MM/src/driver_mm.c");
        };
        status = (status);
        goto BYE;
      }
    }
  };
  t_fast = RDTSC() - t_start;
  printf("fast  time = %llu \n", t_fast);
  printf("speedup = %lf \n", (double)t_simple / (double)t_fast);
  double threshold = 0.00001;
  if (cmp_matrix(Z, chk_Z, m, n, threshold) ||
      cmp_matrix(alt_Z, chk_Z, m, n, threshold)) {
    printf("SUCCESS\n");
  } else {
    printf("FAILURE\n");
    {
      {
        fprintf(stderr, "Line %3d of File %s \n", 64,
                "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                "outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/heads/"
                "master/OPERATORS/MM/src/driver_mm.c");
      };
      status = -1;
      goto BYE;
    };
  }
  free_matrix(X, k);
  free_matrix(Y, n);
  free_matrix(Z, n);
  free_matrix(chk_Z, n);
BYE:
  return status;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x80,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
movq   $0x0,-0x50(%rbp)
movq   $0x0,-0x58(%rbp)
movq   $0x0,-0x60(%rbp)
movq   $0x0,-0x68(%rbp)
movq   $0x0,-0x70(%rbp)
cmpl   $0x4,-0x8(%rbp)
je     121f <main+0x7f>
mov    0x2de7(%rip),%rax
mov    (%rax),%edi
lea    0xe06(%rip),%rsi
mov    $0x17,%edx
lea    0xe10(%rip),%rcx
call   1090 <fprintf@plt>
movl   $0xffffffff,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
call   10a0 <atoi@plt>
mov    %eax,-0x40(%rbp)
cmpl   $0x2,-0x40(%rbp)
jge    1266 <main+0xc6>
mov    0x2da0(%rip),%rax
mov    (%rax),%edi
lea    0xdbf(%rip),%rsi
mov    $0x18,%edx
lea    0xdc9(%rip),%rcx
call   1090 <fprintf@plt>
movl   $0xffffffff,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdi
call   10a0 <atoi@plt>
mov    %eax,-0x3c(%rbp)
cmpl   $0x2,-0x3c(%rbp)
jge    12ad <main+0x10d>
mov    0x2d59(%rip),%rax
mov    (%rax),%edi
lea    0xd78(%rip),%rsi
mov    $0x19,%edx
lea    0xd82(%rip),%rcx
call   1090 <fprintf@plt>
movl   $0xffffffff,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x10(%rbp),%rax
mov    0x18(%rax),%rdi
call   10a0 <atoi@plt>
mov    %eax,-0x44(%rbp)
cmpl   $0x1,-0x44(%rbp)
jge    12f4 <main+0x154>
mov    0x2d12(%rip),%rax
mov    (%rax),%edi
lea    0xd31(%rip),%rsi
mov    $0x1a,%edx
lea    0xd3b(%rip),%rcx
call   1090 <fprintf@plt>
movl   $0xffffffff,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x40(%rbp),%edi
mov    -0x3c(%rbp),%esi
lea    -0x50(%rbp),%rdx
call   1050 <alloc_matrix@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    133c <main+0x19c>
mov    0x2cc9(%rip),%rax
mov    (%rax),%edi
lea    0xce8(%rip),%rsi
mov    $0x1c,%edx
lea    0xcf2(%rip),%rcx
call   1090 <fprintf@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x3c(%rbp),%edi
mov    -0x44(%rbp),%esi
lea    -0x58(%rbp),%rdx
call   1050 <alloc_matrix@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    1384 <main+0x1e4>
mov    0x2c81(%rip),%rax
mov    (%rax),%edi
lea    0xca0(%rip),%rsi
mov    $0x1d,%edx
lea    0xcaa(%rip),%rcx
call   1090 <fprintf@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x40(%rbp),%edi
mov    -0x44(%rbp),%esi
lea    -0x60(%rbp),%rdx
call   1050 <alloc_matrix@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    13cc <main+0x22c>
mov    0x2c39(%rip),%rax
mov    (%rax),%edi
lea    0xc58(%rip),%rsi
mov    $0x1e,%edx
lea    0xc62(%rip),%rcx
call   1090 <fprintf@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x40(%rbp),%edi
mov    -0x44(%rbp),%esi
lea    -0x70(%rbp),%rdx
call   1050 <alloc_matrix@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    1414 <main+0x274>
mov    0x2bf1(%rip),%rax
mov    (%rax),%edi
lea    0xc10(%rip),%rsi
mov    $0x1f,%edx
lea    0xc1a(%rip),%rcx
call   1090 <fprintf@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x40(%rbp),%edi
mov    -0x44(%rbp),%esi
lea    -0x68(%rbp),%rdx
call   1050 <alloc_matrix@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    145c <main+0x2bc>
mov    0x2ba9(%rip),%rax
mov    (%rax),%edi
lea    0xbc8(%rip),%rsi
mov    $0x20,%edx
lea    0xbd2(%rip),%rcx
call   1090 <fprintf@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x50(%rbp),%rdi
mov    -0x40(%rbp),%esi
mov    -0x3c(%rbp),%edx
call   1080 <set_matrix@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    14a4 <main+0x304>
mov    0x2b61(%rip),%rax
mov    (%rax),%edi
lea    0xb80(%rip),%rsi
mov    $0x22,%edx
lea    0xb8a(%rip),%rcx
call   1090 <fprintf@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x58(%rbp),%rdi
mov    -0x3c(%rbp),%esi
mov    -0x44(%rbp),%edx
call   1080 <set_matrix@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    14ec <main+0x34c>
mov    0x2b19(%rip),%rax
mov    (%rax),%edi
lea    0xb38(%rip),%rsi
mov    $0x23,%edx
lea    0xb42(%rip),%rcx
call   1090 <fprintf@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    $0x0,%al
call   10b0 <RDTSC@plt>
mov    %rax,-0x20(%rbp)
mov    -0x50(%rbp),%rdi
mov    -0x58(%rbp),%rsi
mov    -0x68(%rbp),%rdx
mov    -0x40(%rbp),%ecx
mov    -0x3c(%rbp),%r8d
mov    -0x44(%rbp),%r9d
call   1030 <mm_simple@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    154c <main+0x3ac>
mov    0x2ab9(%rip),%rax
mov    (%rax),%edi
lea    0xad8(%rip),%rsi
mov    $0x26,%edx
lea    0xae2(%rip),%rcx
call   1090 <fprintf@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    $0x0,%al
call   10b0 <RDTSC@plt>
sub    -0x20(%rbp),%rax
mov    %rax,-0x28(%rbp)
mov    -0x28(%rbp),%rsi
lea    0xb51(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    $0x0,%al
call   10b0 <RDTSC@plt>
mov    %rax,-0x20(%rbp)
mov    -0x50(%rbp),%rdi
mov    -0x58(%rbp),%rsi
mov    -0x60(%rbp),%rdx
mov    -0x40(%rbp),%ecx
mov    -0x3c(%rbp),%r8d
mov    -0x44(%rbp),%r9d
call   10c0 <mm_fast_many_cols@plt>
mov    %eax,-0x14(%rbp)
cmpl   $0x0,-0x14(%rbp)
jge    15cd <main+0x42d>
mov    0x2a38(%rip),%rax
mov    (%rax),%edi
lea    0xa57(%rip),%rsi
mov    $0x2d,%edx
lea    0xa61(%rip),%rcx
call   1090 <fprintf@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    $0x0,%al
call   10b0 <RDTSC@plt>
sub    -0x20(%rbp),%rax
mov    %rax,-0x30(%rbp)
mov    -0x30(%rbp),%rsi
lea    0xae5(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
cvtsi2sdq -0x28(%rbp),%xmm0
cvtsi2sdq -0x30(%rbp),%xmm1
divsd  %xmm1,%xmm0
lea    0xadb(%rip),%rdi
mov    $0x1,%al
call   1060 <printf@plt>
movsd  0x9ec(%rip),%xmm0
movsd  %xmm0,-0x78(%rbp)
mov    -0x60(%rbp),%rdi
mov    -0x68(%rbp),%rsi
mov    -0x40(%rbp),%edx
mov    -0x44(%rbp),%ecx
movsd  -0x78(%rbp),%xmm0
call   1070 <cmp_matrix@plt>
cmp    $0x0,%rax
jne    165d <main+0x4bd>
mov    -0x70(%rbp),%rdi
mov    -0x68(%rbp),%rsi
mov    -0x40(%rbp),%edx
mov    -0x44(%rbp),%ecx
movsd  -0x78(%rbp),%xmm0
call   1070 <cmp_matrix@plt>
cmp    $0x0,%rax
je     1670 <main+0x4d0>
lea    0xa8c(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
jmp    16ab <main+0x50b>
lea    0xa82(%rip),%rdi
mov    $0x0,%al
call   1060 <printf@plt>
mov    0x295b(%rip),%rax
mov    (%rax),%edi
lea    0x97a(%rip),%rsi
mov    $0x40,%edx
lea    0x984(%rip),%rcx
call   1090 <fprintf@plt>
movl   $0xffffffff,-0x14(%rbp)
jmp    16db <main+0x53b>
mov    -0x50(%rbp),%rdi
mov    -0x3c(%rbp),%esi
call   1040 <free_matrix@plt>
mov    -0x58(%rbp),%rdi
mov    -0x44(%rbp),%esi
call   1040 <free_matrix@plt>
mov    -0x60(%rbp),%rdi
mov    -0x44(%rbp),%esi
call   1040 <free_matrix@plt>
mov    -0x68(%rbp),%rdi
mov    -0x44(%rbp),%esi
call   1040 <free_matrix@plt>
mov    -0x14(%rbp),%eax
add    $0x80,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x28,%rsp
movq   $0x0,0x10(%rsp)
movq   $0x0,0x8(%rsp)
movq   $0x0,0x18(%rsp)
movq   $0x0,(%rsp)
movq   $0x0,0x20(%rsp)
cmp    $0x4,%edi
jne    1221 <main+0x71>
mov    %rsi,%rbx
mov    0x8(%rsi),%rdi
call   10b0 <atoi@plt>
cmp    $0x1,%eax
jg     1242 <main+0x92>
mov    0x2dd9(%rip),%rax
mov    (%rax),%edi
lea    0xdf8(%rip),%rsi
lea    0xe07(%rip),%rcx
mov    $0x18,%edx
jmp    1484 <main+0x2d4>
mov    0x2db8(%rip),%rax
mov    (%rax),%edi
lea    0xdd7(%rip),%rsi
lea    0xde6(%rip),%rcx
mov    $0x17,%edx
jmp    1484 <main+0x2d4>
mov    %eax,%ebp
mov    0x10(%rbx),%rdi
call   10b0 <atoi@plt>
cmp    $0x1,%eax
jg     1273 <main+0xc3>
mov    0x2d87(%rip),%rax
mov    (%rax),%edi
lea    0xda6(%rip),%rsi
lea    0xdb5(%rip),%rcx
mov    $0x19,%edx
jmp    1484 <main+0x2d4>
mov    %eax,%r15d
mov    0x18(%rbx),%rdi
call   10b0 <atoi@plt>
test   %eax,%eax
jle    1468 <main+0x2b8>
mov    %eax,%r14d
lea    0x10(%rsp),%rdx
mov    %ebp,%edi
mov    %r15d,%esi
call   1060 <alloc_matrix@plt>
test   %eax,%eax
js     149f <main+0x2ef>
lea    0x8(%rsp),%rdx
mov    %r15d,%edi
mov    %r14d,%esi
call   1060 <alloc_matrix@plt>
test   %eax,%eax
js     14c4 <main+0x314>
lea    0x18(%rsp),%rdx
mov    %ebp,%edi
mov    %r14d,%esi
call   1060 <alloc_matrix@plt>
test   %eax,%eax
js     14e9 <main+0x339>
lea    0x20(%rsp),%rdx
mov    %ebp,%edi
mov    %r14d,%esi
call   1060 <alloc_matrix@plt>
test   %eax,%eax
js     150e <main+0x35e>
mov    %rsp,%rdx
mov    %ebp,%edi
mov    %r14d,%esi
call   1060 <alloc_matrix@plt>
test   %eax,%eax
js     1536 <main+0x386>
mov    0x10(%rsp),%rdi
mov    %ebp,%esi
mov    %r15d,%edx
call   1090 <set_matrix@plt>
test   %eax,%eax
js     155e <main+0x3ae>
mov    0x8(%rsp),%rdi
mov    %r15d,%esi
mov    %r14d,%edx
call   1090 <set_matrix@plt>
test   %eax,%eax
js     1586 <main+0x3d6>
xor    %eax,%eax
call   10c0 <RDTSC@plt>
mov    %rax,%r13
mov    0x10(%rsp),%rdi
mov    0x8(%rsp),%rsi
mov    (%rsp),%rdx
mov    %ebp,%ecx
mov    %r15d,%r8d
mov    %r14d,%r9d
call   1030 <mm_simple@plt>
test   %eax,%eax
js     15ae <main+0x3fe>
xor    %eax,%eax
call   10c0 <RDTSC@plt>
mov    %rax,%r12
sub    %r13,%r12
lea    0xd4b(%rip),%rdi
mov    %r12,%rsi
xor    %eax,%eax
call   1070 <printf@plt>
xor    %eax,%eax
call   10c0 <RDTSC@plt>
mov    %rax,%r13
mov    0x10(%rsp),%rdi
mov    0x8(%rsp),%rsi
mov    0x18(%rsp),%rdx
mov    %ebp,%ecx
mov    %r15d,%r8d
mov    %r14d,%r9d
call   10d0 <mm_fast_many_cols@plt>
mov    %eax,%ebx
test   %eax,%eax
js     15d6 <main+0x426>
xor    %eax,%eax
call   10c0 <RDTSC@plt>
mov    %r13,%rcx
mov    %rax,%r13
sub    %rcx,%r13
lea    0xd0f(%rip),%rdi
mov    %r13,%rsi
xor    %eax,%eax
call   1070 <printf@plt>
cvtsi2sd %r12,%xmm0
cvtsi2sd %r13,%xmm1
divsd  %xmm1,%xmm0
lea    0xd04(%rip),%rdi
mov    $0x1,%al
call   1070 <printf@plt>
mov    0x18(%rsp),%rdi
mov    (%rsp),%rsi
movsd  0xc0c(%rip),%xmm0
mov    %ebp,%edx
mov    %r14d,%ecx
call   1080 <cmp_matrix@plt>
test   %rax,%rax
jne    1427 <main+0x277>
mov    0x20(%rsp),%rdi
mov    (%rsp),%rsi
movsd  0xbec(%rip),%xmm0
mov    %ebp,%edx
mov    %r14d,%ecx
call   1080 <cmp_matrix@plt>
test   %rax,%rax
je     15fc <main+0x44c>
lea    0xcca(%rip),%rdi
call   1040 <puts@plt>
mov    0x10(%rsp),%rdi
mov    %r15d,%esi
call   1050 <free_matrix@plt>
mov    0x8(%rsp),%rdi
mov    %r14d,%esi
call   1050 <free_matrix@plt>
mov    0x18(%rsp),%rdi
mov    %r14d,%esi
call   1050 <free_matrix@plt>
mov    (%rsp),%rdi
mov    %r14d,%esi
call   1050 <free_matrix@plt>
jmp    148e <main+0x2de>
mov    0x2b71(%rip),%rax
mov    (%rax),%edi
lea    0xb90(%rip),%rsi
lea    0xb9f(%rip),%rcx
mov    $0x1a,%edx
call   10a0 <fprintf@plt>
mov    $0xffffffff,%ebx
mov    %ebx,%eax
add    $0x28,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
mov    %eax,%ebx
mov    0x2b38(%rip),%rax
mov    (%rax),%edi
lea    0xb57(%rip),%rsi
lea    0xb66(%rip),%rcx
mov    $0x1c,%edx
call   10a0 <fprintf@plt>
jmp    148e <main+0x2de>
mov    %eax,%ebx
mov    0x2b13(%rip),%rax
mov    (%rax),%edi
lea    0xb32(%rip),%rsi
lea    0xb41(%rip),%rcx
mov    $0x1d,%edx
call   10a0 <fprintf@plt>
jmp    148e <main+0x2de>
mov    %eax,%ebx
mov    0x2aee(%rip),%rax
mov    (%rax),%edi
lea    0xb0d(%rip),%rsi
lea    0xb1c(%rip),%rcx
mov    $0x1e,%edx
call   10a0 <fprintf@plt>
jmp    148e <main+0x2de>
mov    %eax,%ebx
mov    0x2ac9(%rip),%rax
mov    (%rax),%edi
lea    0xae8(%rip),%rsi
lea    0xaf7(%rip),%rcx
mov    $0x1f,%edx
call   10a0 <fprintf@plt>
jmp    148e <main+0x2de>
mov    %eax,%ebx
mov    0x2aa1(%rip),%rax
mov    (%rax),%edi
lea    0xac0(%rip),%rsi
lea    0xacf(%rip),%rcx
mov    $0x20,%edx
call   10a0 <fprintf@plt>
jmp    148e <main+0x2de>
mov    %eax,%ebx
mov    0x2a79(%rip),%rax
mov    (%rax),%edi
lea    0xa98(%rip),%rsi
lea    0xaa7(%rip),%rcx
mov    $0x22,%edx
call   10a0 <fprintf@plt>
jmp    148e <main+0x2de>
mov    %eax,%ebx
mov    0x2a51(%rip),%rax
mov    (%rax),%edi
lea    0xa70(%rip),%rsi
lea    0xa7f(%rip),%rcx
mov    $0x23,%edx
call   10a0 <fprintf@plt>
jmp    148e <main+0x2de>
mov    %eax,%ebx
mov    0x2a29(%rip),%rax
mov    (%rax),%edi
lea    0xa48(%rip),%rsi
lea    0xa57(%rip),%rcx
mov    $0x26,%edx
call   10a0 <fprintf@plt>
jmp    148e <main+0x2de>
mov    0x2a03(%rip),%rax
mov    (%rax),%edi
lea    0xa22(%rip),%rsi
lea    0xa31(%rip),%rcx
mov    $0x2d,%edx
call   10a0 <fprintf@plt>
jmp    148e <main+0x2de>
lea    0xaed(%rip),%rdi
call   1040 <puts@plt>
mov    0x29d1(%rip),%rax
mov    (%rax),%edi
lea    0x9f0(%rip),%rsi
lea    0x9ff(%rip),%rcx
mov    $0x40,%edx
jmp    1484 <main+0x2d4>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [22 x i8] c"Line %3d of File %s \0A\00"
@.str.1 = [153 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/heads/master/OPERATORS/MM/src/driver_mm.c\00"
@.str.2 = [21 x i8] c"simple time = %llu \0A\00"
@.str.3 = [20 x i8] c"fast time = %llu \0A\00"
@.str.4 = [16 x i8] c"speedup = %lf \0A\00"
@.str.5 = [9 x i8] c"SUCCESS\0A\00"
@.str.6 = [9 x i8] c"FAILURE\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i64
%8 = alloca i64
%9 = alloca i64
%10 = alloca i64
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca double**
%15 = alloca double**
%16 = alloca double**
%17 = alloca double**
%18 = alloca double**
%19 = alloca double
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 0, i32* %6
store double** null, double*** %14
store double** null, double*** %15
store double** null, double*** %16
store double** null, double*** %17
store double** null, double*** %18
%20 = load i32, i32* %4
%21 = icmp ne i32 %20, 4
br i1 %21, label %22, label %25
22: ; preds = %2
%23 = load i32, i32* @stderr
%24 = call i32 @fprintf(i32 %23, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 23, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
store i32 -1, i32* %6
br label %208
25: ; preds = %2
%26 = load i8**, i8*** %5
%27 = getelementptr inbounds i8*, i8** %26, i64 1
%28 = load i8*, i8** %27
%29 = call i32 @atoi(i8* %28)
store i32 %29, i32* %12
%30 = load i32, i32* %12
%31 = icmp slt i32 %30, 2
br i1 %31, label %32, label %35
32: ; preds = %25
%33 = load i32, i32* @stderr
%34 = call i32 @fprintf(i32 %33, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 24, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
store i32 -1, i32* %6
br label %208
35: ; preds = %25
%36 = load i8**, i8*** %5
%37 = getelementptr inbounds i8*, i8** %36, i64 2
%38 = load i8*, i8** %37
%39 = call i32 @atoi(i8* %38)
store i32 %39, i32* %11
%40 = load i32, i32* %11
%41 = icmp slt i32 %40, 2
br i1 %41, label %42, label %45
42: ; preds = %35
%43 = load i32, i32* @stderr
%44 = call i32 @fprintf(i32 %43, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 25, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
store i32 -1, i32* %6
br label %208
45: ; preds = %35
%46 = load i8**, i8*** %5
%47 = getelementptr inbounds i8*, i8** %46, i64 3
%48 = load i8*, i8** %47
%49 = call i32 @atoi(i8* %48)
store i32 %49, i32* %13
%50 = load i32, i32* %13
%51 = icmp slt i32 %50, 1
br i1 %51, label %52, label %55
52: ; preds = %45
%53 = load i32, i32* @stderr
%54 = call i32 @fprintf(i32 %53, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 26, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
store i32 -1, i32* %6
br label %208
55: ; preds = %45
%56 = load i32, i32* %12
%57 = load i32, i32* %11
%58 = call i32 @alloc_matrix(i32 %56, i32 %57, double*** %14)
store i32 %58, i32* %6
%59 = load i32, i32* %6
%60 = icmp slt i32 %59, 0
br i1 %60, label %61, label %65
61: ; preds = %55
%62 = load i32, i32* @stderr
%63 = call i32 @fprintf(i32 %62, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 28, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
%64 = load i32, i32* %6
store i32 %64, i32* %6
br label %208
65: ; preds = %55
%66 = load i32, i32* %11
%67 = load i32, i32* %13
%68 = call i32 @alloc_matrix(i32 %66, i32 %67, double*** %15)
store i32 %68, i32* %6
%69 = load i32, i32* %6
%70 = icmp slt i32 %69, 0
br i1 %70, label %71, label %75
71: ; preds = %65
%72 = load i32, i32* @stderr
%73 = call i32 @fprintf(i32 %72, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 29, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
%74 = load i32, i32* %6
store i32 %74, i32* %6
br label %208
75: ; preds = %65
%76 = load i32, i32* %12
%77 = load i32, i32* %13
%78 = call i32 @alloc_matrix(i32 %76, i32 %77, double*** %16)
store i32 %78, i32* %6
%79 = load i32, i32* %6
%80 = icmp slt i32 %79, 0
br i1 %80, label %81, label %85
81: ; preds = %75
%82 = load i32, i32* @stderr
%83 = call i32 @fprintf(i32 %82, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 30, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
%84 = load i32, i32* %6
store i32 %84, i32* %6
br label %208
85: ; preds = %75
%86 = load i32, i32* %12
%87 = load i32, i32* %13
%88 = call i32 @alloc_matrix(i32 %86, i32 %87, double*** %18)
store i32 %88, i32* %6
%89 = load i32, i32* %6
%90 = icmp slt i32 %89, 0
br i1 %90, label %91, label %95
91: ; preds = %85
%92 = load i32, i32* @stderr
%93 = call i32 @fprintf(i32 %92, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 31, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
%94 = load i32, i32* %6
store i32 %94, i32* %6
br label %208
95: ; preds = %85
%96 = load i32, i32* %12
%97 = load i32, i32* %13
%98 = call i32 @alloc_matrix(i32 %96, i32 %97, double*** %17)
store i32 %98, i32* %6
%99 = load i32, i32* %6
%100 = icmp slt i32 %99, 0
br i1 %100, label %101, label %105
101: ; preds = %95
%102 = load i32, i32* @stderr
%103 = call i32 @fprintf(i32 %102, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 32, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
%104 = load i32, i32* %6
store i32 %104, i32* %6
br label %208
105: ; preds = %95
%106 = load double**, double*** %14
%107 = load i32, i32* %12
%108 = load i32, i32* %11
%109 = call i32 @set_matrix(double** %106, i32 %107, i32 %108)
store i32 %109, i32* %6
%110 = load i32, i32* %6
%111 = icmp slt i32 %110, 0
br i1 %111, label %112, label %116
112: ; preds = %105
%113 = load i32, i32* @stderr
%114 = call i32 @fprintf(i32 %113, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 34, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
%115 = load i32, i32* %6
store i32 %115, i32* %6
br label %208
116: ; preds = %105
%117 = load double**, double*** %15
%118 = load i32, i32* %11
%119 = load i32, i32* %13
%120 = call i32 @set_matrix(double** %117, i32 %118, i32 %119)
store i32 %120, i32* %6
%121 = load i32, i32* %6
%122 = icmp slt i32 %121, 0
br i1 %122, label %123, label %127
123: ; preds = %116
%124 = load i32, i32* @stderr
%125 = call i32 @fprintf(i32 %124, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 35, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
%126 = load i32, i32* %6
store i32 %126, i32* %6
br label %208
127: ; preds = %116
%128 = call i64 (...) @RDTSC()
store i64 %128, i64* %7
%129 = load double**, double*** %14
%130 = load double**, double*** %15
%131 = load double**, double*** %17
%132 = load i32, i32* %12
%133 = load i32, i32* %11
%134 = load i32, i32* %13
%135 = call i32 @mm_simple(double** %129, double** %130, double** %131, i32 %132, i32 %133, i32 %134)
store i32 %135, i32* %6
%136 = load i32, i32* %6
%137 = icmp slt i32 %136, 0
br i1 %137, label %138, label %142
138: ; preds = %127
%139 = load i32, i32* @stderr
%140 = call i32 @fprintf(i32 %139, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 38, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
%141 = load i32, i32* %6
store i32 %141, i32* %6
br label %208
142: ; preds = %127
%143 = call i64 (...) @RDTSC()
%144 = load i64, i64* %7
%145 = sub nsw i64 %143, %144
store i64 %145, i64* %8
%146 = load i64, i64* %8
%147 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.2, i64 0, i64 0), i64 %146)
%148 = call i64 (...) @RDTSC()
store i64 %148, i64* %7
%149 = load double**, double*** %14
%150 = load double**, double*** %15
%151 = load double**, double*** %16
%152 = load i32, i32* %12
%153 = load i32, i32* %11
%154 = load i32, i32* %13
%155 = call i32 @mm_fast_many_cols(double** %149, double** %150, double** %151, i32 %152, i32 %153, i32 %154)
store i32 %155, i32* %6
%156 = load i32, i32* %6
%157 = icmp slt i32 %156, 0
br i1 %157, label %158, label %162
158: ; preds = %142
%159 = load i32, i32* @stderr
%160 = call i32 @fprintf(i32 %159, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 45, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
%161 = load i32, i32* %6
store i32 %161, i32* %6
br label %208
162: ; preds = %142
%163 = call i64 (...) @RDTSC()
%164 = load i64, i64* %7
%165 = sub nsw i64 %163, %164
store i64 %165, i64* %9
%166 = load i64, i64* %9
%167 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.3, i64 0, i64 0), i64 %166)
%168 = load i64, i64* %8
%169 = sitofp i64 %168 to double
%170 = load i64, i64* %9
%171 = sitofp i64 %170 to double
%172 = fdiv double %169, %171
%173 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.4, i64 0, i64 0), double %172)
store double 1.000000e-05, double* %19
%174 = load double**, double*** %16
%175 = load double**, double*** %17
%176 = load i32, i32* %12
%177 = load i32, i32* %13
%178 = load double, double* %19
%179 = call i64 @cmp_matrix(double** %174, double** %175, i32 %176, i32 %177, double %178)
%180 = icmp ne i64 %179, 0
br i1 %180, label %189, label %181
181: ; preds = %162
%182 = load double**, double*** %18
%183 = load double**, double*** %17
%184 = load i32, i32* %12
%185 = load i32, i32* %13
%186 = load double, double* %19
%187 = call i64 @cmp_matrix(double** %182, double** %183, i32 %184, i32 %185, double %186)
%188 = icmp ne i64 %187, 0
br i1 %188, label %189, label %191
189: ; preds = %181, %162
%190 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.5, i64 0, i64 0))
br label %195
191: ; preds = %181
%192 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.6, i64 0, i64 0))
%193 = load i32, i32* @stderr
%194 = call i32 @fprintf(i32 %193, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 64, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
store i32 -1, i32* %6
br label %208
195: ; preds = %189
%196 = load double**, double*** %14
%197 = load i32, i32* %11
%198 = call i32 @free_matrix(double** %196, i32 %197)
%199 = load double**, double*** %15
%200 = load i32, i32* %13
%201 = call i32 @free_matrix(double** %199, i32 %200)
%202 = load double**, double*** %16
%203 = load i32, i32* %13
%204 = call i32 @free_matrix(double** %202, i32 %203)
%205 = load double**, double*** %17
%206 = load i32, i32* %13
%207 = call i32 @free_matrix(double** %205, i32 %206)
br label %208
208: ; preds = %195, %191, %158, %138, %123, %112, %101, %91, %81, %71, %61, %52, %42, %32, %22
%209 = load i32, i32* %6
ret i32 %209
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [22 x i8] c"Line %3d of File %s \0A\00"
@.str.1 = [153 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/NerdWalletOSS/Q/refs/heads/master/OPERATORS/MM/src/driver_mm.c\00"
@.str.2 = [21 x i8] c"simple time = %llu \0A\00"
@.str.3 = [20 x i8] c"fast time = %llu \0A\00"
@.str.4 = [16 x i8] c"speedup = %lf \0A\00"
@str = [8 x i8] c"FAILURE\00"
@str.7 = [8 x i8] c"SUCCESS\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = alloca double**
%4 = alloca double**
%5 = alloca double**
%6 = alloca double**
%7 = alloca double**
%8 = bitcast double*** %3 to i8*
store double** null, double*** %3
%9 = bitcast double*** %4 to i8*
store double** null, double*** %4
%10 = bitcast double*** %5 to i8*
store double** null, double*** %5
%11 = bitcast double*** %6 to i8*
store double** null, double*** %6
%12 = bitcast double*** %7 to i8*
store double** null, double*** %7
%13 = icmp eq i32 %0, 4
br i1 %13, label %17, label %14
14: ; preds = %2
%15 = load i32, i32* @stderr
%16 = tail call i32 @fprintf(i32 %15, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 23, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
17: ; preds = %2
%18 = getelementptr inbounds i8*, i8** %1, i64 1
%19 = load i8*, i8** %18
%20 = tail call i32 @atoi(i8* %19)
%21 = icmp slt i32 %20, 2
br i1 %21, label %22, label %25
22: ; preds = %17
%23 = load i32, i32* @stderr
%24 = tail call i32 @fprintf(i32 %23, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 24, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
25: ; preds = %17
%26 = getelementptr inbounds i8*, i8** %1, i64 2
%27 = load i8*, i8** %26
%28 = tail call i32 @atoi(i8* %27)
%29 = icmp slt i32 %28, 2
br i1 %29, label %30, label %33
30: ; preds = %25
%31 = load i32, i32* @stderr
%32 = tail call i32 @fprintf(i32 %31, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 25, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
33: ; preds = %25
%34 = getelementptr inbounds i8*, i8** %1, i64 3
%35 = load i8*, i8** %34
%36 = tail call i32 @atoi(i8* %35)
%37 = icmp slt i32 %36, 1
br i1 %37, label %38, label %41
38: ; preds = %33
%39 = load i32, i32* @stderr
%40 = tail call i32 @fprintf(i32 %39, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 26, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
41: ; preds = %33
%42 = call i32 @alloc_matrix(i32 %20, i32 %28, double*** %3)
%43 = icmp slt i32 %42, 0
br i1 %43, label %44, label %47
44: ; preds = %41
%45 = load i32, i32* @stderr
%46 = call i32 @fprintf(i32 %45, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 28, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
47: ; preds = %41
%48 = call i32 @alloc_matrix(i32 %28, i32 %36, double*** %4)
%49 = icmp slt i32 %48, 0
br i1 %49, label %50, label %53
50: ; preds = %47
%51 = load i32, i32* @stderr
%52 = call i32 @fprintf(i32 %51, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 29, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
53: ; preds = %47
%54 = call i32 @alloc_matrix(i32 %20, i32 %36, double*** %5)
%55 = icmp slt i32 %54, 0
br i1 %55, label %56, label %59
56: ; preds = %53
%57 = load i32, i32* @stderr
%58 = call i32 @fprintf(i32 %57, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 30, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
59: ; preds = %53
%60 = call i32 @alloc_matrix(i32 %20, i32 %36, double*** %7)
%61 = icmp slt i32 %60, 0
br i1 %61, label %62, label %65
62: ; preds = %59
%63 = load i32, i32* @stderr
%64 = call i32 @fprintf(i32 %63, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 31, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
65: ; preds = %59
%66 = call i32 @alloc_matrix(i32 %20, i32 %36, double*** %6)
%67 = icmp slt i32 %66, 0
br i1 %67, label %68, label %71
68: ; preds = %65
%69 = load i32, i32* @stderr
%70 = call i32 @fprintf(i32 %69, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 32, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
71: ; preds = %65
%72 = load double**, double*** %3
%73 = call i32 @set_matrix(double** %72, i32 %20, i32 %28)
%74 = icmp slt i32 %73, 0
br i1 %74, label %75, label %78
75: ; preds = %71
%76 = load i32, i32* @stderr
%77 = call i32 @fprintf(i32 %76, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 34, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
78: ; preds = %71
%79 = load double**, double*** %4
%80 = call i32 @set_matrix(double** %79, i32 %28, i32 %36)
%81 = icmp slt i32 %80, 0
br i1 %81, label %82, label %85
82: ; preds = %78
%83 = load i32, i32* @stderr
%84 = call i32 @fprintf(i32 %83, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 35, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
85: ; preds = %78
%86 = call i64 (...) @RDTSC()
%87 = load double**, double*** %3
%88 = load double**, double*** %4
%89 = load double**, double*** %6
%90 = call i32 @mm_simple(double** %87, double** %88, double** %89, i32 %20, i32 %28, i32 %36)
%91 = icmp slt i32 %90, 0
br i1 %91, label %92, label %95
92: ; preds = %85
%93 = load i32, i32* @stderr
%94 = call i32 @fprintf(i32 %93, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 38, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
95: ; preds = %85
%96 = call i64 (...) @RDTSC()
%97 = sub nsw i64 %96, %86
%98 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str.2, i64 0, i64 0), i64 %97)
%99 = call i64 (...) @RDTSC()
%100 = load double**, double*** %3
%101 = load double**, double*** %4
%102 = load double**, double*** %5
%103 = call i32 @mm_fast_many_cols(double** %100, double** %101, double** %102, i32 %20, i32 %28, i32 %36)
%104 = icmp slt i32 %103, 0
br i1 %104, label %105, label %108
105: ; preds = %95
%106 = load i32, i32* @stderr
%107 = call i32 @fprintf(i32 %106, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 45, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
108: ; preds = %95
%109 = call i64 (...) @RDTSC()
%110 = sub nsw i64 %109, %99
%111 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.3, i64 0, i64 0), i64 %110)
%112 = sitofp i64 %97 to double
%113 = sitofp i64 %110 to double
%114 = fdiv double %112, %113
%115 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @.str.4, i64 0, i64 0), double %114)
%116 = load double**, double*** %5
%117 = load double**, double*** %6
%118 = call i64 @cmp_matrix(double** %116, double** %117, i32 %20, i32 %36, double 1.000000e-05)
%119 = icmp eq i64 %118, 0
br i1 %119, label %120, label %125
120: ; preds = %108
%121 = load double**, double*** %7
%122 = load double**, double*** %6
%123 = call i64 @cmp_matrix(double** %121, double** %122, i32 %20, i32 %36, double 1.000000e-05)
%124 = icmp eq i64 %123, 0
br i1 %124, label %135, label %125
125: ; preds = %120, %108
%126 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @str.7, i64 0, i64 0))
%127 = load double**, double*** %3
%128 = call i32 @free_matrix(double** %127, i32 %28)
%129 = load double**, double*** %4
%130 = call i32 @free_matrix(double** %129, i32 %36)
%131 = load double**, double*** %5
%132 = call i32 @free_matrix(double** %131, i32 %36)
%133 = load double**, double*** %6
%134 = call i32 @free_matrix(double** %133, i32 %36)
br label %139
135: ; preds = %120
%136 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @str, i64 0, i64 0))
%137 = load i32, i32* @stderr
%138 = call i32 @fprintf(i32 %137, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str, i64 0, i64 0), i32 64, i8* getelementptr inbounds ([153 x i8], [153 x i8]* @.str.1, i64 0, i64 0))
br label %139
139: ; preds = %125, %135, %105, %92, %82, %75, %68, %62, %56, %50, %44, %38, %30, %22, %14
%140 = phi i32 [ -1, %14 ], [ -1, %22 ], [ -1, %30 ], [ -1, %38 ], [ %42, %44 ], [ %48, %50 ], [ %54, %56 ], [ %60, %62 ], [ %66, %68 ], [ %73, %75 ], [ %80, %82 ], [ %90, %92 ], [ %103, %105 ], [ %103, %125 ], [ -1, %135 ]
ret i32 %140
}