#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 */

/* Variables and functions */
int /*<<< orphan*/ db_StitchSimilarity3DRaw(double *, double *, double *,
                                            double **, double **, int, int,
                                            int /*<<< orphan*/, int,
                                            int /*<<< orphan*/);
void db_StitchCameraRotation_2Points(double R[9], double x1[3], double x2[3],
                                     double xp1[3], double xp2[3]) {
  double *x[2];
  double *xp[2];
  double scale, t[3];
  x[0] = x1;
  x[1] = x2;
  xp[0] = xp1;
  xp[1] = xp2;
  db_StitchSimilarity3DRaw(&scale, R, t, xp, x, 2, 1, 0, 1, 0);
}


x86 assembly (clang, -O0):
<db_StitchCameraRotation_2Points>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x40(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x38(%rbp)
mov    -0x20(%rbp),%rax
mov    %rax,-0x50(%rbp)
mov    -0x28(%rbp),%rax
mov    %rax,-0x48(%rbp)
mov    -0x8(%rbp),%rsi
lea    -0x70(%rbp),%rdx
lea    -0x50(%rbp),%rcx
lea    -0x40(%rbp),%r8
lea    -0x58(%rbp),%rdi
mov    $0x2,%r9d
xor    %eax,%eax
movl   $0x1,(%rsp)
movl   $0x0,0x8(%rsp)
movl   $0x1,0x10(%rsp)
movl   $0x0,0x18(%rsp)
call   1030 <db_StitchSimilarity3DRaw@plt>
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<db_StitchCameraRotation_2Points>:
sub    $0x48,%rsp
mov    %rdi,%rax
mov    %rsi,0x10(%rsp)
mov    %rdx,0x18(%rsp)
mov    %rcx,(%rsp)
mov    %r8,0x8(%rsp)
lea    0x28(%rsp),%rdi
lea    0x30(%rsp),%rdx
mov    %rsp,%rcx
lea    0x10(%rsp),%r8
mov    %rax,%rsi
mov    $0x2,%r9d
push   $0x0
push   $0x1
push   $0x0
push   $0x1
call   1030 <db_StitchSimilarity3DRaw@plt>
add    $0x68,%rsp
ret

LLVM IR (-O0):
define void @db_StitchCameraRotation_2Points(double* %0, double* %1, double* %2, double* %3, double* %4) {
%6 = alloca double*
%7 = alloca double*
%8 = alloca double*
%9 = alloca double*
%10 = alloca double*
%11 = alloca [2 x double*]
%12 = alloca [2 x double*]
%13 = alloca double
%14 = alloca [3 x double]
store double* %0, double** %6
store double* %1, double** %7
store double* %2, double** %8
store double* %3, double** %9
store double* %4, double** %10
%15 = load double*, double** %7
%16 = getelementptr inbounds [2 x double*], [2 x double*]* %11, i64 0, i64 0
store double* %15, double** %16
%17 = load double*, double** %8
%18 = getelementptr inbounds [2 x double*], [2 x double*]* %11, i64 0, i64 1
store double* %17, double** %18
%19 = load double*, double** %9
%20 = getelementptr inbounds [2 x double*], [2 x double*]* %12, i64 0, i64 0
store double* %19, double** %20
%21 = load double*, double** %10
%22 = getelementptr inbounds [2 x double*], [2 x double*]* %12, i64 0, i64 1
store double* %21, double** %22
%23 = load double*, double** %6
%24 = getelementptr inbounds [3 x double], [3 x double]* %14, i64 0, i64 0
%25 = getelementptr inbounds [2 x double*], [2 x double*]* %12, i64 0, i64 0
%26 = getelementptr inbounds [2 x double*], [2 x double*]* %11, i64 0, i64 0
%27 = call i32 @db_StitchSimilarity3DRaw(double* %13, double* %23, double* %24, double** %25, double** %26, i32 2, i32 1, i32 0, i32 1, i32 0)
ret void
}

LLVM IR (-O2):
define void @db_StitchCameraRotation_2Points(double* %0, double* %1, double* %2, double* %3, double* %4) {
%6 = alloca [2 x double*]
%7 = alloca [2 x double*]
%8 = alloca double
%9 = alloca [3 x double]
%10 = bitcast [2 x double*]* %6 to i8*
%11 = bitcast [2 x double*]* %7 to i8*
%12 = bitcast double* %8 to i8*
%13 = bitcast [3 x double]* %9 to i8*
%14 = getelementptr inbounds [2 x double*], [2 x double*]* %6, i64 0, i64 0
store double* %1, double** %14
%15 = getelementptr inbounds [2 x double*], [2 x double*]* %6, i64 0, i64 1
store double* %2, double** %15
%16 = getelementptr inbounds [2 x double*], [2 x double*]* %7, i64 0, i64 0
store double* %3, double** %16
%17 = getelementptr inbounds [2 x double*], [2 x double*]* %7, i64 0, i64 1
store double* %4, double** %17
%18 = getelementptr inbounds [3 x double], [3 x double]* %9, i64 0, i64 0
%19 = call i32 @db_StitchSimilarity3DRaw(double* %8, double* %0, double* %18, double** %16, double** %14, i32 2, i32 1, i32 0, i32 1, i32 0)
ret void
}