user: Converte this assembly snippet into its equivalent C code:

```asm
<interpSP6_b>:
  endbr64
  push   %r15
  movd   %xmm0,%r15d
  push   %r14
  mov    %edx,%r14d
  push   %r13
  push   %r12
  mov    %rdi,%r12
  push   %rbp
  mov    %rcx,%rbp
  push   %rbx
  mov    %esi,%ebx
  sub    $0x78,%rsp
  movss  %xmm1,0xc(%rsp)
  mov    %fs:0x28,%rax
  mov    %rax,0x68(%rsp)
  xor    %eax,%eax
  call   <ceilf@plt>
  movss  0xc(%rsp),%xmm0
  lea    -0x3(%rax),%r13d
  xor    %eax,%eax
  test   %r13d,%r13d
  cmovs  %eax,%r13d
  lea    -0x6(%rbx),%eax
  lea    0x6(%r13),%edx
  cmp    %ebx,%edx
  cmovge %eax,%r13d
  call   <ceilf@plt>
  pxor   %xmm0,%xmm0
  pxor   %xmm1,%xmm1
  movslq %ebx,%rsi
  sub    $0x3,%eax
  mov    $0x0,%edx
  movss  0xc(%rsp),%xmm3
  movsd  D63(%rip),%xmm9
  cmovs  %edx,%eax
  lea    -0x6(%r14),%edx
  movsd  D136(%rip),%xmm2
  movsd  D130(%rip),%xmm8
  movss  D102(%rip),%xmm5
  movsd  D162(%rip),%xmm6
  pxor   %xmm7,%xmm7
  pxor   %xmm15,%xmm15
  lea    0x6(%rax),%ecx
  lea    0x50(%rsp),%r11
  movsd  D35(%rip),%xmm4
  movsd  D117(%rip),%xmm11
  cmp    %r14d,%ecx
  lea    0x68(%rsp),%rdi
  movsd  D50(%rip),%xmm10
  movsd  D52(%rip),%xmm13
  cmovge %edx,%eax
  lea    0x10(%rsp),%r10
  xor    %r8d,%r8d
  movsd  D8(%rip),%xmm12
  movq   $0x0,0x20(%rsp)
  cvtsi2ss %eax,%xmm0
  imul   %ebx,%eax
  subss  %xmm0,%xmm3
  cltq
  cvtss2sd %xmm3,%xmm1
  subsd  %xmm9,%xmm1
  subss  %xmm5,%xmm3
  movapd %xmm1,%xmm0
  mulsd  %xmm2,%xmm0
  subsd  %xmm8,%xmm0
  mulsd  %xmm1,%xmm0
  addsd  D57(%rip),%xmm0
  mulsd  %xmm1,%xmm0
  pxor   %xmm1,%xmm1
  cvtss2sd %xmm3,%xmm1
  subsd  %xmm6,%xmm1
  subss  %xmm5,%xmm3
  cvtss2sd %xmm3,%xmm15
  movapd %xmm15,%xmm14
  cvtsd2ss %xmm0,%xmm7
  movapd %xmm1,%xmm0
  mulsd  %xmm4,%xmm0
  addsd  %xmm11,%xmm0
  mulsd  %xmm1,%xmm0
  subsd  %xmm10,%xmm0
  mulsd  %xmm1,%xmm0
  movaps %xmm5,%xmm1
  subss  %xmm3,%xmm1
  cvtsd2ss %xmm0,%xmm0
  movss  %xmm0,0x54(%rsp)
  movsd  D90(%rip),%xmm0
  mulsd  %xmm0,%xmm14
  subsd  %xmm13,%xmm14
  mulsd  %xmm15,%xmm14
  addsd  %xmm12,%xmm14
  mulsd  %xmm15,%xmm14
  pxor   %xmm15,%xmm15
  addsd  %xmm6,%xmm14
  cvtsd2ss %xmm14,%xmm14
  movss  %xmm14,0x58(%rsp)
  pxor   %xmm14,%xmm14
  cvtss2sd %xmm1,%xmm14
  movapd %xmm14,%xmm3
  addss  %xmm5,%xmm1
  mulsd  %xmm0,%xmm3
  subsd  %xmm13,%xmm3
  mulsd  %xmm14,%xmm3
  addsd  %xmm12,%xmm3
  mulsd  %xmm14,%xmm3
  pxor   %xmm14,%xmm14
  cvtss2sd %xmm1,%xmm14
  subsd  %xmm6,%xmm14
  addss  %xmm5,%xmm1
  cvtss2sd %xmm1,%xmm1
  subsd  %xmm9,%xmm1
  addsd  %xmm6,%xmm3
  cvtsd2ss %xmm3,%xmm3
  movss  %xmm3,0x5c(%rsp)
  movapd %xmm14,%xmm3
  mulsd  %xmm4,%xmm3
  addsd  %xmm11,%xmm3
  mulsd  %xmm14,%xmm3
  subsd  %xmm10,%xmm3
  mulsd  %xmm14,%xmm3
  pxor   %xmm14,%xmm14
  cvtsd2ss %xmm3,%xmm3
  movss  %xmm3,0x60(%rsp)
  movapd %xmm1,%xmm3
  mulsd  %xmm2,%xmm3
  subsd  %xmm8,%xmm3
  mulsd  %xmm1,%xmm3
  addsd  D57(%rip),%xmm3
  mulsd  %xmm1,%xmm3
  movd   %r15d,%xmm1
  cvtsd2ss %xmm3,%xmm3
  movss  %xmm3,0x64(%rsp)
  pxor   %xmm3,%xmm3
  cvtsi2ss %r13d,%xmm3
  movslq %r13d,%r13
  add    %r13,%r12
  add    %rax,%r12
  subss  %xmm3,%xmm1
  cvtss2sd %xmm1,%xmm14
  subsd  %xmm9,%xmm14
  subss  %xmm5,%xmm1
  movapd %xmm14,%xmm3
  cvtss2sd %xmm1,%xmm15
  subsd  %xmm6,%xmm15
  subss  %xmm5,%xmm1
  mulsd  %xmm2,%xmm3
  subsd  %xmm8,%xmm3
  mulsd  %xmm14,%xmm3
  addsd  D57(%rip),%xmm3
  mulsd  %xmm14,%xmm3
  movapd %xmm15,%xmm14
  mulsd  %xmm4,%xmm14
  cvtsd2ss %xmm3,%xmm3
  addsd  %xmm11,%xmm14
  mulsd  %xmm15,%xmm14
  subsd  %xmm10,%xmm14
  mulsd  %xmm15,%xmm14
  pxor   %xmm15,%xmm15
  cvtss2sd %xmm1,%xmm15
  cvtsd2ss %xmm14,%xmm14
  movss  %xmm14,0x34(%rsp)
  movapd %xmm15,%xmm14
  mulsd  %xmm0,%xmm14
  subsd  %xmm13,%xmm14
  mulsd  %xmm15,%xmm14
  addsd  %xmm12,%xmm14
  mulsd  %xmm15,%xmm14
  addsd  %xmm6,%xmm14
  cvtsd2ss %xmm14,%xmm14
  movss  %xmm14,0x38(%rsp)
  movaps %xmm5,%xmm14
  subss  %xmm1,%xmm14
  pxor   %xmm1,%xmm1
  cvtss2sd %xmm14,%xmm1
  mulsd  %xmm1,%xmm0
  subsd  %xmm13,%xmm0
  mulsd  %xmm1,%xmm0
  addsd  %xmm12,%xmm0
  mulsd  %xmm1,%xmm0
  pxor   %xmm1,%xmm1
  addsd  %xmm6,%xmm0
  cvtsd2ss %xmm0,%xmm0
  movss  %xmm0,0x3c(%rsp)
  movaps %xmm14,%xmm0
  addss  %xmm5,%xmm0
  cvtss2sd %xmm0,%xmm1
  subsd  %xmm6,%xmm1
  addss  %xmm5,%xmm0
  mulsd  %xmm1,%xmm4
  addsd  %xmm11,%xmm4
  mulsd  %xmm1,%xmm4
  subsd  %xmm10,%xmm4
  mulsd  %xmm1,%xmm4
  pxor   %xmm1,%xmm1
  cvtss2sd %xmm0,%xmm1
  subsd  %xmm9,%xmm1
  movsd  D57(%rip),%xmm0
  mulsd  %xmm1,%xmm2
  cvtsd2ss %xmm4,%xmm4
  movss  %xmm4,0x40(%rsp)
  pxor   %xmm4,%xmm4
  subsd  %xmm8,%xmm2
  mulsd  %xmm1,%xmm2
  addsd  %xmm2,%xmm0
  mulsd  %xmm1,%xmm0
  cvtsd2ss %xmm0,%xmm0
  movss  %xmm0,0x44(%rsp)
  pxor   %xmm0,%xmm0
  movaps %xmm0,0x10(%rsp)
  nopl   0x0(%rax)
L6:
  lea    (%r12,%r8,1),%rdx
  movaps %xmm7,%xmm2
  movaps %xmm4,%xmm1
  mov    %r11,%rax
  jmp    L36
  nopw   0x0(%rax,%rax,1)
L46:
  movss  (%rax),%xmm2
L36:
  movzbl (%rdx),%ecx
  pxor   %xmm0,%xmm0
  add    $0x4,%rax
  add    %rsi,%rdx
  cvtsi2ss %ecx,%xmm0
  mulss  %xmm2,%xmm0
  addss  %xmm0,%xmm1
  cmp    %rax,%rdi
  jne    L46
  movss  %xmm1,(%r10,%r8,4)
  add    $0x1,%r8
  cmp    $0x6,%r8
  jne    L6
  xor    %eax,%eax
  movaps %xmm4,%xmm0
  jmp    L64
  nopw   0x0(%rax,%rax,1)
L39:
  movss  0x30(%rsp,%rax,1),%xmm3
L64:
  mulss  (%r10,%rax,1),%xmm3
  add    $0x4,%rax
  addss  %xmm3,%xmm0
  cmp    $0x18,%rax
  jne    L39
  cvtss2sd %xmm0,%xmm0
  mulsd  D77(%rip),%xmm0
  xor    %eax,%eax
  cvtsd2ss %xmm0,%xmm0
  comiss %xmm0,%xmm4
  ja     L74
  comiss D152(%rip),%xmm0
  mov    $0xffffffff,%eax
  jbe    L33
L74:
  mov    %al,0x0(%rbp)
  mov    0x68(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L40
  add    $0x78,%rsp
  xor    %eax,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L33:
  cvttss2si %xmm0,%eax
  jmp    L74
L40:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: read_data
arguments: data_label: D63
data_type: f64
name: read_data
arguments: data_label: D136
data_type: f64
name: read_data
arguments: data_label: D130
data_type: f64
name: read_data
arguments: data_label: D102
data_type: f32
name: read_data
arguments: data_label: D162
data_type: f32[2]
name: read_data
arguments: data_label: D35
data_type: byte[8]
name: read_data
arguments: data_label: D117
data_type: f64
name: read_data
arguments: data_label: D50
data_type: f64
name: read_data
arguments: data_label: D52
data_type: f64
name: read_data
arguments: data_label: D8
data_type: f64
name: read_data
arguments: data_label: D57
data_type: f64
name: read_data
arguments: data_label: D90
data_type: f64
name: read_data
arguments: data_label: D77
data_type: f64
name: read_data
arguments: data_label: D152
data_type: f32

tool: D63: 2

tool: D136: 0.090909

tool: D130: 0.215311

tool: D102: 1

tool: {"D162": [0.0,1.875]}

tool: {"D35": [0xdc,0x11,0x4e,0x0b,0x5e,0x74,0xe1,0xbf]}

tool: D117: 1.291866

tool: D50: 0.746411

tool: D52: 2.167464

tool: D8: 0.014354

tool: D57: 0.124402

tool: D90: 1.181818

tool: D77: 0.947

tool: D152: 256

assistant: ```c
int interpSP6_b(unsigned char *sl, int w, int h, float x, float y, unsigned char *v) {
  int i, j, m, n;
  float pp, p[6], wx[6], wy[6], xx;
  m = (int)ceilf(x) - 3;
  if (m < 0)
    m = 0;
  if ((m + 7) > w)
    m = w - 6;
  n = (int)ceilf(y) - 3;
  if (n < 0)
    n = 0;
  if ((n + 7) > h)
    n = h - 6;
  xx = y - n;
  wy[0] = ((0.090909 * (xx - 2.0) - 0.215311) * (xx - 2.0) + 0.124402) * (xx - 2.0);
  xx = xx - 1.0;
  wy[1] = ((-0.545455 * (xx - 1.0) + 1.291866) * (xx - 1.0) - 0.746411) * (xx - 1.0);
  xx = xx - 1.0;
  wy[2] = ((1.181818 * xx - 2.167464) * xx + 0.014354) * xx + 1.0;
  xx = 1.0 - xx;
  wy[3] = ((1.181818 * xx - 2.167464) * xx + 0.014354) * xx + 1.0;
  xx = xx + 1.0;
  wy[4] = ((-0.545455 * (xx - 1.0) + 1.291866) * (xx - 1.0) - 0.746411) * (xx - 1.0);
  xx = xx + 1.0;
  wy[5] = ((0.090909 * (xx - 2.0) - 0.215311) * (xx - 2.0) + 0.124402) * (xx - 2.0);
  xx = x - m;
  wx[0] = ((0.090909 * (xx - 2.0) - 0.215311) * (xx - 2.0) + 0.124402) * (xx - 2.0);
  xx = xx - 1.0;
  wx[1] = ((-0.545455 * (xx - 1.0) + 1.291866) * (xx - 1.0) - 0.746411) * (xx - 1.0);
  xx = xx - 1.0;
  wx[2] = ((1.181818 * xx - 2.167464) * xx + 0.014354) * xx + 1.0;
  xx = 1.0 - xx;
  wx[3] = ((1.181818 * xx - 2.167464) * xx + 0.014354) * xx + 1.0;
  xx = xx + 1.0;
  wx[4] = ((-0.545455 * (xx - 1.0) + 1.291866) * (xx - 1.0) - 0.746411) * (xx - 1.0);
  xx = xx + 1.0;
  wx[5] = ((0.090909 * (xx - 2.0) - 0.215311) * (xx - 2.0) + 0.124402) * (xx - 2.0);
  for (i = 0; i < 6; i++) {
    p[i] = 0.0;
    for (j = 0; j < 6; j++) {
      p[i] = p[i] + wy[j] * sl[(j + n) * w + i + m];
    }
  }
  pp = 0.0;
  for (i = 0; i < 6; i++)
    pp = pp + wx[i] * p[i];
  pp = 0.947 * pp;
  if (pp < 0.0)
    pp = 0.0;
  if (pp > 256.0)
    pp = 255.0;
  *v = pp;
  return 0;
}
```