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

```asm
<fast_expansion_sum>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %edi,-0x44(%rbp)
  mov    %rsi,-0x50(%rbp)
  mov    %edx,-0x48(%rbp)
  mov    %rcx,-0x58(%rbp)
  mov    %r8,-0x60(%rbp)
  movl   $0x0,-0x38(%rbp)
  mov    -0x38(%rbp),%eax
  mov    %eax,-0x3c(%rbp)
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x50(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  comisd %xmm1,%xmm0
  seta   %al
  xor    $0x1,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x58(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rax),%xmm0
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x50(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rax),%xmm1
  movq   D22(%rip),%xmm2
  xorpd  %xmm2,%xmm1
  comisd %xmm1,%xmm0
  seta   %al
  xor    %edx,%eax
  test   %al,%al
  je     L71
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x50(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x30(%rbp)
  addl   $0x1,-0x3c(%rbp)
  jmp    L80
L71:
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  %xmm0,-0x30(%rbp)
  addl   $0x1,-0x38(%rbp)
L80:
  movl   $0x0,-0x34(%rbp)
  mov    -0x3c(%rbp),%eax
  cmp    -0x44(%rbp),%eax
  jge    L139
  mov    -0x38(%rbp),%eax
  cmp    -0x48(%rbp),%eax
  jge    L139
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x50(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  comisd %xmm1,%xmm0
  seta   %al
  xor    $0x1,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x58(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rax),%xmm0
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x50(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rax),%xmm1
  movq   D22(%rip),%xmm2
  xorpd  %xmm2,%xmm1
  comisd %xmm1,%xmm0
  seta   %al
  xor    %edx,%eax
  test   %al,%al
  je     L6
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x50(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  -0x30(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x28(%rbp)
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x50(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  movsd  -0x28(%rbp),%xmm0
  subsd  %xmm1,%xmm0
  movsd  %xmm0,-0x20(%rbp)
  movsd  -0x30(%rbp),%xmm0
  subsd  -0x20(%rbp),%xmm0
  mov    -0x60(%rbp),%rax
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x3c(%rbp)
  jmp    L130
L6:
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  -0x30(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x28(%rbp)
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  movsd  -0x28(%rbp),%xmm0
  subsd  %xmm1,%xmm0
  movsd  %xmm0,-0x20(%rbp)
  movsd  -0x30(%rbp),%xmm0
  subsd  -0x20(%rbp),%xmm0
  mov    -0x60(%rbp),%rax
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x38(%rbp)
L130:
  movsd  -0x28(%rbp),%xmm0
  movsd  %xmm0,-0x30(%rbp)
  movl   $0x1,-0x34(%rbp)
  jmp    L57
L31:
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x50(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  comisd %xmm1,%xmm0
  seta   %al
  xor    $0x1,%eax
  mov    %eax,%edx
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x58(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rax),%xmm0
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rcx
  mov    -0x50(%rbp),%rax
  add    %rcx,%rax
  movsd  (%rax),%xmm1
  movq   D22(%rip),%xmm2
  xorpd  %xmm2,%xmm1
  comisd %xmm1,%xmm0
  seta   %al
  xor    %edx,%eax
  test   %al,%al
  je     L142
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x50(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  -0x30(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x28(%rbp)
  movsd  -0x28(%rbp),%xmm0
  subsd  -0x30(%rbp),%xmm0
  movsd  %xmm0,-0x20(%rbp)
  movsd  -0x28(%rbp),%xmm0
  subsd  -0x20(%rbp),%xmm0
  movsd  %xmm0,-0x18(%rbp)
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x50(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  subsd  -0x20(%rbp),%xmm0
  movsd  %xmm0,-0x10(%rbp)
  movsd  -0x30(%rbp),%xmm0
  subsd  -0x18(%rbp),%xmm0
  movsd  %xmm0,-0x8(%rbp)
  mov    -0x34(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x60(%rbp),%rax
  add    %rdx,%rax
  movsd  -0x8(%rbp),%xmm0
  addsd  -0x10(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x3c(%rbp)
  jmp    L17
L142:
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  -0x30(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x28(%rbp)
  movsd  -0x28(%rbp),%xmm0
  subsd  -0x30(%rbp),%xmm0
  movsd  %xmm0,-0x20(%rbp)
  movsd  -0x28(%rbp),%xmm0
  subsd  -0x20(%rbp),%xmm0
  movsd  %xmm0,-0x18(%rbp)
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  subsd  -0x20(%rbp),%xmm0
  movsd  %xmm0,-0x10(%rbp)
  movsd  -0x30(%rbp),%xmm0
  subsd  -0x18(%rbp),%xmm0
  movsd  %xmm0,-0x8(%rbp)
  mov    -0x34(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x60(%rbp),%rax
  add    %rdx,%rax
  movsd  -0x8(%rbp),%xmm0
  addsd  -0x10(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x38(%rbp)
L17:
  movsd  -0x28(%rbp),%xmm0
  movsd  %xmm0,-0x30(%rbp)
  addl   $0x1,-0x34(%rbp)
L57:
  mov    -0x3c(%rbp),%eax
  cmp    -0x44(%rbp),%eax
  jge    L139
  mov    -0x38(%rbp),%eax
  cmp    -0x48(%rbp),%eax
  jl     L31
  jmp    L139
L148:
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x50(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  -0x30(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x28(%rbp)
  movsd  -0x28(%rbp),%xmm0
  subsd  -0x30(%rbp),%xmm0
  movsd  %xmm0,-0x20(%rbp)
  movsd  -0x28(%rbp),%xmm0
  subsd  -0x20(%rbp),%xmm0
  movsd  %xmm0,-0x18(%rbp)
  mov    -0x3c(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x50(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  subsd  -0x20(%rbp),%xmm0
  movsd  %xmm0,-0x10(%rbp)
  movsd  -0x30(%rbp),%xmm0
  subsd  -0x18(%rbp),%xmm0
  movsd  %xmm0,-0x8(%rbp)
  mov    -0x34(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x60(%rbp),%rax
  add    %rdx,%rax
  movsd  -0x8(%rbp),%xmm0
  addsd  -0x10(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x3c(%rbp)
  movsd  -0x28(%rbp),%xmm0
  movsd  %xmm0,-0x30(%rbp)
  addl   $0x1,-0x34(%rbp)
L139:
  mov    -0x3c(%rbp),%eax
  cmp    -0x44(%rbp),%eax
  jl     L148
  jmp    L91
L72:
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  movsd  -0x30(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x28(%rbp)
  movsd  -0x28(%rbp),%xmm0
  subsd  -0x30(%rbp),%xmm0
  movsd  %xmm0,-0x20(%rbp)
  movsd  -0x28(%rbp),%xmm0
  subsd  -0x20(%rbp),%xmm0
  movsd  %xmm0,-0x18(%rbp)
  mov    -0x38(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  subsd  -0x20(%rbp),%xmm0
  movsd  %xmm0,-0x10(%rbp)
  movsd  -0x30(%rbp),%xmm0
  subsd  -0x18(%rbp),%xmm0
  movsd  %xmm0,-0x8(%rbp)
  mov    -0x34(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x60(%rbp),%rax
  add    %rdx,%rax
  movsd  -0x8(%rbp),%xmm0
  addsd  -0x10(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x38(%rbp)
  movsd  -0x28(%rbp),%xmm0
  movsd  %xmm0,-0x30(%rbp)
  addl   $0x1,-0x34(%rbp)
L91:
  mov    -0x38(%rbp),%eax
  cmp    -0x48(%rbp),%eax
  jl     L72
  mov    -0x34(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x60(%rbp),%rax
  add    %rdx,%rax
  movsd  -0x30(%rbp),%xmm0
  movsd  %xmm0,(%rax)
  mov    -0x34(%rbp),%eax
  add    $0x1,%eax
  pop    %rbp
  ret
```

tool_calls: name: disassemble_data
arguments: label: D22
datatype: byte[8]

tool: {"D22": [0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80]}

assistant: ```c
int fast_expansion_sum(int elen, double *e, int flen, double *f, double *h) {
  double Q;
  double Qnew;
  double bvirt;
  double avirt, bround, around;
  int eindex, findex, hindex;
  eindex = findex = 0;
  if (((f[findex]) > (e[eindex])) == ((f[findex]) > -(e[eindex]))) {
    Q = (e[eindex]);
    ++eindex;
  } else {
    Q = (f[findex]);
    ++findex;
  }
  hindex = 0;
  if ((eindex < elen) && (findex < flen)) {
    if (((f[findex]) > (e[eindex])) == ((f[findex]) > -(e[eindex]))) {
      Qnew = (double)((e[eindex]) + Q);
      bvirt = Qnew - (e[eindex]);
      h[0] = Q - bvirt;
      ++eindex;
    } else {
      Qnew = (double)((f[findex]) + Q);
      bvirt = Qnew - (f[findex]);
      h[0] = Q - bvirt;
      ++findex;
    }
    Q = Qnew;
    hindex = 1;
    while ((eindex < elen) && (findex < flen)) {
      if (((f[findex]) > (e[eindex])) == ((f[findex]) > -(e[eindex]))) {
        Qnew = (double)(Q + (e[eindex]));
        bvirt = (double)(Qnew - Q);
        avirt = Qnew - bvirt;
        bround = (e[eindex]) - bvirt;
        around = Q - avirt;
        h[hindex] = around + bround;
        ++eindex;
      } else {
        Qnew = (double)(Q + (f[findex]));
        bvirt = (double)(Qnew - Q);
        avirt = Qnew - bvirt;
        bround = (f[findex]) - bvirt;
        around = Q - avirt;
        h[hindex] = around + bround;
        ++findex;
      }
      Q = Qnew;
      hindex++;
    }
  }
  while (eindex < elen) {
    Qnew = (double)(Q + (e[eindex]));
    bvirt = (double)(Qnew - Q);
    avirt = Qnew - bvirt;
    bround = (e[eindex]) - bvirt;
    around = Q - avirt;
    h[hindex] = around + bround;
    ++eindex;
    Q = Qnew;
    hindex++;
  }
  while (findex < flen) {
    Qnew = (double)(Q + (f[findex]));
    bvirt = (double)(Qnew - Q);
    avirt = Qnew - bvirt;
    bround = (f[findex]) - bvirt;
    around = Q - avirt;
    h[hindex] = around + bround;
    ++findex;
    Q = Qnew;
    hindex++;
  }
  h[hindex] = Q;
  return hindex + 1;
}
```