user: 请从给定的汇编指令推导出C源代码：

```asm
<write_inner_products>:
  endbr64
  push   %rbp
  movslq %esi,%rax
  lea    0xf(,%rax,4),%rax
  mov    %rsp,%rbp
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  mov    %edx,%r12d
  push   %rbx
  sub    $0x58,%rsp
  mov    %edi,-0x48(%rbp)
  mov    %esi,-0x44(%rbp)
  mov    %rsp,%rcx
  mov    %fs:0x28,%rdx
  mov    %rdx,-0x38(%rbp)
  xor    %edx,%edx
  mov    %rax,%rdx
  and    $0xfffffffffffff000,%rax
  sub    %rax,%rcx
  and    $0xfffffffffffffff0,%rdx
  cmp    %rcx,%rsp
  je     L32
L247:
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  cmp    %rcx,%rsp
  jne    L247
L32:
  mov    %rdx,%rax
  and    $0xfff,%eax
  sub    %rax,%rsp
  test   %rax,%rax
  jne    L48
L43:
  movslq -0x48(%rbp),%rax
  mov    %rsp,%rcx
  mov    %rsp,%r13
  lea    0xf(,%rax,8),%rax
  mov    %rax,%rsi
  mov    %rax,%rdx
  and    $0xfffffffffffff000,%rsi
  and    $0xfffffffffffffff0,%rdx
  sub    %rsi,%rcx
  cmp    %rcx,%rsp
  je     L170
L105:
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  cmp    %rcx,%rsp
  jne    L105
L170:
  and    $0xfff,%edx
  sub    %rdx,%rsp
  test   %rdx,%rdx
  jne    L205
L175:
  mov    %rax,%rdx
  mov    %rsp,%rcx
  and    $0xfffffffffffff000,%rax
  mov    %rsp,-0x78(%rbp)
  sub    %rax,%rcx
  and    $0xfffffffffffffff0,%rdx
  cmp    %rcx,%rsp
  je     L24
L227:
  sub    $0x1000,%rsp
  orq    $0x0,0xff8(%rsp)
  cmp    %rcx,%rsp
  jne    L227
L24:
  mov    %rdx,%rax
  and    $0xfff,%eax
  sub    %rax,%rsp
  test   %rax,%rax
  je     L13
  orq    $0x0,-0x8(%rsp,%rax,1)
L13:
  mov    -0x78(%rbp),%rdx
  mov    -0x48(%rbp),%edi
  mov    %r12d,%esi
  mov    %rsp,%r15
  call   <celcon_get_inner_normal@plt>
  mov    %eax,-0x6c(%rbp)
  cmp    $0x1,%eax
  je     L243
  mov    %r12d,%esi
  lea    D39(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  mov    -0x48(%rbp),%esi
  test   %esi,%esi
  jle    L22
  mov    -0x78(%rbp),%rcx
  mov    -0x48(%rbp),%eax
  lea    D61(%rip),%rbx
  mov    %rcx,%r14
  lea    (%rcx,%rax,8),%r12
  nopl   (%rax)
L193:
  movsd  (%r14),%xmm0
  mov    %rbx,%rdi
  mov    $0x1,%eax
  add    $0x8,%r14
  call   <printf@plt>
  cmp    %r12,%r14
  jne    L193
L22:
  lea    D54(%rip),%rdi
  xor    %eax,%eax
  call   <printf@plt>
  lea    -0x39(%rbp),%rsi
  lea    D49(%rip),%rdi
  call   <scanf@plt>
  lea    D58(%rip),%rdi
  call   <puts@plt>
  lea    -0x44(%rbp),%rdi
  mov    %r13,%rsi
  call   <celcon_length_of_supports@plt>
  mov    -0x44(%rbp),%ecx
  mov    %eax,-0x6c(%rbp)
  test   %ecx,%ecx
  jle    L18
  mov    -0x48(%rbp),%eax
  mov    %r13,-0x68(%rbp)
  lea    D65(%rip),%rbx
  movl   $0x0,-0x58(%rbp)
  lea    -0x1(%rax),%ecx
  sub    $0x2,%eax
  mov    %ecx,-0x70(%rbp)
  lea    0x8(%r15,%rax,8),%r12
  nopw   0x0(%rax,%rax,1)
L139:
  mov    -0x58(%rbp),%r14d
  lea    D56(%rip),%rdi
  xor    %eax,%eax
  mov    %r14d,%esi
  call   <printf@plt>
  mov    %r14d,%eax
  mov    %r14d,-0x7c(%rbp)
  add    $0x1,%eax
  mov    %eax,-0x58(%rbp)
  mov    -0x68(%rbp),%rax
  mov    (%rax),%edx
  test   %edx,%edx
  jle    L99
  xor    %r13d,%r13d
  nopl   0x0(%rax,%rax,1)
L250:
  lea    0x1(%r13),%eax
  mov    -0x58(%rbp),%esi
  mov    -0x48(%rbp),%edi
  mov    %r15,%rcx
  mov    %eax,%edx
  mov    %eax,-0x54(%rbp)
  mov    %r15,%r14
  call   <celcon_get_lifted_point@plt>
  mov    %eax,-0x6c(%rbp)
  mov    -0x70(%rbp),%eax
  test   %eax,%eax
  jle    L171
  nopl   0x0(%rax)
L96:
  cvttsd2si (%r14),%esi
  mov    %rbx,%rdi
  xor    %eax,%eax
  add    $0x8,%r14
  call   <printf@plt>
  cmp    %r12,%r14
  jne    L96
L171:
  mov    -0x78(%rbp),%rsi
  mov    -0x48(%rbp),%edi
  mov    %r15,%rdx
  call   <inner_product@plt>
  lea    D4(%rip),%rdi
  mov    $0x1,%eax
  movsd  %xmm0,-0x50(%rbp)
  call   <printf@plt>
  test   %r13d,%r13d
  movsd  -0x50(%rbp),%xmm0
  jne    L162
  movsd  %xmm0,-0x60(%rbp)
  mov    $0x1,%r13d
L210:
  mov    -0x68(%rbp),%rax
  cmp    (%rax),%r13d
  jl     L250
L99:
  movsd  -0x60(%rbp),%xmm0
  mov    -0x7c(%rbp),%esi
  mov    $0x1,%eax
  lea    D20(%rip),%rdi
  call   <printf@plt>
  addq   $0x4,-0x68(%rbp)
  mov    -0x58(%rbp),%eax
  cmp    %eax,-0x44(%rbp)
  jg     L139
L18:
  mov    -0x38(%rbp),%rax
  sub    %fs:0x28,%rax
  jne    L226
  mov    -0x6c(%rbp),%eax
  lea    -0x28(%rbp),%rsp
  pop    %rbx
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  pop    %rbp
  ret
L48:
  orq    $0x0,-0x8(%rsp,%rax,1)
  jmp    L43
L205:
  orq    $0x0,-0x8(%rsp,%rdx,1)
  jmp    L175
  nopl   0x0(%rax)
L162:
  movsd  -0x60(%rbp),%xmm1
  comisd %xmm0,%xmm1
  jbe    L40
  mov    -0x54(%rbp),%r13d
  movsd  %xmm0,-0x60(%rbp)
  jmp    L210
  nopl   0x0(%rax)
L40:
  mov    -0x54(%rbp),%r13d
  jmp    L210
L243:
  lea    D68(%rip),%rdi
  call   <puts@plt>
  jmp    L18
L226:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: parse_data
arguments: tag: D39
type: string
name: parse_data
arguments: tag: D61
type: string
name: parse_data
arguments: tag: D54
type: string
name: parse_data
arguments: tag: D49
type: string
name: parse_data
arguments: tag: D58
type: string
name: parse_data
arguments: tag: D65
type: string
name: parse_data
arguments: tag: D56
type: string
name: parse_data
arguments: tag: D4
type: string
name: parse_data
arguments: tag: D20
type: string
name: parse_data
arguments: tag: D68
type: string

tool: D39: inner normal for cell %d :


tool: D61: %.15le


tool: D54: Hit enter to continue.

tool: D49: %c

tool: D58: 
computing the inner products with all points ...

tool: D65:  %d

tool: D56: support %d :


tool: D4:  : %.15le


tool: D20: -> support %d has minimal product : %.15le


tool: D68: an error happened...

assistant: ```c
int write_inner_products(int n, int r, int k) {
  int fail, i, j, kk;
  int nl[r];
  double normal[n], point[n], prod, minprod;
  char ch;
  fail = celcon_get_inner_normal(n, k, normal);
  if (fail == 1)
    printf("an error happened...\n");
  else {
    printf("inner normal for cell %d :\n", k);
    for (i = 0; i < n; i++)
      printf("%.15le\n", normal[i]);
    printf("Hit enter to continue.");
    scanf("%c", &ch);
    printf("\ncomputing the inner products with all points ...\n");
    fail = celcon_length_of_supports(&r, nl);
    for (i = 0; i < r; i++) {
      printf("support %d :\n", i);
      for (j = 0; j < nl[i]; j++) {
        fail = celcon_get_lifted_point(n, i + 1, j + 1, point);
        for (kk = 0; kk < n - 1; kk++)
          printf(" %d", (int)point[kk]);
        prod = inner_product(n, normal, point);
        printf(" : %.15le\n", prod);
        if (j == 0)
          minprod = prod;
        else if (prod < minprod)
          minprod = prod;
      }
      printf("-> support %d has minimal product : %.15le\n", i, minprod);
    }
  }
  return fail;
}
```