user: What would the C source look like for the assembly code provided here:

```asm
<spotbounds>:
  endbr64
  push   %r15
  pxor   %xmm2,%xmm2
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  mov    %edx,%ebp
  push   %rbx
  mov    %r8,%rbx
  sub    $0x68,%rsp
  movq   $0x0,(%rcx)
  mov    %rdi,0x20(%rsp)
  mov    %esi,0x4c(%rsp)
  mov    %rcx,0x50(%rsp)
  movq   $0x0,(%r8)
  movsd  %xmm0,0x40(%rsp)
  movsd  %xmm1,0x58(%rsp)
  test   %esi,%esi
  jle    L31
  movslq %esi,%rax
  add    $0x8,%rdi
  movapd %xmm2,%xmm3
  xor    %esi,%esi
  mov    %rax,0x38(%rsp)
  lea    0x0(,%rax,8),%r13
  lea    -0x1(%rdx),%eax
  movapd %xmm2,%xmm1
  movsd  D0(%rip),%xmm7
  mov    %eax,0x48(%rsp)
  lea    (%rdi,%rax,8),%r15
  mov    %rdi,0x30(%rsp)
  movsd  %xmm7,0x8(%rsp)
  nopw   0x0(%rax,%rax,1)
L72:
  mov    0x20(%rsp),%rax
  test   %ebp,%ebp
  jle    L160
  nopl   0x0(%rax)
L256:
  mov    (%rax),%rdx
  movsd  (%rdx,%rsi,1),%xmm0
  comisd %xmm2,%xmm0
  jbe    L35
  addsd  %xmm0,%xmm1
  addsd  0x8(%rsp),%xmm3
L35:
  add    $0x8,%rax
  cmp    %r15,%rax
  jne    L256
L160:
  add    $0x8,%rsi
  cmp    %r13,%rsi
  jne    L72
  divsd  %xmm3,%xmm1
  xor    %r12d,%r12d
  movsd  %xmm2,0x10(%rsp)
  movsd  %xmm1,0x28(%rsp)
  nopl   (%rax)
L158:
  mov    0x20(%rsp),%r14
  test   %ebp,%ebp
  jle    L173
  nopl   0x0(%rax)
L190:
  mov    (%r14),%rax
  movsd  (%rax,%r12,1),%xmm0
  comisd %xmm2,%xmm0
  jbe    L231
  subsd  0x28(%rsp),%xmm0
  mov    D26(%rip),%rax
  movsd  %xmm3,0x18(%rsp)
  movq   %rax,%xmm1
  call   <pow@plt>
  pxor   %xmm0,%xmm0
  movsd  0x18(%rsp),%xmm3
  pxor   %xmm2,%xmm2
  cvtsi2sd %rax,%xmm0
  addsd  0x10(%rsp),%xmm0
  movsd  %xmm0,0x10(%rsp)
L231:
  add    $0x8,%r14
  cmp    %r15,%r14
  jne    L190
L173:
  add    $0x8,%r12
  cmp    %r13,%r12
  jne    L158
  subsd  0x8(%rsp),%xmm3
  movsd  0x10(%rsp),%xmm0
  divsd  %xmm3,%xmm0
  ucomisd %xmm0,%xmm2
  ja     L137
L187:
  sqrtsd %xmm0,%xmm0
  movsd  0x28(%rsp),%xmm1
  movslq 0x4c(%rsp),%rax
  mulsd  0x40(%rsp),%xmm0
  subsd  %xmm0,%xmm1
  movsd  %xmm1,(%rbx)
  test   %eax,%eax
  jle    L41
  mov    %rax,0x38(%rsp)
  lea    -0x1(%rbp),%eax
  movsd  D0(%rip),%xmm7
  mov    %eax,0x48(%rsp)
  mov    0x20(%rsp),%rax
  movsd  %xmm7,0x8(%rsp)
  add    $0x8,%rax
  mov    %rax,0x30(%rsp)
  mov    %rax,%rdi
L223:
  mov    0x38(%rsp),%r12
  mov    0x48(%rsp),%eax
  xor    %ecx,%ecx
  movapd %xmm2,%xmm3
  movapd %xmm2,%xmm4
  shl    $0x3,%r12
  lea    (%rdi,%rax,8),%r14
  nopw   0x0(%rax,%rax,1)
L174:
  mov    0x20(%rsp),%rax
  test   %ebp,%ebp
  jle    L83
  nopl   0x0(%rax)
L47:
  mov    (%rax),%rdx
  movsd  (%rdx,%rcx,1),%xmm0
  comisd %xmm2,%xmm0
  jbe    L91
  comisd %xmm0,%xmm1
  jb     L91
  addsd  %xmm0,%xmm4
  addsd  0x8(%rsp),%xmm3
L91:
  add    $0x8,%rax
  cmp    %rax,%r14
  jne    L47
L83:
  add    $0x8,%rcx
  cmp    %rcx,%r12
  jne    L174
  divsd  %xmm3,%xmm4
  xor    %r15d,%r15d
  movsd  %xmm2,0x10(%rsp)
  movsd  %xmm4,0x28(%rsp)
  nopl   0x0(%rax,%rax,1)
L53:
  mov    0x20(%rsp),%r13
  test   %ebp,%ebp
  jg     L163
  jmp    L265
  nopl   0x0(%rax,%rax,1)
L118:
  add    $0x8,%r13
  cmp    %r13,%r14
  je     L265
L163:
  mov    0x0(%r13),%rax
  movsd  (%rax,%r15,1),%xmm0
  comisd %xmm2,%xmm0
  jbe    L118
  movsd  (%rbx),%xmm1
  comisd %xmm0,%xmm1
  jb     L118
  subsd  0x28(%rsp),%xmm0
  mov    D26(%rip),%rax
  movsd  %xmm3,0x18(%rsp)
  add    $0x8,%r13
  movq   %rax,%xmm1
  call   <pow@plt>
  pxor   %xmm0,%xmm0
  movsd  0x18(%rsp),%xmm3
  pxor   %xmm2,%xmm2
  cvtsi2sd %rax,%xmm0
  addsd  0x10(%rsp),%xmm0
  movsd  %xmm0,0x10(%rsp)
  cmp    %r13,%r14
  jne    L163
  nopl   0x0(%rax,%rax,1)
L265:
  add    $0x8,%r15
  cmp    %r15,%r12
  jne    L53
  subsd  0x8(%rsp),%xmm3
  movsd  0x10(%rsp),%xmm0
  divsd  %xmm3,%xmm0
  ucomisd %xmm0,%xmm2
  ja     L1
L65:
  sqrtsd %xmm0,%xmm0
L215:
  mulsd  0x58(%rsp),%xmm0
  movsd  0x28(%rsp),%xmm1
  mov    0x50(%rsp),%rax
  subsd  %xmm0,%xmm1
  movsd  %xmm1,(%rax)
  add    $0x68,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L31:
  movapd %xmm2,%xmm7
  movsd  D53(%rip),%xmm0
  divsd  %xmm2,%xmm7
  movsd  %xmm7,0x28(%rsp)
  jmp    L187
L41:
  divsd  %xmm2,%xmm2
  movsd  D53(%rip),%xmm0
  movsd  %xmm2,0x28(%rsp)
  jmp    L65
L137:
  call   <sqrt@plt>
  mulsd  0x40(%rsp),%xmm0
  movsd  0x28(%rsp),%xmm1
  pxor   %xmm2,%xmm2
  mov    0x30(%rsp),%rdi
  subsd  %xmm0,%xmm1
  movsd  %xmm1,(%rbx)
  jmp    L223
L1:
  call   <sqrt@plt>
  jmp    L215
```

tool_calls: name: parse_data
arguments: tag: D0
type_infered: f64
name: parse_data
arguments: tag: D26
type_infered: f64
name: parse_data
arguments: tag: D53
type_infered: f32[2]

tool: D0: 1

tool: D26: 2

tool: {"D53": [0.0,-0.0]}

assistant: ```c
void spotbounds(double **cdat, int naxis1, int naxis2, double *umb, double *pen, double umb_sig, double pen_sig) {
  double mean, stdev;
  double smean, sstdev;
  int i, j;
  double counter;
  counter = 0.0;
  mean = smean = 0.0;
  stdev = sstdev = 0.0;
  *umb = 0.0;
  *pen = 0.0;
  for (i = 0; i < naxis1; i++) {
    for (j = 0; j < naxis2; j++) {
      if (cdat[j][i] > 0) {
        mean += cdat[j][i];
        counter++;
      }
    }
  }
  mean /= counter;
  for (i = 0; i < naxis1; i++) {
    for (j = 0; j < naxis2; j++) {
      if (cdat[j][i] > 0) {
        stdev += pow(cdat[j][i] - mean, 2.0);
      }
    }
  }
  stdev = sqrt(stdev / (counter - 1.0));
  *pen = mean - umb_sig * stdev;
  counter = 0.0;
  for (i = 0; i < naxis1; i++) {
    for (j = 0; j < naxis2; j++) {
      if ((cdat[j][i] > 0) && (cdat[j][i] <= *pen)) {
        smean += cdat[j][i];
        counter++;
      }
    }
  }
  smean /= counter;
  for (i = 0; i < naxis1; i++) {
    for (j = 0; j < naxis2; j++) {
      if ((cdat[j][i] > 0) && (cdat[j][i] <= *pen)) {
        sstdev += pow(cdat[j][i] - smean, 2.0);
      }
    }
  }
  sstdev = sqrt(sstdev / (counter - 1.0));
  *umb = smean - pen_sig * sstdev;
  return;
}
```