#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*/ quadratic_spline(double, double, double, double, double,
                                    double, double, double);
int /*<<< orphan*/ splinerel(double, double, int);
int /*<<< orphan*/ vdmnum(int, char *);
int /*<<< orphan*/ vdmprintf(char *, ...);
void vdmspline(int numpoints, int o_x, int o_y, int *numbers) {
  double cx_1, cy_1, cx_2, cy_2, cx_3, cy_3, cx_4, cy_4;
  double x_1, y_1, x_2, y_2;
  char xcoord[4], ycoord[4];
  int i;
  x_1 = o_x;
  y_1 = o_y;
  x_2 = o_x + numbers[(2 * 0)];
  y_2 = o_y + numbers[(2 * 0) + 1];
  cx_1 = (x_1 + x_2) / 2.0;
  cy_1 = (y_1 + y_2) / 2.0;
  cx_2 = (x_1 + 3.0 * x_2) / 4.0;
  cy_2 = (y_1 + 3.0 * y_2) / 4.0;
  vdmprintf("1%s%s", vdmnum((int)x_1, xcoord), vdmnum((int)y_1, ycoord));
  splinerel(x_1, y_1, -1);
  splinerel(cx_1, cy_1, 0);
  for (i = 1; i < (numpoints); i++) {
    x_1 = x_2;
    y_1 = y_2;
    x_2 = x_1 + numbers[(2 * i)];
    y_2 = y_1 + numbers[(2 * i) + 1];
    cx_3 = (3.0 * x_1 + x_2) / 4.0;
    cy_3 = (3.0 * y_1 + y_2) / 4.0;
    cx_4 = (x_1 + x_2) / 2.0;
    cy_4 = (y_1 + y_2) / 2.0;
    quadratic_spline(cx_1, cy_1, cx_2, cy_2, cx_3, cy_3, cx_4, cy_4);
    cx_1 = cx_4;
    cy_1 = cy_4;
    cx_2 = (x_1 + 3.0 * x_2) / 4.0;
    cy_2 = (y_1 + 3.0 * y_2) / 4.0;
  }
  x_1 = x_2;
  y_1 = y_2;
  x_2 = o_x + numbers[(2 * 0)];
  y_2 = o_y + numbers[(2 * 0) + 1];
  cx_3 = (3.0 * x_1 + x_2) / 4.0;
  cy_3 = (3.0 * y_1 + y_2) / 4.0;
  cx_4 = (x_1 + x_2) / 2.0;
  cy_4 = (y_1 + y_2) / 2.0;
  splinerel(x_1, y_1, 0);
  splinerel(x_1, y_1, 1);
  vdmprintf("\x1e\n");
}


x86 assembly (clang, -O0):
<vdmspline>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %rcx,-0x18(%rbp)
cvtsi2sdl -0x8(%rbp),%xmm0
movsd  %xmm0,-0x60(%rbp)
cvtsi2sdl -0xc(%rbp),%xmm0
movsd  %xmm0,-0x68(%rbp)
mov    -0x8(%rbp),%eax
mov    -0x18(%rbp),%rcx
add    (%rcx),%eax
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0x70(%rbp)
mov    -0xc(%rbp),%eax
mov    -0x18(%rbp),%rcx
add    0x4(%rcx),%eax
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x60(%rbp),%xmm0
addsd  -0x70(%rbp),%xmm0
movsd  0xe6d(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  -0x68(%rbp),%xmm0
addsd  -0x78(%rbp),%xmm0
movsd  0xe52(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x28(%rbp)
movsd  -0x60(%rbp),%xmm1
movsd  -0x70(%rbp),%xmm0
movsd  0xe2f(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xe17(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x68(%rbp),%xmm1
movsd  -0x78(%rbp),%xmm0
movsd  0xe04(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xdec(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x38(%rbp)
cvttsd2si -0x60(%rbp),%edi
lea    -0x7c(%rbp),%rsi
call   1030 <vdmnum@plt>
mov    %eax,-0x88(%rbp)
cvttsd2si -0x68(%rbp),%edi
lea    -0x80(%rbp),%rsi
call   1030 <vdmnum@plt>
mov    -0x88(%rbp),%esi
mov    %eax,%edx
lea    0xdca(%rip),%rdi
mov    $0x0,%al
call   1040 <vdmprintf@plt>
movsd  -0x60(%rbp),%xmm0
movsd  -0x68(%rbp),%xmm1
mov    $0xffffffff,%edi
call   1060 <splinerel@plt>
movsd  -0x20(%rbp),%xmm0
movsd  -0x28(%rbp),%xmm1
xor    %edi,%edi
call   1060 <splinerel@plt>
movl   $0x1,-0x84(%rbp)
mov    -0x84(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    1427 <vdmspline+0x2e7>
movsd  -0x70(%rbp),%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  -0x78(%rbp),%xmm0
movsd  %xmm0,-0x68(%rbp)
movsd  -0x60(%rbp),%xmm0
mov    -0x18(%rbp),%rax
mov    -0x84(%rbp),%ecx
shl    $0x1,%ecx
movslq %ecx,%rcx
cvtsi2sdl (%rax,%rcx,4),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  -0x68(%rbp),%xmm0
mov    -0x18(%rbp),%rax
mov    -0x84(%rbp),%ecx
shl    $0x1,%ecx
add    $0x1,%ecx
movslq %ecx,%rcx
cvtsi2sdl (%rax,%rcx,4),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x60(%rbp),%xmm0
movsd  -0x70(%rbp),%xmm1
movsd  0xd06(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xcee(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x68(%rbp),%xmm0
movsd  -0x78(%rbp),%xmm1
movsd  0xcdb(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xcc3(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  -0x60(%rbp),%xmm0
addsd  -0x70(%rbp),%xmm0
movsd  0xcb8(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  -0x68(%rbp),%xmm0
addsd  -0x78(%rbp),%xmm0
movsd  0xc9d(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x20(%rbp),%xmm0
movsd  -0x28(%rbp),%xmm1
movsd  -0x30(%rbp),%xmm2
movsd  -0x38(%rbp),%xmm3
movsd  -0x40(%rbp),%xmm4
movsd  -0x48(%rbp),%xmm5
movsd  -0x50(%rbp),%xmm6
movsd  -0x58(%rbp),%xmm7
call   1050 <quadratic_spline@plt>
movsd  -0x50(%rbp),%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  -0x58(%rbp),%xmm0
movsd  %xmm0,-0x28(%rbp)
movsd  -0x60(%rbp),%xmm1
movsd  -0x70(%rbp),%xmm0
movsd  0xc39(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xc21(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x68(%rbp),%xmm1
movsd  -0x78(%rbp),%xmm0
movsd  0xc0e(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xbf6(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x38(%rbp)
mov    -0x84(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x84(%rbp)
jmp    1284 <vdmspline+0x144>
movsd  -0x70(%rbp),%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  -0x78(%rbp),%xmm0
movsd  %xmm0,-0x68(%rbp)
mov    -0x8(%rbp),%eax
mov    -0x18(%rbp),%rcx
add    (%rcx),%eax
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0x70(%rbp)
mov    -0xc(%rbp),%eax
mov    -0x18(%rbp),%rcx
add    0x4(%rcx),%eax
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x60(%rbp),%xmm0
movsd  -0x70(%rbp),%xmm1
movsd  0xb96(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xb7e(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x68(%rbp),%xmm0
movsd  -0x78(%rbp),%xmm1
movsd  0xb6b(%rip),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xb53(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  -0x60(%rbp),%xmm0
addsd  -0x70(%rbp),%xmm0
movsd  0xb48(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  -0x68(%rbp),%xmm0
addsd  -0x78(%rbp),%xmm0
movsd  0xb2d(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x58(%rbp)
movsd  -0x60(%rbp),%xmm0
movsd  -0x68(%rbp),%xmm1
xor    %edi,%edi
call   1060 <splinerel@plt>
movsd  -0x60(%rbp),%xmm0
movsd  -0x68(%rbp),%xmm1
mov    $0x1,%edi
call   1060 <splinerel@plt>
lea    0xb06(%rip),%rdi
mov    $0x0,%al
call   1040 <vdmprintf@plt>
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<vdmspline>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x40,%rsp
mov    %rcx,%r12
mov    %edx,%ebp
mov    %esi,%eax
movd   %edx,%xmm0
movd   %esi,%xmm1
punpckldq %xmm0,%xmm1
cvtdq2pd %xmm1,%xmm2
movapd %xmm2,0x20(%rsp)
movq   (%rcx),%xmm0
paddd  %xmm1,%xmm0
cvtdq2pd %xmm0,%xmm0
mov    %edi,%r14d
movapd %xmm2,%xmm1
movapd %xmm0,0x10(%rsp)
addpd  %xmm0,%xmm1
mulpd  0xe72(%rip),%xmm1
movapd %xmm1,(%rsp)
lea    0x3c(%rsp),%rsi
mov    %eax,%edi
call   1030 <vdmnum@plt>
mov    %eax,%r15d
lea    0x38(%rsp),%rsi
mov    %ebp,%edi
call   1030 <vdmnum@plt>
lea    0xe7b(%rip),%rdi
mov    %r15d,%esi
mov    %eax,%edx
xor    %eax,%eax
call   1040 <vdmprintf@plt>
movaps 0x20(%rsp),%xmm0
movaps %xmm0,%xmm1
unpckhpd %xmm0,%xmm1
mov    $0xffffffff,%edi
call   1060 <splinerel@plt>
movapd (%rsp),%xmm0
movapd %xmm0,%xmm1
unpckhpd %xmm0,%xmm1
xor    %edi,%edi
call   1060 <splinerel@plt>
cmp    $0x2,%r14d
jl     12e9 <vdmspline+0x1a9>
movapd 0xe13(%rip),%xmm2
movapd 0x10(%rsp),%xmm1
mulpd  %xmm1,%xmm2
addpd  0x20(%rsp),%xmm2
mov    %r14d,%ebp
mov    $0x1,%ebx
movapd (%rsp),%xmm0
nopw   0x0(%rax,%rax,1)
movapd %xmm2,%xmm3
unpckhpd %xmm2,%xmm3
movsd  0xdf0(%rip),%xmm6
mulsd  %xmm6,%xmm3
mulsd  %xmm6,%xmm2
cvtdq2pd (%r12,%rbx,8),%xmm5
addpd  %xmm1,%xmm5
movapd %xmm1,%xmm7
movapd %xmm1,0x10(%rsp)
movapd %xmm1,%xmm4
movsd  0xdcf(%rip),%xmm8
mulsd  %xmm8,%xmm4
addsd  %xmm5,%xmm4
mulsd  %xmm6,%xmm4
movapd %xmm5,%xmm1
movapd %xmm5,%xmm9
movapd %xmm5,(%rsp)
unpckhpd %xmm5,%xmm1
movapd %xmm7,%xmm5
unpckhpd %xmm7,%xmm5
mulsd  %xmm8,%xmm5
addsd  %xmm1,%xmm5
mulsd  %xmm6,%xmm5
movapd %xmm7,%xmm6
addpd  %xmm9,%xmm6
mulpd  0xd62(%rip),%xmm6
movapd %xmm0,%xmm1
unpckhpd %xmm0,%xmm1
movapd %xmm6,%xmm7
movapd %xmm6,0x20(%rsp)
unpckhpd %xmm6,%xmm7
call   1050 <quadratic_spline@plt>
movapd (%rsp),%xmm3
movapd %xmm3,%xmm2
mulpd  0xd46(%rip),%xmm2
addpd  0x10(%rsp),%xmm2
add    $0x1,%rbx
movapd %xmm3,%xmm1
movapd 0x20(%rsp),%xmm0
cmp    %rbx,%rbp
jne    1220 <vdmspline+0xe0>
jmp    12ef <vdmspline+0x1af>
movapd 0x10(%rsp),%xmm3
movapd %xmm3,(%rsp)
movapd %xmm3,%xmm1
unpckhpd %xmm3,%xmm1
movapd %xmm1,0x10(%rsp)
movapd %xmm3,%xmm0
xor    %edi,%edi
call   1060 <splinerel@plt>
movaps (%rsp),%xmm0
movaps 0x10(%rsp),%xmm1
mov    $0x1,%edi
call   1060 <splinerel@plt>
lea    0xd0f(%rip),%rdi
xor    %eax,%eax
call   1040 <vdmprintf@plt>
add    $0x40,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [6 x i8] c"1%s%s\00"
@.str.1 = [3 x i8] c"\1E\0A\00"
define void @vdmspline(i32 %0, i32 %1, i32 %2, i32* %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32*
%9 = alloca double
%10 = alloca double
%11 = alloca double
%12 = alloca double
%13 = alloca double
%14 = alloca double
%15 = alloca double
%16 = alloca double
%17 = alloca double
%18 = alloca double
%19 = alloca double
%20 = alloca double
%21 = alloca [4 x i8]
%22 = alloca [4 x i8]
%23 = alloca i32
store i32 %0, i32* %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i32* %3, i32** %8
%24 = load i32, i32* %6
%25 = sitofp i32 %24 to double
store double %25, double* %17
%26 = load i32, i32* %7
%27 = sitofp i32 %26 to double
store double %27, double* %18
%28 = load i32, i32* %6
%29 = load i32*, i32** %8
%30 = getelementptr inbounds i32, i32* %29, i64 0
%31 = load i32, i32* %30
%32 = add nsw i32 %28, %31
%33 = sitofp i32 %32 to double
store double %33, double* %19
%34 = load i32, i32* %7
%35 = load i32*, i32** %8
%36 = getelementptr inbounds i32, i32* %35, i64 1
%37 = load i32, i32* %36
%38 = add nsw i32 %34, %37
%39 = sitofp i32 %38 to double
store double %39, double* %20
%40 = load double, double* %17
%41 = load double, double* %19
%42 = fadd double %40, %41
%43 = fdiv double %42, 2.000000e+00
store double %43, double* %9
%44 = load double, double* %18
%45 = load double, double* %20
%46 = fadd double %44, %45
%47 = fdiv double %46, 2.000000e+00
store double %47, double* %10
%48 = load double, double* %17
%49 = load double, double* %19
%50 = call double @llvm.fmuladd.f64(double 3.000000e+00, double %49, double %48)
%51 = fdiv double %50, 4.000000e+00
store double %51, double* %11
%52 = load double, double* %18
%53 = load double, double* %20
%54 = call double @llvm.fmuladd.f64(double 3.000000e+00, double %53, double %52)
%55 = fdiv double %54, 4.000000e+00
store double %55, double* %12
%56 = load double, double* %17
%57 = fptosi double %56 to i32
%58 = getelementptr inbounds [4 x i8], [4 x i8]* %21, i64 0, i64 0
%59 = call i32 @vdmnum(i32 %57, i8* %58)
%60 = load double, double* %18
%61 = fptosi double %60 to i32
%62 = getelementptr inbounds [4 x i8], [4 x i8]* %22, i64 0, i64 0
%63 = call i32 @vdmnum(i32 %61, i8* %62)
%64 = call i32 (i8*, ...) @vdmprintf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %59, i32 %63)
%65 = load double, double* %17
%66 = load double, double* %18
%67 = call i32 @splinerel(double %65, double %66, i32 -1)
%68 = load double, double* %9
%69 = load double, double* %10
%70 = call i32 @splinerel(double %68, double %69, i32 0)
store i32 1, i32* %23
br label %71
71: ; preds = %132, %4
%72 = load i32, i32* %23
%73 = load i32, i32* %5
%74 = icmp slt i32 %72, %73
br i1 %74, label %75, label %135
75: ; preds = %71
%76 = load double, double* %19
store double %76, double* %17
%77 = load double, double* %20
store double %77, double* %18
%78 = load double, double* %17
%79 = load i32*, i32** %8
%80 = load i32, i32* %23
%81 = mul nsw i32 2, %80
%82 = sext i32 %81 to i64
%83 = getelementptr inbounds i32, i32* %79, i64 %82
%84 = load i32, i32* %83
%85 = sitofp i32 %84 to double
%86 = fadd double %78, %85
store double %86, double* %19
%87 = load double, double* %18
%88 = load i32*, i32** %8
%89 = load i32, i32* %23
%90 = mul nsw i32 2, %89
%91 = add nsw i32 %90, 1
%92 = sext i32 %91 to i64
%93 = getelementptr inbounds i32, i32* %88, i64 %92
%94 = load i32, i32* %93
%95 = sitofp i32 %94 to double
%96 = fadd double %87, %95
store double %96, double* %20
%97 = load double, double* %17
%98 = load double, double* %19
%99 = call double @llvm.fmuladd.f64(double 3.000000e+00, double %97, double %98)
%100 = fdiv double %99, 4.000000e+00
store double %100, double* %13
%101 = load double, double* %18
%102 = load double, double* %20
%103 = call double @llvm.fmuladd.f64(double 3.000000e+00, double %101, double %102)
%104 = fdiv double %103, 4.000000e+00
store double %104, double* %14
%105 = load double, double* %17
%106 = load double, double* %19
%107 = fadd double %105, %106
%108 = fdiv double %107, 2.000000e+00
store double %108, double* %15
%109 = load double, double* %18
%110 = load double, double* %20
%111 = fadd double %109, %110
%112 = fdiv double %111, 2.000000e+00
store double %112, double* %16
%113 = load double, double* %9
%114 = load double, double* %10
%115 = load double, double* %11
%116 = load double, double* %12
%117 = load double, double* %13
%118 = load double, double* %14
%119 = load double, double* %15
%120 = load double, double* %16
%121 = call i32 @quadratic_spline(double %113, double %114, double %115, double %116, double %117, double %118, double %119, double %120)
%122 = load double, double* %15
store double %122, double* %9
%123 = load double, double* %16
store double %123, double* %10
%124 = load double, double* %17
%125 = load double, double* %19
%126 = call double @llvm.fmuladd.f64(double 3.000000e+00, double %125, double %124)
%127 = fdiv double %126, 4.000000e+00
store double %127, double* %11
%128 = load double, double* %18
%129 = load double, double* %20
%130 = call double @llvm.fmuladd.f64(double 3.000000e+00, double %129, double %128)
%131 = fdiv double %130, 4.000000e+00
store double %131, double* %12
br label %132
132: ; preds = %75
%133 = load i32, i32* %23
%134 = add nsw i32 %133, 1
store i32 %134, i32* %23
br label %71
135: ; preds = %71
%136 = load double, double* %19
store double %136, double* %17
%137 = load double, double* %20
store double %137, double* %18
%138 = load i32, i32* %6
%139 = load i32*, i32** %8
%140 = getelementptr inbounds i32, i32* %139, i64 0
%141 = load i32, i32* %140
%142 = add nsw i32 %138, %141
%143 = sitofp i32 %142 to double
store double %143, double* %19
%144 = load i32, i32* %7
%145 = load i32*, i32** %8
%146 = getelementptr inbounds i32, i32* %145, i64 1
%147 = load i32, i32* %146
%148 = add nsw i32 %144, %147
%149 = sitofp i32 %148 to double
store double %149, double* %20
%150 = load double, double* %17
%151 = load double, double* %19
%152 = call double @llvm.fmuladd.f64(double 3.000000e+00, double %150, double %151)
%153 = fdiv double %152, 4.000000e+00
store double %153, double* %13
%154 = load double, double* %18
%155 = load double, double* %20
%156 = call double @llvm.fmuladd.f64(double 3.000000e+00, double %154, double %155)
%157 = fdiv double %156, 4.000000e+00
store double %157, double* %14
%158 = load double, double* %17
%159 = load double, double* %19
%160 = fadd double %158, %159
%161 = fdiv double %160, 2.000000e+00
store double %161, double* %15
%162 = load double, double* %18
%163 = load double, double* %20
%164 = fadd double %162, %163
%165 = fdiv double %164, 2.000000e+00
store double %165, double* %16
%166 = load double, double* %17
%167 = load double, double* %18
%168 = call i32 @splinerel(double %166, double %167, i32 0)
%169 = load double, double* %17
%170 = load double, double* %18
%171 = call i32 @splinerel(double %169, double %170, i32 1)
%172 = call i32 (i8*, ...) @vdmprintf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [6 x i8] c"1%s%s\00"
@.str.1 = [3 x i8] c"\1E\0A\00"
define void @vdmspline(i32 %0, i32 %1, i32 %2, i32* nocapture %3) {
%5 = alloca [4 x i8]
%6 = alloca [4 x i8]
%7 = getelementptr inbounds [4 x i8], [4 x i8]* %5, i64 0, i64 0
%8 = getelementptr inbounds [4 x i8], [4 x i8]* %6, i64 0, i64 0
%9 = insertelement <2 x i32> poison, i32 %1, i64 0
%10 = insertelement <2 x i32> %9, i32 %2, i64 1
%11 = sitofp <2 x i32> %10 to <2 x double>
%12 = bitcast i32* %3 to <2 x i32>*
%13 = load <2 x i32>, <2 x i32>* %12
%14 = add nsw <2 x i32> %13, %10
%15 = sitofp <2 x i32> %14 to <2 x double>
%16 = fadd <2 x double> %11, %15
%17 = fmul <2 x double> %16, <double 5.000000e-01, double 5.000000e-01>
%18 = call i32 @vdmnum(i32 %1, i8* %7)
%19 = call i32 @vdmnum(i32 %2, i8* %8)
%20 = call i32 (i8*, ...) @vdmprintf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 %18, i32 %19)
%21 = extractelement <2 x double> %11, i64 0
%22 = extractelement <2 x double> %11, i64 1
%23 = call i32 @splinerel(double %21, double %22, i32 -1)
%24 = extractelement <2 x double> %17, i64 0
%25 = extractelement <2 x double> %17, i64 1
%26 = call i32 @splinerel(double %24, double %25, i32 0)
%27 = icmp sgt i32 %0, 1
br i1 %27, label %28, label %64
28: ; preds = %4
%29 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %15, <2 x double> <double 3.000000e+00, double 3.000000e+00>, <2 x double> %11)
%30 = zext i32 %0 to i64
br label %31
31: ; preds = %28, %31
%32 = phi i64 [ 1, %28 ], [ %62, %31 ]
%33 = phi <2 x double> [ %15, %28 ], [ %45, %31 ]
%34 = phi <2 x double> [ %17, %28 ], [ %55, %31 ]
%35 = phi <2 x double> [ %29, %28 ], [ %61, %31 ]
%36 = extractelement <2 x double> %35, i64 1
%37 = fmul double %36, 2.500000e-01
%38 = extractelement <2 x double> %35, i64 0
%39 = fmul double %38, 2.500000e-01
%40 = shl nuw nsw i64 %32, 1
%41 = getelementptr inbounds i32, i32* %3, i64 %40
%42 = bitcast i32* %41 to <2 x i32>*
%43 = load <2 x i32>, <2 x i32>* %42
%44 = sitofp <2 x i32> %43 to <2 x double>
%45 = fadd <2 x double> %33, %44
%46 = extractelement <2 x double> %45, i64 0
%47 = extractelement <2 x double> %33, i64 0
%48 = call double @llvm.fmuladd.f64(double %47, double 3.000000e+00, double %46)
%49 = fmul double %48, 2.500000e-01
%50 = extractelement <2 x double> %45, i64 1
%51 = extractelement <2 x double> %33, i64 1
%52 = call double @llvm.fmuladd.f64(double %51, double 3.000000e+00, double %50)
%53 = fmul double %52, 2.500000e-01
%54 = fadd <2 x double> %33, %45
%55 = fmul <2 x double> %54, <double 5.000000e-01, double 5.000000e-01>
%56 = extractelement <2 x double> %34, i64 0
%57 = extractelement <2 x double> %34, i64 1
%58 = extractelement <2 x double> %55, i64 0
%59 = extractelement <2 x double> %55, i64 1
%60 = call i32 @quadratic_spline(double %56, double %57, double %39, double %37, double %49, double %53, double %58, double %59)
%61 = call <2 x double> @llvm.fmuladd.v2f64(<2 x double> %45, <2 x double> <double 3.000000e+00, double 3.000000e+00>, <2 x double> %33)
%62 = add nuw nsw i64 %32, 1
%63 = icmp eq i64 %62, %30
br i1 %63, label %64, label %31
64: ; preds = %31, %4
%65 = phi <2 x double> [ %15, %4 ], [ %45, %31 ]
%66 = extractelement <2 x double> %65, i64 0
%67 = extractelement <2 x double> %65, i64 1
%68 = call i32 @splinerel(double %66, double %67, i32 0)
%69 = call i32 @splinerel(double %66, double %67, i32 1)
%70 = call i32 (i8*, ...) @vdmprintf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
ret void
}