user: Converte this assembly snippet into its equivalent C code:

```asm
<convert>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %r15
  mov    %edx,%r15d
  push   %r14
  lea    -0x1(%r15),%ecx
  mov    %rsi,%r14
  push   %r13
  movslq %ecx,%r13
  push   %r12
  lea    0x0(,%r13,8),%r8
  mov    %rdi,%r12
  push   %rbx
  sub    $0x38,%rsp
  mov    %fs:0x28,%rdx
  mov    %rdx,-0x38(%rbp)
  xor    %edx,%edx
  lea    0xf(%r8),%rdx
  mov    %rsp,%rdi
  mov    %rdx,%rsi
  and    $0xfffffffffffff000,%rdx
  sub    %rdx,%rdi
  and    $0xfffffffffffffff0,%rsi
  cmp    %rdi,%rsp
  je     L106
L79:
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  cmp    %rdi,%rsp
  jne    L79
L106:
  and    $0xfff,%esi
  sub    %rsi,%rsp
  test   %rsi,%rsi
  jne    L41
L77:
  lea    0x7(%rsp),%rbx
  mov    %rbx,%rax
  and    $0xfffffffffffffff8,%rbx
  shr    $0x3,%rax
  mov    %rax,-0x58(%rbp)
  cmp    $0x1,%r15d
  jne    L94
  movsd  (%r14),%xmm0
  movsd  %xmm0,(%r12)
L119:
  mov    -0x38(%rbp),%rax
  sub    %fs:0x28,%rax
  jne    L35
  lea    -0x28(%rbp),%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
  nopw   0x0(%rax,%rax,1)
L94:
  mov    %ecx,%edx
  mov    %r14,%rsi
  mov    %rbx,%rdi
  mov    %r8,-0x50(%rbp)
  mov    %ecx,-0x44(%rbp)
  call   <convert>
  mov    -0x58(%rbp),%rax
  mov    -0x44(%rbp),%ecx
  lea    -0x2(%r15),%esi
  mov    -0x50(%rbp),%r8
  movsd  0x0(,%rax,8),%xmm0
  lea    (%r14,%r8,1),%rdx
  lea    0x8(%r8),%rdi
  movapd %xmm0,%xmm1
  xorpd  D0(%rip),%xmm1
  mulsd  (%rdx),%xmm1
  movsd  %xmm1,(%r12)
  cmp    $0x1,%ecx
  jle    L31
  lea    (%r12,%rcx,8),%rcx
  lea    0x8(%r12),%r8
  cmp    %rcx,%rdx
  setae  %cl
  add    %rdi,%r14
  cmp    %r14,%r8
  setae  %dil
  or     %dil,%cl
  je     L50
  cmp    $0x3,%r15d
  je     L50
  mov    %esi,%eax
  movsd  (%rdx),%xmm2
  shr    %eax
  lea    -0x1(%rax),%ecx
  unpcklpd %xmm2,%xmm2
  mov    $0x8,%eax
  shl    $0x4,%rcx
  add    $0x18,%rcx
  nopl   0x0(%rax,%rax,1)
L114:
  movupd (%rbx,%rax,1),%xmm1
  movupd -0x8(%rbx,%rax,1),%xmm0
  mulpd  %xmm2,%xmm1
  subpd  %xmm1,%xmm0
  movups %xmm0,(%r12,%rax,1)
  add    $0x10,%rax
  cmp    %rax,%rcx
  jne    L114
  mov    %esi,%ecx
  mov    %esi,%eax
  and    $0xfffffffe,%ecx
  or     $0x1,%eax
  test   $0x1,%sil
  je     L31
  cltq
  movslq %ecx,%rcx
  movsd  (%rbx,%rax,8),%xmm1
  mulsd  (%rdx),%xmm1
  movsd  (%rbx,%rcx,8),%xmm0
  subsd  %xmm1,%xmm0
  movsd  %xmm0,(%r12,%rax,8)
L31:
  movslq %esi,%rsi
  movsd  (%rbx,%rsi,8),%xmm0
  movsd  %xmm0,(%r12,%r13,8)
  jmp    L119
  nopl   0x0(%rax)
L41:
  orq    $0x0,-0x8(%rsp,%rsi,1)
  jmp    L77
  nopl   0x0(%rax,%rax,1)
L50:
  lea    -0x3(%r15),%ecx
  mov    $0x1,%eax
  add    $0x2,%rcx
  nopl   (%rax)
L13:
  movsd  (%rdx),%xmm2
  movapd %xmm0,%xmm1
  movsd  (%rbx,%rax,8),%xmm0
  mulsd  %xmm0,%xmm2
  subsd  %xmm2,%xmm1
  movsd  %xmm1,(%r12,%rax,8)
  add    $0x1,%rax
  cmp    %rcx,%rax
  jne    L13
  jmp    L31
L35:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: retrieve_data
arguments: label: D0
type: byte[16]

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

assistant: ```c
void convert(double a[], double b[], int n) {
  int i;
  double c[n - 1];
  if (n == 1)
    a[0] = b[0];
  else {
    convert(c, b, n - 1);
    a[0] = -c[0] * b[n - 1];
    for (i = 1; i < n - 1; i++)
      a[i] = c[i - 1] - c[i] * b[n - 1];
    a[n - 1] = c[n - 2];
  }
}
```