user: 请从给定的汇编指令推导出C源代码:

```asm
<vec4_slerp_to>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x18,%rsp
  mov    %rdi,%r12
  mov    %rsi,%rbx
  mov    %rdx,%rbp
  movss  %xmm0,0x4(%rsp)
  movss  0xc(%rsi),%xmm0
  mulss  0xc(%rdx),%xmm0
  movss  (%rsi),%xmm1
  mulss  (%rdx),%xmm1
  addss  %xmm1,%xmm0
  movss  0x4(%rsi),%xmm1
  mulss  0x4(%rdx),%xmm1
  addss  %xmm1,%xmm0
  movss  0x8(%rsi),%xmm1
  mulss  0x8(%rdx),%xmm1
  addss  %xmm1,%xmm0
  mov    D16(%rip),%r13d
  pxor   %xmm1,%xmm1
  comiss %xmm0,%xmm1
  ja     L38
  mov    D12(%rip),%r13d
L38:
  movd   %r13d,%xmm7
  mulss  %xmm7,%xmm0
  call   <acosf@plt>
  movss  %xmm0,0x8(%rsp)
  call   <sinf@plt>
  movss  %xmm0,0xc(%rsp)
  movss  0x8(%rsp),%xmm0
  call   <fabs@plt>
  movss  0x4(%rsp),%xmm5
  comiss %xmm5,%xmm0
  jbe    L47
  divss  %xmm0,%xmm5
  movss  %xmm5,0x4(%rsp)
  movss  0xc(%rsp),%xmm0
  call   <fabs@plt>
  comiss D42(%rip),%xmm0
  jbe    L66
  movss  0x4(%rsp),%xmm5
  comiss D77(%rip),%xmm5
  jbe    L66
  movss  D12(%rip),%xmm0
  comiss %xmm5,%xmm0
  jbe    L66
  subss  %xmm5,%xmm0
  mulss  0x8(%rsp),%xmm0
  call   <sinf@plt>
  movaps %xmm0,%xmm6
  divss  0xc(%rsp),%xmm6
  movd   %xmm6,%r14d
  movss  0x8(%rsp),%xmm0
  mulss  0x4(%rsp),%xmm0
  movd   %r13d,%xmm7
  mulss  %xmm7,%xmm0
  call   <sinf@plt>
  movss  0x4(%rsp),%xmm5
  movss  %xmm5,0x8(%rsp)
  divss  0xc(%rsp),%xmm0
  movss  %xmm0,0x4(%rsp)
  jmp    L70
L49:
  call   <sqrtf@plt>
  jmp    L3
L47:
  movss  0xc(%rsp),%xmm0
  call   <fabs@plt>
  movss  D12(%rip),%xmm5
  movss  %xmm5,0x4(%rsp)
L66:
  movss  D12(%rip),%xmm0
  movss  0x4(%rsp),%xmm6
  subss  %xmm6,%xmm0
  movd   %xmm0,%r14d
  movss  %xmm6,0x8(%rsp)
L70:
  movd   %r14d,%xmm2
  movd   %r14d,%xmm1
  mulss  (%rbx),%xmm1
  movss  0x4(%rsp),%xmm3
  movaps %xmm3,%xmm0
  mulss  0x0(%rbp),%xmm0
  addss  %xmm0,%xmm1
  movd   %xmm1,%r14d
  movss  %xmm1,(%r12)
  movaps %xmm2,%xmm1
  mulss  0x4(%rbx),%xmm1
  movaps %xmm3,%xmm0
  mulss  0x4(%rbp),%xmm0
  addss  %xmm0,%xmm1
  movd   %xmm1,%r13d
  movss  %xmm1,0x4(%r12)
  movaps %xmm2,%xmm1
  mulss  0x8(%rbx),%xmm1
  movaps %xmm3,%xmm0
  mulss  0x8(%rbp),%xmm0
  addss  %xmm0,%xmm1
  movd   %xmm1,%r15d
  movss  %xmm1,0x8(%r12)
  mulss  0xc(%rbx),%xmm2
  mulss  0xc(%rbp),%xmm3
  movaps %xmm2,%xmm4
  addss  %xmm3,%xmm4
  movss  %xmm4,0x4(%rsp)
  movd   %r14d,%xmm0
  mulss  %xmm0,%xmm0
  movd   %r13d,%xmm1
  mulss  %xmm1,%xmm1
  addss  %xmm1,%xmm0
  movd   %r15d,%xmm1
  mulss  %xmm1,%xmm1
  addss  %xmm1,%xmm0
  movaps %xmm4,%xmm1
  mulss  %xmm4,%xmm1
  addss  %xmm1,%xmm0
  pxor   %xmm1,%xmm1
  ucomiss %xmm0,%xmm1
  ja     L49
  sqrtss %xmm0,%xmm0
L3:
  movss  D12(%rip),%xmm1
  divss  %xmm0,%xmm1
  movd   %r14d,%xmm0
  mulss  %xmm1,%xmm0
  movss  %xmm0,(%r12)
  movd   %r13d,%xmm0
  mulss  %xmm1,%xmm0
  movss  %xmm0,0x4(%r12)
  movd   %r15d,%xmm0
  mulss  %xmm1,%xmm0
  movss  %xmm0,0x8(%r12)
  mulss  0x4(%rsp),%xmm1
  movss  %xmm1,0xc(%r12)
  movss  0x8(%rsp),%xmm0
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

tool_calls: name: parse_data
arguments: label: D16
data_type: byte[4]
name: parse_data
arguments: label: D12
data_type: byte[4]
name: parse_data
arguments: label: D42
data_type: byte[4]
name: parse_data
arguments: label: D77
data_type: byte[4]

tool: {"D16": [0x00,0x00,0x80,0xbf]}

tool: {"D12": [0x00,0x00,0x80,0x3f]}

tool: {"D42": [0xac,0xc5,0x27,0x37]}

tool: {"D77": [0x17,0xb7,0xd1,0x38]}

assistant: ```c
float vec4_slerp_to(float ret[4], const float q1[4], const float q2[4], float max_step_rad) {
  float cos_fi, sin_fi, fi, k1, k2, sign;
  float t = 1.0f;
  cos_fi = q1[3] * q2[3] + q1[0] * q2[0] + q1[1] * q2[1] + q1[2] * q2[2];
  sign = (cos_fi < 0.0f) ? (-1.0f) : (1.0f);
  fi = acosf(sign * cos_fi);
  sin_fi = sinf(fi);
  t = fabs(fi);
  if (t > max_step_rad) {
    t = max_step_rad / t;
  } else {
    t = 1.0f;
  }
  if ((fabs(sin_fi) > 0.00001f) && (t > 0.0001f) && (t < 1.0f)) {
    k1 = sinf(fi * (1.0f - t)) / sin_fi;
    k2 = sinf(fi * t * sign) / sin_fi;
  } else {
    k1 = 1.0f - t;
    k2 = t;
  }
  ret[0] = k1 * q1[0] + k2 * q2[0];
  ret[1] = k1 * q1[1] + k2 * q2[1];
  ret[2] = k1 * q1[2] + k2 * q2[2];
  ret[3] = k1 * q1[3] + k2 * q2[3];
  fi = 1.0f / (sqrtf((ret)[0] * (ret)[0] + (ret)[1] * (ret)[1] + (ret)[2] * (ret)[2] + (ret)[3] * (ret)[3]));
  ret[0] *= fi;
  ret[1] *= fi;
  ret[2] *= fi;
  ret[3] *= fi;
  return t;
}
```