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

```asm
<band_energy>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x90,%rsp
  mov    %rdi,-0x68(%rbp)
  mov    %rsi,-0x70(%rbp)
  mov    %rdx,-0x78(%rbp)
  mov    %ecx,-0x7c(%rbp)
  mov    %r8,-0x88(%rbp)
  mov    %r9d,-0x80(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  mov    -0x80(%rbp),%eax
  add    $0x3,%eax
  imul   0x18(%rbp),%eax
  cltq
  shl    $0x2,%eax
  mov    %eax,%edi
  call   <opus_malloc@plt>
  mov    %rax,-0x30(%rbp)
  mov    0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  mov    %rax,-0x28(%rbp)
  mov    0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x28(%rbp),%rax
  add    %rdx,%rax
  mov    %rax,-0x20(%rbp)
  mov    0x18(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  mov    %rax,-0x18(%rbp)
  mov    0x18(%rbp),%eax
  mov    %eax,%edx
  shr    $0x1f,%edx
  add    %edx,%eax
  sar    %eax
  mov    %eax,-0x3c(%rbp)
  movl   $0x0,-0x58(%rbp)
  jmp    L182
L150:
  mov    0x18(%rbp),%eax
  sub    $0x1,%eax
  pxor   %xmm2,%xmm2
  cvtsi2ss %eax,%xmm2
  movss  D45(%rip),%xmm0
  movaps %xmm0,%xmm1
  divss  %xmm2,%xmm1
  pxor   %xmm0,%xmm0
  cvtsi2ssl -0x58(%rbp),%xmm0
  mulss  %xmm1,%xmm0
  cvttss2si %xmm0,%eax
  mov    %eax,%edi
  call   <cos@plt>
  pxor   %xmm1,%xmm1
  cvtsi2ss %rax,%xmm1
  movss  D59(%rip),%xmm0
  mulss  %xmm0,%xmm1
  mov    -0x58(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movss  D59(%rip),%xmm0
  subss  %xmm1,%xmm0
  movss  %xmm0,(%rax)
  addl   $0x1,-0x58(%rbp)
L182:
  mov    -0x58(%rbp),%eax
  cmp    0x18(%rbp),%eax
  jl     L150
  movl   $0x0,-0x58(%rbp)
  jmp    L3
L174:
  pxor   %xmm2,%xmm2
  cvtsi2ssl 0x18(%rbp),%xmm2
  movss  D45(%rip),%xmm0
  movaps %xmm0,%xmm1
  divss  %xmm2,%xmm1
  pxor   %xmm0,%xmm0
  cvtsi2ssl -0x58(%rbp),%xmm0
  mulss  %xmm1,%xmm0
  cvttss2si %xmm0,%eax
  mov    %eax,%edi
  call   <cos@plt>
  mov    %rax,%rdx
  mov    -0x58(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rcx
  mov    -0x28(%rbp),%rax
  add    %rcx,%rax
  pxor   %xmm0,%xmm0
  cvtsi2ss %rdx,%xmm0
  movss  %xmm0,(%rax)
  addl   $0x1,-0x58(%rbp)
L3:
  mov    -0x58(%rbp),%eax
  cmp    0x18(%rbp),%eax
  jl     L174
  movl   $0x0,-0x58(%rbp)
  jmp    L114
L146:
  pxor   %xmm2,%xmm2
  cvtsi2ssl 0x18(%rbp),%xmm2
  movss  D45(%rip),%xmm0
  movaps %xmm0,%xmm1
  divss  %xmm2,%xmm1
  pxor   %xmm0,%xmm0
  cvtsi2ssl -0x58(%rbp),%xmm0
  mulss  %xmm1,%xmm0
  cvttss2si %xmm0,%eax
  mov    %eax,%edi
  call   <sin@plt>
  mov    %rax,%rdx
  mov    -0x58(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rcx
  mov    -0x20(%rbp),%rax
  add    %rcx,%rax
  pxor   %xmm0,%xmm0
  cvtsi2ss %rdx,%xmm0
  movss  %xmm0,(%rax)
  addl   $0x1,-0x58(%rbp)
L114:
  mov    -0x58(%rbp),%eax
  cmp    0x18(%rbp),%eax
  jl     L146
  movq   $0x0,-0x38(%rbp)
  jmp    L23
L35:
  movl   $0x0,-0x54(%rbp)
  jmp    L50
L87:
  movl   $0x0,-0x50(%rbp)
  jmp    L130
L34:
  mov    -0x50(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x30(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm1
  mov    0x20(%rbp),%eax
  cltq
  imul   -0x38(%rbp),%rax
  mov    %rax,%rdx
  mov    -0x50(%rbp),%eax
  cltq
  add    %rax,%rdx
  mov    -0x80(%rbp),%eax
  cltq
  imul   %rax,%rdx
  mov    -0x54(%rbp),%eax
  cltq
  add    %rdx,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x88(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  mov    -0x54(%rbp),%eax
  imul   0x18(%rbp),%eax
  mov    %eax,%edx
  mov    -0x50(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  mulss  %xmm1,%xmm0
  movss  %xmm0,(%rax)
  addl   $0x1,-0x50(%rbp)
L130:
  mov    -0x50(%rbp),%eax
  cmp    0x18(%rbp),%eax
  jl     L34
  addl   $0x1,-0x54(%rbp)
L50:
  mov    -0x54(%rbp),%eax
  cmp    -0x80(%rbp),%eax
  jl     L87
  movl   $0x0,-0x58(%rbp)
  mov    -0x58(%rbp),%eax
  mov    %eax,-0x4c(%rbp)
  jmp    L164
L57:
  movq   $0x0,-0x10(%rbp)
  jmp    L136
L42:
  movl   $0x0,-0x54(%rbp)
  jmp    L100
L196:
  movl   $0x0,-0x40(%rbp)
  pxor   %xmm0,%xmm0
  movss  %xmm0,-0x44(%rbp)
  movss  -0x44(%rbp),%xmm0
  movss  %xmm0,-0x48(%rbp)
  movl   $0x0,-0x50(%rbp)
  jmp    L64
L25:
  mov    -0x40(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x28(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm1
  mov    -0x54(%rbp),%eax
  imul   0x18(%rbp),%eax
  mov    %eax,%edx
  mov    -0x50(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  mulss  %xmm1,%xmm0
  movss  -0x48(%rbp),%xmm1
  addss  %xmm1,%xmm0
  movss  %xmm0,-0x48(%rbp)
  mov    -0x40(%rbp),%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x20(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm1
  mov    -0x54(%rbp),%eax
  imul   0x18(%rbp),%eax
  mov    %eax,%edx
  mov    -0x50(%rbp),%eax
  add    %edx,%eax
  cltq
  lea    0x0(,%rax,4),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  mulss  %xmm0,%xmm1
  movss  -0x44(%rbp),%xmm0
  subss  %xmm1,%xmm0
  movss  %xmm0,-0x44(%rbp)
  mov    -0x58(%rbp),%eax
  add    %eax,-0x40(%rbp)
  mov    -0x40(%rbp),%eax
  cmp    0x18(%rbp),%eax
  jl     L84
  mov    0x18(%rbp),%eax
  sub    %eax,-0x40(%rbp)
L84:
  addl   $0x1,-0x50(%rbp)
L64:
  mov    -0x50(%rbp),%eax
  cmp    0x18(%rbp),%eax
  jl     L25
  pxor   %xmm0,%xmm0
  cvtsi2ssl 0x28(%rbp),%xmm0
  movss  -0x48(%rbp),%xmm1
  mulss  %xmm1,%xmm0
  movss  %xmm0,-0x48(%rbp)
  pxor   %xmm0,%xmm0
  cvtsi2ssl 0x28(%rbp),%xmm0
  movss  -0x44(%rbp),%xmm1
  mulss  %xmm1,%xmm0
  movss  %xmm0,-0x44(%rbp)
  movss  -0x48(%rbp),%xmm0
  movaps %xmm0,%xmm1
  mulss  %xmm0,%xmm1
  movss  -0x44(%rbp),%xmm0
  mulss  %xmm0,%xmm0
  addss  %xmm0,%xmm1
  mov    -0x3c(%rbp),%eax
  cltq
  imul   -0x38(%rbp),%rax
  mov    %rax,%rdx
  mov    -0x58(%rbp),%eax
  cltq
  add    %rax,%rdx
  mov    -0x80(%rbp),%eax
  cltq
  imul   %rax,%rdx
  mov    -0x54(%rbp),%eax
  cltq
  add    %rdx,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x70(%rbp),%rax
  add    %rdx,%rax
  movss  D15(%rip),%xmm0
  addss  %xmm1,%xmm0
  movss  %xmm0,(%rax)
  mov    -0x54(%rbp),%eax
  cltq
  movss  -0x10(%rbp,%rax,4),%xmm1
  mov    -0x3c(%rbp),%eax
  cltq
  imul   -0x38(%rbp),%rax
  mov    %rax,%rdx
  mov    -0x58(%rbp),%eax
  cltq
  add    %rax,%rdx
  mov    -0x80(%rbp),%eax
  cltq
  imul   %rax,%rdx
  mov    -0x54(%rbp),%eax
  cltq
  add    %rdx,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x70(%rbp),%rax
  add    %rdx,%rax
  movss  (%rax),%xmm0
  addss  %xmm1,%xmm0
  mov    -0x54(%rbp),%eax
  cltq
  movss  %xmm0,-0x10(%rbp,%rax,4)
  addl   $0x1,-0x54(%rbp)
L100:
  mov    -0x54(%rbp),%eax
  cmp    -0x80(%rbp),%eax
  jl     L196
  addl   $0x1,-0x58(%rbp)
L136:
  mov    -0x4c(%rbp),%eax
  cltq
  add    $0x1,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x78(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  cmp    %eax,-0x58(%rbp)
  jl     L42
  cmpq   $0x0,-0x68(%rbp)
  je     L239
  movss  -0x10(%rbp),%xmm0
  mov    -0x4c(%rbp),%eax
  cltq
  add    $0x1,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x78(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  mov    -0x4c(%rbp),%edx
  movslq %edx,%rdx
  lea    0x0(,%rdx,4),%rcx
  mov    -0x78(%rbp),%rdx
  add    %rcx,%rdx
  mov    (%rdx),%edx
  sub    %edx,%eax
  pxor   %xmm1,%xmm1
  cvtsi2ss %eax,%xmm1
  mov    -0x7c(%rbp),%eax
  cltq
  imul   -0x38(%rbp),%rax
  mov    %rax,%rdx
  mov    -0x4c(%rbp),%eax
  cltq
  add    %rax,%rdx
  mov    -0x80(%rbp),%eax
  cltq
  imul   %rdx,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x68(%rbp),%rax
  add    %rdx,%rax
  divss  %xmm1,%xmm0
  movss  %xmm0,(%rax)
  cmpl   $0x2,-0x80(%rbp)
  jne    L239
  movss  -0xc(%rbp),%xmm0
  mov    -0x4c(%rbp),%eax
  cltq
  add    $0x1,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x78(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%eax
  mov    -0x4c(%rbp),%edx
  movslq %edx,%rdx
  lea    0x0(,%rdx,4),%rcx
  mov    -0x78(%rbp),%rdx
  add    %rcx,%rdx
  mov    (%rdx),%edx
  sub    %edx,%eax
  pxor   %xmm1,%xmm1
  cvtsi2ss %eax,%xmm1
  mov    -0x7c(%rbp),%eax
  cltq
  imul   -0x38(%rbp),%rax
  mov    %rax,%rdx
  mov    -0x4c(%rbp),%eax
  cltq
  add    %rax,%rdx
  mov    -0x80(%rbp),%eax
  cltq
  imul   %rdx,%rax
  add    $0x1,%rax
  lea    0x0(,%rax,4),%rdx
  mov    -0x68(%rbp),%rax
  add    %rdx,%rax
  divss  %xmm1,%xmm0
  movss  %xmm0,(%rax)
L239:
  addl   $0x1,-0x4c(%rbp)
L164:
  mov    -0x4c(%rbp),%eax
  cmp    -0x7c(%rbp),%eax
  jl     L57
  addq   $0x1,-0x38(%rbp)
L23:
  mov    -0x38(%rbp),%rax
  cmp    0x10(%rbp),%rax
  jb     L35
  mov    -0x30(%rbp),%rax
  mov    %rax,%rdi
  call   <free@plt>
  nop
  mov    -0x8(%rbp),%rax
  sub    %fs:0x28,%rax
  je     L26
  call   <__stack_chk_fail@plt>
L26:
  leave
  ret
```

tool_calls: name: disassemble_data
arguments: label: D45
datatype: byte[4]
name: disassemble_data
arguments: label: D59
datatype: byte[4]
name: disassemble_data
arguments: label: D15
datatype: byte[4]

tool: {"D45": [0xdb,0x0f,0xc9,0x40]}

tool: {"D59": [0x00,0x00,0x00,0x3f]}

tool: {"D15": [0x00,0x50,0xc3,0x47]}

assistant: ```c
void band_energy(float *_out, float *_ps, const int *_bands, int _nbands, const float *_in, int _nchannels, size_t _nframes, int _window_sz, int _step, int _downsample) {
  float *window;
  float *x;
  float *c;
  float *s;
  size_t xi;
  int xj;
  int ps_sz;
  window = (float *)opus_malloc((3 + _nchannels) * _window_sz * sizeof(*window));
  c = window + _window_sz;
  s = c + _window_sz;
  x = s + _window_sz;
  ps_sz = _window_sz / 2;
  for (xj = 0; xj < _window_sz; xj++) {
    window[xj] = 0.5F - 0.5F * ((float)cos((2 * (3.14159265F) / (_window_sz - 1)) * xj));
  }
  for (xj = 0; xj < _window_sz; xj++) {
    c[xj] = ((float)cos((2 * (3.14159265F) / _window_sz) * xj));
  }
  for (xj = 0; xj < _window_sz; xj++) {
    s[xj] = ((float)sin((2 * (3.14159265F) / _window_sz) * xj));
  }
  for (xi = 0; xi < _nframes; xi++) {
    int ci;
    int xk;
    int bi;
    for (ci = 0; ci < _nchannels; ci++) {
      for (xk = 0; xk < _window_sz; xk++) {
        x[ci * _window_sz + xk] = window[xk] * _in[(xi * _step + xk) * _nchannels + ci];
      }
    }
    for (bi = xj = 0; bi < _nbands; bi++) {
      float p[2] = {0};
      for (; xj < _bands[bi + 1]; xj++) {
        for (ci = 0; ci < _nchannels; ci++) {
          float re;
          float im;
          int ti;
          ti = 0;
          re = im = 0;
          for (xk = 0; xk < _window_sz; xk++) {
            re += c[ti] * x[ci * _window_sz + xk];
            im -= s[ti] * x[ci * _window_sz + xk];
            ti += xj;
            if (ti >= _window_sz)
              ti -= _window_sz;
          }
          re *= _downsample;
          im *= _downsample;
          _ps[(xi * ps_sz + xj) * _nchannels + ci] = re * re + im * im + 100000;
          p[ci] += _ps[(xi * ps_sz + xj) * _nchannels + ci];
        }
      }
      if (_out) {
        _out[(xi * _nbands + bi) * _nchannels] = p[0] / (_bands[bi + 1] - _bands[bi]);
        if (_nchannels == 2) {
          _out[(xi * _nbands + bi) * _nchannels + 1] = p[1] / (_bands[bi + 1] - _bands[bi]);
        }
      }
    }
  }
  free(window);
}
```