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

```asm
<f3_corr>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x60,%rsp
  mov    %rdi,-0x58(%rbp)
  mov    %esi,-0x5c(%rbp)
  pxor   %xmm0,%xmm0
  movsd  %xmm0,-0x40(%rbp)
  pxor   %xmm0,%xmm0
  movsd  %xmm0,-0x28(%rbp)
  pxor   %xmm0,%xmm0
  movsd  %xmm0,-0x30(%rbp)
  pxor   %xmm0,%xmm0
  movsd  %xmm0,-0x20(%rbp)
  mov    -0x5c(%rbp),%eax
  mov    %eax,%esi
  mov    $0x0,%edi
  call   <allocate_vector@plt>
  mov    %rax,-0x18(%rbp)
  movl   $0x0,-0x48(%rbp)
  jmp    L91
L67:
  mov    -0x48(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  pxor   %xmm0,%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x48(%rbp)
L91:
  mov    -0x48(%rbp),%eax
  cmp    -0x5c(%rbp),%eax
  jl     L67
  movl   $0x0,-0x48(%rbp)
  jmp    L8
L104:
  movl   $0x0,-0x44(%rbp)
  jmp    L101
L113:
  mov    -0x48(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  mov    -0x48(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x44(%rbp),%eax
  cltq
  shl    $0x3,%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mov    -0x48(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  addsd  %xmm1,%xmm0
  movsd  %xmm0,(%rax)
  addl   $0x1,-0x44(%rbp)
L101:
  mov    -0x44(%rbp),%eax
  cmp    -0x5c(%rbp),%eax
  jl     L113
  addl   $0x1,-0x48(%rbp)
L8:
  mov    -0x48(%rbp),%eax
  cmp    -0x5c(%rbp),%eax
  jl     L104
  movl   $0x0,-0x48(%rbp)
  jmp    L18
L96:
  mov    -0x48(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  pxor   %xmm0,%xmm0
  cvtsi2sdl -0x48(%rbp),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  -0x30(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x30(%rbp)
  mov    -0x48(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm1
  pxor   %xmm0,%xmm0
  cvtsi2sdl -0x48(%rbp),%xmm0
  mulsd  %xmm0,%xmm1
  pxor   %xmm0,%xmm0
  cvtsi2sdl -0x48(%rbp),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  -0x40(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x40(%rbp)
  addl   $0x1,-0x48(%rbp)
L18:
  mov    -0x48(%rbp),%eax
  cmp    -0x5c(%rbp),%eax
  jl     L96
  movsd  -0x30(%rbp),%xmm0
  movsd  %xmm0,-0x20(%rbp)
  movsd  -0x40(%rbp),%xmm0
  movsd  %xmm0,-0x28(%rbp)
  movsd  -0x30(%rbp),%xmm0
  movapd %xmm0,%xmm1
  mulsd  %xmm0,%xmm1
  movsd  -0x40(%rbp),%xmm0
  subsd  %xmm1,%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  call   <sqrt@plt>
  movq   %xmm0,%rax
  mov    %rax,-0x10(%rbp)
  movsd  -0x10(%rbp),%xmm0
  movsd  %xmm0,-0x8(%rbp)
  pxor   %xmm0,%xmm0
  movsd  %xmm0,-0x38(%rbp)
  movl   $0x0,-0x48(%rbp)
  jmp    L95
L64:
  movl   $0x0,-0x44(%rbp)
  jmp    L19
L43:
  mov    -0x48(%rbp),%eax
  imul   -0x44(%rbp),%eax
  pxor   %xmm1,%xmm1
  cvtsi2sd %eax,%xmm1
  mov    -0x48(%rbp),%eax
  cltq
  lea    0x0(,%rax,8),%rdx
  mov    -0x58(%rbp),%rax
  add    %rdx,%rax
  mov    (%rax),%rdx
  mov    -0x44(%rbp),%eax
  cltq
  shl    $0x3,%rax
  add    %rdx,%rax
  movsd  (%rax),%xmm0
  mulsd  %xmm1,%xmm0
  movsd  -0x38(%rbp),%xmm1
  addsd  %xmm1,%xmm0
  movsd  %xmm0,-0x38(%rbp)
  addl   $0x1,-0x44(%rbp)
L19:
  mov    -0x44(%rbp),%eax
  cmp    -0x5c(%rbp),%eax
  jl     L43
  addl   $0x1,-0x48(%rbp)
L95:
  mov    -0x48(%rbp),%eax
  cmp    -0x5c(%rbp),%eax
  jl     L64
  mov    -0x18(%rbp),%rax
  mov    %rax,%rdi
  call   <free@plt>
  movsd  -0x30(%rbp),%xmm0
  movapd %xmm0,%xmm1
  mulsd  -0x20(%rbp),%xmm1
  movsd  -0x38(%rbp),%xmm0
  subsd  %xmm1,%xmm0
  movsd  -0x10(%rbp),%xmm1
  mulsd  -0x8(%rbp),%xmm1
  divsd  %xmm1,%xmm0
  movq   %xmm0,%rax
  movq   %rax,%xmm0
  leave
  ret
```

assistant: ```c
double f3_corr(double **P, int Ng) {
  int i, j;
  double sum_sqrx = 0, sum_sqry = 0, tmp, *px;
  double meanx = 0, meany = 0, stddevx, stddevy;
  px = allocate_vector(0, Ng);
  for (i = 0; i < Ng; ++i)
    px[i] = 0;
  for (i = 0; i < Ng; ++i)
    for (j = 0; j < Ng; ++j)
      px[i] += P[i][j];
  for (i = 0; i < Ng; ++i) {
    meanx += px[i] * i;
    sum_sqrx += px[i] * i * i;
  }
  meany = meanx;
  sum_sqry = sum_sqrx;
  stddevx = sqrt(sum_sqrx - (meanx * meanx));
  stddevy = stddevx;
  for (tmp = 0, i = 0; i < Ng; ++i)
    for (j = 0; j < Ng; ++j)
      tmp += i * j * P[i][j];
  free(px);
  return (tmp - meanx * meany) / (stddevx * stddevy);
}
```