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

```asm
<spline>:
  endbr64
  movsd  D57(%rip),%xmm8
  mov    %edx,%r9d
  comisd %xmm8,%xmm0
  jbe    L63
  movq   $0x0,(%r8)
  movq   $0x0,(%rcx)
  cmp    $0x2,%r9d
  jle    L33
L79:
  lea    -0x3(%r9),%r10d
  mov    %rdi,%rdx
  mov    $0x1,%eax
  movsd  D13(%rip),%xmm7
  movsd  D80(%rip),%xmm5
  movsd  D20(%rip),%xmm6
  add    $0x2,%r10
  nopl   0x0(%rax,%rax,1)
L59:
  movsd  (%rdx),%xmm3
  movsd  0x8(%rdx),%xmm2
  add    $0x8,%rdx
  movsd  0x8(%rdx),%xmm0
  movsd  -0x8(%rcx,%rax,8),%xmm4
  subsd  %xmm3,%xmm2
  subsd  %xmm3,%xmm0
  divsd  %xmm0,%xmm2
  mulsd  %xmm2,%xmm4
  movapd %xmm2,%xmm0
  subsd  %xmm5,%xmm0
  addsd  %xmm7,%xmm4
  divsd  %xmm4,%xmm0
  movsd  %xmm0,(%rcx,%rax,8)
  movsd  (%rsi,%rax,8),%xmm3
  movsd  (%rdx),%xmm9
  movsd  0x8(%rsi,%rax,8),%xmm0
  movsd  0x8(%rdx),%xmm10
  mulsd  -0x8(%r8,%rax,8),%xmm2
  subsd  %xmm3,%xmm0
  subsd  %xmm9,%xmm10
  subsd  -0x8(%rsi,%rax,8),%xmm3
  subsd  -0x8(%rdx),%xmm9
  divsd  %xmm10,%xmm0
  divsd  %xmm9,%xmm3
  subsd  %xmm3,%xmm0
  movsd  %xmm0,(%r8,%rax,8)
  mulsd  %xmm6,%xmm0
  movsd  0x8(%rdx),%xmm3
  subsd  -0x8(%rdx),%xmm3
  divsd  %xmm3,%xmm0
  subsd  %xmm2,%xmm0
  divsd  %xmm4,%xmm0
  movsd  %xmm0,(%r8,%rax,8)
  add    $0x1,%rax
  cmp    %rax,%r10
  jne    L59
L13:
  movslq %r9d,%rax
  shl    $0x3,%rax
  comisd %xmm8,%xmm1
  jbe    L45
  pxor   %xmm1,%xmm1
  movapd %xmm1,%xmm0
L89:
  movsd  -0x10(%r8,%rax,1),%xmm2
  sub    $0x2,%r9d
  mulsd  %xmm0,%xmm2
  mulsd  -0x10(%rcx,%rax,1),%xmm0
  subsd  %xmm2,%xmm1
  addsd  %xmm5,%xmm0
  divsd  %xmm0,%xmm1
  movsd  %xmm1,-0x8(%rcx,%rax,1)
  movslq %r9d,%rax
  js     L48
  nopw   0x0(%rax,%rax,1)
L25:
  movsd  (%rcx,%rax,8),%xmm0
  mulsd  0x8(%rcx,%rax,8),%xmm0
  addsd  (%r8,%rax,8),%xmm0
  movsd  %xmm0,(%rcx,%rax,8)
  sub    $0x1,%rax
  test   %eax,%eax
  jns    L25
L48:
  ret
  nopw   0x0(%rax,%rax,1)
L45:
  movsd  -0x8(%rdi,%rax,1),%xmm2
  movsd  -0x8(%rsi,%rax,1),%xmm0
  subsd  -0x10(%rdi,%rax,1),%xmm2
  subsd  -0x10(%rsi,%rax,1),%xmm0
  divsd  %xmm2,%xmm0
  subsd  %xmm0,%xmm1
  movsd  D4(%rip),%xmm0
  divsd  %xmm2,%xmm0
  mulsd  %xmm0,%xmm1
  movsd  D1(%rip),%xmm0
  jmp    L89
  nopl   (%rax)
L63:
  mov    D52(%rip),%rax
  mov    %rax,(%rcx)
  movsd  0x8(%rdi),%xmm3
  movsd  0x8(%rsi),%xmm2
  subsd  (%rdi),%xmm3
  subsd  (%rsi),%xmm2
  divsd  %xmm3,%xmm2
  subsd  %xmm0,%xmm2
  movsd  D4(%rip),%xmm0
  divsd  %xmm3,%xmm0
  mulsd  %xmm0,%xmm2
  movsd  %xmm2,(%r8)
  cmp    $0x2,%r9d
  jg     L79
L33:
  movsd  D80(%rip),%xmm5
  jmp    L13
```

tool_calls: name: unpack_data
arguments: label: D57
data_type: f64
name: unpack_data
arguments: label: D13
data_type: f64
name: unpack_data
arguments: label: D80
data_type: f64
name: unpack_data
arguments: label: D20
data_type: f64
name: unpack_data
arguments: label: D4
data_type: f64
name: unpack_data
arguments: label: D1
data_type: f64
name: unpack_data
arguments: label: D52
data_type: f32[2]

tool: D57: 9.9e+29

tool: D13: 2

tool: D80: 1

tool: D20: 6

tool: D4: 3

tool: D1: 0.5

tool: {"D52": [0.0,-1.75]}

assistant: ```c
void spline(double *x, double *y, int n, double yp1, double ypn, double *y2, double *u) {
  int i, k;
  double p, qn, sig, un;
  if (yp1 > 0.99e30) {
    y2[0] = u[0] = 0.0;
  } else {
    y2[0] = -0.5;
    u[0] = (3.0 / (x[1] - x[0])) * ((y[1] - y[0]) / (x[1] - x[0]) - yp1);
  }
  for (i = 1; i <= n - 2; i++) {
    sig = (x[i] - x[i - 1]) / (x[i + 1] - x[i - 1]);
    p = sig * y2[i - 1] + 2.0;
    y2[i] = (sig - 1.0) / p;
    u[i] = (y[i + 1] - y[i]) / (x[i + 1] - x[i]) - (y[i] - y[i - 1]) / (x[i] - x[i - 1]);
    u[i] = (6.0 * u[i] / (x[i + 1] - x[i - 1]) - sig * u[i - 1]) / p;
  }
  if (ypn > 0.99e30) {
    qn = un = 0.0;
  } else {
    qn = 0.5;
    un = (3.0 / (x[n - 1] - x[n - 2])) * (ypn - (y[n - 1] - y[n - 2]) / (x[n - 1] - x[n - 2]));
  }
  y2[n - 1] = (un - qn * u[n - 2]) / (qn * y2[n - 2] + 1.0);
  for (k = n - 2; k >= 0; k--) {
    y2[k] = y2[k] * y2[k + 1] + u[k];
  }
  return;
}
```