// File: /workspace/github_c_makefile_star2_O1/PoulinV[P]AxiCLASS/build/../source/background.c
// Function: background_tau_of_z
int background_tau_of_z(
                        struct background *pba,
                        double z,
                        double * tau
                        ) {

  /** Summary: */

  /** - define local variables */

  /* necessary for calling array_interpolate(), but never used */
  int last_index;

  /** - check that \f$ z \f$ is in the pre-computed range */
  class_test(z < pba->z_table[pba->bt_size-1],
             pba->error_message,
             "out of range: z=%e < z_min=%e\n",z,pba->z_table[pba->bt_size-1]);

  class_test(z > pba->z_table[0],
             pba->error_message,
             "out of range: z=%e > z_max=%e\n",z,pba->z_table[0]);

  /** - interpolate from pre-computed table with array_interpolate() */
  class_call(array_interpolate_spline(
                                      pba->z_table,
                                      pba->bt_size,
                                      pba->tau_table,
                                      pba->d2tau_dz2_table,
                                      1,
                                      z,
                                      &last_index,
                                      tau,
                                      1,
                                      pba->error_message),
             pba->error_message,
             pba->error_message);
  return _SUCCESS_;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x1000, %rsp           # imm = 0x1000
movq %rsi, %rax
movq %rdi, %rbx
movq 0x458(%rdi), %rdi
movslq 0x440(%rbx), %rsi
movsd -0x8(%rdi,%rsi,8), %xmm1
ucomisd %xmm0, %xmm1
jbe 0x5f03f
movsd -0x8(%rdi,%rsi,8), %xmm1
leaq 0xaef07(%rip), %rsi     # 0x10def7
leaq 0x800(%rsp), %r14
movq %r14, %rdi
movb $0x2, %al
callq 0x30c2c
leaq 0x92079(%rip), %rsi     # 0xf1082
leaq 0xaef06(%rip), %rdx     # 0x10df16
movq %rsp, %r15
movq %r15, %rdi
movq %r14, %rcx
xorl %eax, %eax
callq 0x30c2c
addq $0xd1c, %rbx            # imm = 0xD1C
leaq 0x92006(%rip), %rsi     # 0xf1034
leaq 0xaef02(%rip), %rdx     # 0x10df37
movq %rbx, %rdi
movl $0x11f, %ecx            # imm = 0x11F
jmp 0x5f09d
ucomisd (%rdi), %xmm0
jbe 0x5f0b9
movsd (%rdi), %xmm1
leaq 0xaeefb(%rip), %rsi     # 0x10df4b
leaq 0x800(%rsp), %r14
movq %r14, %rdi
movb $0x2, %al
callq 0x30c2c
leaq 0x92019(%rip), %rsi     # 0xf1082
leaq 0xaeefa(%rip), %rdx     # 0x10df6a
movq %rsp, %r15
movq %r15, %rdi
movq %r14, %rcx
xorl %eax, %eax
callq 0x30c2c
addq $0xd1c, %rbx            # imm = 0xD1C
leaq 0x91fa6(%rip), %rsi     # 0xf1034
leaq 0xaeea2(%rip), %rdx     # 0x10df37
movq %rbx, %rdi
movl $0x123, %ecx            # imm = 0x123
movq %r15, %r8
xorl %eax, %eax
callq 0x30c2c
movl $0x1, %eax
addq $0x1000, %rsp           # imm = 0x1000
popq %rbx
popq %r14
popq %r15
retq
movq 0x450(%rbx), %rdx
movq 0x468(%rbx), %rcx
addq $0xd1c, %rbx            # imm = 0xD1C
subq $0x8, %rsp
leaq 0x8(%rsp), %r9
movl $0x1, %r8d
pushq %rbx
pushq $0x1
pushq %rax
callq 0x17ee6
addq $0x20, %rsp
movl %eax, %ecx
xorl %eax, %eax
cmpl $0x1, %ecx
jne 0x5f0ac
leaq 0x922f6(%rip), %rsi     # 0xf13f0
leaq 0xaee7d(%rip), %rdx     # 0x10df7e
leaq 0x800(%rsp), %r14
movq %r14, %rdi
movq %rbx, %rcx
xorl %eax, %eax
callq 0x30c2c
leaq 0x91f17(%rip), %rsi     # 0xf1034
leaq 0xaee13(%rip), %rdx     # 0x10df37
movq %rbx, %rdi
movl $0x132, %ecx            # imm = 0x132
movq %r14, %r8
jmp 0x5f0a0