// File: /workspace/github_c_makefile_star2_O3/PoulinV[P]AxiCLASS/build/../source/lensing.c
// Function: lensing_d11
int lensing_d11(
                double * mu,
                int num_mu,
                int lmax,
                double ** d11
                ) {
  double ll;
  int index_mu, l;
  double *fac1, *fac2, *fac3, *fac4;
  ErrorMsg erreur;
  class_alloc(fac1,lmax*sizeof(double),erreur);
  class_alloc(fac2,lmax*sizeof(double),erreur);
  class_alloc(fac3,lmax*sizeof(double),erreur);
  class_alloc(fac4,lmax*sizeof(double),erreur);
  for (l=2;l<lmax;l++) {
    ll = (double) l;
    fac1[l] = sqrt((2*ll+3)/(2*ll+1))*(ll+1)*(2*ll+1)/(ll*(ll+2));
    fac2[l] = 1.0/(ll*(ll+1.));
    fac3[l] = sqrt((2*ll+3)/(2*ll-1))*(ll-1)*(ll+1)/(ll*(ll+2))*(ll+1)/ll;
    fac4[l] = sqrt(2./(2*ll+3));
  }

  class_setup_parallel();
  for (index_mu=0;index_mu<num_mu;index_mu++) {
    class_run_parallel(=,
      int l;
      double declare_list_of_variables_inside_parallel_region(dlm1, dl, dlp1);
      d11[index_mu][0]=0;
      dlm1=(1.0+mu[index_mu])/2. * sqrt(3./2.); /*l=1*/
      d11[index_mu][1]=dlm1 * sqrt(2./3.);
      dl=(1.0+mu[index_mu])/2.*(2.0*mu[index_mu]-1.0) * sqrt(5./2.); /*l=2*/
      d11[index_mu][2] = dl * sqrt(2./5.);
      for (l=2;l<lmax;l++){
        /* sqrt((2l+1)/2)*d11 recurrence, supposed to be more stable */
        dlp1 = fac1[l]*(mu[index_mu]-fac2[l])*dl - fac3[l]*dlm1;
        d11[index_mu][l+1] = dlp1 * fac4[l];
        dlm1 = dl;
        dl = dlp1;
      }
      return _SUCCESS_;
    );
  }
  class_finish_parallel();
  free(fac1); free(fac2); free(fac3); free(fac4);
  return _SUCCESS_;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10d8, %rsp           # imm = 0x10D8
movq %rcx, 0xb8(%rsp)
movl %esi, 0x24(%rsp)
movq %rdi, 0xb0(%rsp)
movl %edx, 0xc(%rsp)
movslq %edx, %r13
shlq $0x3, %r13
movq %r13, %rdi
callq 0x8460
movq %rax, 0x48(%rsp)
testq %rax, %rax
je 0xba0fa
movq %r13, %rdi
callq 0x8460
movq %rax, 0x40(%rsp)
testq %rax, %rax
je 0xba13d
movq %r13, %rdi
callq 0x8460
movq %rax, 0x38(%rsp)
testq %rax, %rax
je 0xba17d
movq %r13, %rdi
callq 0x8460
movq %rax, 0x30(%rsp)
testq %rax, %rax
je 0xba1bd
cmpl $0x3, 0xc(%rsp)
jl 0xb9dfe
movl 0xc(%rsp), %ebx
addq $-0x2, %rbx
xorl %r14d, %r14d
xorpd %xmm2, %xmm2
leal 0x2(%r14), %eax
xorps %xmm3, %xmm3
cvtsi2sd %eax, %xmm3
movapd %xmm3, %xmm5
addsd %xmm3, %xmm5
movapd %xmm5, %xmm4
unpcklpd %xmm5, %xmm4            # xmm4 = xmm4[0],xmm5[0]
addpd 0x68a98(%rip), %xmm4    # 0x122720
movapd %xmm4, %xmm1
unpckhpd %xmm4, %xmm1            # xmm1 = xmm1[1],xmm4[1]
movapd %xmm4, %xmm0
divsd %xmm1, %xmm0
ucomisd %xmm2, %xmm0
movsd %xmm3, 0x28(%rsp)
movapd %xmm4, 0xc0(%rsp)
jb 0xb9cb3
sqrtsd %xmm0, %xmm0
jmp 0xb9cef
movapd %xmm5, 0xa0(%rsp)
movapd %xmm1, 0x90(%rsp)
callq 0x82b0
movapd 0x90(%rsp), %xmm1
movapd 0xa0(%rsp), %xmm5
movapd 0xc0(%rsp), %xmm4
movsd 0x28(%rsp), %xmm3
xorpd %xmm2, %xmm2
leal 0x3(%r14), %eax
xorps %xmm6, %xmm6
cvtsi2sd %eax, %xmm6
mulsd %xmm6, %xmm0
mulsd %xmm1, %xmm0
leal 0x4(%r14), %eax
xorps %xmm7, %xmm7
cvtsi2sd %rax, %xmm7
mulsd %xmm3, %xmm7
divsd %xmm7, %xmm0
movq 0x48(%rsp), %rax
movsd %xmm0, 0x10(%rax,%r14,8)
movapd %xmm3, %xmm0
mulsd %xmm6, %xmm0
movsd 0x3452e(%rip), %xmm1    # 0xee260
divsd %xmm0, %xmm1
movq 0x40(%rsp), %rax
movsd %xmm1, 0x10(%rax,%r14,8)
addsd 0x34a9e(%rip), %xmm5    # 0xee7e8
movapd %xmm4, %xmm0
divsd %xmm5, %xmm0
ucomisd %xmm2, %xmm0
jb 0xb9d5e
sqrtsd %xmm0, %xmm0
jmp 0xb9d9a
movsd %xmm6, 0xa0(%rsp)
movsd %xmm7, 0x90(%rsp)
callq 0x82b0
movsd 0x90(%rsp), %xmm7
movsd 0xa0(%rsp), %xmm6
movapd 0xc0(%rsp), %xmm4
movsd 0x28(%rsp), %xmm3
xorpd %xmm2, %xmm2
leal 0x1(%r14), %eax
xorps %xmm1, %xmm1
cvtsi2sd %eax, %xmm1
mulsd %xmm0, %xmm1
mulsd %xmm6, %xmm1
divsd %xmm7, %xmm1
mulsd %xmm6, %xmm1
divsd %xmm3, %xmm1
movq 0x38(%rsp), %rax
movsd %xmm1, 0x10(%rax,%r14,8)
movsd 0x34f33(%rip), %xmm0    # 0xeed00
divsd %xmm4, %xmm0
ucomisd %xmm2, %xmm0
jb 0xb9ddd
sqrtsd %xmm0, %xmm0
jmp 0xb9de6
callq 0x82b0
xorpd %xmm2, %xmm2
movq 0x30(%rsp), %rax
movsd %xmm0, 0x10(%rax,%r14,8)
incq %r14
cmpq %r14, %rbx
jne 0xb9c65
callq 0x1c686
leaq 0xd0(%rsp), %rdi
movl %eax, %esi
callq 0x1c736
xorpd %xmm0, %xmm0
movapd %xmm0, 0x60(%rsp)
movq $0x0, 0x70(%rsp)
cmpl $0x0, 0x24(%rsp)
jle 0xba0b4
xorl %ebx, %ebx
movabsq $0x100000001, %r15      # imm = 0x100000001
leaq 0x8d3fd(%rip), %rax     # 0x147240
addq $0x10, %rax
movq %rax, 0x28(%rsp)
movl $0x20, %edi
callq 0x83b0
movq %rax, %r14
movq %r15, 0x8(%rax)
movq 0x28(%rsp), %rax
movq %rax, (%r14)
movl $0x78, %edi
callq 0x83b0
movq %rax, %r12
movq %r15, 0x8(%rax)
leaq 0x8e453(%rip), %rax     # 0x1482d0
movq %rax, (%r12)
movq %r12, %r15
addq $0x10, %r15
movq %r15, %rdi
leaq 0x10(%rsp), %rsi
callq 0x1d4aa
movq %r14, %r13
addq $0x10, %r13
leaq 0x8e47d(%rip), %rax     # 0x148320
movq %rax, 0x10(%r12)
movq 0xb8(%rsp), %rax
movq %rax, 0x38(%r12)
movl %ebx, 0x40(%r12)
movq 0xb0(%rsp), %rax
movq %rax, 0x48(%r12)
movl 0xc(%rsp), %eax
movl %eax, 0x50(%r12)
movq 0x48(%rsp), %rax
movq %rax, 0x58(%r12)
movq 0x40(%rsp), %rax
movq %rax, 0x60(%r12)
movq 0x38(%rsp), %rax
movq %rax, 0x68(%r12)
movq 0x30(%rsp), %rax
movq %rax, 0x70(%r12)
movq %r15, 0x10(%r14)
movq %r12, 0x18(%r14)
leaq 0x80(%rsp), %rdi
movq %r13, %rsi
callq 0x1d3e8
movq %r13, 0x50(%rsp)
movq %r14, 0x58(%rsp)
movq 0x8f08f(%rip), %rax     # 0x148fb0
cmpb $0x0, (%rax)
je 0xb9f2c
incl 0x8(%r14)
jmp 0xb9f31
lock
incl 0x8(%r14)
movl $0x1, %r12d
lock
xaddl %r12d, 0xf0(%rsp)
movl 0xd0(%rsp), %ecx
testl %ecx, %ecx
je 0xb9f9c
xorl %r13d, %r13d
leal (%r12,%r13), %eax
xorl %edx, %edx
divl %ecx
movq 0xf8(%rsp), %r15
imulq $0xb0, %rdx, %rbp
leaq (%r15,%rbp), %rdi
addq $0x58, %rdi
movq %rdi, 0x10(%rsp)
callq 0x8080
testl %eax, %eax
sete 0x18(%rsp)
je 0xb9fe7
leaq 0x10(%rsp), %rdi
callq 0x1d204
incl %r13d
movl 0xd0(%rsp), %ecx
cmpl %ecx, %r13d
jb 0xb9f4f
jmp 0xb9f9e
xorl %ecx, %ecx
movl %r12d, %eax
xorl %edx, %edx
divl %ecx
movq 0xf8(%rsp), %r15
imulq $0xb0, %rdx, %r12
leaq (%r15,%r12), %rax
addq $0x58, %rax
movq %rax, 0x10(%rsp)
movb $0x0, 0x18(%rsp)
leaq 0x10(%rsp), %rdi
callq 0x1d294
addq %r12, %r15
movb $0x1, 0x18(%rsp)
movq %r15, %rdi
leaq 0x50(%rsp), %rsi
callq 0xc2b62
jmp 0xb9ff7
addq %rbp, %r15
movq %r15, %rdi
leaq 0x50(%rsp), %rsi
callq 0xc2b62
leaq 0x10(%rsp), %rdi
callq 0x1d204
subq $-0x80, %r15
movq %r15, %rdi
callq 0x81c0
movq 0x58(%rsp), %rdi
testq %rdi, %rdi
je 0xba01c
callq 0x1d330
movabsq $0x100000001, %r15      # imm = 0x100000001
movq %r14, %rdi
callq 0x1d330
leaq 0x60(%rsp), %rdi
leaq 0x80(%rsp), %rsi
callq 0x1dd2e
movq 0x88(%rsp), %rdi
testq %rdi, %rdi
je 0xba052
callq 0x1d330
incl %ebx
cmpl 0x24(%rsp), %ebx
jne 0xb9e4c
movq 0x60(%rsp), %r13
movq 0x68(%rsp), %rbx
cmpq %rbx, %r13
je 0xba090
movq %r13, %rdi
callq 0x1c7ba
testl %eax, %eax
jne 0xba21e
addq $0x10, %r13
cmpq %rbx, %r13
jne 0xba06d
movq 0x60(%rsp), %r13
movq 0x68(%rsp), %rbx
cmpq %r13, %rbx
je 0xba0b4
movq %r13, %r14
movq 0x8(%r14), %rdi
testq %rdi, %rdi
je 0xba0a6
callq 0x1d330
addq $0x10, %r14
cmpq %rbx, %r14
jne 0xba098
movq %r13, 0x68(%rsp)
movq 0x48(%rsp), %rdi
callq 0x8410
movq 0x40(%rsp), %rdi
callq 0x8410
movq 0x38(%rsp), %rdi
callq 0x8410
movq 0x30(%rsp), %rdi
callq 0x8410
xorl %ebx, %ebx
leaq 0x60(%rsp), %rdi
callq 0x1c806
leaq 0xd0(%rsp), %rdi
callq 0x1c84c
jmp 0xba20a
leaq 0x33f03(%rip), %rsi     # 0xee004
leaq 0x6b97c(%rip), %rdx     # 0x125a84
leaq 0xd0(%rsp), %rbx
movq %rbx, %rdi
movl %r13d, %ecx
xorl %eax, %eax
callq 0x30af0
leaq 0x33f10(%rip), %rsi     # 0xee034
leaq 0x6b974(%rip), %rdx     # 0x125a9f
leaq 0x8d0(%rsp), %rdi
movl $0x530, %ecx            # imm = 0x530
jmp 0xba1fb
leaq 0x33ec0(%rip), %rsi     # 0xee004
leaq 0x6b94a(%rip), %rdx     # 0x125a95
leaq 0xd0(%rsp), %rbx
movq %rbx, %rdi
movl %r13d, %ecx
xorl %eax, %eax
callq 0x30af0
leaq 0x33ecd(%rip), %rsi     # 0xee034
leaq 0x6b931(%rip), %rdx     # 0x125a9f
leaq 0x8d0(%rsp), %rdi
movl $0x531, %ecx            # imm = 0x531
jmp 0xba1fb
leaq 0x33e80(%rip), %rsi     # 0xee004
leaq 0x6b90f(%rip), %rdx     # 0x125a9a
leaq 0xd0(%rsp), %rbx
movq %rbx, %rdi
movl %r13d, %ecx
xorl %eax, %eax
callq 0x30af0
leaq 0x33e8d(%rip), %rsi     # 0xee034
leaq 0x6b8f1(%rip), %rdx     # 0x125a9f
leaq 0x8d0(%rsp), %rdi
movl $0x532, %ecx            # imm = 0x532
jmp 0xba1fb
leaq 0x33e40(%rip), %rsi     # 0xee004
leaq 0x6b8e0(%rip), %rdx     # 0x125aab
leaq 0xd0(%rsp), %rbx
movq %rbx, %rdi
movl %r13d, %ecx
xorl %eax, %eax
callq 0x30af0
leaq 0x33e4d(%rip), %rsi     # 0xee034
leaq 0x6b8b1(%rip), %rdx     # 0x125a9f
leaq 0x8d0(%rsp), %rdi
movl $0x533, %ecx            # imm = 0x533
movq %rbx, %r8
xorl %eax, %eax
callq 0x30af0
movl $0x1, %ebx
movl %ebx, %eax
addq $0x10d8, %rsp           # imm = 0x10D8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x1, %ebx
jmp 0xba0de
jmp 0xba231
jmp 0xba273
movq %rax, %rbx
jmp 0xba23e
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x1d204
movq 0x58(%rsp), %rdi
testq %rdi, %rdi
je 0xba24d
callq 0x1d330
movq 0x88(%rsp), %rdi
testq %rdi, %rdi
je 0xba295
callq 0x1d330
jmp 0xba295
movq %rax, %rbx
movq 0x88(%rsp), %rdi
testq %rdi, %rdi
jne 0xba298
jmp 0xba29d
movq %rax, %rbx
jmp 0xba29d
movq %rax, %rbx
jmp 0xba288
movq %rax, %rbx
movq %r12, %rdi
callq 0x8380
movq %r14, %rdi
callq 0x8380
jmp 0xba29d
movq %rax, %rbx
movq %r14, %rdi
callq 0x1d330
leaq 0x60(%rsp), %rdi
callq 0x1c806
leaq 0xd0(%rsp), %rdi
callq 0x1c84c
movq %rbx, %rdi
callq 0x8650