user: 请将以下的汇编代码转换成C语言代码：

```asm
<dwt_encode_97>:
  endbr64
  push   %r15
  push   %r14
  mov    %rdi,%r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %esi,%ebp
  push   %rbx
  mov    %edx,%ebx
  sub    $0x18,%rsp
  test   %ecx,%ecx
  jne    L597
  test   %esi,%esi
  jg     L116
  cmp    $0x1,%edx
  jle    L102
  test   %esi,%esi
  jle    L660
L116:
  lea    -0x1(%rbx),%eax
  lea    0x1(%rbp),%r12d
  mov    $0x1,%r13d
  mov    %eax,0x4(%rsp)
  add    %eax,%eax
  cltq
  mov    %r12d,0xc(%rsp)
  lea    (%r14,%rax,4),%r15
  jmp    L609
  cs nopw 0x0(%rax,%rax,1)
L9:
  mov    (%r15),%edi
  cmp    %r13d,%ebx
  jg     L754
L309:
  mov    (%r15),%eax
L434:
  add    %eax,%edi
  mov    $0x32c1,%esi
  xor    %eax,%eax
  call   <fix_mul@plt>
  sub    %eax,-0x4(%r14,%r13,8)
  add    $0x1,%r13
  cmp    %r12,%r13
  je     L571
L609:
  lea    -0x1(%r13),%ecx
  mov    %r13d,%eax
  cmp    %ecx,%ebx
  jle    L9
  mov    -0x8(%r14,%r13,8),%edi
  cmp    %r13d,%ebx
  jle    L309
L754:
  add    %eax,%eax
  cltq
  mov    (%r14,%rax,4),%eax
  jmp    L434
  nopw   0x0(%rax,%rax,1)
L597:
  test   %edx,%edx
  jg     L382
  cmp    $0x1,%esi
  jg     L382
L102:
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax,%rax,1)
L382:
  test   %ebp,%ebp
  jle    L364
  lea    -0x1(%rbx),%eax
  movslq %ebp,%r13
  xor    %r15d,%r15d
  mov    %eax,0x4(%rsp)
  lea    -0x1(%rbx,%rbx,1),%eax
  cltq
  lea    (%r14,%rax,4),%r12
  jmp    L157
  nopl   0x0(%rax)
L747:
  mov    (%r12),%eax
  test   %r15d,%r15d
  je     L465
  cmp    %r15d,%ebx
  jge    L680
  mov    %eax,%edi
L579:
  add    %eax,%edi
  mov    $0x32c1,%esi
  xor    %eax,%eax
  call   <fix_mul@plt>
  sub    %eax,(%r14,%r15,8)
  add    $0x1,%r15
  cmp    %r13,%r15
  je     L822
L157:
  cmp    %r15d,%ebx
  jle    L747
  lea    0x1(%r15,%r15,1),%eax
  mov    (%r14,%rax,4),%eax
  test   %r15d,%r15d
  je     L465
L680:
  mov    -0x4(%r14,%r15,8),%edi
  jmp    L579
  nopl   0x0(%rax)
L465:
  mov    0x4(%r14),%edi
  jmp    L579
  xchg   %ax,%ax
L571:
  test   %ebx,%ebx
  jle    L262
L682:
  lea    -0x1(%rbp),%eax
  movslq %ebx,%r12
  xor    %r15d,%r15d
  mov    %eax,0x8(%rsp)
  lea    -0x1(%rbp,%rbp,1),%eax
  cltq
  lea    (%r14,%rax,4),%r13
  jmp    L193
  nopl   0x0(%rax)
L269:
  cmp    %r15d,%ebp
  jge    L691
  mov    0x0(%r13),%edi
  mov    %edi,%eax
L730:
  add    %eax,%edi
  mov    $0x1b2,%esi
  xor    %eax,%eax
  call   <fix_mul@plt>
  sub    %eax,(%r14,%r15,8)
  add    $0x1,%r15
  cmp    %r15,%r12
  je     L535
L193:
  mov    %r15d,%edx
  test   %r15,%r15
  jne    L269
  mov    0x4(%r14),%eax
  cmp    %edx,%ebp
  jle    L32
L90:
  lea    0x1(%r15,%r15,1),%edx
  mov    (%r14,%rdx,4),%edi
  jmp    L730
  nopl   0x0(%rax)
L535:
  lea    -0x1(%rbx),%eax
  mov    %eax,0x4(%rsp)
  lea    0x1(%rbp),%eax
  mov    %eax,0xc(%rsp)
  test   %ebp,%ebp
  jle    L286
L262:
  mov    0x4(%rsp),%r13d
  mov    0xc(%rsp),%r12d
  add    %r13d,%r13d
  movslq %r13d,%r13
  lea    (%r14,%r13,4),%r15
  mov    $0x1,%r13d
  jmp    L689
  nopw   0x0(%rax,%rax,1)
L503:
  mov    (%r15),%edi
  cmp    %r13d,%ebx
  jg     L376
L576:
  mov    (%r15),%eax
L449:
  add    %eax,%edi
  mov    $0x1c41,%esi
  xor    %eax,%eax
  call   <fix_mul@plt>
  add    %eax,-0x4(%r14,%r13,8)
  add    $0x1,%r13
  cmp    %r13,%r12
  je     L253
L689:
  lea    -0x1(%r13),%edx
  mov    %r13d,%eax
  cmp    %edx,%ebx
  jle    L503
  mov    -0x8(%r14,%r13,8),%edi
  cmp    %r13d,%ebx
  jle    L576
L376:
  add    %eax,%eax
  cltq
  mov    (%r14,%rax,4),%eax
  jmp    L449
  nopw   0x0(%rax,%rax,1)
L691:
  mov    -0x4(%r14,%r15,8),%eax
  cmp    %edx,%ebp
  jg     L90
L32:
  mov    0x0(%r13),%edi
  jmp    L730
  cs nopw 0x0(%rax,%rax,1)
L822:
  test   %ebx,%ebx
  jle    L197
L358:
  lea    -0x2(%rbp,%rbp,1),%eax
  lea    0x1(%rbx),%r13d
  mov    $0x1,%r12d
  cltq
  lea    (%r14,%rax,4),%r15
  jmp    L385
  nopw   0x0(%rax,%rax,1)
L625:
  mov    (%r15),%edi
  cmp    %r12d,%ebp
  jg     L772
L732:
  mov    (%r15),%eax
L251:
  add    %eax,%edi
  mov    $0x1b2,%esi
  xor    %eax,%eax
  call   <fix_mul@plt>
  sub    %eax,-0x4(%r14,%r12,8)
  add    $0x1,%r12
  cmp    %r13,%r12
  je     L432
L385:
  lea    -0x1(%r12),%edx
  mov    %r12d,%eax
  cmp    %edx,%ebp
  jle    L625
  mov    -0x8(%r14,%r12,8),%edi
  cmp    %r12d,%ebp
  jle    L732
L772:
  add    %eax,%eax
  cltq
  mov    (%r14,%rax,4),%eax
  jmp    L251
  nopw   0x0(%rax,%rax,1)
L432:
  lea    -0x1(%rbx),%eax
  movslq %ebp,%r13
  mov    %eax,0x4(%rsp)
  test   %ebp,%ebp
  jle    L601
L197:
  mov    0x4(%rsp),%eax
  xor    %r12d,%r12d
  lea    0x1(%rax,%rax,1),%eax
  cltq
  lea    (%r14,%rax,4),%r15
  jmp    L789
  nopl   0x0(%rax)
L265:
  mov    (%r15),%eax
  test   %r12d,%r12d
  je     L495
  cmp    %r12d,%ebx
  jge    L572
  mov    %eax,%edi
L504:
  add    %eax,%edi
  mov    $0x1c41,%esi
  xor    %eax,%eax
  call   <fix_mul@plt>
  add    %eax,(%r14,%r12,8)
  add    $0x1,%r12
  cmp    %r12,%r13
  je     L601
L789:
  cmp    %r12d,%ebx
  jle    L265
  lea    0x1(%r12,%r12,1),%eax
  mov    (%r14,%rax,4),%eax
  test   %r12d,%r12d
  je     L495
L572:
  mov    -0x4(%r14,%r12,8),%edi
  jmp    L504
  nopl   0x0(%rax)
L495:
  mov    0x4(%r14),%edi
  jmp    L504
  cs nopw 0x0(%rax,%rax,1)
L601:
  test   %ebx,%ebx
  jle    L676
  lea    -0x2(%rbp,%rbp,1),%eax
  lea    0x1(%rbx),%r13d
  mov    $0x1,%r12d
  cltq
  lea    (%r14,%rax,4),%r15
  jmp    L436
  xchg   %ax,%ax
L229:
  mov    (%r15),%edi
  cmp    %r12d,%ebp
  jg     L662
L650:
  mov    (%r15),%eax
L422:
  add    %eax,%edi
  mov    $0xe31,%esi
  xor    %eax,%eax
  call   <fix_mul@plt>
  add    %eax,-0x4(%r14,%r12,8)
  add    $0x1,%r12
  cmp    %r12,%r13
  je     L133
L436:
  lea    -0x1(%r12),%edx
  mov    %r12d,%eax
  cmp    %edx,%ebp
  jle    L229
  mov    -0x8(%r14,%r12,8),%edi
  cmp    %r12d,%ebp
  jle    L650
L662:
  add    %eax,%eax
  cltq
  mov    (%r14,%rax,4),%eax
  jmp    L422
  nopw   0x0(%rax,%rax,1)
L133:
  test   %ebp,%ebp
  jle    L113
L658:
  xor    %r12d,%r12d
  nopw   0x0(%rax,%rax,1)
L598:
  mov    (%r14,%r12,8),%edi
  mov    $0x13ae,%esi
  xor    %eax,%eax
  call   <fix_mul@plt>
  mov    %eax,(%r14,%r12,8)
  add    $0x1,%r12
  cmp    %r12d,%ebp
  jg     L598
  test   %ebx,%ebx
  jle    L102
L113:
  xor    %ebp,%ebp
  nopw   0x0(%rax,%rax,1)
L34:
  mov    0x4(%r14,%rbp,8),%edi
  mov    $0x1a03,%esi
  xor    %eax,%eax
  call   <fix_mul@plt>
  mov    %eax,0x4(%r14,%rbp,8)
  add    $0x1,%rbp
  cmp    %ebp,%ebx
  jg     L34
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   (%rax)
L253:
  lea    -0x1(%rbp),%eax
  mov    %eax,0x8(%rsp)
  test   %ebx,%ebx
  jle    L578
L286:
  mov    0x8(%rsp),%eax
  mov    %ebx,%r12d
  xor    %r15d,%r15d
  lea    0x1(%rax,%rax,1),%eax
  cltq
  lea    (%r14,%rax,4),%r13
  jmp    L556
  nopl   (%rax)
L173:
  cmp    %r15d,%ebp
  jge    L746
  mov    0x0(%r13),%eax
  mov    %eax,%edi
L306:
  add    %eax,%edi
  mov    $0xe31,%esi
  xor    %eax,%eax
  call   <fix_mul@plt>
  add    %eax,(%r14,%r15,8)
  add    $0x1,%r15
  cmp    %r15,%r12
  je     L668
L556:
  mov    %r15d,%eax
  test   %r15,%r15
  jne    L173
  mov    0x4(%r14),%edi
  cmp    %eax,%ebp
  jle    L29
L511:
  lea    0x1(%r15,%r15,1),%eax
  mov    (%r14,%rax,4),%eax
  jmp    L306
  nopl   0x0(%rax)
L746:
  mov    -0x4(%r14,%r15,8),%edi
  cmp    %eax,%ebp
  jg     L511
L29:
  mov    0x0(%r13),%eax
  jmp    L306
  nop
L668:
  test   %ebp,%ebp
  jle    L720
L755:
  mov    0x8(%rsp),%eax
  lea    0x4(%r14),%rbp
  lea    0xc(%r14,%rax,8),%r12
  nopl   0x0(%rax)
L800:
  mov    0x0(%rbp),%edi
  mov    $0x13ae,%esi
  xor    %eax,%eax
  add    $0x8,%rbp
  call   <fix_mul@plt>
  mov    %eax,-0x8(%rbp)
  cmp    %r12,%rbp
  jne    L800
  test   %ebx,%ebx
  jle    L102
L720:
  lea    -0x1(%rbx),%eax
  lea    0x8(%r14,%rax,8),%rbx
  nopl   0x0(%rax,%rax,1)
L225:
  mov    (%r14),%edi
  mov    $0x1a03,%esi
  xor    %eax,%eax
  add    $0x8,%r14
  call   <fix_mul@plt>
  mov    %eax,-0x8(%r14)
  cmp    %rbx,%r14
  jne    L225
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax,%rax,1)
L660:
  test   %edx,%edx
  jg     L682
L578:
  lea    -0x1(%rbp),%eax
  mov    %eax,0x8(%rsp)
  test   %ebp,%ebp
  jg     L755
  jmp    L102
  nopl   0x0(%rax)
L364:
  test   %ebx,%ebx
  jg     L358
L676:
  test   %ebp,%ebp
  jg     L658
  jmp    L102
```

assistant: ```c
void dwt_encode_97(int *a, int dn, int sn, int cas) {
  int i;
  if (!cas) {
    if ((dn > 0) || (sn > 1)) {
      for (i = 0; i < dn; i++) {
        a[(1 + (i)*2)] -= fix_mul(((i) < 0 ? a[(0) * 2] : ((i) >= sn ? a[(sn - 1) * 2] : a[(i)*2])) + ((i + 1) < 0 ? a[(0) * 2] : ((i + 1) >= sn ? a[(sn - 1) * 2] : a[(i + 1) * 2])), 12993);
      }
      for (i = 0; i < sn; i++) {
        a[(i)*2] -= fix_mul(((i - 1) < 0 ? a[(1 + (0) * 2)] : ((i - 1) >= dn ? a[(1 + (dn - 1) * 2)] : a[(1 + (i - 1) * 2)])) + ((i) < 0 ? a[(1 + (0) * 2)] : ((i) >= dn ? a[(1 + (dn - 1) * 2)] : a[(1 + (i)*2)])), 434);
      }
      for (i = 0; i < dn; i++) {
        a[(1 + (i)*2)] += fix_mul(((i) < 0 ? a[(0) * 2] : ((i) >= sn ? a[(sn - 1) * 2] : a[(i)*2])) + ((i + 1) < 0 ? a[(0) * 2] : ((i + 1) >= sn ? a[(sn - 1) * 2] : a[(i + 1) * 2])), 7233);
      }
      for (i = 0; i < sn; i++) {
        a[(i)*2] += fix_mul(((i - 1) < 0 ? a[(1 + (0) * 2)] : ((i - 1) >= dn ? a[(1 + (dn - 1) * 2)] : a[(1 + (i - 1) * 2)])) + ((i) < 0 ? a[(1 + (0) * 2)] : ((i) >= dn ? a[(1 + (dn - 1) * 2)] : a[(1 + (i)*2)])), 3633);
      }
      for (i = 0; i < dn; i++) {
        a[(1 + (i)*2)] = fix_mul(a[(1 + (i)*2)], 5038);
      }
      for (i = 0; i < sn; i++) {
        a[(i)*2] = fix_mul(a[(i)*2], 6659);
      }
    }
  } else {
    if ((sn > 0) || (dn > 1)) {
      for (i = 0; i < dn; i++) {
        a[(i)*2] -= fix_mul(((i) < 0 ? a[(1 + (0) * 2)] : ((i) >= sn ? a[(1 + (sn - 1) * 2)] : a[(1 + (i)*2)])) + ((i - 1) < 0 ? a[(1 + (0) * 2)] : ((i - 1) >= sn ? a[(1 + (sn - 1) * 2)] : a[(1 + (i - 1) * 2)])), 12993);
      }
      for (i = 0; i < sn; i++) {
        a[(1 + (i)*2)] -= fix_mul(((i) < 0 ? a[(0) * 2] : ((i) >= dn ? a[(dn - 1) * 2] : a[(i)*2])) + ((i + 1) < 0 ? a[(0) * 2] : ((i + 1) >= dn ? a[(dn - 1) * 2] : a[(i + 1) * 2])), 434);
      }
      for (i = 0; i < dn; i++) {
        a[(i)*2] += fix_mul(((i) < 0 ? a[(1 + (0) * 2)] : ((i) >= sn ? a[(1 + (sn - 1) * 2)] : a[(1 + (i)*2)])) + ((i - 1) < 0 ? a[(1 + (0) * 2)] : ((i - 1) >= sn ? a[(1 + (sn - 1) * 2)] : a[(1 + (i - 1) * 2)])), 7233);
      }
      for (i = 0; i < sn; i++) {
        a[(1 + (i)*2)] += fix_mul(((i) < 0 ? a[(0) * 2] : ((i) >= dn ? a[(dn - 1) * 2] : a[(i)*2])) + ((i + 1) < 0 ? a[(0) * 2] : ((i + 1) >= dn ? a[(dn - 1) * 2] : a[(i + 1) * 2])), 3633);
      }
      for (i = 0; i < dn; i++) {
        a[(i)*2] = fix_mul(a[(i)*2], 5038);
      }
      for (i = 0; i < sn; i++) {
        a[(1 + (i)*2)] = fix_mul(a[(1 + (i)*2)], 6659);
      }
    }
  }
}
```