#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 der;
int /*<<< orphan*/ free(double *);
scalar_t__ malloc(int);
double sqrt(int);
double emvnd(int m, double *w, double *x, double rh, int k, int ks,
             double eps) {
  double gd(double), der;
  double romberg(double (*)(double), double, double, double);
  int i;
  extern int mm, kk, ksign;
  extern double *ww, *xx, rs, r1;
  mm = m;
  kk = k;
  rs = sqrt(rh);
  r1 = sqrt(1. - rh);
  ksign = ks;
  xx = (double *)malloc((mm + 1) * sizeof(double));
  ww = (double *)malloc((mm + 1) * sizeof(double));
  for (i = 1; i <= mm; i++) {
    ww[i] = w[i];
    xx[i] = x[i];
  }
  der = romberg(gd, -6., 6., eps);
  free(xx);
  free(ww);
  return (ks * der);
}


x86 assembly (clang, -O0):
<emvnd>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
movsd  %xmm0,-0x20(%rbp)
mov    %ecx,-0x24(%rbp)
mov    %r8d,-0x28(%rbp)
movsd  %xmm1,-0x30(%rbp)
mov    -0x4(%rbp),%ecx
mov    0x2e8a(%rip),%rax
mov    %ecx,(%rax)
mov    -0x24(%rbp),%ecx
mov    0x2e56(%rip),%rax
mov    %ecx,(%rax)
cvttsd2si -0x20(%rbp),%edi
call   1060 <sqrt@plt>
mov    0x2e1b(%rip),%rax
movsd  %xmm0,(%rax)
movsd  0xe67(%rip),%xmm0
subsd  -0x20(%rbp),%xmm0
cvttsd2si %xmm0,%edi
call   1060 <sqrt@plt>
mov    0x2e42(%rip),%rax
movsd  %xmm0,(%rax)
mov    -0x28(%rbp),%ecx
mov    0x2e0c(%rip),%rax
mov    %ecx,(%rax)
mov    0x2e33(%rip),%rax
mov    (%rax),%eax
add    $0x1,%eax
cltq
shl    $0x3,%rax
mov    %eax,%edi
call   1050 <malloc@plt>
mov    %rax,%rcx
mov    0x2dd7(%rip),%rax
mov    %rcx,(%rax)
mov    0x2e0d(%rip),%rax
mov    (%rax),%eax
add    $0x1,%eax
cltq
shl    $0x3,%rax
mov    %eax,%edi
call   1050 <malloc@plt>
mov    %rax,%rcx
mov    0x2da9(%rip),%rax
mov    %rcx,(%rax)
movl   $0x1,-0x3c(%rbp)
mov    -0x3c(%rbp),%eax
mov    0x2ddd(%rip),%rcx
cmp    (%rcx),%eax
jg     1271 <emvnd+0x131>
mov    -0x10(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x2d79(%rip),%rax
mov    (%rax),%rax
movslq -0x3c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x18(%rbp),%rax
movslq -0x3c(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x2d61(%rip),%rax
mov    (%rax),%rax
movslq -0x3c(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
jmp    1211 <emvnd+0xd1>
movsd  -0x30(%rbp),%xmm2
mov    0x2d5b(%rip),%rdi
movsd  0xd83(%rip),%xmm0
movsd  0xd83(%rip),%xmm1
call   1040 <romberg@plt>
movsd  %xmm0,-0x38(%rbp)
mov    0x2d1a(%rip),%rax
mov    (%rax),%rdi
call   1030 <free@plt>
mov    0x2d03(%rip),%rax
mov    (%rax),%rdi
call   1030 <free@plt>
cvtsi2sdl -0x28(%rbp),%xmm0
mulsd  -0x38(%rbp),%xmm0
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<emvnd>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x28,%rsp
movsd  %xmm1,0x18(%rsp)
mov    %r8d,%r14d
movsd  %xmm0,0x10(%rsp)
mov    %rdx,%rbx
mov    %rsi,%rbp
mov    0x2e8e(%rip),%r13
mov    %edi,0x0(%r13)
mov    0x2e5b(%rip),%rax
mov    %ecx,(%rax)
cvttsd2si %xmm0,%edi
call   1060 <sqrt@plt>
mov    0x2e21(%rip),%rax
movsd  %xmm0,(%rax)
movsd  0xe6d(%rip),%xmm0
subsd  0x10(%rsp),%xmm0
cvttsd2si %xmm0,%edi
call   1060 <sqrt@plt>
mov    0x2e47(%rip),%rax
movsd  %xmm0,(%rax)
mov    0x2e14(%rip),%rax
mov    %r14d,(%rax)
mov    0x0(%r13),%eax
lea    0x8(,%rax,8),%edi
call   1050 <malloc@plt>
mov    0x2dea(%rip),%r15
mov    %rax,(%r15)
mov    0x0(%r13),%eax
lea    0x8(,%rax,8),%edi
call   1050 <malloc@plt>
mov    0x2dc8(%rip),%r12
mov    %rax,(%r12)
mov    0x0(%r13),%r8d
test   %r8d,%r8d
jle    140b <emvnd+0x2cb>
mov    (%r15),%rcx
lea    0x1(%r8),%r10
mov    $0x1,%esi
cmp    $0x4,%r8
jae    127b <emvnd+0x13b>
mov    %rsi,%rdx
not    %rdx
test   $0x1,%r10b
jne    1230 <emvnd+0xf0>
movsd  0x0(%rbp,%rsi,8),%xmm0
movsd  %xmm0,(%rax,%rsi,8)
movsd  (%rbx,%rsi,8),%xmm0
movsd  %xmm0,(%rcx,%rsi,8)
add    $0x1,%rsi
add    %r10,%rdx
je     140b <emvnd+0x2cb>
nopl   0x0(%rax)
movsd  0x0(%rbp,%rsi,8),%xmm0
movsd  %xmm0,(%rax,%rsi,8)
movsd  (%rbx,%rsi,8),%xmm0
movsd  %xmm0,(%rcx,%rsi,8)
movsd  0x8(%rbp,%rsi,8),%xmm0
movsd  %xmm0,0x8(%rax,%rsi,8)
movsd  0x8(%rbx,%rsi,8),%xmm0
movsd  %xmm0,0x8(%rcx,%rsi,8)
add    $0x2,%rsi
cmp    %rsi,%r10
jne    1240 <emvnd+0x100>
jmp    140b <emvnd+0x2cb>
mov    %r14d,0xc(%rsp)
lea    (%rax,%r10,8),%r15
mov    %rax,%rdx
add    $0x8,%rdx
lea    0x8(%rcx),%r11
lea    (%rcx,%r10,8),%r12
lea    0x8(%rbp),%r13
lea    0x0(,%r10,8),%r9
add    %rbp,%r9
lea    0x8(%rbx),%rdi
mov    %rdi,0x20(%rsp)
lea    (%rbx,%r10,8),%r14
cmp    %r12,%rdx
setb   0x10(%rsp)
cmp    %r15,%r11
setb   0xb(%rsp)
cmp    %r9,%rdx
setb   %dil
cmp    %r15,%r13
setb   0xa(%rsp)
cmp    %r14,%rdx
setb   0x9(%rsp)
mov    0x20(%rsp),%rdx
cmp    %r15,%rdx
setb   %r15b
cmp    %r9,%r11
setb   %r9b
cmp    %r12,%r13
setb   %r13b
cmp    %r14,%r11
setb   %r11b
cmp    %r12,%rdx
setb   %r12b
mov    0xb(%rsp),%dl
test   %dl,0x10(%rsp)
jne    1461 <emvnd+0x321>
and    0xa(%rsp),%dil
jne    1461 <emvnd+0x321>
and    %r15b,0x9(%rsp)
jne    1461 <emvnd+0x321>
and    %r13b,%r9b
jne    1461 <emvnd+0x321>
and    %r12b,%r11b
mov    0xc(%rsp),%r14d
mov    0x2c7e(%rip),%r15
mov    0x2c6f(%rip),%r12
jne    120b <emvnd+0xcb>
mov    %r8d,%esi
and    $0xfffffffc,%esi
lea    -0x4(%rsi),%rdx
mov    %rdx,%r9
shr    $0x2,%r9
add    $0x1,%r9
test   %rdx,%rdx
je     1482 <emvnd+0x342>
mov    %r9,%rdx
and    $0xfffffffffffffffe,%rdx
mov    $0x1,%edi
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
movups 0x0(%rbp,%rdi,8),%xmm0
movups 0x10(%rbp,%rdi,8),%xmm1
movups %xmm0,(%rax,%rdi,8)
movups %xmm1,0x10(%rax,%rdi,8)
movups (%rbx,%rdi,8),%xmm0
movups 0x10(%rbx,%rdi,8),%xmm1
movups %xmm0,(%rcx,%rdi,8)
movups %xmm1,0x10(%rcx,%rdi,8)
movups 0x20(%rbp,%rdi,8),%xmm0
movups 0x30(%rbp,%rdi,8),%xmm1
movups %xmm0,0x20(%rax,%rdi,8)
movups %xmm1,0x30(%rax,%rdi,8)
movupd 0x20(%rbx,%rdi,8),%xmm0
movups 0x30(%rbx,%rdi,8),%xmm1
movupd %xmm0,0x20(%rcx,%rdi,8)
movups %xmm1,0x30(%rcx,%rdi,8)
add    $0x8,%rdi
add    $0xfffffffffffffffe,%rdx
jne    1380 <emvnd+0x240>
test   $0x1,%r9b
je     1406 <emvnd+0x2c6>
movups 0x0(%rbp,%rdi,8),%xmm0
movups 0x10(%rbp,%rdi,8),%xmm1
movups %xmm0,(%rax,%rdi,8)
movups %xmm1,0x10(%rax,%rdi,8)
movupd (%rbx,%rdi,8),%xmm0
movups 0x10(%rbx,%rdi,8),%xmm1
movupd %xmm0,(%rcx,%rdi,8)
movups %xmm1,0x10(%rcx,%rdi,8)
cmp    %rsi,%r8
jne    1479 <emvnd+0x339>
mov    0x2bc6(%rip),%rdi
movsd  0xbee(%rip),%xmm0
movsd  0xbee(%rip),%xmm1
movsd  0x18(%rsp),%xmm2
call   1040 <romberg@plt>
movsd  %xmm0,0x18(%rsp)
mov    (%r15),%rdi
call   1030 <free@plt>
mov    (%r12),%rdi
call   1030 <free@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %r14d,%xmm0
mulsd  0x18(%rsp),%xmm0
add    $0x28,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
mov    0xc(%rsp),%r14d
mov    0x2b4b(%rip),%r15
mov    0x2b3c(%rip),%r12
jmp    120b <emvnd+0xcb>
or     $0x1,%rsi
jmp    120b <emvnd+0xcb>
mov    $0x1,%edi
test   $0x1,%r9b
jne    13df <emvnd+0x29f>
jmp    1406 <emvnd+0x2c6>

LLVM IR (-O0):
@mm = external global i32
@kk = external global i32
@rs = external global double
@r1 = external global double
@ksign = external global i32
@xx = external global double*
@ww = external global double*
@der = global i32 0
define double @emvnd(i32 %0, double* %1, double* %2, double %3, i32 %4, i32 %5, double %6) {
%8 = alloca i32
%9 = alloca double*
%10 = alloca double*
%11 = alloca double
%12 = alloca i32
%13 = alloca i32
%14 = alloca double
%15 = alloca double
%16 = alloca i32
store i32 %0, i32* %8
store double* %1, double** %9
store double* %2, double** %10
store double %3, double* %11
store i32 %4, i32* %12
store i32 %5, i32* %13
store double %6, double* %14
%17 = load i32, i32* %8
store i32 %17, i32* @mm
%18 = load i32, i32* %12
store i32 %18, i32* @kk
%19 = load double, double* %11
%20 = fptosi double %19 to i32
%21 = call double @sqrt(i32 %20)
store double %21, double* @rs
%22 = load double, double* %11
%23 = fsub double 1.000000e+00, %22
%24 = fptosi double %23 to i32
%25 = call double @sqrt(i32 %24)
store double %25, double* @r1
%26 = load i32, i32* %13
store i32 %26, i32* @ksign
%27 = load i32, i32* @mm
%28 = add nsw i32 %27, 1
%29 = sext i32 %28 to i64
%30 = mul i64 %29, 8
%31 = trunc i64 %30 to i32
%32 = call i64 @malloc(i32 %31)
%33 = inttoptr i64 %32 to double*
store double* %33, double** @xx
%34 = load i32, i32* @mm
%35 = add nsw i32 %34, 1
%36 = sext i32 %35 to i64
%37 = mul i64 %36, 8
%38 = trunc i64 %37 to i32
%39 = call i64 @malloc(i32 %38)
%40 = inttoptr i64 %39 to double*
store double* %40, double** @ww
store i32 1, i32* %16
br label %41
41: ; preds = %64, %7
%42 = load i32, i32* %16
%43 = load i32, i32* @mm
%44 = icmp sle i32 %42, %43
br i1 %44, label %45, label %67
45: ; preds = %41
%46 = load double*, double** %9
%47 = load i32, i32* %16
%48 = sext i32 %47 to i64
%49 = getelementptr inbounds double, double* %46, i64 %48
%50 = load double, double* %49
%51 = load double*, double** @ww
%52 = load i32, i32* %16
%53 = sext i32 %52 to i64
%54 = getelementptr inbounds double, double* %51, i64 %53
store double %50, double* %54
%55 = load double*, double** %10
%56 = load i32, i32* %16
%57 = sext i32 %56 to i64
%58 = getelementptr inbounds double, double* %55, i64 %57
%59 = load double, double* %58
%60 = load double*, double** @xx
%61 = load i32, i32* %16
%62 = sext i32 %61 to i64
%63 = getelementptr inbounds double, double* %60, i64 %62
store double %59, double* %63
br label %64
64: ; preds = %45
%65 = load i32, i32* %16
%66 = add nsw i32 %65, 1
store i32 %66, i32* %16
br label %41
67: ; preds = %41
%68 = load double, double* %14
%69 = call double @romberg(double (double)* @gd, double -6.000000e+00, double 6.000000e+00, double %68)
store double %69, double* %15
%70 = load double*, double** @xx
%71 = call i32 @free(double* %70)
%72 = load double*, double** @ww
%73 = call i32 @free(double* %72)
%74 = load i32, i32* %13
%75 = sitofp i32 %74 to double
%76 = load double, double* %15
%77 = fmul double %75, %76
ret double %77
}

LLVM IR (-O2):
@mm = external global i32
@kk = external global i32
@rs = external global double
@r1 = external global double
@ksign = external global i32
@xx = external global double*
@ww = external global double*
@der = global i32 0
define double @emvnd(i32 %0, double* nocapture %1, double* nocapture %2, double %3, i32 %4, i32 %5, double %6) {
store i32 %0, i32* @mm
store i32 %4, i32* @kk
%8 = fptosi double %3 to i32
%9 = tail call double @sqrt(i32 %8)
store double %9, double* @rs
%10 = fsub double 1.000000e+00, %3
%11 = fptosi double %10 to i32
%12 = tail call double @sqrt(i32 %11)
store double %12, double* @r1
store i32 %5, i32* @ksign
%13 = load i32, i32* @mm
%14 = shl i32 %13, 3
%15 = add i32 %14, 8
%16 = tail call i64 @malloc(i32 %15)
%17 = inttoptr i64 %16 to double*
store double* %17, double** @xx
%18 = load i32, i32* @mm
%19 = shl i32 %18, 3
%20 = add i32 %19, 8
%21 = tail call i64 @malloc(i32 %20)
%22 = inttoptr i64 %21 to double*
store double* %22, double** @ww
%23 = load i32, i32* @mm
%24 = icmp slt i32 %23, 1
br i1 %24, label %179, label %25
25: ; preds = %7
%26 = load double*, double** @xx
%27 = add nuw i32 %23, 1
%28 = zext i32 %27 to i64
%29 = add nsw i64 %28, -1
%30 = icmp ult i64 %29, 4
br i1 %30, label %145, label %31
31: ; preds = %25
%32 = getelementptr double, double* %22, i64 1
%33 = getelementptr double, double* %22, i64 %28
%34 = getelementptr double, double* %26, i64 1
%35 = getelementptr double, double* %26, i64 %28
%36 = getelementptr double, double* %1, i64 1
%37 = getelementptr double, double* %1, i64 %28
%38 = getelementptr double, double* %2, i64 1
%39 = getelementptr double, double* %2, i64 %28
%40 = icmp ult double* %32, %35
%41 = icmp ult double* %34, %33
%42 = and i1 %40, %41
%43 = icmp ult double* %32, %37
%44 = icmp ult double* %36, %33
%45 = and i1 %43, %44
%46 = or i1 %42, %45
%47 = icmp ult double* %32, %39
%48 = icmp ult double* %38, %33
%49 = and i1 %47, %48
%50 = or i1 %46, %49
%51 = icmp ult double* %34, %37
%52 = icmp ult double* %36, %35
%53 = and i1 %51, %52
%54 = or i1 %50, %53
%55 = icmp ult double* %34, %39
%56 = icmp ult double* %38, %35
%57 = and i1 %55, %56
%58 = or i1 %54, %57
br i1 %58, label %145, label %59
59: ; preds = %31
%60 = and i64 %29, -4
%61 = or i64 %60, 1
%62 = add nsw i64 %60, -4
%63 = lshr exact i64 %62, 2
%64 = add nuw nsw i64 %63, 1
%65 = and i64 %64, 1
%66 = icmp eq i64 %62, 0
br i1 %66, label %119, label %67
67: ; preds = %59
%68 = and i64 %64, 9223372036854775806
br label %69
69: ; preds = %69, %67
%70 = phi i64 [ 0, %67 ], [ %114, %69 ]
%71 = phi i64 [ 0, %67 ], [ %115, %69 ]
%72 = or i64 %70, 1
%73 = getelementptr inbounds double, double* %1, i64 %72
%74 = bitcast double* %73 to <2 x double>*
%75 = load <2 x double>, <2 x double>* %74
%76 = getelementptr inbounds double, double* %73, i64 2
%77 = bitcast double* %76 to <2 x double>*
%78 = load <2 x double>, <2 x double>* %77
%79 = getelementptr inbounds double, double* %22, i64 %72
%80 = bitcast double* %79 to <2 x double>*
store <2 x double> %75, <2 x double>* %80
%81 = getelementptr inbounds double, double* %79, i64 2
%82 = bitcast double* %81 to <2 x double>*
store <2 x double> %78, <2 x double>* %82
%83 = getelementptr inbounds double, double* %2, i64 %72
%84 = bitcast double* %83 to <2 x double>*
%85 = load <2 x double>, <2 x double>* %84
%86 = getelementptr inbounds double, double* %83, i64 2
%87 = bitcast double* %86 to <2 x double>*
%88 = load <2 x double>, <2 x double>* %87
%89 = getelementptr inbounds double, double* %26, i64 %72
%90 = bitcast double* %89 to <2 x double>*
store <2 x double> %85, <2 x double>* %90
%91 = getelementptr inbounds double, double* %89, i64 2
%92 = bitcast double* %91 to <2 x double>*
store <2 x double> %88, <2 x double>* %92
%93 = or i64 %70, 5
%94 = getelementptr inbounds double, double* %1, i64 %93
%95 = bitcast double* %94 to <2 x double>*
%96 = load <2 x double>, <2 x double>* %95
%97 = getelementptr inbounds double, double* %94, i64 2
%98 = bitcast double* %97 to <2 x double>*
%99 = load <2 x double>, <2 x double>* %98
%100 = getelementptr inbounds double, double* %22, i64 %93
%101 = bitcast double* %100 to <2 x double>*
store <2 x double> %96, <2 x double>* %101
%102 = getelementptr inbounds double, double* %100, i64 2
%103 = bitcast double* %102 to <2 x double>*
store <2 x double> %99, <2 x double>* %103
%104 = getelementptr inbounds double, double* %2, i64 %93
%105 = bitcast double* %104 to <2 x double>*
%106 = load <2 x double>, <2 x double>* %105
%107 = getelementptr inbounds double, double* %104, i64 2
%108 = bitcast double* %107 to <2 x double>*
%109 = load <2 x double>, <2 x double>* %108
%110 = getelementptr inbounds double, double* %26, i64 %93
%111 = bitcast double* %110 to <2 x double>*
store <2 x double> %106, <2 x double>* %111
%112 = getelementptr inbounds double, double* %110, i64 2
%113 = bitcast double* %112 to <2 x double>*
store <2 x double> %109, <2 x double>* %113
%114 = add nuw i64 %70, 8
%115 = add i64 %71, 2
%116 = icmp eq i64 %115, %68
br i1 %116, label %117, label %69
117: ; preds = %69
%118 = or i64 %114, 1
br label %119
119: ; preds = %117, %59
%120 = phi i64 [ 1, %59 ], [ %118, %117 ]
%121 = icmp eq i64 %65, 0
br i1 %121, label %143, label %122
122: ; preds = %119
%123 = getelementptr inbounds double, double* %1, i64 %120
%124 = bitcast double* %123 to <2 x double>*
%125 = load <2 x double>, <2 x double>* %124
%126 = getelementptr inbounds double, double* %123, i64 2
%127 = bitcast double* %126 to <2 x double>*
%128 = load <2 x double>, <2 x double>* %127
%129 = getelementptr inbounds double, double* %22, i64 %120
%130 = bitcast double* %129 to <2 x double>*
store <2 x double> %125, <2 x double>* %130
%131 = getelementptr inbounds double, double* %129, i64 2
%132 = bitcast double* %131 to <2 x double>*
store <2 x double> %128, <2 x double>* %132
%133 = getelementptr inbounds double, double* %2, i64 %120
%134 = bitcast double* %133 to <2 x double>*
%135 = load <2 x double>, <2 x double>* %134
%136 = getelementptr inbounds double, double* %133, i64 2
%137 = bitcast double* %136 to <2 x double>*
%138 = load <2 x double>, <2 x double>* %137
%139 = getelementptr inbounds double, double* %26, i64 %120
%140 = bitcast double* %139 to <2 x double>*
store <2 x double> %135, <2 x double>* %140
%141 = getelementptr inbounds double, double* %139, i64 2
%142 = bitcast double* %141 to <2 x double>*
store <2 x double> %138, <2 x double>* %142
br label %143
143: ; preds = %119, %122
%144 = icmp eq i64 %29, %60
br i1 %144, label %179, label %145
145: ; preds = %31, %25, %143
%146 = phi i64 [ 1, %31 ], [ 1, %25 ], [ %61, %143 ]
%147 = xor i64 %146, -1
%148 = and i64 %28, 1
%149 = icmp eq i64 %148, 0
br i1 %149, label %150, label %158
150: ; preds = %145
%151 = getelementptr inbounds double, double* %1, i64 %146
%152 = load double, double* %151
%153 = getelementptr inbounds double, double* %22, i64 %146
store double %152, double* %153
%154 = getelementptr inbounds double, double* %2, i64 %146
%155 = load double, double* %154
%156 = getelementptr inbounds double, double* %26, i64 %146
store double %155, double* %156
%157 = add nuw nsw i64 %146, 1
br label %158
158: ; preds = %150, %145
%159 = phi i64 [ %146, %145 ], [ %157, %150 ]
%160 = sub nsw i64 0, %28
%161 = icmp eq i64 %147, %160
br i1 %161, label %179, label %162
162: ; preds = %158, %162
%163 = phi i64 [ %177, %162 ], [ %159, %158 ]
%164 = getelementptr inbounds double, double* %1, i64 %163
%165 = load double, double* %164
%166 = getelementptr inbounds double, double* %22, i64 %163
store double %165, double* %166
%167 = getelementptr inbounds double, double* %2, i64 %163
%168 = load double, double* %167
%169 = getelementptr inbounds double, double* %26, i64 %163
store double %168, double* %169
%170 = add nuw nsw i64 %163, 1
%171 = getelementptr inbounds double, double* %1, i64 %170
%172 = load double, double* %171
%173 = getelementptr inbounds double, double* %22, i64 %170
store double %172, double* %173
%174 = getelementptr inbounds double, double* %2, i64 %170
%175 = load double, double* %174
%176 = getelementptr inbounds double, double* %26, i64 %170
store double %175, double* %176
%177 = add nuw nsw i64 %163, 2
%178 = icmp eq i64 %177, %28
br i1 %178, label %179, label %162
179: ; preds = %158, %162, %143, %7
%180 = tail call double @romberg(double (double)* @gd, double -6.000000e+00, double 6.000000e+00, double %6)
%181 = load double*, double** @xx
%182 = tail call i32 @free(double* %181)
%183 = load double*, double** @ww
%184 = tail call i32 @free(double* %183)
%185 = sitofp i32 %5 to double
%186 = fmul double %180, %185
ret double %186
}