#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__ clock_t;

/* Variables and functions */
float CLOCKS_PER_SEC;
scalar_t__ clock();
int /*<<< orphan*/ fgets(char *, int, int /*<<< orphan*/);
int /*<<< orphan*/ free(double *);
int /*<<< orphan*/ free_matrix(double **, int);
double **generate_random_matrix(int);
double *generate_random_vector(int);
int /*<<< orphan*/ printf(char *, ...);
int read_dimension();
double **read_matrix(char *, int);
double *read_vector(char *, int);
int /*<<< orphan*/ solveLU(int, double **, double *);
int /*<<< orphan*/ stdin;
int strlen(char *);
int /*<<< orphan*/ write_vector(char *, double *, int);
int main() {
  int n = 0;
  char filename[256];
  double **matrixA;
  clock_t time;
  double *vectorB;
  n = read_dimension();
  printf("Dimensio n=%d\n", n);
  printf("Arxiu matriu A? (buit per matriu random) ");
  fgets(filename, 255, stdin);
  if (filename[0] != '\n') {
    if (filename[strlen(filename) - 1] == '\n') {
      filename[strlen(filename) - 1] = '\0';
    }
    printf("\nMatriu de l'arxiu %s\n", filename);
    matrixA = read_matrix(filename, n);
  } else {
    printf("\nMatriu random\n");
    matrixA = generate_random_matrix(n);
  }
  printf("Arxiu vector b? (buit per vector random) ");
  fgets(filename, 255, stdin);
  if (filename[0] != '\n') {
    if (filename[strlen(filename) - 1] == '\n') {
      filename[strlen(filename) - 1] = '\0';
    }
    printf("\nVector de l'arxiu %s\n", filename);
    vectorB = read_vector(filename, n);
  } else {
    printf("\n Vector random\n");
    vectorB = generate_random_vector(n);
  }
  printf("Començant calcul LUx = b...\n");
  time = clock();
  solveLU(n, matrixA, vectorB);
  time = clock() - time;
  printf("Calcul finalitzat.\n");
  printf("S'escriura el vector X a l'arxiu output2.txt\n");
  write_vector("output2.txt", vectorB, n);
  printf("n = %d, t = %.6f, t/n = %.6f\n", n, ((float)time) / CLOCKS_PER_SEC,
         (((float)time) / CLOCKS_PER_SEC) / n);
  free_matrix(matrixA, n);
  free(vectorB);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x130,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x8(%rbp)
mov    $0x0,%al
call   10e0 <read_dimension@plt>
mov    %eax,-0x8(%rbp)
mov    -0x8(%rbp),%esi
lea    0xe03(%rip),%rdi
mov    $0x0,%al
call   1070 <printf@plt>
lea    0xe04(%rip),%rdi
mov    $0x0,%al
call   1070 <printf@plt>
lea    -0x110(%rbp),%rdi
mov    0x2dc8(%rip),%rax
mov    (%rax),%edx
mov    $0xff,%esi
call   10a0 <fgets@plt>
movsbl -0x110(%rbp),%eax
cmp    $0xa,%eax
je     12a7 <main+0xd7>
lea    -0x110(%rbp),%rdi
call   1060 <strlen@plt>
sub    $0x1,%eax
cltq
movsbl -0x110(%rbp,%rax,1),%eax
ff
cmp    $0xa,%eax
jne    1277 <main+0xa7>
lea    -0x110(%rbp),%rdi
call   1060 <strlen@plt>
sub    $0x1,%eax
cltq
movb   $0x0,-0x110(%rbp,%rax,1)
lea    -0x110(%rbp),%rsi
lea    0xdb4(%rip),%rdi
mov    $0x0,%al
call   1070 <printf@plt>
lea    -0x110(%rbp),%rdi
mov    -0x8(%rbp),%esi
call   10d0 <read_matrix@plt>
mov    %rax,-0x118(%rbp)
jmp    12c4 <main+0xf4>
lea    0xda2(%rip),%rdi
mov    $0x0,%al
call   1070 <printf@plt>
mov    -0x8(%rbp),%edi
call   1080 <generate_random_matrix@plt>
mov    %rax,-0x118(%rbp)
lea    0xd95(%rip),%rdi
mov    $0x0,%al
call   1070 <printf@plt>
lea    -0x110(%rbp),%rdi
mov    0x2d08(%rip),%rax
mov    (%rax),%edx
mov    $0xff,%esi
call   10a0 <fgets@plt>
movsbl -0x110(%rbp),%eax
cmp    $0xa,%eax
je     1367 <main+0x197>
lea    -0x110(%rbp),%rdi
call   1060 <strlen@plt>
sub    $0x1,%eax
cltq
movsbl -0x110(%rbp,%rax,1),%eax
ff
cmp    $0xa,%eax
jne    1337 <main+0x167>
lea    -0x110(%rbp),%rdi
call   1060 <strlen@plt>
sub    $0x1,%eax
cltq
movb   $0x0,-0x110(%rbp,%rax,1)
lea    -0x110(%rbp),%rsi
lea    0xd45(%rip),%rdi
mov    $0x0,%al
call   1070 <printf@plt>
lea    -0x110(%rbp),%rdi
mov    -0x8(%rbp),%esi
call   10b0 <read_vector@plt>
mov    %rax,-0x128(%rbp)
jmp    1384 <main+0x1b4>
lea    0xd33(%rip),%rdi
mov    $0x0,%al
call   1070 <printf@plt>
mov    -0x8(%rbp),%edi
call   1090 <generate_random_vector@plt>
mov    %rax,-0x128(%rbp)
lea    0xd27(%rip),%rdi
mov    $0x0,%al
call   1070 <printf@plt>
mov    $0x0,%al
call   1050 <clock@plt>
mov    %rax,-0x120(%rbp)
mov    -0x8(%rbp),%edi
mov    -0x118(%rbp),%rsi
mov    -0x128(%rbp),%rdx
call   10f0 <solveLU@plt>
mov    $0x0,%al
call   1050 <clock@plt>
sub    -0x120(%rbp),%rax
mov    %rax,-0x120(%rbp)
lea    0xcfe(%rip),%rdi
mov    $0x0,%al
call   1070 <printf@plt>
lea    0xd04(%rip),%rdi
mov    $0x0,%al
call   1070 <printf@plt>
mov    -0x128(%rbp),%rsi
mov    -0x8(%rbp),%edx
lea    0xd1a(%rip),%rdi
call   10c0 <write_vector@plt>
mov    -0x8(%rbp),%esi
cvtsi2ssq -0x120(%rbp),%xmm0
ff ff
mov    0x2bd0(%rip),%rax
divss  (%rax),%xmm0
cvtss2sd %xmm0,%xmm0
cvtsi2ssq -0x120(%rbp),%xmm1
ff ff
mov    0x2bb8(%rip),%rax
divss  (%rax),%xmm1
cvtsi2ssl -0x8(%rbp),%xmm2
divss  %xmm2,%xmm1
cvtss2sd %xmm1,%xmm1
lea    0xcde(%rip),%rdi
mov    $0x2,%al
call   1070 <printf@plt>
mov    -0x118(%rbp),%rdi
mov    -0x8(%rbp),%esi
call   1040 <free_matrix@plt>
mov    -0x128(%rbp),%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x130,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x100,%rsp
xor    %eax,%eax
call   10f0 <read_dimension@plt>
mov    %eax,%r15d
lea    0xe00(%rip),%rdi
mov    %eax,%esi
xor    %eax,%eax
call   1080 <printf@plt>
lea    0xdff(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
mov    0x2dca(%rip),%rbp
mov    0x0(%rbp),%edx
mov    %rsp,%rbx
mov    %rbx,%rdi
mov    $0xff,%esi
call   10b0 <fgets@plt>
cmpb   $0xa,(%rsp)
jne    124d <main+0x6d>
lea    0xe71(%rip),%rdi
call   1040 <puts@plt>
mov    %r15d,%edi
call   1090 <generate_random_matrix@plt>
jmp    128c <main+0xac>
mov    %rbx,%rdi
call   1070 <strlen@plt>
cltq
cmpb   $0xa,-0x1(%rax,%rbx,1)
jne    126d <main+0x8d>
mov    %rbx,%rdi
call   1070 <strlen@plt>
cltq
movb   $0x0,-0x1(%rax,%rbx,1)
lea    0xdc5(%rip),%rdi
mov    %rsp,%rbx
mov    %rbx,%rsi
xor    %eax,%eax
call   1080 <printf@plt>
mov    %rbx,%rdi
mov    %r15d,%esi
call   10e0 <read_matrix@plt>
mov    %rax,%r14
lea    0xdba(%rip),%rdi
xor    %eax,%eax
call   1080 <printf@plt>
mov    0x0(%rbp),%edx
mov    %rsp,%rbx
mov    %rbx,%rdi
mov    $0xff,%esi
call   10b0 <fgets@plt>
cmpb   $0xa,(%rsp)
jne    12cc <main+0xec>
lea    0xe01(%rip),%rdi
call   1040 <puts@plt>
mov    %r15d,%edi
call   10a0 <generate_random_vector@plt>
jmp    130b <main+0x12b>
mov    %rbx,%rdi
call   1070 <strlen@plt>
cltq
cmpb   $0xa,-0x1(%rax,%rbx,1)
jne    12ec <main+0x10c>
mov    %rbx,%rdi
call   1070 <strlen@plt>
cltq
movb   $0x0,-0x1(%rax,%rbx,1)
lea    0xd87(%rip),%rdi
mov    %rsp,%rbx
mov    %rbx,%rsi
xor    %eax,%eax
call   1080 <printf@plt>
mov    %rbx,%rdi
mov    %r15d,%esi
call   10c0 <read_vector@plt>
mov    %rax,%r12
lea    0xdb9(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   1060 <clock@plt>
mov    %rax,%rbp
mov    %r15d,%edi
mov    %r14,%rsi
mov    %r12,%rdx
call   1100 <solveLU@plt>
xor    %eax,%eax
call   1060 <clock@plt>
mov    %rax,%rbx
sub    %rbp,%rbx
lea    0xda5(%rip),%rdi
call   1040 <puts@plt>
lea    0xdac(%rip),%rdi
call   1040 <puts@plt>
lea    0xdc1(%rip),%rdi
mov    %r12,%rsi
mov    %r15d,%edx
call   10d0 <write_vector@plt>
cvtsi2ss %rbx,%xmm1
mov    0x2c6b(%rip),%rax
divss  (%rax),%xmm1
cvtsi2ss %r15d,%xmm2
cvtss2sd %xmm1,%xmm0
divss  %xmm2,%xmm1
cvtss2sd %xmm1,%xmm1
lea    0xd00(%rip),%rdi
mov    %r15d,%esi
mov    $0x2,%al
call   1080 <printf@plt>
mov    %r14,%rdi
mov    %r15d,%esi
call   1050 <free_matrix@plt>
mov    %r12,%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x100,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [15 x i8] c"Dimensio n=%d\0A\00"
@.str.1 = [42 x i8] c"Arxiu matriu A? (buit per matriu random) \00"
@stdin = global i32 0
@.str.2 = [23 x i8] c"\0AMatriu de l'arxiu %s\0A\00"
@.str.3 = [16 x i8] c"\0AMatriu random\0A\00"
@.str.4 = [42 x i8] c"Arxiu vector b? (buit per vector random) \00"
@.str.5 = [23 x i8] c"\0AVector de l'arxiu %s\0A\00"
@.str.6 = [17 x i8] c"\0A Vector random\0A\00"
@.str.7 = [30 x i8] c"Comen\C3\A7ant calcul LUx = b...\0A\00"
@.str.8 = [20 x i8] c"Calcul finalitzat.\0A\00"
@.str.9 = [46 x i8] c"S'escriura el vector X a l'arxiu output2.txt\0A\00"
@.str.10 = [12 x i8] c"output2.txt\00"
@.str.11 = [30 x i8] c"n = %d, t = %.6f, t/n = %.6f\0A\00"
@CLOCKS_PER_SEC = global float 0.000000e+00
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca [256 x i8]
%4 = alloca double**
%5 = alloca i64
%6 = alloca double*
store i32 0, i32* %1
store i32 0, i32* %2
%7 = call i32 (...) @read_dimension()
store i32 %7, i32* %2
%8 = load i32, i32* %2
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), i32 %8)
%10 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.1, i64 0, i64 0))
%11 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%12 = load i32, i32* @stdin
%13 = call i32 @fgets(i8* %11, i32 255, i32 %12)
%14 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%15 = load i8, i8* %14
%16 = sext i8 %15 to i32
%17 = icmp ne i32 %16, 10
br i1 %17, label %18, label %39
18: ; preds = %0
%19 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%20 = call i32 @strlen(i8* %19)
%21 = sub nsw i32 %20, 1
%22 = sext i32 %21 to i64
%23 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 %22
%24 = load i8, i8* %23
%25 = sext i8 %24 to i32
%26 = icmp eq i32 %25, 10
br i1 %26, label %27, label %33
27: ; preds = %18
%28 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%29 = call i32 @strlen(i8* %28)
%30 = sub nsw i32 %29, 1
%31 = sext i32 %30 to i64
%32 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 %31
store i8 0, i8* %32
br label %33
33: ; preds = %27, %18
%34 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%35 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.2, i64 0, i64 0), i8* %34)
%36 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%37 = load i32, i32* %2
%38 = call double** @read_matrix(i8* %36, i32 %37)
store double** %38, double*** %4
br label %43
39: ; preds = %0
%40 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.3, i64 0, i64 0))
%41 = load i32, i32* %2
%42 = call double** @generate_random_matrix(i32 %41)
store double** %42, double*** %4
br label %43
43: ; preds = %39, %33
%44 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.4, i64 0, i64 0))
%45 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%46 = load i32, i32* @stdin
%47 = call i32 @fgets(i8* %45, i32 255, i32 %46)
%48 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%49 = load i8, i8* %48
%50 = sext i8 %49 to i32
%51 = icmp ne i32 %50, 10
br i1 %51, label %52, label %73
52: ; preds = %43
%53 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%54 = call i32 @strlen(i8* %53)
%55 = sub nsw i32 %54, 1
%56 = sext i32 %55 to i64
%57 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 %56
%58 = load i8, i8* %57
%59 = sext i8 %58 to i32
%60 = icmp eq i32 %59, 10
br i1 %60, label %61, label %67
61: ; preds = %52
%62 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%63 = call i32 @strlen(i8* %62)
%64 = sub nsw i32 %63, 1
%65 = sext i32 %64 to i64
%66 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 %65
store i8 0, i8* %66
br label %67
67: ; preds = %61, %52
%68 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%69 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.5, i64 0, i64 0), i8* %68)
%70 = getelementptr inbounds [256 x i8], [256 x i8]* %3, i64 0, i64 0
%71 = load i32, i32* %2
%72 = call double* @read_vector(i8* %70, i32 %71)
store double* %72, double** %6
br label %77
73: ; preds = %43
%74 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.6, i64 0, i64 0))
%75 = load i32, i32* %2
%76 = call double* @generate_random_vector(i32 %75)
store double* %76, double** %6
br label %77
77: ; preds = %73, %67
%78 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.7, i64 0, i64 0))
%79 = call i64 (...) @clock()
store i64 %79, i64* %5
%80 = load i32, i32* %2
%81 = load double**, double*** %4
%82 = load double*, double** %6
%83 = call i32 @solveLU(i32 %80, double** %81, double* %82)
%84 = call i64 (...) @clock()
%85 = load i64, i64* %5
%86 = sub nsw i64 %84, %85
store i64 %86, i64* %5
%87 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.8, i64 0, i64 0))
%88 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.9, i64 0, i64 0))
%89 = load double*, double** %6
%90 = load i32, i32* %2
%91 = call i32 @write_vector(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0), double* %89, i32 %90)
%92 = load i32, i32* %2
%93 = load i64, i64* %5
%94 = sitofp i64 %93 to float
%95 = load float, float* @CLOCKS_PER_SEC
%96 = fdiv float %94, %95
%97 = fpext float %96 to double
%98 = load i64, i64* %5
%99 = sitofp i64 %98 to float
%100 = load float, float* @CLOCKS_PER_SEC
%101 = fdiv float %99, %100
%102 = load i32, i32* %2
%103 = sitofp i32 %102 to float
%104 = fdiv float %101, %103
%105 = fpext float %104 to double
%106 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.11, i64 0, i64 0), i32 %92, double %97, double %105)
%107 = load double**, double*** %4
%108 = load i32, i32* %2
%109 = call i32 @free_matrix(double** %107, i32 %108)
%110 = load double*, double** %6
%111 = call i32 @free(double* %110)
ret i32 0
}

LLVM IR (-O2):
@.str = [15 x i8] c"Dimensio n=%d\0A\00"
@.str.1 = [42 x i8] c"Arxiu matriu A? (buit per matriu random) \00"
@stdin = global i32 0
@.str.2 = [23 x i8] c"\0AMatriu de l'arxiu %s\0A\00"
@.str.4 = [42 x i8] c"Arxiu vector b? (buit per vector random) \00"
@.str.5 = [23 x i8] c"\0AVector de l'arxiu %s\0A\00"
@.str.10 = [12 x i8] c"output2.txt\00"
@.str.11 = [30 x i8] c"n = %d, t = %.6f, t/n = %.6f\0A\00"
@CLOCKS_PER_SEC = global float 0.000000e+00
@str = [15 x i8] c"\0AMatriu random\00"
@str.12 = [16 x i8] c"\0A Vector random\00"
@str.13 = [29 x i8] c"Comen\C3\A7ant calcul LUx = b...\00"
@str.14 = [19 x i8] c"Calcul finalitzat.\00"
@str.15 = [45 x i8] c"S'escriura el vector X a l'arxiu output2.txt\00"
define i32 @main() {
%1 = alloca [256 x i8]
%2 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 0
%3 = tail call i32 (...) @read_dimension()
%4 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), i32 %3)
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([42 x i8], [42 x i8]* @.str.1, i64 0, i64 0))
%6 = load i32, i32* @stdin
%7 = call i32 @fgets(i8* %2, i32 255, i32 %6)
%8 = load i8, i8* %2
%9 = icmp eq i8 %8, 10
br i1 %9, label %25, label %10
10: ; preds = %0
%11 = call i32 @strlen(i8* %2)
%12 = add nsw i32 %11, -1
%13 = sext i32 %12 to i64
%14 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 %13
%15 = load i8, i8* %14
%16 = icmp eq i8 %15, 10
br i1 %16, label %17, label %22
17: ; preds = %10
%18 = call i32 @strlen(i8* %2)
%19 = add nsw i32 %18, -1
%20 = sext i32 %19 to i64
%21 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 %20
store i8 0, i8* %21
br label %22
22: ; preds = %17, %10
%23 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @.str.2, i64 0, i64 0), i8* %2)
%24 = call double** @read_matrix(i8* %2, i32 %3)
br label %28
25: ; preds = %0
%26 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @str, i64 0, i64 0))
%27 = call double** @generate_random_matrix(i32 %3)
br label %28
28: ; preds = %25, %22
%29 = phi double** [ %24, %22 ], [ %27, %25 ]
%30 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([42 x i8], [42 x i8]* @.str.4, i64 0, i64 0))
%31 = load i32, i32* @stdin
%32 = call i32 @fgets(i8* %2, i32 255, i32 %31)
%33 = load i8, i8* %2
%34 = icmp eq i8 %33, 10
br i1 %34, label %50, label %35
35: ; preds = %28
%36 = call i32 @strlen(i8* %2)
%37 = add nsw i32 %36, -1
%38 = sext i32 %37 to i64
%39 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 %38
%40 = load i8, i8* %39
%41 = icmp eq i8 %40, 10
br i1 %41, label %42, label %47
42: ; preds = %35
%43 = call i32 @strlen(i8* %2)
%44 = add nsw i32 %43, -1
%45 = sext i32 %44 to i64
%46 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 %45
store i8 0, i8* %46
br label %47
47: ; preds = %42, %35
%48 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @.str.5, i64 0, i64 0), i8* %2)
%49 = call double* @read_vector(i8* %2, i32 %3)
br label %53
50: ; preds = %28
%51 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @str.12, i64 0, i64 0))
%52 = call double* @generate_random_vector(i32 %3)
br label %53
53: ; preds = %50, %47
%54 = phi double* [ %49, %47 ], [ %52, %50 ]
%55 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @str.13, i64 0, i64 0))
%56 = call i64 (...) @clock()
%57 = call i32 @solveLU(i32 %3, double** %29, double* %54)
%58 = call i64 (...) @clock()
%59 = sub nsw i64 %58, %56
%60 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @str.14, i64 0, i64 0))
%61 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([45 x i8], [45 x i8]* @str.15, i64 0, i64 0))
%62 = call i32 @write_vector(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0), double* %54, i32 %3)
%63 = sitofp i64 %59 to float
%64 = load float, float* @CLOCKS_PER_SEC
%65 = fdiv float %63, %64
%66 = fpext float %65 to double
%67 = sitofp i32 %3 to float
%68 = fdiv float %65, %67
%69 = fpext float %68 to double
%70 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([30 x i8], [30 x i8]* @.str.11, i64 0, i64 0), i32 %3, double %66, double %69)
%71 = call i32 @free_matrix(double** %29, i32 %3)
%72 = call i32 @free(double* %54)
ret i32 0
}