#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 */
typedef int uint_fast16_t;
typedef int /*<<< orphan*/ uint64_t;

/* Variables and functions */
double M_PI;
int UINT64_MAX;
int cos(double);
double exp(double);
int /*<<< orphan*/ free(double *);
double *malloc(int);
int /*<<< orphan*/ rvm_r(double *, int, int /*<<< orphan*/, double,
                         int /*<<< orphan*/ *);
double sin(double);
double xorshift4096_r(int /*<<< orphan*/ *);
int mvvm_sampler_safe_rejection(int n, int p, double *mu, double *kappa,
                                double *lambda, double lmin, uint64_t *seeds,
                                double *ret) {
  uint_fast16_t i, j, k;
  double *auxv;
  double v;
  auxv = malloc(sizeof(double) * p);
  i = 0;
  while (i < n) {
    rvm_r(ret + (i * p), p, 0, lmin / 4, seeds);
    for (j = 0; j < p; j++)
      if (xorshift4096_r(seeds) > (UINT64_MAX / 2))
        ret[i * p + j] = ret[i * p + j] / 2 + M_PI;
      else
        ret[i * p + j] /= 2;
    v = 0;
    for (j = 0; j < p; j++)
      auxv[j] = sin(ret[i * p + j]);
    for (j = 0; j < p; j++) {
      v += kappa[j] * (cos(ret[i * p + j]) - 1);
      lambda[j * (p + 1)] = lmin;
      for (k = 0; k < p; k++)
        v += 0.5 * auxv[j] * auxv[k] * lambda[j * p + k];
      lambda[j * (p + 1)] = 0;
    }
    if (((xorshift4096_r(seeds) * 1.0) / (UINT64_MAX)) <= exp(v)) {
      for (j = 0; j < p; j++)
        ret[i * p + j] += mu[j];
      i++;
    }
  }
  free(auxv);
  return 0;
}


x86 assembly (clang, -O0):
<mvvm_sampler_safe_rejection>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
mov    0x10(%rbp),%rax
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %rdx,-0x10(%rbp)
mov    %rcx,-0x18(%rbp)
mov    %r8,-0x20(%rbp)
movsd  %xmm0,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
movslq -0x8(%rbp),%rax
shl    $0x3,%rax
mov    %eax,%edi
call   1070 <malloc@plt>
mov    %rax,-0x48(%rbp)
movl   $0x0,-0x34(%rbp)
mov    -0x34(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    14a6 <mvvm_sampler_safe_rejection+0x336>
mov    0x10(%rbp),%rdi
mov    -0x34(%rbp),%eax
imul   -0x8(%rbp),%eax
cltq
shl    $0x3,%rax
add    %rax,%rdi
mov    -0x8(%rbp),%esi
movsd  -0x28(%rbp),%xmm0
movsd  0xe1f(%rip),%xmm1
divsd  %xmm1,%xmm0
mov    -0x30(%rbp),%rcx
xor    %edx,%edx
call   1040 <rvm_r@plt>
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    12ad <mvvm_sampler_safe_rejection+0x13d>
mov    -0x30(%rbp),%rdi
call   1050 <xorshift4096_r@plt>
mov    0x2dbd(%rip),%rax
mov    (%rax),%eax
mov    $0x2,%ecx
cltd
idiv   %ecx
cvtsi2sd %eax,%xmm1
ucomisd %xmm1,%xmm0
jbe    1273 <mvvm_sampler_safe_rejection+0x103>
mov    0x10(%rbp),%rax
mov    -0x34(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  0xdcf(%rip),%xmm1
divsd  %xmm1,%xmm0
mov    0x2d94(%rip),%rax
addsd  (%rax),%xmm0
mov    0x10(%rbp),%rax
mov    -0x34(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
jmp    129a <mvvm_sampler_safe_rejection+0x12a>
mov    0x10(%rbp),%rax
mov    -0x34(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  0xd87(%rip),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,(%rax,%rcx,8)
jmp    129f <mvvm_sampler_safe_rejection+0x12f>
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    11f7 <mvvm_sampler_safe_rejection+0x87>
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x50(%rbp)
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    12fe <mvvm_sampler_safe_rejection+0x18e>
mov    0x10(%rbp),%rax
mov    -0x34(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
call   1060 <sin@plt>
mov    -0x48(%rbp),%rax
movslq -0x38(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    12bc <mvvm_sampler_safe_rejection+0x14c>
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    140d <mvvm_sampler_safe_rejection+0x29d>
mov    -0x18(%rbp),%rax
movslq -0x38(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x58(%rbp)
mov    0x10(%rbp),%rax
mov    -0x34(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm0
call   1090 <cos@plt>
movsd  -0x58(%rbp),%xmm0
sub    $0x1,%eax
cvtsi2sd %eax,%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  -0x28(%rbp),%xmm0
mov    -0x20(%rbp),%rax
mov    -0x38(%rbp),%ecx
mov    -0x8(%rbp),%edx
add    $0x1,%edx
imul   %edx,%ecx
movslq %ecx,%rcx
movsd  %xmm0,(%rax,%rcx,8)
movl   $0x0,-0x3c(%rbp)
mov    -0x3c(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    13e4 <mvvm_sampler_safe_rejection+0x274>
mov    -0x48(%rbp),%rax
movslq -0x38(%rbp),%rcx
movsd  0xc74(%rip),%xmm0
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x48(%rbp),%rax
movslq -0x3c(%rbp),%rcx
mulsd  (%rax,%rcx,8),%xmm0
mov    -0x20(%rbp),%rax
mov    -0x38(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x3c(%rbp),%ecx
movslq %ecx,%rcx
movsd  (%rax,%rcx,8),%xmm2
movsd  -0x50(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x3c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x3c(%rbp)
jmp    1380 <mvvm_sampler_safe_rejection+0x210>
mov    -0x20(%rbp),%rax
mov    -0x38(%rbp),%ecx
mov    -0x8(%rbp),%edx
add    $0x1,%edx
imul   %edx,%ecx
movslq %ecx,%rcx
xorps  %xmm0,%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    1305 <mvvm_sampler_safe_rejection+0x195>
mov    -0x30(%rbp),%rdi
call   1050 <xorshift4096_r@plt>
movsd  0xbea(%rip),%xmm1
mulsd  %xmm1,%xmm0
mov    0x2ba7(%rip),%rax
cvtsi2sdl (%rax),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,-0x60(%rbp)
movsd  -0x50(%rbp),%xmm0
call   1080 <exp@plt>
movsd  -0x60(%rbp),%xmm1
ucomisd %xmm1,%xmm0
jb     14a1 <mvvm_sampler_safe_rejection+0x331>
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1498 <mvvm_sampler_safe_rejection+0x328>
mov    -0x10(%rbp),%rax
movslq -0x38(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
mov    0x10(%rbp),%rax
mov    -0x34(%rbp),%ecx
imul   -0x8(%rbp),%ecx
add    -0x38(%rbp),%ecx
movslq %ecx,%rcx
addsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    1456 <mvvm_sampler_safe_rejection+0x2e6>
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    11b1 <mvvm_sampler_safe_rejection+0x41>
mov    -0x48(%rbp),%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mvvm_sampler_safe_rejection>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0xf8,%rsp
mov    %r9,%r13
movsd  %xmm0,0x40(%rsp)
mov    %r8,%rbx
mov    %rcx,0xf0(%rsp)
mov    %rdx,%r14
mov    %edi,%r15d
mov    %rsi,0x8(%rsp)
lea    0x0(,%rsi,8),%edi
call   1070 <malloc@plt>
mov    %rax,%rbp
mov    %r15d,0x2c(%rsp)
test   %r15d,%r15d
jle    17ec <mvvm_sampler_safe_rejection+0x67c>
mov    %rbx,%r8
mov    0x130(%rsp),%rcx
movsd  0xe30(%rip),%xmm0
mulsd  0x40(%rsp),%xmm0
movsd  %xmm0,0xc8(%rsp)
mov    0x8(%rsp),%rdx
lea    0x1(%rdx),%eax
cltq
mov    %rax,0xe8(%rsp)
movslq %edx,%rax
mov    %edx,%edx
lea    (%rcx,%rdx,8),%rsi
mov    %rsi,0x70(%rsp)
lea    (%r14,%rdx,8),%rsi
mov    %rsi,0x80(%rsp)
lea    -0x1(%rdx),%rsi
mov    %rsi,0x48(%rsp)
mov    %edx,%esi
and    $0xfffffffc,%esi
mov    %rsi,0x30(%rsp)
add    $0xfffffffffffffffc,%rsi
mov    %rsi,0x68(%rsp)
mov    %rsi,%rdi
shr    $0x2,%rdi
add    $0x1,%rdi
mov    %edx,%ebx
and    $0x3,%ebx
mov    %edx,%r15d
and    $0xfffffffe,%r15d
mov    %rdi,%rsi
mov    %rdi,0x60(%rsp)
and    $0xfffffffffffffffe,%rdi
mov    %rdi,0x58(%rsp)
mov    %rdx,0x20(%rsp)
neg    %rdx
mov    %rdx,0x98(%rsp)
lea    0x18(%rcx),%rdx
mov    %rdx,0x88(%rsp)
lea    0x8(%r8),%rdx
mov    %rdx,0x90(%rsp)
mov    %rax,0xe0(%rsp)
lea    0x0(,%rax,8),%rax
mov    %rax,0xa8(%rsp)
lea    0x30(%rcx),%rax
mov    %rax,0x50(%rsp)
lea    0x8(%rcx),%rax
mov    %rax,0x78(%rsp)
xor    %r12d,%r12d
mov    %r13,0xd0(%rsp)
mov    %r14,0xc0(%rsp)
mov    %r8,0xb8(%rsp)
mov    %rbx,0xb0(%rsp)
mov    %r15,0xa0(%rsp)
jmp    12df <mvvm_sampler_safe_rejection+0x16f>
xchg   %ax,%ax
add    $0x1,%r12d
cmp    0x2c(%rsp),%r12d
jge    17ec <mvvm_sampler_safe_rejection+0x67c>
mov    %r12d,%eax
mov    0x8(%rsp),%rbx
imul   %ebx,%eax
movslq %eax,%rcx
mov    0x130(%rsp),%rax
mov    %rcx,(%rsp)
lea    (%rax,%rcx,8),%r14
mov    %r14,%rdi
mov    %ebx,%esi
xor    %edx,%edx
movsd  0xc8(%rsp),%xmm0
mov    %r13,%rcx
call   1040 <rvm_r@plt>
xorpd  %xmm2,%xmm2
test   %ebx,%ebx
mov    %r12,0x38(%rsp)
mov    %r14,0xd8(%rsp)
jle    15e0 <mvvm_sampler_safe_rejection+0x470>
mov    %r14,%r15
xor    %ebx,%ebx
mov    0x2cae(%rip),%r14
mov    0x2c8f(%rip),%r12
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    %r13,%rdi
call   1050 <xorshift4096_r@plt>
mov    (%r12),%eax
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
sar    %ecx
xorps  %xmm1,%xmm1
cvtsi2sd %ecx,%xmm1
movsd  (%r15,%rbx,8),%xmm2
mulsd  0xc8e(%rip),%xmm2
cmpltsd %xmm0,%xmm1
movsd  (%r14),%xmm0
andpd  %xmm1,%xmm0
movsd  0xc80(%rip),%xmm3
andnpd %xmm3,%xmm1
orpd   %xmm0,%xmm1
addsd  %xmm2,%xmm1
movsd  %xmm1,(%r15,%rbx,8)
add    $0x1,%rbx
cmp    %rbx,0x20(%rsp)
jne    1350 <mvvm_sampler_safe_rejection+0x1e0>
cmpl   $0x0,0x8(%rsp)
jle    13c0 <mvvm_sampler_safe_rejection+0x250>
cmpq   $0x3,0x48(%rsp)
jae    13c9 <mvvm_sampler_safe_rejection+0x259>
xor    %ebx,%ebx
jmp    1430 <mvvm_sampler_safe_rejection+0x2c0>
xorpd  %xmm2,%xmm2
jmp    15e0 <mvvm_sampler_safe_rejection+0x470>
mov    0x88(%rsp),%rax
mov    (%rsp),%rcx
lea    (%rax,%rcx,8),%r14
xor    %ebx,%ebx
mov    0x30(%rsp),%r12
movsd  -0x18(%r14,%rbx,8),%xmm0
call   1060 <sin@plt>
movsd  %xmm0,0x0(%rbp,%rbx,8)
movsd  -0x10(%r14,%rbx,8),%xmm0
call   1060 <sin@plt>
movsd  %xmm0,0x8(%rbp,%rbx,8)
movsd  -0x8(%r14,%rbx,8),%xmm0
call   1060 <sin@plt>
movsd  %xmm0,0x10(%rbp,%rbx,8)
movsd  (%r14,%rbx,8),%xmm0
call   1060 <sin@plt>
movsd  %xmm0,0x18(%rbp,%rbx,8)
add    $0x4,%rbx
cmp    %rbx,%r12
jne    13e0 <mvvm_sampler_safe_rejection+0x270>
mov    0xb0(%rsp),%r13
test   %r13,%r13
mov    0xa0(%rsp),%r15
je     148a <mvvm_sampler_safe_rejection+0x31a>
lea    0x0(,%rbx,8),%r14
add    %rbp,%r14
add    (%rsp),%rbx
mov    0x130(%rsp),%rax
lea    (%rax,%rbx,8),%rbx
xor    %r12d,%r12d
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
movsd  (%rbx,%r12,8),%xmm0
call   1060 <sin@plt>
movsd  %xmm0,(%r14,%r12,8)
add    $0x1,%r12
cmp    %r12,%r13
jne    1470 <mvvm_sampler_safe_rejection+0x300>
cmpl   $0x0,0x8(%rsp)
mov    0xb8(%rsp),%r12
mov    0xa8(%rsp),%r13
xorpd  %xmm2,%xmm2
jle    15e0 <mvvm_sampler_safe_rejection+0x470>
xorpd  %xmm0,%xmm0
mov    0x90(%rsp),%r14
xor    %ebx,%ebx
jmp    14dc <mvvm_sampler_safe_rejection+0x36c>
nopl   0x0(%rax)
movq   $0x0,(%r12,%rcx,8)
add    $0x1,%rbx
add    %r13,%r14
movapd %xmm2,%xmm0
cmp    %rdi,%rbx
je     15e0 <mvvm_sampler_safe_rejection+0x470>
movsd  %xmm0,0x18(%rsp)
mov    0xf0(%rsp),%rax
movsd  (%rax,%rbx,8),%xmm0
movsd  %xmm0,0x10(%rsp)
mov    (%rsp),%rax
add    %rbx,%rax
mov    0x130(%rsp),%rcx
movsd  (%rcx,%rax,8),%xmm0
call   1090 <cos@plt>
mov    %rbx,%rcx
imul   0xe8(%rsp),%rcx
add    $0xffffffff,%eax
movsd  0x40(%rsp),%xmm0
movsd  %xmm0,(%r12,%rcx,8)
xorps  %xmm2,%xmm2
cvtsi2sd %eax,%xmm2
mulsd  0x10(%rsp),%xmm2
addsd  0x18(%rsp),%xmm2
movsd  0x0(%rbp,%rbx,8),%xmm0
mulsd  0xabe(%rip),%xmm0
cmpq   $0x0,0x48(%rsp)
je     15a0 <mvvm_sampler_safe_rejection+0x430>
xor    %eax,%eax
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
movsd  0x0(%rbp,%rax,8),%xmm1
mulsd  %xmm0,%xmm1
mulsd  -0x8(%r14,%rax,8),%xmm1
addsd  %xmm2,%xmm1
movsd  0x8(%rbp,%rax,8),%xmm2
mulsd  %xmm0,%xmm2
mulsd  (%r14,%rax,8),%xmm2
addsd  %xmm1,%xmm2
add    $0x2,%rax
cmp    %rax,%r15
jne    1560 <mvvm_sampler_safe_rejection+0x3f0>
jmp    15a2 <mvvm_sampler_safe_rejection+0x432>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
xor    %eax,%eax
mov    0x20(%rsp),%rdi
test   $0x1,%dil
je     14c0 <mvvm_sampler_safe_rejection+0x350>
mov    %rbx,%rdx
imul   0xe0(%rsp),%rdx
mulsd  0x0(%rbp,%rax,8),%xmm0
add    %rax,%rdx
mulsd  (%r12,%rdx,8),%xmm0
addsd  %xmm0,%xmm2
jmp    14c0 <mvvm_sampler_safe_rejection+0x350>
cs nopw 0x0(%rax,%rax,1)
nop
movsd  %xmm2,0x18(%rsp)
mov    0xd0(%rsp),%r13
mov    %r13,%rdi
call   1050 <xorshift4096_r@plt>
mov    0x29d3(%rip),%rax
xorps  %xmm1,%xmm1
cvtsi2sdl (%rax),%xmm1
divsd  %xmm1,%xmm0
movsd  %xmm0,0x10(%rsp)
movsd  0x18(%rsp),%xmm0
call   1080 <exp@plt>
ucomisd 0x10(%rsp),%xmm0
jae    1640 <mvvm_sampler_safe_rejection+0x4d0>
mov    0x38(%rsp),%r12
cmp    0x2c(%rsp),%r12d
jl     12df <mvvm_sampler_safe_rejection+0x16f>
jmp    17ec <mvvm_sampler_safe_rejection+0x67c>
cs nopw 0x0(%rax,%rax,1)
cmpl   $0x0,0x8(%rsp)
mov    0xc0(%rsp),%rsi
mov    0x20(%rsp),%rdi
mov    0x38(%rsp),%r12
jle    12d0 <mvvm_sampler_safe_rejection+0x160>
cmpl   $0x4,0x8(%rsp)
jb     1690 <mvvm_sampler_safe_rejection+0x520>
mov    0xd8(%rsp),%rax
cmp    0x80(%rsp),%rax
jae    170f <mvvm_sampler_safe_rejection+0x59f>
mov    0x70(%rsp),%rax
mov    (%rsp),%rcx
lea    (%rax,%rcx,8),%rax
cmp    %rsi,%rax
jbe    170f <mvvm_sampler_safe_rejection+0x59f>
xor    %ecx,%ecx
mov    %rcx,%rax
test   $0x1,%dil
je     16c0 <mvvm_sampler_safe_rejection+0x550>
movsd  (%rsi,%rcx,8),%xmm0
mov    (%rsp),%rax
add    %rcx,%rax
mov    0x130(%rsp),%rdx
addsd  (%rdx,%rax,8),%xmm0
movsd  %xmm0,(%rdx,%rax,8)
mov    %rcx,%rax
or     $0x1,%rax
not    %rcx
cmp    0x98(%rsp),%rcx
je     12d0 <mvvm_sampler_safe_rejection+0x160>
mov    0x78(%rsp),%rcx
mov    (%rsp),%rdx
lea    (%rcx,%rdx,8),%rcx
xchg   %ax,%ax
movsd  (%rsi,%rax,8),%xmm0
addsd  -0x8(%rcx,%rax,8),%xmm0
movsd  %xmm0,-0x8(%rcx,%rax,8)
movsd  0x8(%rsi,%rax,8),%xmm0
addsd  (%rcx,%rax,8),%xmm0
movsd  %xmm0,(%rcx,%rax,8)
add    $0x2,%rax
cmp    %rax,%rdi
jne    16e0 <mvvm_sampler_safe_rejection+0x570>
jmp    12d0 <mvvm_sampler_safe_rejection+0x160>
cmpq   $0x0,0x68(%rsp)
je     17e1 <mvvm_sampler_safe_rejection+0x671>
mov    0x50(%rsp),%rax
mov    (%rsp),%rcx
lea    (%rax,%rcx,8),%rcx
mov    0x58(%rsp),%rdx
xor    %eax,%eax
nop
movupd (%rsi,%rax,8),%xmm0
movupd 0x10(%rsi,%rax,8),%xmm1
movupd -0x30(%rcx,%rax,8),%xmm2
addpd  %xmm0,%xmm2
movupd -0x20(%rcx,%rax,8),%xmm0
addpd  %xmm1,%xmm0
movupd -0x10(%rcx,%rax,8),%xmm1
movupd (%rcx,%rax,8),%xmm3
movupd %xmm2,-0x30(%rcx,%rax,8)
movupd %xmm0,-0x20(%rcx,%rax,8)
movupd 0x20(%rsi,%rax,8),%xmm0
addpd  %xmm1,%xmm0
movupd 0x30(%rsi,%rax,8),%xmm1
addpd  %xmm3,%xmm1
movupd %xmm0,-0x10(%rcx,%rax,8)
movupd %xmm1,(%rcx,%rax,8)
add    $0x8,%rax
add    $0xfffffffffffffffe,%rdx
jne    1730 <mvvm_sampler_safe_rejection+0x5c0>
testb  $0x1,0x60(%rsp)
je     17cb <mvvm_sampler_safe_rejection+0x65b>
movupd (%rsi,%rax,8),%xmm0
movupd 0x10(%rsi,%rax,8),%xmm1
add    (%rsp),%rax
mov    0x130(%rsp),%rcx
movupd (%rcx,%rax,8),%xmm2
addpd  %xmm0,%xmm2
movupd 0x10(%rcx,%rax,8),%xmm0
addpd  %xmm1,%xmm0
movupd %xmm2,(%rcx,%rax,8)
movupd %xmm0,0x10(%rcx,%rax,8)
mov    0x30(%rsp),%rax
mov    %rax,%rcx
cmp    %rdi,%rax
je     12d0 <mvvm_sampler_safe_rejection+0x160>
jmp    1692 <mvvm_sampler_safe_rejection+0x522>
xor    %eax,%eax
testb  $0x1,0x60(%rsp)
jne    1796 <mvvm_sampler_safe_rejection+0x626>
jmp    17cb <mvvm_sampler_safe_rejection+0x65b>
mov    %rbp,%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0xf8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@UINT64_MAX = global i32 0
@M_PI = global double 0.000000e+00
define i32 @mvvm_sampler_safe_rejection(i32 %0, i32 %1, double* %2, double* %3, double* %4, double %5, i32* %6, double* %7) {
%9 = alloca i32
%10 = alloca i32
%11 = alloca double*
%12 = alloca double*
%13 = alloca double*
%14 = alloca double
%15 = alloca i32*
%16 = alloca double*
%17 = alloca i32
%18 = alloca i32
%19 = alloca i32
%20 = alloca double*
%21 = alloca double
store i32 %0, i32* %9
store i32 %1, i32* %10
store double* %2, double** %11
store double* %3, double** %12
store double* %4, double** %13
store double %5, double* %14
store i32* %6, i32** %15
store double* %7, double** %16
%22 = load i32, i32* %10
%23 = sext i32 %22 to i64
%24 = mul i64 8, %23
%25 = trunc i64 %24 to i32
%26 = call double* @malloc(i32 %25)
store double* %26, double** %20
store i32 0, i32* %17
br label %27
27: ; preds = %225, %8
%28 = load i32, i32* %17
%29 = load i32, i32* %9
%30 = icmp slt i32 %28, %29
br i1 %30, label %31, label %226
31: ; preds = %27
%32 = load double*, double** %16
%33 = load i32, i32* %17
%34 = load i32, i32* %10
%35 = mul nsw i32 %33, %34
%36 = sext i32 %35 to i64
%37 = getelementptr inbounds double, double* %32, i64 %36
%38 = load i32, i32* %10
%39 = load double, double* %14
%40 = fdiv double %39, 4.000000e+00
%41 = load i32*, i32** %15
%42 = call i32 @rvm_r(double* %37, i32 %38, i32 0, double %40, i32* %41)
store i32 0, i32* %18
br label %43
43: ; preds = %87, %31
%44 = load i32, i32* %18
%45 = load i32, i32* %10
%46 = icmp slt i32 %44, %45
br i1 %46, label %47, label %90
47: ; preds = %43
%48 = load i32*, i32** %15
%49 = call double @xorshift4096_r(i32* %48)
%50 = load i32, i32* @UINT64_MAX
%51 = sdiv i32 %50, 2
%52 = sitofp i32 %51 to double
%53 = fcmp ogt double %49, %52
br i1 %53, label %54, label %75
54: ; preds = %47
%55 = load double*, double** %16
%56 = load i32, i32* %17
%57 = load i32, i32* %10
%58 = mul nsw i32 %56, %57
%59 = load i32, i32* %18
%60 = add nsw i32 %58, %59
%61 = sext i32 %60 to i64
%62 = getelementptr inbounds double, double* %55, i64 %61
%63 = load double, double* %62
%64 = fdiv double %63, 2.000000e+00
%65 = load double, double* @M_PI
%66 = fadd double %64, %65
%67 = load double*, double** %16
%68 = load i32, i32* %17
%69 = load i32, i32* %10
%70 = mul nsw i32 %68, %69
%71 = load i32, i32* %18
%72 = add nsw i32 %70, %71
%73 = sext i32 %72 to i64
%74 = getelementptr inbounds double, double* %67, i64 %73
store double %66, double* %74
br label %86
75: ; preds = %47
%76 = load double*, double** %16
%77 = load i32, i32* %17
%78 = load i32, i32* %10
%79 = mul nsw i32 %77, %78
%80 = load i32, i32* %18
%81 = add nsw i32 %79, %80
%82 = sext i32 %81 to i64
%83 = getelementptr inbounds double, double* %76, i64 %82
%84 = load double, double* %83
%85 = fdiv double %84, 2.000000e+00
store double %85, double* %83
br label %86
86: ; preds = %75, %54
br label %87
87: ; preds = %86
%88 = load i32, i32* %18
%89 = add nsw i32 %88, 1
store i32 %89, i32* %18
br label %43
90: ; preds = %43
store double 0.000000e+00, double* %21
store i32 0, i32* %18
br label %91
91: ; preds = %110, %90
%92 = load i32, i32* %18
%93 = load i32, i32* %10
%94 = icmp slt i32 %92, %93
br i1 %94, label %95, label %113
95: ; preds = %91
%96 = load double*, double** %16
%97 = load i32, i32* %17
%98 = load i32, i32* %10
%99 = mul nsw i32 %97, %98
%100 = load i32, i32* %18
%101 = add nsw i32 %99, %100
%102 = sext i32 %101 to i64
%103 = getelementptr inbounds double, double* %96, i64 %102
%104 = load double, double* %103
%105 = call double @sin(double %104)
%106 = load double*, double** %20
%107 = load i32, i32* %18
%108 = sext i32 %107 to i64
%109 = getelementptr inbounds double, double* %106, i64 %108
store double %105, double* %109
br label %110
110: ; preds = %95
%111 = load i32, i32* %18
%112 = add nsw i32 %111, 1
store i32 %112, i32* %18
br label %91
113: ; preds = %91
store i32 0, i32* %18
br label %114
114: ; preds = %185, %113
%115 = load i32, i32* %18
%116 = load i32, i32* %10
%117 = icmp slt i32 %115, %116
br i1 %117, label %118, label %188
118: ; preds = %114
%119 = load double*, double** %12
%120 = load i32, i32* %18
%121 = sext i32 %120 to i64
%122 = getelementptr inbounds double, double* %119, i64 %121
%123 = load double, double* %122
%124 = load double*, double** %16
%125 = load i32, i32* %17
%126 = load i32, i32* %10
%127 = mul nsw i32 %125, %126
%128 = load i32, i32* %18
%129 = add nsw i32 %127, %128
%130 = sext i32 %129 to i64
%131 = getelementptr inbounds double, double* %124, i64 %130
%132 = load double, double* %131
%133 = call i32 @cos(double %132)
%134 = sub nsw i32 %133, 1
%135 = sitofp i32 %134 to double
%136 = load double, double* %21
%137 = call double @llvm.fmuladd.f64(double %123, double %135, double %136)
store double %137, double* %21
%138 = load double, double* %14
%139 = load double*, double** %13
%140 = load i32, i32* %18
%141 = load i32, i32* %10
%142 = add nsw i32 %141, 1
%143 = mul nsw i32 %140, %142
%144 = sext i32 %143 to i64
%145 = getelementptr inbounds double, double* %139, i64 %144
store double %138, double* %145
store i32 0, i32* %19
br label %146
146: ; preds = %174, %118
%147 = load i32, i32* %19
%148 = load i32, i32* %10
%149 = icmp slt i32 %147, %148
br i1 %149, label %150, label %177
150: ; preds = %146
%151 = load double*, double** %20
%152 = load i32, i32* %18
%153 = sext i32 %152 to i64
%154 = getelementptr inbounds double, double* %151, i64 %153
%155 = load double, double* %154
%156 = fmul double 5.000000e-01, %155
%157 = load double*, double** %20
%158 = load i32, i32* %19
%159 = sext i32 %158 to i64
%160 = getelementptr inbounds double, double* %157, i64 %159
%161 = load double, double* %160
%162 = fmul double %156, %161
%163 = load double*, double** %13
%164 = load i32, i32* %18
%165 = load i32, i32* %10
%166 = mul nsw i32 %164, %165
%167 = load i32, i32* %19
%168 = add nsw i32 %166, %167
%169 = sext i32 %168 to i64
%170 = getelementptr inbounds double, double* %163, i64 %169
%171 = load double, double* %170
%172 = load double, double* %21
%173 = call double @llvm.fmuladd.f64(double %162, double %171, double %172)
store double %173, double* %21
br label %174
174: ; preds = %150
%175 = load i32, i32* %19
%176 = add nsw i32 %175, 1
store i32 %176, i32* %19
br label %146
177: ; preds = %146
%178 = load double*, double** %13
%179 = load i32, i32* %18
%180 = load i32, i32* %10
%181 = add nsw i32 %180, 1
%182 = mul nsw i32 %179, %181
%183 = sext i32 %182 to i64
%184 = getelementptr inbounds double, double* %178, i64 %183
store double 0.000000e+00, double* %184
br label %185
185: ; preds = %177
%186 = load i32, i32* %18
%187 = add nsw i32 %186, 1
store i32 %187, i32* %18
br label %114
188: ; preds = %114
%189 = load i32*, i32** %15
%190 = call double @xorshift4096_r(i32* %189)
%191 = fmul double %190, 1.000000e+00
%192 = load i32, i32* @UINT64_MAX
%193 = sitofp i32 %192 to double
%194 = fdiv double %191, %193
%195 = load double, double* %21
%196 = call double @exp(double %195)
%197 = fcmp ole double %194, %196
br i1 %197, label %198, label %225
198: ; preds = %188
store i32 0, i32* %18
br label %199
199: ; preds = %219, %198
%200 = load i32, i32* %18
%201 = load i32, i32* %10
%202 = icmp slt i32 %200, %201
br i1 %202, label %203, label %222
203: ; preds = %199
%204 = load double*, double** %11
%205 = load i32, i32* %18
%206 = sext i32 %205 to i64
%207 = getelementptr inbounds double, double* %204, i64 %206
%208 = load double, double* %207
%209 = load double*, double** %16
%210 = load i32, i32* %17
%211 = load i32, i32* %10
%212 = mul nsw i32 %210, %211
%213 = load i32, i32* %18
%214 = add nsw i32 %212, %213
%215 = sext i32 %214 to i64
%216 = getelementptr inbounds double, double* %209, i64 %215
%217 = load double, double* %216
%218 = fadd double %217, %208
store double %218, double* %216
br label %219
219: ; preds = %203
%220 = load i32, i32* %18
%221 = add nsw i32 %220, 1
store i32 %221, i32* %18
br label %199
222: ; preds = %199
%223 = load i32, i32* %17
%224 = add nsw i32 %223, 1
store i32 %224, i32* %17
br label %225
225: ; preds = %222, %188
br label %27
226: ; preds = %27
%227 = load double*, double** %20
%228 = call i32 @free(double* %227)
ret i32 0
}

LLVM IR (-O2):
@UINT64_MAX = global i32 0
@M_PI = global double 0.000000e+00
define i32 @mvvm_sampler_safe_rejection(i32 %0, i32 %1, double* nocapture %2, double* nocapture %3, double* nocapture %4, double %5, i32* %6, double* %7) {
%9 = shl i32 %1, 3
%10 = tail call double* @malloc(i32 %9)
%11 = icmp sgt i32 %0, 0
br i1 %11, label %12, label %284
12: ; preds = %8
%13 = fmul double %5, 2.500000e-01
%14 = icmp sgt i32 %1, 0
%15 = add nsw i32 %1, 1
%16 = sext i32 %15 to i64
%17 = sext i32 %1 to i64
%18 = zext i32 %1 to i64
%19 = zext i32 %1 to i64
%20 = zext i32 %1 to i64
%21 = getelementptr double, double* %7, i64 %18
%22 = getelementptr double, double* %2, i64 %18
%23 = add nsw i64 %18, -1
%24 = and i64 %18, 4294967292
%25 = add nsw i64 %24, -4
%26 = lshr exact i64 %25, 2
%27 = add nuw nsw i64 %26, 1
%28 = and i64 %18, 3
%29 = icmp ult i64 %23, 3
%30 = and i64 %18, 4294967292
%31 = icmp eq i64 %28, 0
%32 = and i64 %18, 1
%33 = icmp eq i64 %23, 0
%34 = and i64 %18, 4294967294
%35 = icmp eq i64 %32, 0
%36 = icmp ult i32 %1, 4
%37 = and i64 %18, 4294967292
%38 = and i64 %27, 1
%39 = icmp eq i64 %25, 0
%40 = and i64 %27, 9223372036854775806
%41 = icmp eq i64 %38, 0
%42 = icmp eq i64 %37, %18
%43 = and i64 %18, 1
%44 = icmp eq i64 %43, 0
%45 = sub nsw i64 0, %18
br label %46
46: ; preds = %12, %281
%47 = phi i32 [ 0, %12 ], [ %282, %281 ]
%48 = mul nsw i32 %47, %1
%49 = sext i32 %48 to i64
%50 = getelementptr inbounds double, double* %7, i64 %49
%51 = tail call i32 @rvm_r(double* %50, i32 %1, i32 0, double %13, i32* %6)
br i1 %14, label %54, label %169
52: ; preds = %54
br i1 %14, label %53, label %169
53: ; preds = %52
br i1 %29, label %70, label %84
54: ; preds = %46, %54
%55 = phi i64 [ %68, %54 ], [ 0, %46 ]
%56 = tail call double @xorshift4096_r(i32* %6)
%57 = load i32, i32* @UINT64_MAX
%58 = sdiv i32 %57, 2
%59 = sitofp i32 %58 to double
%60 = fcmp ogt double %56, %59
%61 = add nsw i64 %55, %49
%62 = getelementptr inbounds double, double* %7, i64 %61
%63 = load double, double* %62
%64 = fmul double %63, 5.000000e-01
%65 = load double, double* @M_PI
%66 = select i1 %60, double %65, double -0.000000e+00
%67 = fadd double %64, %66
store double %67, double* %62
%68 = add nuw nsw i64 %55, 1
%69 = icmp eq i64 %68, %18
br i1 %69, label %52, label %54
70: ; preds = %84, %53
%71 = phi i64 [ 0, %53 ], [ %110, %84 ]
br i1 %31, label %83, label %72
72: ; preds = %70, %72
%73 = phi i64 [ %80, %72 ], [ %71, %70 ]
%74 = phi i64 [ %81, %72 ], [ 0, %70 ]
%75 = add nsw i64 %73, %49
%76 = getelementptr inbounds double, double* %7, i64 %75
%77 = load double, double* %76
%78 = tail call double @sin(double %77)
%79 = getelementptr inbounds double, double* %10, i64 %73
store double %78, double* %79
%80 = add nuw nsw i64 %73, 1
%81 = add i64 %74, 1
%82 = icmp eq i64 %81, %28
br i1 %82, label %83, label %72
83: ; preds = %72, %70
br i1 %14, label %113, label %169
84: ; preds = %53, %84
%85 = phi i64 [ %110, %84 ], [ 0, %53 ]
%86 = phi i64 [ %111, %84 ], [ 0, %53 ]
%87 = add nsw i64 %85, %49
%88 = getelementptr inbounds double, double* %7, i64 %87
%89 = load double, double* %88
%90 = tail call double @sin(double %89)
%91 = getelementptr inbounds double, double* %10, i64 %85
store double %90, double* %91
%92 = or i64 %85, 1
%93 = add nsw i64 %92, %49
%94 = getelementptr inbounds double, double* %7, i64 %93
%95 = load double, double* %94
%96 = tail call double @sin(double %95)
%97 = getelementptr inbounds double, double* %10, i64 %92
store double %96, double* %97
%98 = or i64 %85, 2
%99 = add nsw i64 %98, %49
%100 = getelementptr inbounds double, double* %7, i64 %99
%101 = load double, double* %100
%102 = tail call double @sin(double %101)
%103 = getelementptr inbounds double, double* %10, i64 %98
store double %102, double* %103
%104 = or i64 %85, 3
%105 = add nsw i64 %104, %49
%106 = getelementptr inbounds double, double* %7, i64 %105
%107 = load double, double* %106
%108 = tail call double @sin(double %107)
%109 = getelementptr inbounds double, double* %10, i64 %104
store double %108, double* %109
%110 = add nuw nsw i64 %85, 4
%111 = add i64 %86, 4
%112 = icmp eq i64 %111, %30
br i1 %112, label %70, label %84
113: ; preds = %83, %165
%114 = phi i64 [ %167, %165 ], [ 0, %83 ]
%115 = phi double [ %166, %165 ], [ 0.000000e+00, %83 ]
%116 = getelementptr inbounds double, double* %3, i64 %114
%117 = load double, double* %116
%118 = add nsw i64 %114, %49
%119 = getelementptr inbounds double, double* %7, i64 %118
%120 = load double, double* %119
%121 = tail call i32 @cos(double %120)
%122 = mul nsw i64 %114, %16
%123 = getelementptr inbounds double, double* %4, i64 %122
store double %5, double* %123
%124 = add nsw i32 %121, -1
%125 = sitofp i32 %124 to double
%126 = tail call double @llvm.fmuladd.f64(double %117, double %125, double %115)
%127 = getelementptr inbounds double, double* %10, i64 %114
%128 = load double, double* %127
%129 = fmul double %128, 5.000000e-01
%130 = mul nsw i64 %114, %17
br i1 %33, label %153, label %131
131: ; preds = %113, %131
%132 = phi i64 [ %150, %131 ], [ 0, %113 ]
%133 = phi double [ %149, %131 ], [ %126, %113 ]
%134 = phi i64 [ %151, %131 ], [ 0, %113 ]
%135 = getelementptr inbounds double, double* %10, i64 %132
%136 = load double, double* %135
%137 = fmul double %129, %136
%138 = add nsw i64 %132, %130
%139 = getelementptr inbounds double, double* %4, i64 %138
%140 = load double, double* %139
%141 = tail call double @llvm.fmuladd.f64(double %137, double %140, double %133)
%142 = or i64 %132, 1
%143 = getelementptr inbounds double, double* %10, i64 %142
%144 = load double, double* %143
%145 = fmul double %129, %144
%146 = add nsw i64 %142, %130
%147 = getelementptr inbounds double, double* %4, i64 %146
%148 = load double, double* %147
%149 = tail call double @llvm.fmuladd.f64(double %145, double %148, double %141)
%150 = add nuw nsw i64 %132, 2
%151 = add i64 %134, 2
%152 = icmp eq i64 %151, %34
br i1 %152, label %153, label %131
153: ; preds = %131, %113
%154 = phi double [ undef, %113 ], [ %149, %131 ]
%155 = phi i64 [ 0, %113 ], [ %150, %131 ]
%156 = phi double [ %126, %113 ], [ %149, %131 ]
br i1 %35, label %165, label %157
157: ; preds = %153
%158 = getelementptr inbounds double, double* %10, i64 %155
%159 = load double, double* %158
%160 = fmul double %129, %159
%161 = add nsw i64 %155, %130
%162 = getelementptr inbounds double, double* %4, i64 %161
%163 = load double, double* %162
%164 = tail call double @llvm.fmuladd.f64(double %160, double %163, double %156)
br label %165
165: ; preds = %153, %157
%166 = phi double [ %154, %153 ], [ %164, %157 ]
store double 0.000000e+00, double* %123
%167 = add nuw nsw i64 %114, 1
%168 = icmp eq i64 %167, %19
br i1 %168, label %169, label %113
169: ; preds = %165, %46, %52, %83
%170 = phi double [ 0.000000e+00, %83 ], [ 0.000000e+00, %52 ], [ 0.000000e+00, %46 ], [ %166, %165 ]
%171 = tail call double @xorshift4096_r(i32* %6)
%172 = load i32, i32* @UINT64_MAX
%173 = sitofp i32 %172 to double
%174 = fdiv double %171, %173
%175 = tail call double @exp(double %170)
%176 = fcmp ugt double %174, %175
br i1 %176, label %281, label %177
177: ; preds = %169
br i1 %14, label %178, label %279
178: ; preds = %177
br i1 %36, label %248, label %179
179: ; preds = %178
%180 = getelementptr double, double* %7, i64 %49
%181 = getelementptr double, double* %21, i64 %49
%182 = icmp ult double* %180, %22
%183 = icmp ugt double* %181, %2
%184 = and i1 %182, %183
br i1 %184, label %248, label %185
185: ; preds = %179
br i1 %39, label %227, label %186
186: ; preds = %185, %186
%187 = phi i64 [ %224, %186 ], [ 0, %185 ]
%188 = phi i64 [ %225, %186 ], [ 0, %185 ]
%189 = getelementptr inbounds double, double* %2, i64 %187
%190 = bitcast double* %189 to <2 x double>*
%191 = load <2 x double>, <2 x double>* %190
%192 = getelementptr inbounds double, double* %189, i64 2
%193 = bitcast double* %192 to <2 x double>*
%194 = load <2 x double>, <2 x double>* %193
%195 = add nsw i64 %187, %49
%196 = getelementptr inbounds double, double* %7, i64 %195
%197 = bitcast double* %196 to <2 x double>*
%198 = load <2 x double>, <2 x double>* %197
%199 = getelementptr inbounds double, double* %196, i64 2
%200 = bitcast double* %199 to <2 x double>*
%201 = load <2 x double>, <2 x double>* %200
%202 = fadd <2 x double> %191, %198
%203 = fadd <2 x double> %194, %201
%204 = bitcast double* %196 to <2 x double>*
store <2 x double> %202, <2 x double>* %204
%205 = bitcast double* %199 to <2 x double>*
store <2 x double> %203, <2 x double>* %205
%206 = or i64 %187, 4
%207 = getelementptr inbounds double, double* %2, i64 %206
%208 = bitcast double* %207 to <2 x double>*
%209 = load <2 x double>, <2 x double>* %208
%210 = getelementptr inbounds double, double* %207, i64 2
%211 = bitcast double* %210 to <2 x double>*
%212 = load <2 x double>, <2 x double>* %211
%213 = add nsw i64 %206, %49
%214 = getelementptr inbounds double, double* %7, i64 %213
%215 = bitcast double* %214 to <2 x double>*
%216 = load <2 x double>, <2 x double>* %215
%217 = getelementptr inbounds double, double* %214, i64 2
%218 = bitcast double* %217 to <2 x double>*
%219 = load <2 x double>, <2 x double>* %218
%220 = fadd <2 x double> %209, %216
%221 = fadd <2 x double> %212, %219
%222 = bitcast double* %214 to <2 x double>*
store <2 x double> %220, <2 x double>* %222
%223 = bitcast double* %217 to <2 x double>*
store <2 x double> %221, <2 x double>* %223
%224 = add nuw i64 %187, 8
%225 = add i64 %188, 2
%226 = icmp eq i64 %225, %40
br i1 %226, label %227, label %186
227: ; preds = %186, %185
%228 = phi i64 [ 0, %185 ], [ %224, %186 ]
br i1 %41, label %247, label %229
229: ; preds = %227
%230 = getelementptr inbounds double, double* %2, i64 %228
%231 = bitcast double* %230 to <2 x double>*
%232 = load <2 x double>, <2 x double>* %231
%233 = getelementptr inbounds double, double* %230, i64 2
%234 = bitcast double* %233 to <2 x double>*
%235 = load <2 x double>, <2 x double>* %234
%236 = add nsw i64 %228, %49
%237 = getelementptr inbounds double, double* %7, i64 %236
%238 = bitcast double* %237 to <2 x double>*
%239 = load <2 x double>, <2 x double>* %238
%240 = getelementptr inbounds double, double* %237, i64 2
%241 = bitcast double* %240 to <2 x double>*
%242 = load <2 x double>, <2 x double>* %241
%243 = fadd <2 x double> %232, %239
%244 = fadd <2 x double> %235, %242
%245 = bitcast double* %237 to <2 x double>*
store <2 x double> %243, <2 x double>* %245
%246 = bitcast double* %240 to <2 x double>*
store <2 x double> %244, <2 x double>* %246
br label %247
247: ; preds = %227, %229
br i1 %42, label %279, label %248
248: ; preds = %179, %178, %247
%249 = phi i64 [ 0, %179 ], [ 0, %178 ], [ %37, %247 ]
%250 = xor i64 %249, -1
br i1 %44, label %259, label %251
251: ; preds = %248
%252 = getelementptr inbounds double, double* %2, i64 %249
%253 = load double, double* %252
%254 = add nsw i64 %249, %49
%255 = getelementptr inbounds double, double* %7, i64 %254
%256 = load double, double* %255
%257 = fadd double %253, %256
store double %257, double* %255
%258 = or i64 %249, 1
br label %259
259: ; preds = %251, %248
%260 = phi i64 [ %249, %248 ], [ %258, %251 ]
%261 = icmp eq i64 %250, %45
br i1 %261, label %279, label %262
262: ; preds = %259, %262
%263 = phi i64 [ %277, %262 ], [ %260, %259 ]
%264 = getelementptr inbounds double, double* %2, i64 %263
%265 = load double, double* %264
%266 = add nsw i64 %263, %49
%267 = getelementptr inbounds double, double* %7, i64 %266
%268 = load double, double* %267
%269 = fadd double %265, %268
store double %269, double* %267
%270 = add nuw nsw i64 %263, 1
%271 = getelementptr inbounds double, double* %2, i64 %270
%272 = load double, double* %271
%273 = add nsw i64 %270, %49
%274 = getelementptr inbounds double, double* %7, i64 %273
%275 = load double, double* %274
%276 = fadd double %272, %275
store double %276, double* %274
%277 = add nuw nsw i64 %263, 2
%278 = icmp eq i64 %277, %20
br i1 %278, label %279, label %262
279: ; preds = %259, %262, %247, %177
%280 = add nsw i32 %47, 1
br label %281
281: ; preds = %279, %169
%282 = phi i32 [ %280, %279 ], [ %47, %169 ]
%283 = icmp slt i32 %282, %0
br i1 %283, label %46, label %284
284: ; preds = %281, %8
%285 = tail call i32 @free(double* %10)
ret i32 0
}