int generate_snp_sites(char filename[], int exclude_gaps, char suffix[]) {
  int length_of_genome;
  char *reference_sequence;
  int number_of_snps;
  int *snp_locations;
  int number_of_samples;
  int i;
  length_of_genome = genome_length(filename);
  reference_sequence = (char *)calloc((length_of_genome + 1), sizeof(char));
  build_reference_sequence(reference_sequence, filename);
  number_of_snps =
      detect_snps(reference_sequence, filename, length_of_genome, exclude_gaps);
  snp_locations = (int *)calloc((number_of_snps + 1), sizeof(int));
  build_snp_locations(snp_locations, reference_sequence);
  free(reference_sequence);
  number_of_samples = number_of_sequences_in_file(filename);
  char *sequence_names[number_of_samples];
  sequence_names[number_of_samples - 1] = '\0';
  for (i = 0; i < number_of_samples; i++) {
    sequence_names[i] = calloc(1024, sizeof(char));
  }
  get_sample_names_for_header(filename, sequence_names, number_of_samples);
  int internal_nodes[number_of_samples];
  int a = 0;
  for (a = 0; a < number_of_samples; a++) {
    internal_nodes[a] = 0;
  }
  char **bases_for_snps = malloc(number_of_snps * sizeof(char *));
  for (i = 0; i < number_of_snps; i++) {
    bases_for_snps[i] = calloc((number_of_samples + 1), sizeof(char));
  }
  get_bases_for_each_snp(filename, snp_locations, bases_for_snps,
                         length_of_genome, number_of_snps);
  char filename_without_directory[1024];
  strip_directory_from_filename(filename, filename_without_directory);
  concat_strings_created_with_malloc(filename_without_directory, suffix);
  create_vcf_file(filename_without_directory, snp_locations, number_of_snps,
                  bases_for_snps, sequence_names, number_of_samples,
                  internal_nodes, 1, length_of_genome);
  create_phylip_of_snp_sites(filename_without_directory, number_of_snps,
                             bases_for_snps, sequence_names, number_of_samples,
                             internal_nodes);
  create_fasta_of_snp_sites(filename_without_directory, number_of_snps,
                            bases_for_snps, sequence_names, number_of_samples,
                            internal_nodes);
  free(snp_locations);
  return 1;
}


x86 assembly (clang, -O0):
<generate_snp_sites>:
push   %rbp
mov    %rsp,%rbp
sub    $0x490,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x8(%rbp),%rdi
xor    %eax,%eax
mov    %al,-0x479(%rbp)
call   1040 <genome_length@plt>
mov    %eax,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
movslq %eax,%rdi
mov    $0x1,%esi
call   10c0 <calloc@plt>
mov    %rax,%rcx
mov    -0x479(%rbp),%al
mov    %rcx,-0x28(%rbp)
mov    -0x28(%rbp),%rdi
mov    -0x8(%rbp),%rsi
call   10d0 <build_reference_sequence@plt>
mov    -0x479(%rbp),%al
mov    -0x28(%rbp),%rdi
mov    -0x8(%rbp),%rsi
mov    -0x1c(%rbp),%edx
mov    -0xc(%rbp),%ecx
call   10b0 <detect_snps@plt>
mov    %eax,-0x2c(%rbp)
mov    -0x2c(%rbp),%eax
add    $0x1,%eax
movslq %eax,%rdi
mov    $0x4,%esi
call   10c0 <calloc@plt>
mov    %rax,%rcx
mov    -0x479(%rbp),%al
mov    %rcx,-0x38(%rbp)
mov    -0x38(%rbp),%rdi
mov    -0x28(%rbp),%rsi
call   1070 <build_snp_locations@plt>
mov    -0x28(%rbp),%rdi
call   1030 <free@plt>
mov    -0x479(%rbp),%al
mov    -0x8(%rbp),%rdi
call   1100 <number_of_sequences_in_file@plt>
mov    %eax,-0x3c(%rbp)
mov    -0x3c(%rbp),%eax
mov    %eax,%ecx
mov    %rsp,%rax
mov    %rax,-0x48(%rbp)
lea    0xf(,%rcx,8),%rdx
and    $0xfffffffffffffff0,%rdx
mov    %rsp,%rax
sub    %rdx,%rax
mov    %rax,-0x478(%rbp)
mov    %rax,%rsp
mov    %rcx,-0x50(%rbp)
mov    -0x3c(%rbp),%ecx
sub    $0x1,%ecx
movslq %ecx,%rcx
movq   $0x0,(%rax,%rcx,8)
movl   $0x0,-0x40(%rbp)
mov    -0x40(%rbp),%eax
cmp    -0x3c(%rbp),%eax
jge    132a <generate_snp_sites+0x13a>
mov    $0x400,%edi
mov    $0x1,%esi
call   10c0 <calloc@plt>
mov    %rax,%rdx
mov    -0x478(%rbp),%rax
movslq -0x40(%rbp),%rcx
mov    %rdx,(%rax,%rcx,8)
mov    -0x40(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x40(%rbp)
jmp    12ef <generate_snp_sites+0xff>
mov    -0x478(%rbp),%rsi
mov    -0x8(%rbp),%rdi
mov    -0x3c(%rbp),%edx
xor    %eax,%eax
call   1080 <get_sample_names_for_header@plt>
mov    -0x3c(%rbp),%eax
lea    0xf(,%rax,4),%rdx
and    $0xfffffffffffffff0,%rdx
mov    %rsp,%rcx
sub    %rdx,%rcx
mov    %rcx,-0x488(%rbp)
mov    %rcx,%rsp
mov    %rax,-0x58(%rbp)
movl   $0x0,-0x5c(%rbp)
movl   $0x0,-0x5c(%rbp)
mov    -0x5c(%rbp),%eax
cmp    -0x3c(%rbp),%eax
jge    139c <generate_snp_sites+0x1ac>
mov    -0x488(%rbp),%rax
movslq -0x5c(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
mov    -0x5c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x5c(%rbp)
jmp    1370 <generate_snp_sites+0x180>
movslq -0x2c(%rbp),%rdi
shl    $0x3,%rdi
call   10f0 <malloc@plt>
mov    %rax,-0x68(%rbp)
movl   $0x0,-0x40(%rbp)
mov    -0x40(%rbp),%eax
cmp    -0x2c(%rbp),%eax
jge    13f0 <generate_snp_sites+0x200>
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
movslq %eax,%rdi
mov    $0x1,%esi
call   10c0 <calloc@plt>
mov    %rax,%rdx
mov    -0x68(%rbp),%rax
movslq -0x40(%rbp),%rcx
mov    %rdx,(%rax,%rcx,8)
mov    -0x40(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x40(%rbp)
jmp    13b4 <generate_snp_sites+0x1c4>
mov    -0x8(%rbp),%rdi
mov    -0x38(%rbp),%rsi
mov    -0x68(%rbp),%rdx
mov    -0x1c(%rbp),%ecx
mov    -0x2c(%rbp),%r8d
mov    $0x0,%al
call   1110 <get_bases_for_each_snp@plt>
mov    -0x8(%rbp),%rdi
lea    -0x470(%rbp),%rsi
mov    $0x0,%al
call   10a0 <strip_directory_from_filename@plt>
lea    -0x470(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    $0x0,%al
call   1060 <concat_strings_created_with_malloc@plt>
mov    -0x478(%rbp),%r8
mov    -0x488(%rbp),%r10
lea    -0x470(%rbp),%rdi
mov    -0x38(%rbp),%rsi
mov    -0x2c(%rbp),%edx
mov    -0x68(%rbp),%rcx
mov    -0x3c(%rbp),%r9d
mov    -0x1c(%rbp),%eax
sub    $0x20,%rsp
mov    %r10,(%rsp)
movl   $0x1,0x8(%rsp)
mov    %eax,0x10(%rsp)
mov    $0x0,%al
call   1090 <create_vcf_file@plt>
mov    -0x478(%rbp),%rcx
mov    -0x488(%rbp),%r9
add    $0x20,%rsp
lea    -0x470(%rbp),%rdi
mov    -0x2c(%rbp),%esi
mov    -0x68(%rbp),%rdx
mov    -0x3c(%rbp),%r8d
mov    $0x0,%al
call   1050 <create_phylip_of_snp_sites@plt>
mov    -0x478(%rbp),%rcx
mov    -0x488(%rbp),%r9
lea    -0x470(%rbp),%rdi
mov    -0x2c(%rbp),%esi
mov    -0x68(%rbp),%rdx
mov    -0x3c(%rbp),%r8d
mov    $0x0,%al
call   10e0 <create_fasta_of_snp_sites@plt>
mov    -0x38(%rbp),%rdi
call   1030 <free@plt>
mov    -0x48(%rbp),%rax
mov    %rax,%rsp
mov    $0x1,%eax
mov    %rbp,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<generate_snp_sites>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x438,%rsp
mov    %rdx,-0x60(%rbp)
mov    %esi,%r14d
mov    %rdi,%rbx
xor    %eax,%eax
call   1040 <genome_length@plt>
mov    %eax,%r12d
lea    0x1(%r12),%eax
movslq %eax,%rdi
mov    $0x1,%esi
call   10d0 <calloc@plt>
mov    %rax,%r15
mov    %rax,%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   10e0 <build_reference_sequence@plt>
mov    %r15,%rdi
mov    %rbx,%rsi
mov    %r12d,%edx
mov    %r14d,%ecx
mov    %rbx,%r14
xor    %eax,%eax
call   10c0 <detect_snps@plt>
mov    %rax,-0x30(%rbp)
add    $0x1,%eax
movslq %eax,%rdi
mov    $0x4,%esi
call   10d0 <calloc@plt>
mov    %rax,-0x38(%rbp)
mov    %rax,%rdi
mov    %r15,%rsi
xor    %eax,%eax
call   1070 <build_snp_locations@plt>
mov    %r15,%rdi
call   1030 <free@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1110 <number_of_sequences_in_file@plt>
mov    %eax,%r13d
lea    0xf(,%r13,8),%rcx
and    $0xfffffffffffffff0,%rcx
mov    %rsp,%r15
sub    %rcx,%r15
mov    %r15,%rsp
cltq
movq   $0x0,-0x8(%r15,%rax,8)
test   %eax,%eax
mov    %r12,-0x50(%rbp)
mov    %rbx,-0x58(%rbp)
mov    %r13,-0x48(%rbp)
jle    132b <generate_snp_sites+0x12b>
xor    %ebx,%ebx
nopl   0x0(%rax)
mov    $0x400,%edi
mov    $0x1,%esi
call   10d0 <calloc@plt>
mov    %rax,(%r15,%rbx,8)
add    $0x1,%rbx
cmp    %rbx,%r13
jne    12d0 <generate_snp_sites+0xd0>
mov    %r14,%rdi
mov    %r15,%rsi
mov    %r13d,%edx
xor    %eax,%eax
call   1080 <get_sample_names_for_header@plt>
mov    %rsp,%rdi
lea    0xf(,%r13,4),%rax
and    $0xfffffffffffffff0,%rax
sub    %rax,%rdi
mov    %rdi,%rsp
test   %r13d,%r13d
mov    %rdi,-0x40(%rbp)
jle    1354 <generate_snp_sites+0x154>
lea    0x0(,%r13,4),%rdx
xor    %esi,%esi
call   10b0 <memset@plt>
jmp    1354 <generate_snp_sites+0x154>
mov    %r14,%rdi
mov    %r15,%rsi
mov    %r13d,%edx
xor    %eax,%eax
call   1080 <get_sample_names_for_header@plt>
mov    %rsp,%rcx
lea    0xf(,%r13,4),%rax
and    $0xfffffffffffffff0,%rax
sub    %rax,%rcx
mov    %rcx,-0x40(%rbp)
mov    %rcx,%rsp
mov    -0x30(%rbp),%rbx
movslq %ebx,%rdi
shl    $0x3,%rdi
call   1100 <malloc@plt>
mov    %rax,%r13
test   %ebx,%ebx
jle    139b <generate_snp_sites+0x19b>
mov    -0x48(%rbp),%rax
add    $0x1,%eax
movslq %eax,%rbx
mov    -0x30(%rbp),%r12d
xor    %r14d,%r14d
nopl   0x0(%rax)
mov    $0x1,%esi
mov    %rbx,%rdi
call   10d0 <calloc@plt>
mov    %rax,0x0(%r13,%r14,8)
add    $0x1,%r14
cmp    %r14,%r12
jne    1380 <generate_snp_sites+0x180>
mov    -0x58(%rbp),%r14
mov    %r14,%rdi
mov    -0x38(%rbp),%rsi
mov    %r13,%rdx
mov    -0x50(%rbp),%rcx
mov    -0x30(%rbp),%r12
mov    %r12d,%r8d
xor    %eax,%eax
call   1120 <get_bases_for_each_snp@plt>
lea    -0x460(%rbp),%rbx
mov    %r14,%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   10a0 <strip_directory_from_filename@plt>
mov    %rbx,%rdi
mov    -0x60(%rbp),%rsi
xor    %eax,%eax
call   1060 <concat_strings_created_with_malloc@plt>
sub    $0x8,%rsp
mov    %rbx,%rdi
mov    -0x38(%rbp),%rsi
mov    %r12d,%edx
mov    %r13,%rcx
mov    %r15,%r8
mov    -0x48(%rbp),%r14
mov    %r14d,%r9d
xor    %eax,%eax
push   -0x50(%rbp)
push   $0x1
mov    -0x40(%rbp),%rbx
push   %rbx
call   1090 <create_vcf_file@plt>
add    $0x20,%rsp
lea    -0x460(%rbp),%rdi
mov    %r12d,%esi
mov    %r13,%rdx
mov    %r15,%rcx
mov    %r14d,%r8d
mov    %rbx,%r9
xor    %eax,%eax
call   1050 <create_phylip_of_snp_sites@plt>
lea    -0x460(%rbp),%rdi
mov    %r12d,%esi
mov    %r13,%rdx
mov    %r15,%rcx
mov    %r14d,%r8d
mov    %rbx,%r9
xor    %eax,%eax
call   10f0 <create_fasta_of_snp_sites@plt>
mov    -0x38(%rbp),%rdi
call   1030 <free@plt>
mov    $0x1,%eax
lea    -0x28(%rbp),%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
define i32 @generate_snp_sites(i8* %0, i32 %1, i8* %2) {
%4 = alloca i8*
%5 = alloca i32
%6 = alloca i8*
%7 = alloca i32
%8 = alloca i8*
%9 = alloca i32
%10 = alloca i32*
%11 = alloca i32
%12 = alloca i32
%13 = alloca i8*
%14 = alloca i64
%15 = alloca i64
%16 = alloca i32
%17 = alloca i8**
%18 = alloca [1024 x i8]
store i8* %0, i8** %4
store i32 %1, i32* %5
store i8* %2, i8** %6
%19 = load i8*, i8** %4
%20 = call i32 (i8*, ...) bitcast (i32 (...)* @genome_length to i32 (i8*, ...)*)(i8* %19)
store i32 %20, i32* %7
%21 = load i32, i32* %7
%22 = add nsw i32 %21, 1
%23 = sext i32 %22 to i64
%24 = call i8* @calloc(i64 %23, i64 1)
store i8* %24, i8** %8
%25 = load i8*, i8** %8
%26 = load i8*, i8** %4
%27 = call i32 (i8*, i8*, ...) bitcast (i32 (...)* @build_reference_sequence to i32 (i8*, i8*, ...)*)(i8* %25, i8* %26)
%28 = load i8*, i8** %8
%29 = load i8*, i8** %4
%30 = load i32, i32* %7
%31 = load i32, i32* %5
%32 = call i32 (i8*, i8*, i32, i32, ...) bitcast (i32 (...)* @detect_snps to i32 (i8*, i8*, i32, i32, ...)*)(i8* %28, i8* %29, i32 %30, i32 %31)
store i32 %32, i32* %9
%33 = load i32, i32* %9
%34 = add nsw i32 %33, 1
%35 = sext i32 %34 to i64
%36 = call i8* @calloc(i64 %35, i64 4)
%37 = bitcast i8* %36 to i32*
store i32* %37, i32** %10
%38 = load i32*, i32** %10
%39 = load i8*, i8** %8
%40 = call i32 (i32*, i8*, ...) bitcast (i32 (...)* @build_snp_locations to i32 (i32*, i8*, ...)*)(i32* %38, i8* %39)
%41 = load i8*, i8** %8
%42 = load i8*, i8** %4
%43 = call i32 (i8*, ...) bitcast (i32 (...)* @number_of_sequences_in_file to i32 (i8*, ...)*)(i8* %42)
store i32 %43, i32* %11
%44 = load i32, i32* %11
%45 = zext i32 %44 to i64
%46 = call i8* @llvm.stacksave()
store i8* %46, i8** %13
%47 = alloca i8*, i64 %45
store i64 %45, i64* %14
%48 = load i32, i32* %11
%49 = sub nsw i32 %48, 1
%50 = sext i32 %49 to i64
%51 = getelementptr inbounds i8*, i8** %47, i64 %50
store i8* null, i8** %51
store i32 0, i32* %12
br label %52
52: ; preds = %61, %3
%53 = load i32, i32* %12
%54 = load i32, i32* %11
%55 = icmp slt i32 %53, %54
br i1 %55, label %56, label %64
56: ; preds = %52
%57 = call i8* @calloc(i64 1024, i64 1)
%58 = load i32, i32* %12
%59 = sext i32 %58 to i64
%60 = getelementptr inbounds i8*, i8** %47, i64 %59
store i8* %57, i8** %60
br label %61
61: ; preds = %56
%62 = load i32, i32* %12
%63 = add nsw i32 %62, 1
store i32 %63, i32* %12
br label %52
64: ; preds = %52
%65 = load i8*, i8** %4
%66 = load i32, i32* %11
%67 = call i32 (i8*, i8**, i32, ...) bitcast (i32 (...)* @get_sample_names_for_header to i32 (i8*, i8**, i32, ...)*)(i8* %65, i8** %47, i32 %66)
%68 = load i32, i32* %11
%69 = zext i32 %68 to i64
%70 = alloca i32, i64 %69
store i64 %69, i64* %15
store i32 0, i32* %16
store i32 0, i32* %16
br label %71
71: ; preds = %79, %64
%72 = load i32, i32* %16
%73 = load i32, i32* %11
%74 = icmp slt i32 %72, %73
br i1 %74, label %75, label %82
75: ; preds = %71
%76 = load i32, i32* %16
%77 = sext i32 %76 to i64
%78 = getelementptr inbounds i32, i32* %70, i64 %77
store i32 0, i32* %78
br label %79
79: ; preds = %75
%80 = load i32, i32* %16
%81 = add nsw i32 %80, 1
store i32 %81, i32* %16
br label %71
82: ; preds = %71
%83 = load i32, i32* %9
%84 = sext i32 %83 to i64
%85 = mul i64 %84, 8
%86 = call i8* @malloc(i64 %85)
%87 = bitcast i8* %86 to i8**
store i8** %87, i8*** %17
store i32 0, i32* %12
br label %88
88: ; preds = %101, %82
%89 = load i32, i32* %12
%90 = load i32, i32* %9
%91 = icmp slt i32 %89, %90
br i1 %91, label %92, label %104
92: ; preds = %88
%93 = load i32, i32* %11
%94 = add nsw i32 %93, 1
%95 = sext i32 %94 to i64
%96 = call i8* @calloc(i64 %95, i64 1)
%97 = load i8**, i8*** %17
%98 = load i32, i32* %12
%99 = sext i32 %98 to i64
%100 = getelementptr inbounds i8*, i8** %97, i64 %99
store i8* %96, i8** %100
br label %101
101: ; preds = %92
%102 = load i32, i32* %12
%103 = add nsw i32 %102, 1
store i32 %103, i32* %12
br label %88
104: ; preds = %88
%105 = load i8*, i8** %4
%106 = load i32*, i32** %10
%107 = load i8**, i8*** %17
%108 = load i32, i32* %7
%109 = load i32, i32* %9
%110 = call i32 (i8*, i32*, i8**, i32, i32, ...) bitcast (i32 (...)* @get_bases_for_each_snp to i32 (i8*, i32*, i8**, i32, i32, ...)*)(i8* %105, i32* %106, i8** %107, i32 %108, i32 %109)
%111 = load i8*, i8** %4
%112 = getelementptr inbounds [1024 x i8], [1024 x i8]* %18, i64 0, i64 0
%113 = call i32 (i8*, i8*, ...) bitcast (i32 (...)* @strip_directory_from_filename to i32 (i8*, i8*, ...)*)(i8* %111, i8* %112)
%114 = getelementptr inbounds [1024 x i8], [1024 x i8]* %18, i64 0, i64 0
%115 = load i8*, i8** %6
%116 = call i32 (i8*, i8*, ...) bitcast (i32 (...)* @concat_strings_created_with_malloc to i32 (i8*, i8*, ...)*)(i8* %114, i8* %115)
%117 = getelementptr inbounds [1024 x i8], [1024 x i8]* %18, i64 0, i64 0
%118 = load i32*, i32** %10
%119 = load i32, i32* %9
%120 = load i8**, i8*** %17
%121 = load i32, i32* %11
%122 = load i32, i32* %7
%123 = call i32 (i8*, i32*, i32, i8**, i8**, i32, i32*, i32, i32, ...) bitcast (i32 (...)* @create_vcf_file to i32 (i8*, i32*, i32, i8**, i8**, i32, i32*, i32, i32, ...)*)(i8* %117, i32* %118, i32 %119, i8** %120, i8** %47, i32 %121, i32* %70, i32 1, i32 %122)
%124 = getelementptr inbounds [1024 x i8], [1024 x i8]* %18, i64 0, i64 0
%125 = load i32, i32* %9
%126 = load i8**, i8*** %17
%127 = load i32, i32* %11
%128 = call i32 (i8*, i32, i8**, i8**, i32, i32*, ...) bitcast (i32 (...)* @create_phylip_of_snp_sites to i32 (i8*, i32, i8**, i8**, i32, i32*, ...)*)(i8* %124, i32 %125, i8** %126, i8** %47, i32 %127, i32* %70)
%129 = getelementptr inbounds [1024 x i8], [1024 x i8]* %18, i64 0, i64 0
%130 = load i32, i32* %9
%131 = load i8**, i8*** %17
%132 = load i32, i32* %11
%133 = call i32 (i8*, i32, i8**, i8**, i32, i32*, ...) bitcast (i32 (...)* @create_fasta_of_snp_sites to i32 (i8*, i32, i8**, i8**, i32, i32*, ...)*)(i8* %129, i32 %130, i8** %131, i8** %47, i32 %132, i32* %70)
%134 = load i32*, i32** %10
%135 = bitcast i32* %134 to i8*
%136 = load i8*, i8** %13
ret i32 1
}

LLVM IR (-O2):
define i32 @generate_snp_sites(i8* %0, i32 %1, i8* %2) {
%4 = alloca [1024 x i8]
%5 = tail call i32 (i8*, ...) bitcast (i32 (...)* @genome_length to i32 (i8*, ...)*)(i8* %0)
%6 = add nsw i32 %5, 1
%7 = sext i32 %6 to i64
%8 = tail call i8* @calloc(i64 %7, i64 1)
%9 = tail call i32 (i8*, i8*, ...) bitcast (i32 (...)* @build_reference_sequence to i32 (i8*, i8*, ...)*)(i8* %8, i8* %0)
%10 = tail call i32 (i8*, i8*, i32, i32, ...) bitcast (i32 (...)* @detect_snps to i32 (i8*, i8*, i32, i32, ...)*)(i8* %8, i8* %0, i32 %5, i32 %1)
%11 = add nsw i32 %10, 1
%12 = sext i32 %11 to i64
%13 = tail call i8* @calloc(i64 %12, i64 4)
%14 = bitcast i8* %13 to i32*
%15 = tail call i32 (i32*, i8*, ...) bitcast (i32 (...)* @build_snp_locations to i32 (i32*, i8*, ...)*)(i32* %14, i8* %8)
tail call void @free(i8* %8)
%16 = tail call i32 (i8*, ...) bitcast (i32 (...)* @number_of_sequences_in_file to i32 (i8*, ...)*)(i8* %0)
%17 = zext i32 %16 to i64
%18 = alloca i8*, i64 %17
%19 = add nsw i32 %16, -1
%20 = sext i32 %19 to i64
%21 = getelementptr inbounds i8*, i8** %18, i64 %20
store i8* null, i8** %21
%22 = icmp sgt i32 %16, 0
br i1 %22, label %26, label %23
23: ; preds = %3
%24 = call i32 (i8*, i8**, i32, ...) bitcast (i32 (...)* @get_sample_names_for_header to i32 (i8*, i8**, i32, ...)*)(i8* %0, i8** %18, i32 %16)
%25 = alloca i32, i64 %17
br label %38
26: ; preds = %3, %26
%27 = phi i64 [ %30, %26 ], [ 0, %3 ]
%28 = tail call dereferenceable_or_null(1024) i8* @calloc(i64 1024, i64 1)
%29 = getelementptr inbounds i8*, i8** %18, i64 %27
store i8* %28, i8** %29
%30 = add nuw nsw i64 %27, 1
%31 = icmp eq i64 %30, %17
br i1 %31, label %32, label %26
32: ; preds = %26
%33 = call i32 (i8*, i8**, i32, ...) bitcast (i32 (...)* @get_sample_names_for_header to i32 (i8*, i8**, i32, ...)*)(i8* %0, i8** %18, i32 %16)
%34 = alloca i32, i64 %17
br i1 %22, label %35, label %38
35: ; preds = %32
%36 = bitcast i32* %34 to i8*
%37 = shl nuw nsw i64 %17, 2
br label %38
38: ; preds = %23, %35, %32
%39 = phi i32* [ %25, %23 ], [ %34, %35 ], [ %34, %32 ]
%40 = sext i32 %10 to i64
%41 = shl nsw i64 %40, 3
%42 = call i8* @malloc(i64 %41)
%43 = bitcast i8* %42 to i8**
%44 = icmp sgt i32 %10, 0
br i1 %44, label %45, label %55
45: ; preds = %38
%46 = add nsw i32 %16, 1
%47 = sext i32 %46 to i64
%48 = zext i32 %10 to i64
br label %49
49: ; preds = %45, %49
%50 = phi i64 [ 0, %45 ], [ %53, %49 ]
%51 = call i8* @calloc(i64 %47, i64 1)
%52 = getelementptr inbounds i8*, i8** %43, i64 %50
store i8* %51, i8** %52
%53 = add nuw nsw i64 %50, 1
%54 = icmp eq i64 %53, %48
br i1 %54, label %55, label %49
55: ; preds = %49, %38
%56 = call i32 (i8*, i32*, i8**, i32, i32, ...) bitcast (i32 (...)* @get_bases_for_each_snp to i32 (i8*, i32*, i8**, i32, i32, ...)*)(i8* %0, i32* %14, i8** %43, i32 %5, i32 %10)
%57 = getelementptr inbounds [1024 x i8], [1024 x i8]* %4, i64 0, i64 0
%58 = call i32 (i8*, i8*, ...) bitcast (i32 (...)* @strip_directory_from_filename to i32 (i8*, i8*, ...)*)(i8* %0, i8* %57)
%59 = call i32 (i8*, i8*, ...) bitcast (i32 (...)* @concat_strings_created_with_malloc to i32 (i8*, i8*, ...)*)(i8* %57, i8* %2)
%60 = call i32 (i8*, i32*, i32, i8**, i8**, i32, i32*, i32, i32, ...) bitcast (i32 (...)* @create_vcf_file to i32 (i8*, i32*, i32, i8**, i8**, i32, i32*, i32, i32, ...)*)(i8* %57, i32* %14, i32 %10, i8** %43, i8** %18, i32 %16, i32* %39, i32 1, i32 %5)
%61 = call i32 (i8*, i32, i8**, i8**, i32, i32*, ...) bitcast (i32 (...)* @create_phylip_of_snp_sites to i32 (i8*, i32, i8**, i8**, i32, i32*, ...)*)(i8* %57, i32 %10, i8** %43, i8** %18, i32 %16, i32* %39)
%62 = call i32 (i8*, i32, i8**, i8**, i32, i32*, ...) bitcast (i32 (...)* @create_fasta_of_snp_sites to i32 (i8*, i32, i8**, i8**, i32, i32*, ...)*)(i8* %57, i32 %10, i8** %43, i8** %18, i32 %16, i32* %39)
ret i32 1
}