user: 请显示与下面列出的汇编代码相匹配的C语言实现：

```asm
<sympoly>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x28,%rsp
  mov    %rdx,%r15
  mov    %rcx,%rbx
  mov    %r8,%r14
  movq   $0x0,(%r8)
  mov    D32(%rip),%rax
  mov    %rax,(%rcx)
  test   %edi,%edi
  jle    L66
  lea    0x8(%rcx),%rax
  lea    -0x1(%rdi),%edx
  lea    0x10(%rcx,%rdx,8),%rdx
L165:
  movq   $0x0,(%rax)
  add    $0x8,%rax
  cmp    %rdx,%rax
  jne    L165
  lea    0x1(%rsi),%r12d
  cmp    %edi,%r12d
  cmovg  %edi,%r12d
  mov    $0x2,%eax
  cmp    %eax,%r12d
  cmovl  %eax,%r12d
  movsd  (%r15),%xmm0
  movsd  %xmm0,0x8(%rbx)
  cmp    $0x1,%edi
  jle    L171
  mov    %edi,%eax
  mov    %rax,0x10(%rsp)
  mov    $0x1,%r13d
  mov    D32(%rip),%rbp
  jmp    L96
L66:
  je     L5
  add    $0x1,%esi
  cmp    %edi,%esi
  cmovle %esi,%edi
  mov    %edi,%r12d
  mov    $0x2,%eax
  cmp    %eax,%edi
  cmovl  %eax,%r12d
  movsd  (%rdx),%xmm0
  movsd  %xmm0,0x8(%rcx)
L171:
  movsd  (%r14),%xmm0
  movsd  D16(%rip),%xmm1
  comisd %xmm0,%xmm1
  ja     L151
L5:
  mov    $0x0,%eax
  add    $0x28,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L155:
  movq   %rbp,%xmm5
  movsd  0x8(%rsp),%xmm0
  divsd  %xmm0,%xmm5
  movsd  %xmm5,0x18(%rsp)
  call   <log@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %rax,%xmm0
  addsd  (%r14),%xmm0
  movsd  %xmm0,(%r14)
  mov    %r13d,%esi
  test   %r13d,%r13d
  jle    L81
  mov    $0x2,%eax
L124:
  movq   %rbp,%xmm1
  mov    -0x8(%rbx,%rax,8),%rbp
  movq   %rbp,%xmm0
  divsd  0x8(%rsp),%xmm0
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x8(%rbx,%rax,8)
  mov    %eax,%edx
  add    $0x1,%rax
  cmp    %esi,%edx
  jg     L130
  cmp    %r12d,%edx
  jl     L124
L130:
  movslq %edx,%rdx
  mov    %rbp,(%rbx,%rdx,8)
  mov    0x18(%rsp),%rbp
  jmp    L122
L81:
  mov    $0x1,%edx
  jmp    L130
L93:
  movslq %edx,%rdx
  mulsd  0x8(%rsp),%xmm1
  movsd  %xmm1,(%rbx,%rdx,8)
L122:
  add    $0x1,%r13
  cmp    %r13,0x10(%rsp)
  je     L171
L96:
  movsd  (%r15,%r13,8),%xmm4
  movsd  %xmm4,0x8(%rsp)
  comisd D32(%rip),%xmm4
  ja     L155
  mov    %r13d,%esi
  movq   %rbp,%xmm1
  mov    $0x2,%eax
  mov    $0x1,%edx
  test   %r13d,%r13d
  jle    L93
L182:
  movapd %xmm1,%xmm0
  movsd  -0x8(%rbx,%rax,8),%xmm1
  mulsd  0x8(%rsp),%xmm0
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x8(%rbx,%rax,8)
  mov    %eax,%edx
  add    $0x1,%rax
  cmp    %esi,%edx
  jg     L93
  cmp    %r12d,%edx
  jl     L182
  jmp    L93
L151:
  call   <exp@plt>
  lea    0x8(%rbx),%rax
  lea    -0x1(%r12),%edx
  lea    0x10(%rbx,%rdx,8),%rdx
L45:
  movapd %xmm0,%xmm1
  mulsd  (%rax),%xmm1
  movsd  %xmm1,(%rax)
  add    $0x8,%rax
  cmp    %rax,%rdx
  jne    L45
  movq   $0x0,(%r14)
  jmp    L5
```

tool_calls: name: extract_symbolic_data
arguments: data_label: D32
type_infered: f64[2]
name: extract_symbolic_data
arguments: data_label: D16
type_infered: byte[8]

tool: {"D32": [1.0,15.0]}

tool: {"D16": [0x00,0x00,0x00,0x00,0x00,0x00,0x2e,0x40]}

assistant: ```c
int sympoly(int K, int BK, double *val, double *res, double *overflow) {
  int h, k;
  double mult = 1;
  BK++;
  if (BK > K)
    BK = K;
  if (BK <= 1)
    BK = 2;
  *overflow = 0;
  res[0] = 1;
  for (k = 1; k <= K; k++)
    res[k] = 0;
  if (K == 0)
    return 0;
  res[1] = val[0];
  for (k = 1; k < K; k++) {
    double vk = val[k];
    if (vk > 1) {
      double lastv = mult;
      mult /= vk;
      *overflow += log(vk);
      for (h = 1; h <= k && h < BK; h++) {
        double thisv = res[h];
        res[h] = thisv / vk + lastv;
        lastv = thisv;
      }
      res[h] = lastv;
    } else {
      double lastv = mult;
      for (h = 1; h <= k && h < BK; h++) {
        double thisv = res[h];
        res[h] += vk * lastv;
        lastv = thisv;
      }
      res[h] = vk * lastv;
    }
  }
  if (*overflow < 15) {
    double eo = exp(*overflow);
    for (h = 1; h <= BK; h++)
      res[h] *= eo;
    *overflow = 0;
  }
  return 0;
}
```