#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 Distance(int, int, double **);
double Reduction10MVR(int a, double la, int b, double lb, int i, double lamda,
                      double **delta) {
  double Dui;
  Dui = (lamda * Distance(a, i, delta)) +
        ((1 - lamda) * (Distance(b, i, delta))) - (lamda * la) -
        ((1 - lamda) * lb);
  return (Dui);
}


x86 assembly (clang, -O0):
<Reduction10MVR>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
mov    %edi,-0x4(%rbp)
movsd  %xmm0,-0x10(%rbp)
mov    %esi,-0x14(%rbp)
movsd  %xmm1,-0x20(%rbp)
mov    %edx,-0x24(%rbp)
movsd  %xmm2,-0x30(%rbp)
mov    %rcx,-0x38(%rbp)
movsd  -0x30(%rbp),%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x24(%rbp),%esi
mov    -0x38(%rbp),%rdx
call   1030 <Distance@plt>
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  0xea2(%rip),%xmm0
subsd  -0x30(%rbp),%xmm0
movsd  %xmm0,-0x58(%rbp)
mov    -0x14(%rbp),%edi
mov    -0x24(%rbp),%esi
mov    -0x38(%rbp),%rdx
call   1030 <Distance@plt>
movsd  -0x58(%rbp),%xmm1
movsd  -0x50(%rbp),%xmm0
movsd  -0x48(%rbp),%xmm2
cvtsi2sd %eax,%xmm3
mulsd  %xmm3,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  -0x30(%rbp),%xmm1
movsd  -0x10(%rbp),%xmm2
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
movsd  0xe39(%rip),%xmm0
subsd  -0x30(%rbp),%xmm0
movsd  -0x20(%rbp),%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x40(%rbp),%xmm0
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Reduction10MVR>:
push   %rbp
push   %r14
push   %rbx
sub    $0x30,%rsp
mov    %rcx,%rbx
movsd  %xmm2,0x8(%rsp)
mov    %edx,%ebp
movsd  %xmm1,0x28(%rsp)
mov    %esi,%r14d
movsd  %xmm0,0x20(%rsp)
mov    %edx,%esi
mov    %rcx,%rdx
call   1030 <Distance@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
movsd  %xmm0,0x18(%rsp)
movsd  0xeaf(%rip),%xmm0
subsd  0x8(%rsp),%xmm0
movsd  %xmm0,0x10(%rsp)
mov    %r14d,%edi
mov    %ebp,%esi
mov    %rbx,%rdx
call   1030 <Distance@plt>
xorps  %xmm2,%xmm2
cvtsi2sd %eax,%xmm2
movsd  0x10(%rsp),%xmm3
mulsd  %xmm3,%xmm2
movsd  0x8(%rsp),%xmm1
movsd  0x18(%rsp),%xmm0
mulsd  %xmm1,%xmm0
addsd  %xmm2,%xmm0
movsd  0x20(%rsp),%xmm2
mulsd  %xmm1,%xmm2
subsd  %xmm2,%xmm0
mulsd  0x28(%rsp),%xmm3
subsd  %xmm3,%xmm0
add    $0x30,%rsp
pop    %rbx
pop    %r14
pop    %rbp
ret

LLVM IR (-O0):
define double @Reduction10MVR(i32 %0, double %1, i32 %2, double %3, i32 %4, double %5, double** %6) {
%8 = alloca i32
%9 = alloca double
%10 = alloca i32
%11 = alloca double
%12 = alloca i32
%13 = alloca double
%14 = alloca double**
%15 = alloca double
store i32 %0, i32* %8
store double %1, double* %9
store i32 %2, i32* %10
store double %3, double* %11
store i32 %4, i32* %12
store double %5, double* %13
store double** %6, double*** %14
%16 = load double, double* %13
%17 = load i32, i32* %8
%18 = load i32, i32* %12
%19 = load double**, double*** %14
%20 = call i32 @Distance(i32 %17, i32 %18, double** %19)
%21 = sitofp i32 %20 to double
%22 = load double, double* %13
%23 = fsub double 1.000000e+00, %22
%24 = load i32, i32* %10
%25 = load i32, i32* %12
%26 = load double**, double*** %14
%27 = call i32 @Distance(i32 %24, i32 %25, double** %26)
%28 = sitofp i32 %27 to double
%29 = fmul double %23, %28
%30 = call double @llvm.fmuladd.f64(double %16, double %21, double %29)
%31 = load double, double* %13
%32 = load double, double* %9
%33 = fneg double %31
%34 = call double @llvm.fmuladd.f64(double %33, double %32, double %30)
%35 = load double, double* %13
%36 = fsub double 1.000000e+00, %35
%37 = load double, double* %11
%38 = fneg double %36
%39 = call double @llvm.fmuladd.f64(double %38, double %37, double %34)
store double %39, double* %15
%40 = load double, double* %15
ret double %40
}

LLVM IR (-O2):
define double @Reduction10MVR(i32 %0, double %1, i32 %2, double %3, i32 %4, double %5, double** %6) {
%8 = tail call i32 @Distance(i32 %0, i32 %4, double** %6)
%9 = sitofp i32 %8 to double
%10 = fsub double 1.000000e+00, %5
%11 = tail call i32 @Distance(i32 %2, i32 %4, double** %6)
%12 = sitofp i32 %11 to double
%13 = fmul double %10, %12
%14 = tail call double @llvm.fmuladd.f64(double %5, double %9, double %13)
%15 = fneg double %5
%16 = tail call double @llvm.fmuladd.f64(double %15, double %1, double %14)
%17 = fneg double %10
%18 = tail call double @llvm.fmuladd.f64(double %17, double %3, double %16)
ret double %18
}