user: 这段汇编代码用C语言表示是什么样的：

```asm
<shrink_to_sigma_factor>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x28,%rsp
  mov    %rdi,%rbp
  mov    %rsi,%rbx
  mov    %rdx,%r12
  mov    %ecx,%r13d
  movsd  %xmm0,0x8(%rsp)
  movsd  %xmm1,0x10(%rsp)
  movapd %xmm1,%xmm3
  mulsd  %xmm0,%xmm3
  movapd %xmm3,%xmm0
  call   <ceil@plt>
  mov    %rax,0x18(%rsp)
  lea    -0x1(%rax,%rax,1),%eax
  mov    %eax,(%rbx)
  cmp    %r13d,%eax
  ja     L85
  test   $0x1,%r13b
  jne    L31
L85:
  lea    D19(%rip),%rsi
  mov    $0x4286,%edi
  call   <error_kernels@plt>
L31:
  mov    (%rbx),%esi
  mov    %esi,%r14d
  imul   %esi,%r14d
  imul   %esi,%r14d
  movsd  0x10(%rsp),%xmm0
  mulsd  %xmm0,%xmm0
  movsd  0x8(%rsp),%xmm4
  mulsd  %xmm4,%xmm0
  mulsd  %xmm4,%xmm0
  movsd  %xmm0,0x8(%rsp)
  mov    %r14,%rdx
  lea    D17(%rip),%rdi
  call   <printf@plt>
  mov    %r14,%rsi
  mov    %rbp,%rdi
  call   <do_vect@plt>
  mov    %r13d,%esi
  sub    (%rbx),%esi
  shr    %esi
  mov    %r13d,%r8d
  sub    %esi,%r8d
  cmp    %r8d,%esi
  jge    L140
  mov    %r13d,%eax
  imul   %r13d,%eax
  mov    %eax,0x10(%rsp)
  lea    0x1(%r13),%r14d
  imul   %r13d,%r14d
  imul   %esi,%r14d
  mov    %r8d,%r15d
  sub    %esi,%r15d
  mov    $0x0,%r10d
L0:
  mov    %r14d,%edi
  mov    %esi,%r11d
L2:
  mov    %r11d,%ecx
  mov    %esi,%edx
L94:
  mov    (%rbx),%r9d
  lea    (%rdi,%rdx,1),%eax
  movsd  (%r12,%rax,8),%xmm0
  mov    %r9d,%eax
  imul   %r10d,%eax
  sub    %esi,%eax
  add    %ecx,%eax
  imul   %r9d,%eax
  sub    %esi,%eax
  lea    (%rax,%rdx,1),%r9d
  mov    0x0(%rbp),%rax
  movsd  %xmm0,(%rax,%r9,8)
  add    $0x1,%edx
  cmp    %r8d,%edx
  jne    L94
  add    $0x1,%r11d
  add    %r13d,%edi
  cmp    %r8d,%r11d
  jne    L2
  add    $0x1,%r10d
  add    0x10(%rsp),%r14d
  cmp    %r15d,%r10d
  jne    L0
L140:
  mov    $0x0,%r11d
  mov    $0x1,%edi
  sub    0x18(%rsp),%edi
  cmpl   $0x0,(%rbx)
  jg     L71
L56:
  add    $0x28,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L121:
  add    $0x1,%edx
  mov    (%rbx),%ecx
  cmp    %edx,%ecx
  jle    L158
L51:
  lea    (%rdi,%rdx,1),%eax
  imul   %eax,%eax
  add    %esi,%eax
  add    %r8d,%eax
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  comisd 0x8(%rsp),%xmm0
  jbe    L121
  mov    %r12d,%eax
  imul   %ecx,%eax
  add    %r9d,%eax
  imul   %ecx,%eax
  lea    (%rax,%rdx,1),%ecx
  mov    0x0(%rbp),%rax
  movq   $0x0,(%rax,%rcx,8)
  jmp    L121
L158:
  add    $0x1,%r10d
  cmp    %r10d,(%rbx)
  jle    L86
L109:
  mov    (%rbx),%ecx
  test   %ecx,%ecx
  jle    L158
  mov    %r10d,%r9d
  lea    (%rdi,%r10,1),%esi
  imul   %esi,%esi
  mov    $0x0,%edx
  jmp    L51
L86:
  add    $0x1,%r11d
  cmp    %r11d,(%rbx)
  jle    L56
L71:
  cmpl   $0x0,(%rbx)
  jle    L86
  mov    %r11d,%r12d
  lea    (%rdi,%r11,1),%r8d
  imul   %r8d,%r8d
  mov    $0x0,%r10d
  jmp    L109
```

tool_calls: name: read_data
arguments: label: D19
type: string
name: read_data
arguments: label: D17
type: string

tool: D19: lib_vwk

tool: D17: lib_vwk> Generating kernel with %d^3 = %lu voxels.


assistant: ```c
void shrink_to_sigma_factor(double **outmap, unsigned *out_ext, double *inmap, unsigned in_ext, double sigmap, double sigma_factor) {
  int exth, indx, indy, indz;
  unsigned long nvox, index_old, index_new;
  unsigned margin;
  double cvalue, dsqu;
  char *program = "lib_vwk";
  exth = (int)ceil(sigma_factor * sigmap);
  *out_ext = 2 * exth - 1;
  if (*out_ext > in_ext || 2 * (in_ext / 2) == in_ext) {
    error_kernels(17030, program);
  }
  nvox = *out_ext * *out_ext * *out_ext;
  cvalue = sigma_factor * sigma_factor * sigmap * sigmap;
  printf("lib_vwk> Generating kernel with %d^3 = %lu voxels.\n", *out_ext, nvox);
  do_vect(outmap, nvox);
  margin = (in_ext - *out_ext) / 2;
  for (indz = margin; indz < (int)(in_ext - margin); indz++)
    for (indy = margin; indy < (int)(in_ext - margin); indy++)
      for (indx = margin; indx < (int)(in_ext - margin); indx++) {
        index_new = *out_ext * *out_ext * (indz - margin) + *out_ext * (indy - margin) + (indx - margin);
        index_old = in_ext * in_ext * indz + in_ext * indy + indx;
        *(*outmap + index_new) = *(inmap + index_old);
      }
  for (indz = 0; indz < (int)*out_ext; indz++)
    for (indy = 0; indy < (int)*out_ext; indy++)
      for (indx = 0; indx < (int)*out_ext; indx++) {
        index_new = (*out_ext) * (*out_ext) * indz + (*out_ext) * indy + indx;
        dsqu = (indx - exth + 1) * (indx - exth + 1) + (indy - exth + 1) * (indy - exth + 1) + (indz - exth + 1) * (indz - exth + 1);
        if (dsqu > cvalue)
          *(*outmap + index_new) = 0.0;
      }
}
```