user: Please show me the C implementation that matches the assembly code listed below:

```asm
<evaluateGTRGAMMAPROTMULT_VECTOR>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x58,%rsp
  mov    %rdi,0x20(%rsp)
  mov    %rsi,0x48(%rsp)
  mov    %rdx,0x28(%rsp)
  mov    %rcx,0x30(%rsp)
  mov    %r8,%r13
  mov    %r9,0x38(%rsp)
  mov    0xb8(%rsp),%ebx
  pxor   %xmm6,%xmm6
  movsd  %xmm6,0x8(%rsp)
  cmpl   $0x0,0xc0(%rsp)
  jne    L31
  mov    0x98(%rsp),%rax
  movsd  (%rax),%xmm0
  movsd  D24(%rip),%xmm1
  comisd %xmm0,%xmm1
  jbe    L56
  movapd %xmm1,%xmm0
L56:
  call   <log@plt>
  pxor   %xmm7,%xmm7
  cvtsi2sd %eax,%xmm7
  movsd  %xmm7,0x8(%rsp)
L31:
  imul   $0x260,%ebx,%edi
  call   <malloc@plt>
  mov    %rax,0x40(%rsp)
  test   %ebx,%ebx
  jle    L113
  lea    0x260(%rax),%r15
  mov    %ebx,%eax
  mov    %rax,0x18(%rsp)
  mov    $0x0,%r12d
  jmp    L62
L80:
  lea    -0x260(%r15),%rbp
  mov    %r12,%r14
  shl    $0x5,%r14
  add    0x38(%rsp),%r14
  mov    %r12,0x10(%rsp)
L100:
  mov    (%r14),%r12
  mov    $0x0,%ebx
L118:
  movq   %r12,%xmm0
  mulsd  0x0(%r13,%rbx,1),%xmm0
  mulsd  0x8(%rsp),%xmm0
  call   <exp@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x0(%rbp,%rbx,1)
  add    $0x8,%rbx
  cmp    $0x98,%rbx
  jne    L118
  add    $0x98,%rbp
  add    $0x8,%r14
  cmp    %r15,%rbp
  jne    L100
  mov    0x10(%rsp),%r12
  add    $0x1,%r12
  add    $0x260,%r15
  add    $0x98,%r13
  cmp    0x18(%rsp),%r12
  je     L113
L62:
  cmpl   $0x0,0xc0(%rsp)
  je     L80
  mov    0x98(%rsp),%rax
  movsd  (%rax,%r12,8),%xmm0
  movsd  D24(%rip),%xmm3
  movapd %xmm0,%xmm1
  cmpnltsd %xmm3,%xmm1
  andpd  %xmm1,%xmm0
  andnpd %xmm3,%xmm1
  orpd   %xmm1,%xmm0
  call   <log@plt>
  pxor   %xmm5,%xmm5
  cvtsi2sd %eax,%xmm5
  movsd  %xmm5,0x8(%rsp)
  jmp    L80
L113:
  mov    0xb0(%rsp),%eax
  cmp    %eax,0xa8(%rsp)
  jge    L120
  movslq 0xa8(%rsp),%rbx
  sub    $0x1,%eax
  sub    0xa8(%rsp),%eax
  lea    0x1(%rbx,%rax,1),%r13
  mov    D46(%rip),%r14
  mov    0x40(%rsp),%r15
  mov    0x48(%rsp),%rbp
  jmp    L12
L20:
  mulsd  D49(%rip),%xmm0
  call   <log@plt>
  mov    %eax,0x8(%rsp)
  mov    0x20(%rsp),%rdi
  mov    (%rdi,%rbx,4),%r12d
  mov    D20(%rip),%rcx
  movq   %rcx,%xmm0
  call   <log@plt>
  imul   %eax,%r12d
  mov    0x8(%rsp),%eax
  add    %r12d,%eax
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  mov    0x30(%rsp),%rax
  movsd  %xmm0,(%rax,%rbx,8)
  add    $0x1,%rbx
  cmp    %r13,%rbx
  je     L120
L12:
  mov    0x0(%rbp,%rbx,4),%edx
  mov    0xa0(%rsp),%rax
  movsbl (%rax,%rbx,1),%eax
  lea    (%rax,%rax,4),%ecx
  imul   $0x1cc,%edx,%eax
  lea    (%rax,%rcx,4),%eax
  cltq
  mov    0x90(%rsp),%rsi
  lea    (%rsi,%rax,8),%rax
  imul   $0x4c,%edx,%edx
  movslq %edx,%rdx
  lea    (%r15,%rdx,8),%rdx
  mov    (%rax),%r10
  mov    0x8(%rax),%r9
  mov    0x10(%rax),%r8
  mov    0x18(%rax),%rdi
  mov    0x20(%rax),%rsi
  movsd  0x28(%rax),%xmm15
  movsd  0x30(%rax),%xmm14
  movsd  0x38(%rax),%xmm13
  movsd  0x40(%rax),%xmm12
  movsd  0x48(%rax),%xmm11
  movsd  0x50(%rax),%xmm10
  movsd  0x58(%rax),%xmm9
  movsd  0x60(%rax),%xmm8
  movsd  0x68(%rax),%xmm7
  movsd  0x70(%rax),%xmm6
  movsd  0x78(%rax),%xmm5
  movsd  0x80(%rax),%xmm4
  movsd  0x88(%rax),%xmm3
  movsd  0x90(%rax),%xmm2
  mov    0x98(%rax),%r11
  lea    (%rbx,%rbx,4),%rax
  shl    $0x7,%rax
  add    0x28(%rsp),%rax
  lea    0x260(%rdx),%rcx
  movq   %r14,%xmm0
L5:
  movq   %r10,%xmm1
  mulsd  (%rax),%xmm1
  addsd  %xmm1,%xmm0
  movq   %r9,%xmm1
  mulsd  0x8(%rax),%xmm1
  mulsd  (%rdx),%xmm1
  addsd  %xmm1,%xmm0
  movq   %r8,%xmm1
  mulsd  0x10(%rax),%xmm1
  mulsd  0x8(%rdx),%xmm1
  addsd  %xmm0,%xmm1
  movq   %rdi,%xmm0
  mulsd  0x18(%rax),%xmm0
  mulsd  0x10(%rdx),%xmm0
  addsd  %xmm1,%xmm0
  movq   %rsi,%xmm1
  mulsd  0x20(%rax),%xmm1
  mulsd  0x18(%rdx),%xmm1
  addsd  %xmm0,%xmm1
  movapd %xmm15,%xmm0
  mulsd  0x28(%rax),%xmm0
  mulsd  0x20(%rdx),%xmm0
  addsd  %xmm1,%xmm0
  movapd %xmm14,%xmm1
  mulsd  0x30(%rax),%xmm1
  mulsd  0x28(%rdx),%xmm1
  addsd  %xmm0,%xmm1
  movapd %xmm13,%xmm0
  mulsd  0x38(%rax),%xmm0
  mulsd  0x30(%rdx),%xmm0
  addsd  %xmm1,%xmm0
  movapd %xmm12,%xmm1
  mulsd  0x40(%rax),%xmm1
  mulsd  0x38(%rdx),%xmm1
  addsd  %xmm0,%xmm1
  movapd %xmm11,%xmm0
  mulsd  0x48(%rax),%xmm0
  mulsd  0x40(%rdx),%xmm0
  addsd  %xmm1,%xmm0
  movapd %xmm10,%xmm1
  mulsd  0x50(%rax),%xmm1
  mulsd  0x48(%rdx),%xmm1
  addsd  %xmm0,%xmm1
  movapd %xmm9,%xmm0
  mulsd  0x58(%rax),%xmm0
  mulsd  0x50(%rdx),%xmm0
  addsd  %xmm1,%xmm0
  movapd %xmm8,%xmm1
  mulsd  0x60(%rax),%xmm1
  mulsd  0x58(%rdx),%xmm1
  addsd  %xmm0,%xmm1
  movapd %xmm7,%xmm0
  mulsd  0x68(%rax),%xmm0
  mulsd  0x60(%rdx),%xmm0
  addsd  %xmm1,%xmm0
  movapd %xmm6,%xmm1
  mulsd  0x70(%rax),%xmm1
  mulsd  0x68(%rdx),%xmm1
  addsd  %xmm0,%xmm1
  movapd %xmm5,%xmm0
  mulsd  0x78(%rax),%xmm0
  mulsd  0x70(%rdx),%xmm0
  addsd  %xmm1,%xmm0
  movapd %xmm4,%xmm1
  mulsd  0x80(%rax),%xmm1
  mulsd  0x78(%rdx),%xmm1
  addsd  %xmm0,%xmm1
  movapd %xmm3,%xmm0
  mulsd  0x88(%rax),%xmm0
  mulsd  0x80(%rdx),%xmm0
  addsd  %xmm1,%xmm0
  movapd %xmm2,%xmm1
  mulsd  0x90(%rax),%xmm1
  mulsd  0x88(%rdx),%xmm1
  addsd  %xmm0,%xmm1
  add    $0x98,%rdx
  movq   %r11,%xmm0
  mulsd  0x98(%rax),%xmm0
  mulsd  -0x8(%rdx),%xmm0
  addsd  %xmm1,%xmm0
  add    $0xa0,%rax
  cmp    %rdx,%rcx
  jne    L5
  jmp    L20
L120:
  mov    0x40(%rsp),%rdi
  call   <free@plt>
  add    $0x58,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

tool_calls: name: disassemble_data
arguments: data_label: D24
data_type: byte[8]
name: disassemble_data
arguments: data_label: D46
data_type: f64
name: disassemble_data
arguments: data_label: D49
data_type: f64
name: disassemble_data
arguments: data_label: D20
data_type: byte[8]

tool: {"D24": [0x16,0x56,0xe7,0x9e,0xaf,0x03,0xd2,0x3c]}

tool: D46: 0

tool: D49: 0.25

tool: {"D20": [0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x2f]}

assistant: ```c
void evaluateGTRGAMMAPROTMULT_VECTOR(int *ex2, int *modelptr, double *x2, double *v, double *EIGN, double *gammaRates, double *tipVector, double *pz, char *tipX1, int lower, int n, int numberOfModels, int multiBranch) {
  double z, lz = 0.0, term, ki;
  int i, j;
  double *diagptable, *diagptable_start;
  double *left, *right;
  int model;
  if (!multiBranch) {
    z = pz[0];
    if (z < 1.0E-15)
      z = 1.0E-15;
    lz = log(z);
  }
  diagptable = diagptable_start = (double *)malloc(sizeof(double) * 4 * 19 * numberOfModels);
  for (model = 0; model < numberOfModels; model++) {
    if (multiBranch) {
      z = pz[model];
      if (z < 1.0E-15)
        z = 1.0E-15;
      lz = log(z);
    }
    diagptable = &diagptable_start[4 * 19 * model];
    for (i = 0; i < 4; i++) {
      ki = gammaRates[model * 4 + i];
      for (j = 0; j < 19; j++)
        *diagptable++ = exp(EIGN[model * 19 + j] * ki * lz);
    }
  }
  for (i = lower; i < n; i++) {
    model = modelptr[i];
    left = &(tipVector[460 * model + 20 * tipX1[i]]);
    diagptable = &diagptable_start[76 * model];
    term = 0;
    for (j = 0; j < 4; j++) {
      right = &(x2[80 * i + 20 * j]);
      term += left[0] * right[0];
      term += left[1] * right[1] * *diagptable++;
      term += left[2] * right[2] * *diagptable++;
      term += left[3] * right[3] * *diagptable++;
      term += left[4] * right[4] * *diagptable++;
      term += left[5] * right[5] * *diagptable++;
      term += left[6] * right[6] * *diagptable++;
      term += left[7] * right[7] * *diagptable++;
      term += left[8] * right[8] * *diagptable++;
      term += left[9] * right[9] * *diagptable++;
      term += left[10] * right[10] * *diagptable++;
      term += left[11] * right[11] * *diagptable++;
      term += left[12] * right[12] * *diagptable++;
      term += left[13] * right[13] * *diagptable++;
      term += left[14] * right[14] * *diagptable++;
      term += left[15] * right[15] * *diagptable++;
      term += left[16] * right[16] * *diagptable++;
      term += left[17] * right[17] * *diagptable++;
      term += left[18] * right[18] * *diagptable++;
      term += left[19] * right[19] * *diagptable++;
    }
    term = log(0.25 * term) + ex2[i] * log((1.0 / 115792089237316195423570985008687907853269984665640564039457584007913129639936.0));
    v[i] = term;
  }
  free(diagptable_start);
}
```