#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 */
struct sift_keypoints {
  int dummy;
};

/* Variables and functions */
int EXIT_FAILURE;
int EXIT_SUCCESS;
int FILENAME_MAX;
int /*<<< orphan*/ matching(struct sift_keypoints *, struct sift_keypoints *,
                            struct sift_keypoints *, struct sift_keypoints *,
                            struct sift_keypoints *, float, int);
int parse_options(int, char **, int *, int *, int *, int *, float *, int *,
                  char *);
int /*<<< orphan*/ print_pairs(struct sift_keypoints *,
                               struct sift_keypoints *);
int /*<<< orphan*/ save_pairs_extra(char *, struct sift_keypoints *,
                                    struct sift_keypoints *,
                                    struct sift_keypoints *);
int /*<<< orphan*/ sift_free_keypoints(struct sift_keypoints *);
struct sift_keypoints *sift_malloc_keypoints();
int /*<<< orphan*/ sift_read_keypoints(struct sift_keypoints *, char *, int,
                                       int, int, int);
int /*<<< orphan*/ sift_save_keypoints(struct sift_keypoints *, char *, int);
int /*<<< orphan*/ sprintf(char *, char *, char *);
int /*<<< orphan*/ strcpy(char *, char *);
int main(int argc, char **argv) {
  int n_hist = 4;
  int n_ori = 8;
  int n_bins = 36;
  int meth_flag = 1;
  float thresh = 0.6;
  int verb_flag = 0;
  char label[256];
  strcpy(label, "extra");
  int res = parse_options(argc, argv, &n_bins, &n_hist, &n_ori, &meth_flag,
                          &thresh, &verb_flag, label);
  if (res == EXIT_FAILURE)
    return EXIT_FAILURE;
  struct sift_keypoints *k1 = sift_malloc_keypoints();
  struct sift_keypoints *k2 = sift_malloc_keypoints();
  struct sift_keypoints *out_k1 = sift_malloc_keypoints();
  struct sift_keypoints *out_k2A = sift_malloc_keypoints();
  struct sift_keypoints *out_k2B = sift_malloc_keypoints();
  int readflag = verb_flag + 1;
  sift_read_keypoints(k1, argv[1], n_hist, n_ori, n_bins, readflag);
  sift_read_keypoints(k2, argv[2], n_hist, n_ori, n_bins, readflag);
  matching(k1, k2, out_k1, out_k2A, out_k2B, thresh, meth_flag);
  print_pairs(out_k1, out_k2A);
  char name[FILENAME_MAX];
  if (verb_flag == 1) {
    save_pairs_extra("OUTmatches.txt", out_k1, out_k2A, out_k2B);
    sprintf(name, "%s_im0.txt", label);
    sift_save_keypoints(out_k1, name, 1);
    sprintf(name, "%s_im1.txt", label);
    sift_save_keypoints(out_k2A, name, 1);
  }
  sift_free_keypoints(k1);
  sift_free_keypoints(k2);
  sift_free_keypoints(out_k1);
  sift_free_keypoints(out_k2A);
  sift_free_keypoints(out_k2B);
  return EXIT_SUCCESS;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x190,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x4,-0x14(%rbp)
movl   $0x8,-0x18(%rbp)
movl   $0x24,-0x1c(%rbp)
movl   $0x1,-0x20(%rbp)
movss  0xe23(%rip),%xmm0
movss  %xmm0,-0x24(%rbp)
movl   $0x0,-0x28(%rbp)
lea    -0x130(%rbp),%rdi
lea    0xe0d(%rip),%rsi
call   1040 <strcpy@plt>
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
lea    -0x130(%rbp),%rax
lea    -0x1c(%rbp),%rdx
lea    -0x14(%rbp),%rcx
lea    -0x18(%rbp),%r8
lea    -0x20(%rbp),%r9
lea    -0x24(%rbp),%r11
lea    -0x28(%rbp),%r10
sub    $0x20,%rsp
mov    %r11,(%rsp)
mov    %r10,0x8(%rsp)
mov    %rax,0x10(%rsp)
call   1070 <parse_options@plt>
add    $0x20,%rsp
mov    %eax,-0x134(%rbp)
mov    -0x134(%rbp),%eax
mov    0x2d88(%rip),%rcx
cmp    (%rcx),%eax
jne    1269 <main+0xc9>
mov    0x2d79(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
jmp    1481 <main+0x2e1>
xor    %eax,%eax
mov    %al,-0x181(%rbp)
call   1030 <sift_malloc_keypoints@plt>
mov    %rax,%rcx
mov    -0x181(%rbp),%al
mov    %rcx,-0x140(%rbp)
call   1030 <sift_malloc_keypoints@plt>
mov    %rax,%rcx
mov    -0x181(%rbp),%al
mov    %rcx,-0x148(%rbp)
call   1030 <sift_malloc_keypoints@plt>
mov    %rax,%rcx
mov    -0x181(%rbp),%al
mov    %rcx,-0x150(%rbp)
call   1030 <sift_malloc_keypoints@plt>
mov    %rax,%rcx
mov    -0x181(%rbp),%al
mov    %rcx,-0x158(%rbp)
call   1030 <sift_malloc_keypoints@plt>
mov    %rax,-0x160(%rbp)
mov    -0x28(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x164(%rbp)
mov    -0x140(%rbp),%rdi
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rsi
mov    -0x14(%rbp),%edx
mov    -0x18(%rbp),%ecx
mov    -0x1c(%rbp),%r8d
mov    -0x164(%rbp),%r9d
call   1060 <sift_read_keypoints@plt>
mov    -0x148(%rbp),%rdi
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rsi
mov    -0x14(%rbp),%edx
mov    -0x18(%rbp),%ecx
mov    -0x1c(%rbp),%r8d
mov    -0x164(%rbp),%r9d
call   1060 <sift_read_keypoints@plt>
mov    -0x140(%rbp),%rdi
mov    -0x148(%rbp),%rsi
mov    -0x150(%rbp),%rdx
mov    -0x158(%rbp),%rcx
mov    -0x160(%rbp),%r8
movss  -0x24(%rbp),%xmm0
mov    -0x20(%rbp),%r9d
call   10a0 <matching@plt>
mov    -0x150(%rbp),%rdi
mov    -0x158(%rbp),%rsi
call   1090 <print_pairs@plt>
mov    0x2c76(%rip),%rax
mov    (%rax),%eax
mov    %rsp,%rcx
mov    %rcx,-0x170(%rbp)
mov    %rax,%rdx
add    $0xf,%rdx
and    $0xfffffffffffffff0,%rdx
mov    %rsp,%rcx
sub    %rdx,%rcx
mov    %rcx,-0x180(%rbp)
mov    %rcx,%rsp
mov    %rax,-0x178(%rbp)
cmpl   $0x1,-0x28(%rbp)
jne    142f <main+0x28f>
mov    -0x150(%rbp),%rsi
mov    -0x158(%rbp),%rdx
mov    -0x160(%rbp),%rcx
lea    0xc44(%rip),%rdi
call   1050 <save_pairs_extra@plt>
mov    -0x180(%rbp),%rdi
lea    -0x130(%rbp),%rdx
lea    0xc39(%rip),%rsi
call   10c0 <sprintf@plt>
mov    -0x180(%rbp),%rsi
mov    -0x150(%rbp),%rdi
mov    $0x1,%edx
call   10b0 <sift_save_keypoints@plt>
mov    -0x180(%rbp),%rdi
lea    -0x130(%rbp),%rdx
lea    0xc12(%rip),%rsi
call   10c0 <sprintf@plt>
mov    -0x180(%rbp),%rsi
mov    -0x158(%rbp),%rdi
mov    $0x1,%edx
call   10b0 <sift_save_keypoints@plt>
mov    -0x140(%rbp),%rdi
call   1080 <sift_free_keypoints@plt>
mov    -0x148(%rbp),%rdi
call   1080 <sift_free_keypoints@plt>
mov    -0x150(%rbp),%rdi
call   1080 <sift_free_keypoints@plt>
mov    -0x158(%rbp),%rdi
call   1080 <sift_free_keypoints@plt>
mov    -0x160(%rbp),%rdi
call   1080 <sift_free_keypoints@plt>
mov    0x2b5e(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x4(%rbp)
mov    -0x170(%rbp),%rax
mov    %rax,%rsp
mov    -0x4(%rbp),%eax
mov    %rbp,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x148,%rsp
mov    %rsi,%r13
mov    %edi,%ebx
movl   $0x4,-0x38(%rbp)
movl   $0x8,-0x34(%rbp)
movl   $0x24,-0x30(%rbp)
movl   $0x1,-0x40(%rbp)
movl   $0x3f19999a,-0x3c(%rbp)
movl   $0x0,-0x2c(%rbp)
lea    0xe16(%rip),%rsi
lea    -0x170(%rbp),%r14
mov    %r14,%rdi
call   1040 <strcpy@plt>
sub    $0x8,%rsp
lea    -0x2c(%rbp),%rax
lea    -0x3c(%rbp),%r10
lea    -0x30(%rbp),%rdx
lea    -0x38(%rbp),%rcx
lea    -0x34(%rbp),%r8
lea    -0x40(%rbp),%r9
mov    %ebx,%edi
mov    %r13,%rsi
push   %r14
push   %rax
push   %r10
call   1070 <parse_options@plt>
add    $0x20,%rsp
mov    0x2da9(%rip),%rcx
cmp    (%rcx),%eax
je     13a3 <main+0x203>
xor    %eax,%eax
call   1030 <sift_malloc_keypoints@plt>
mov    %rax,%r12
xor    %eax,%eax
call   1030 <sift_malloc_keypoints@plt>
mov    %rax,%r15
xor    %eax,%eax
call   1030 <sift_malloc_keypoints@plt>
mov    %rax,-0x58(%rbp)
xor    %eax,%eax
call   1030 <sift_malloc_keypoints@plt>
mov    %rax,%r14
xor    %eax,%eax
call   1030 <sift_malloc_keypoints@plt>
mov    %rax,-0x50(%rbp)
mov    -0x2c(%rbp),%ebx
add    $0x1,%ebx
mov    0x8(%r13),%rsi
mov    -0x38(%rbp),%edx
mov    -0x34(%rbp),%ecx
mov    -0x30(%rbp),%r8d
mov    %r12,%rdi
mov    %ebx,%r9d
call   1060 <sift_read_keypoints@plt>
mov    0x10(%r13),%rsi
mov    -0x38(%rbp),%edx
mov    -0x34(%rbp),%ecx
mov    -0x30(%rbp),%r8d
mov    %r15,%rdi
mov    %ebx,%r9d
call   1060 <sift_read_keypoints@plt>
movss  -0x3c(%rbp),%xmm0
mov    -0x40(%rbp),%r9d
mov    %r12,-0x60(%rbp)
mov    %r12,%rdi
mov    -0x58(%rbp),%r12
mov    %r15,-0x68(%rbp)
mov    %r15,%rsi
mov    %r12,%rdx
mov    %r14,%rcx
mov    -0x50(%rbp),%r8
mov    %r8,%r15
call   10a0 <matching@plt>
mov    %r12,%rdi
mov    %r14,%r13
mov    %r14,%rsi
call   1090 <print_pairs@plt>
mov    %rsp,%r14
mov    0x2d00(%rip),%rax
mov    (%rax),%eax
mov    %rsp,%rbx
add    $0xf,%rax
and    $0xfffffffffffffff0,%rax
sub    %rax,%rbx
mov    %rbx,%rsp
cmpl   $0x1,-0x2c(%rbp)
jne    136d <main+0x1cd>
lea    0xcfe(%rip),%rdi
mov    %r12,%rsi
mov    %r14,-0x48(%rbp)
mov    %r13,%r14
mov    %r13,%rdx
mov    %r15,%rcx
call   1050 <save_pairs_extra@plt>
lea    0xcf1(%rip),%rsi
lea    -0x170(%rbp),%rdx
mov    %rbx,%rdi
call   10c0 <sprintf@plt>
mov    %r12,%rdi
mov    %rbx,%rsi
mov    $0x1,%edx
call   10b0 <sift_save_keypoints@plt>
lea    0xcd6(%rip),%rsi
mov    %rbx,%rdi
lea    -0x170(%rbp),%rdx
call   10c0 <sprintf@plt>
mov    %r13,%rdi
mov    -0x48(%rbp),%r14
mov    %rbx,%rsi
mov    $0x1,%edx
call   10b0 <sift_save_keypoints@plt>
mov    -0x60(%rbp),%rdi
call   1080 <sift_free_keypoints@plt>
mov    -0x68(%rbp),%rdi
call   1080 <sift_free_keypoints@plt>
mov    %r12,%rdi
call   1080 <sift_free_keypoints@plt>
mov    %r13,%rdi
call   1080 <sift_free_keypoints@plt>
mov    %r15,%rdi
call   1080 <sift_free_keypoints@plt>
mov    0x2c32(%rip),%rax
mov    (%rax),%eax
mov    %r14,%rsp
lea    -0x28(%rbp),%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
%struct.sift_keypoints = type { i32 }
@.str = [6 x i8] c"extra\00"
@EXIT_FAILURE = global i32 0
@FILENAME_MAX = global i32 0
@.str.1 = [15 x i8] c"OUTmatches.txt\00"
@.str.2 = [11 x i8] c"%s_im0.txt\00"
@.str.3 = [11 x i8] c"%s_im1.txt\00"
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca float
%11 = alloca i32
%12 = alloca [256 x i8]
%13 = alloca i32
%14 = alloca %struct.sift_keypoints*
%15 = alloca %struct.sift_keypoints*
%16 = alloca %struct.sift_keypoints*
%17 = alloca %struct.sift_keypoints*
%18 = alloca %struct.sift_keypoints*
%19 = alloca i32
%20 = alloca i8*
%21 = alloca i64
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 4, i32* %6
store i32 8, i32* %7
store i32 36, i32* %8
store i32 1, i32* %9
store float 0x3FE3333340000000, float* %10
store i32 0, i32* %11
%22 = getelementptr inbounds [256 x i8], [256 x i8]* %12, i64 0, i64 0
%23 = call i32 @strcpy(i8* %22, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
%24 = load i32, i32* %4
%25 = load i8**, i8*** %5
%26 = getelementptr inbounds [256 x i8], [256 x i8]* %12, i64 0, i64 0
%27 = call i32 @parse_options(i32 %24, i8** %25, i32* %8, i32* %6, i32* %7, i32* %9, float* %10, i32* %11, i8* %26)
store i32 %27, i32* %13
%28 = load i32, i32* %13
%29 = load i32, i32* @EXIT_FAILURE
%30 = icmp eq i32 %28, %29
br i1 %30, label %31, label %33
31: ; preds = %2
%32 = load i32, i32* @EXIT_FAILURE
store i32 %32, i32* %3
br label %102
33: ; preds = %2
%34 = call %struct.sift_keypoints* (...) @sift_malloc_keypoints()
store %struct.sift_keypoints* %34, %struct.sift_keypoints** %14
%35 = call %struct.sift_keypoints* (...) @sift_malloc_keypoints()
store %struct.sift_keypoints* %35, %struct.sift_keypoints** %15
%36 = call %struct.sift_keypoints* (...) @sift_malloc_keypoints()
store %struct.sift_keypoints* %36, %struct.sift_keypoints** %16
%37 = call %struct.sift_keypoints* (...) @sift_malloc_keypoints()
store %struct.sift_keypoints* %37, %struct.sift_keypoints** %17
%38 = call %struct.sift_keypoints* (...) @sift_malloc_keypoints()
store %struct.sift_keypoints* %38, %struct.sift_keypoints** %18
%39 = load i32, i32* %11
%40 = add nsw i32 %39, 1
store i32 %40, i32* %19
%41 = load %struct.sift_keypoints*, %struct.sift_keypoints** %14
%42 = load i8**, i8*** %5
%43 = getelementptr inbounds i8*, i8** %42, i64 1
%44 = load i8*, i8** %43
%45 = load i32, i32* %6
%46 = load i32, i32* %7
%47 = load i32, i32* %8
%48 = load i32, i32* %19
%49 = call i32 @sift_read_keypoints(%struct.sift_keypoints* %41, i8* %44, i32 %45, i32 %46, i32 %47, i32 %48)
%50 = load %struct.sift_keypoints*, %struct.sift_keypoints** %15
%51 = load i8**, i8*** %5
%52 = getelementptr inbounds i8*, i8** %51, i64 2
%53 = load i8*, i8** %52
%54 = load i32, i32* %6
%55 = load i32, i32* %7
%56 = load i32, i32* %8
%57 = load i32, i32* %19
%58 = call i32 @sift_read_keypoints(%struct.sift_keypoints* %50, i8* %53, i32 %54, i32 %55, i32 %56, i32 %57)
%59 = load %struct.sift_keypoints*, %struct.sift_keypoints** %14
%60 = load %struct.sift_keypoints*, %struct.sift_keypoints** %15
%61 = load %struct.sift_keypoints*, %struct.sift_keypoints** %16
%62 = load %struct.sift_keypoints*, %struct.sift_keypoints** %17
%63 = load %struct.sift_keypoints*, %struct.sift_keypoints** %18
%64 = load float, float* %10
%65 = load i32, i32* %9
%66 = call i32 @matching(%struct.sift_keypoints* %59, %struct.sift_keypoints* %60, %struct.sift_keypoints* %61, %struct.sift_keypoints* %62, %struct.sift_keypoints* %63, float %64, i32 %65)
%67 = load %struct.sift_keypoints*, %struct.sift_keypoints** %16
%68 = load %struct.sift_keypoints*, %struct.sift_keypoints** %17
%69 = call i32 @print_pairs(%struct.sift_keypoints* %67, %struct.sift_keypoints* %68)
%70 = load i32, i32* @FILENAME_MAX
%71 = zext i32 %70 to i64
%72 = call i8* @llvm.stacksave()
store i8* %72, i8** %20
%73 = alloca i8, i64 %71
store i64 %71, i64* %21
%74 = load i32, i32* %11
%75 = icmp eq i32 %74, 1
br i1 %75, label %76, label %89
76: ; preds = %33
%77 = load %struct.sift_keypoints*, %struct.sift_keypoints** %16
%78 = load %struct.sift_keypoints*, %struct.sift_keypoints** %17
%79 = load %struct.sift_keypoints*, %struct.sift_keypoints** %18
%80 = call i32 @save_pairs_extra(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.1, i64 0, i64 0), %struct.sift_keypoints* %77, %struct.sift_keypoints* %78, %struct.sift_keypoints* %79)
%81 = getelementptr inbounds [256 x i8], [256 x i8]* %12, i64 0, i64 0
%82 = call i32 @sprintf(i8* %73, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.2, i64 0, i64 0), i8* %81)
%83 = load %struct.sift_keypoints*, %struct.sift_keypoints** %16
%84 = call i32 @sift_save_keypoints(%struct.sift_keypoints* %83, i8* %73, i32 1)
%85 = getelementptr inbounds [256 x i8], [256 x i8]* %12, i64 0, i64 0
%86 = call i32 @sprintf(i8* %73, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0), i8* %85)
%87 = load %struct.sift_keypoints*, %struct.sift_keypoints** %17
%88 = call i32 @sift_save_keypoints(%struct.sift_keypoints* %87, i8* %73, i32 1)
br label %89
89: ; preds = %76, %33
%90 = load %struct.sift_keypoints*, %struct.sift_keypoints** %14
%91 = call i32 @sift_free_keypoints(%struct.sift_keypoints* %90)
%92 = load %struct.sift_keypoints*, %struct.sift_keypoints** %15
%93 = call i32 @sift_free_keypoints(%struct.sift_keypoints* %92)
%94 = load %struct.sift_keypoints*, %struct.sift_keypoints** %16
%95 = call i32 @sift_free_keypoints(%struct.sift_keypoints* %94)
%96 = load %struct.sift_keypoints*, %struct.sift_keypoints** %17
%97 = call i32 @sift_free_keypoints(%struct.sift_keypoints* %96)
%98 = load %struct.sift_keypoints*, %struct.sift_keypoints** %18
%99 = call i32 @sift_free_keypoints(%struct.sift_keypoints* %98)
%100 = load i32, i32* @EXIT_SUCCESS
store i32 %100, i32* %3
%101 = load i8*, i8** %20
br label %102
102: ; preds = %89, %31
%103 = load i32, i32* %3
ret i32 %103
}

LLVM IR (-O2):
%struct.sift_keypoints = type { i32 }
@.str = [6 x i8] c"extra\00"
@EXIT_FAILURE = global i32 0
@FILENAME_MAX = global i32 0
@.str.1 = [15 x i8] c"OUTmatches.txt\00"
@.str.2 = [11 x i8] c"%s_im0.txt\00"
@.str.3 = [11 x i8] c"%s_im1.txt\00"
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca float
%8 = alloca i32
%9 = alloca [256 x i8]
%10 = bitcast i32* %3 to i8*
store i32 4, i32* %3
%11 = bitcast i32* %4 to i8*
store i32 8, i32* %4
%12 = bitcast i32* %5 to i8*
store i32 36, i32* %5
%13 = bitcast i32* %6 to i8*
store i32 1, i32* %6
%14 = bitcast float* %7 to i8*
store float 0x3FE3333340000000, float* %7
%15 = bitcast i32* %8 to i8*
store i32 0, i32* %8
%16 = getelementptr inbounds [256 x i8], [256 x i8]* %9, i64 0, i64 0
%17 = call i32 @strcpy(i8* %16, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0))
%18 = call i32 @parse_options(i32 %0, i8** %1, i32* %5, i32* %3, i32* %4, i32* %6, float* %7, i32* %8, i8* %16)
%19 = load i32, i32* @EXIT_FAILURE
%20 = icmp eq i32 %18, %19
br i1 %20, label %64, label %21
21: ; preds = %2
%22 = call %struct.sift_keypoints* (...) @sift_malloc_keypoints()
%23 = call %struct.sift_keypoints* (...) @sift_malloc_keypoints()
%24 = call %struct.sift_keypoints* (...) @sift_malloc_keypoints()
%25 = call %struct.sift_keypoints* (...) @sift_malloc_keypoints()
%26 = call %struct.sift_keypoints* (...) @sift_malloc_keypoints()
%27 = load i32, i32* %8
%28 = add nsw i32 %27, 1
%29 = getelementptr inbounds i8*, i8** %1, i64 1
%30 = load i8*, i8** %29
%31 = load i32, i32* %3
%32 = load i32, i32* %4
%33 = load i32, i32* %5
%34 = call i32 @sift_read_keypoints(%struct.sift_keypoints* %22, i8* %30, i32 %31, i32 %32, i32 %33, i32 %28)
%35 = getelementptr inbounds i8*, i8** %1, i64 2
%36 = load i8*, i8** %35
%37 = load i32, i32* %3
%38 = load i32, i32* %4
%39 = load i32, i32* %5
%40 = call i32 @sift_read_keypoints(%struct.sift_keypoints* %23, i8* %36, i32 %37, i32 %38, i32 %39, i32 %28)
%41 = load float, float* %7
%42 = load i32, i32* %6
%43 = call i32 @matching(%struct.sift_keypoints* %22, %struct.sift_keypoints* %23, %struct.sift_keypoints* %24, %struct.sift_keypoints* %25, %struct.sift_keypoints* %26, float %41, i32 %42)
%44 = call i32 @print_pairs(%struct.sift_keypoints* %24, %struct.sift_keypoints* %25)
%45 = load i32, i32* @FILENAME_MAX
%46 = zext i32 %45 to i64
%47 = call i8* @llvm.stacksave()
%48 = alloca i8, i64 %46
%49 = load i32, i32* %8
%50 = icmp eq i32 %49, 1
br i1 %50, label %51, label %57
51: ; preds = %21
%52 = call i32 @save_pairs_extra(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.1, i64 0, i64 0), %struct.sift_keypoints* %24, %struct.sift_keypoints* %25, %struct.sift_keypoints* %26)
%53 = call i32 @sprintf(i8* %48, i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.2, i64 0, i64 0), i8* %16)
%54 = call i32 @sift_save_keypoints(%struct.sift_keypoints* %24, i8* %48, i32 1)
%55 = call i32 @sprintf(i8* %48, i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0), i8* %16)
%56 = call i32 @sift_save_keypoints(%struct.sift_keypoints* %25, i8* %48, i32 1)
br label %57
57: ; preds = %51, %21
%58 = call i32 @sift_free_keypoints(%struct.sift_keypoints* %22)
%59 = call i32 @sift_free_keypoints(%struct.sift_keypoints* %23)
%60 = call i32 @sift_free_keypoints(%struct.sift_keypoints* %24)
%61 = call i32 @sift_free_keypoints(%struct.sift_keypoints* %25)
%62 = call i32 @sift_free_keypoints(%struct.sift_keypoints* %26)
%63 = load i32, i32* @EXIT_SUCCESS
br label %64
64: ; preds = %2, %57
%65 = phi i32 [ %63, %57 ], [ %18, %2 ]
ret i32 %65
}