user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<bilinear_interpolate>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x90,%rsp
  movsd  %xmm0,-0x78(%rbp)
  movsd  %xmm1,-0x80(%rbp)
  mov    %edi,-0x84(%rbp)
  mov    %esi,-0x88(%rbp)
  mov    %rdx,-0x90(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  mov    -0x78(%rbp),%rax
  movq   %rax,%xmm0
  call   <floor@plt>
  mov    %eax,-0x70(%rbp)
  mov    -0x80(%rbp),%rax
  movq   %rax,%xmm0
  call   <floor@plt>
  mov    %eax,-0x6c(%rbp)
  pxor   %xmm0,%xmm0
  cvtsi2sdl -0x70(%rbp),%xmm0
  movsd  %xmm0,-0x60(%rbp)
  movsd  -0x60(%rbp),%xmm1
  movsd  D13(%rip),%xmm0
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x58(%rbp)
  pxor   %xmm0,%xmm0
  cvtsi2sdl -0x6c(%rbp),%xmm0
  movsd  %xmm0,-0x50(%rbp)
  movsd  -0x50(%rbp),%xmm1
  movsd  D13(%rip),%xmm0
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x48(%rbp)
  mov    -0x70(%rbp),%eax
  cmp    -0x84(%rbp),%eax
  je     L56
  cmpl   $0x0,-0x70(%rbp)
  je     L56
  mov    -0x6c(%rbp),%eax
  cmp    -0x88(%rbp),%eax
  je     L56
  cmpl   $0x0,-0x6c(%rbp)
  jne    L0
L56:
  lea    D21(%rip),%rax
  mov    %rax,%rdi
  call   <printf@plt>
  mov    -0x6c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x90(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x70(%rbp),%eax
  cltq
  shl    $0x3,%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x68(%rbp)
  jmp    L7
L0:
  mov    -0x6c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x90(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x70(%rbp),%eax
  cltq
  shl    $0x3,%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x30(%rbp)
  mov    -0x6c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x90(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x70(%rbp),%eax
  cltq
  add    $0x1,%rax
  shl    $0x3,%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x20(%rbp)
  mov    -0x6c(%rbp),%eax
  cltq
  add    $0x1,%rax
  lea    0x0(,%rax,8),%rdx
  mov    -0x90(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x70(%rbp),%eax
  cltq
  shl    $0x3,%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x28(%rbp)
  mov    -0x6c(%rbp),%eax
  cltq
  add    $0x1,%rax
  lea    0x0(,%rax,8),%rdx
  mov    -0x90(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x70(%rbp),%eax
  cltq
  add    $0x1,%rax
  shl    $0x3,%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x18(%rbp)
  movsd  -0x58(%rbp),%xmm0
  subsd  -0x78(%rbp),%xmm0
  movsd  -0x58(%rbp),%xmm1
  movapd %xmm1,%xmm2
  subsd  -0x60(%rbp),%xmm2
  movapd %xmm0,%xmm1
  divsd  %xmm2,%xmm1
  movsd  -0x30(%rbp),%xmm0
  movapd %xmm1,%xmm2
  mulsd  %xmm0,%xmm2
  movsd  -0x78(%rbp),%xmm0
  subsd  -0x60(%rbp),%xmm0
  movsd  -0x58(%rbp),%xmm1
  movapd %xmm1,%xmm3
  subsd  -0x60(%rbp),%xmm3
  movapd %xmm0,%xmm1
  divsd  %xmm3,%xmm1
  movsd  -0x20(%rbp),%xmm0
  mulsd  %xmm1,%xmm0
  addsd  %xmm2,%xmm0
  movsd  %xmm0,-0x40(%rbp)
  movsd  -0x58(%rbp),%xmm0
  subsd  -0x78(%rbp),%xmm0
  movsd  -0x58(%rbp),%xmm1
  movapd %xmm1,%xmm2
  subsd  -0x60(%rbp),%xmm2
  movapd %xmm0,%xmm1
  divsd  %xmm2,%xmm1
  movsd  -0x28(%rbp),%xmm0
  movapd %xmm1,%xmm2
  mulsd  %xmm0,%xmm2
  movsd  -0x78(%rbp),%xmm0
  subsd  -0x60(%rbp),%xmm0
  movsd  -0x58(%rbp),%xmm1
  movapd %xmm1,%xmm3
  subsd  -0x60(%rbp),%xmm3
  movapd %xmm0,%xmm1
  divsd  %xmm3,%xmm1
  movsd  -0x18(%rbp),%xmm0
  mulsd  %xmm1,%xmm0
  addsd  %xmm2,%xmm0
  movsd  %xmm0,-0x38(%rbp)
  movsd  -0x48(%rbp),%xmm0
  subsd  -0x80(%rbp),%xmm0
  movsd  -0x48(%rbp),%xmm1
  movapd %xmm1,%xmm2
  subsd  -0x50(%rbp),%xmm2
  movapd %xmm0,%xmm1
  divsd  %xmm2,%xmm1
  movsd  -0x40(%rbp),%xmm0
  movapd %xmm1,%xmm2
  mulsd  %xmm0,%xmm2
  movsd  -0x80(%rbp),%xmm0
  subsd  -0x50(%rbp),%xmm0
  movsd  -0x48(%rbp),%xmm1
  movapd %xmm1,%xmm3
  subsd  -0x50(%rbp),%xmm3
  movapd %xmm0,%xmm1
  divsd  %xmm3,%xmm1
  movsd  -0x38(%rbp),%xmm0
  mulsd  %xmm1,%xmm0
  addsd  %xmm2,%xmm0
  movsd  %xmm0,-0x68(%rbp)
L7:
  movsd  -0x68(%rbp),%xmm0
  movq   %xmm0,%rax
  mov    -0x8(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L6
  call   <__stack_chk_fail@plt>
L6:
  movq   %rax,%xmm0
  leave
  ret
```

tool_calls: name: parse_data
arguments: tag: D13
type_infered: byte[8]
name: parse_data
arguments: tag: D21
type_infered: string

tool: {"D13": [0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x3f]}

tool: D21: Interpolation boundary issues.


assistant: ```c
double bilinear_interpolate(double x, double y, int naxis1, int naxis2, double **image) {
  double f_R[2];
  double f_Q[2][2];
  double x1, x2, y1, y2;
  int xi, yi;
  double new_value;
  xi = (int)floor(x);
  yi = (int)floor(y);
  x1 = (double)xi;
  x2 = x1 + 1;
  y1 = (double)yi;
  y2 = y1 + 1;
  if ((xi == naxis1) || (xi == 0) || (yi == naxis2) || (yi == 0)) {
    printf("Interpolation boundary issues.\n");
    new_value = image[yi][xi];
  } else {
    f_Q[0][0] = image[yi][xi];
    f_Q[1][0] = image[yi][xi + 1];
    f_Q[0][1] = image[yi + 1][xi];
    f_Q[1][1] = image[yi + 1][xi + 1];
    f_R[0] = ((x2 - x) / (x2 - x1)) * f_Q[0][0] + ((x - x1) / (x2 - x1)) * f_Q[1][0];
    f_R[1] = ((x2 - x) / (x2 - x1)) * f_Q[0][1] + ((x - x1) / (x2 - x1)) * f_Q[1][1];
    new_value = ((y2 - y) / (y2 - y1)) * f_R[0] + ((y - y1) / (y2 - y1)) * f_R[1];
  }
  return new_value;
}
```