user: Translate the below assembly code into C programming language:

```asm
<NormalizeVector>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  mov    %edi,%r12d
  push   %rbp
  mov    %rsi,%rbp
  push   %rbx
  sub    $0x28,%rsp
  test   %rdx,%rdx
  je     L147
  test   %edi,%edi
  jle    L122
  pxor   %xmm2,%xmm2
  mov    %rdx,%r13
  movslq %edi,%r14
  xor    %ebx,%ebx
  movq   %xmm2,%r15
  movsd  %xmm2,0x8(%rsp)
L0:
  movsd  0x0(%r13,%rbx,8),%xmm1
  movsd  0x0(%rbp,%rbx,8),%xmm0
  mov    $0x2,%edi
  add    $0x1,%rbx
  movapd %xmm1,%xmm3
  movsd  %xmm1,0x18(%rsp)
  mulsd  %xmm0,%xmm3
  addsd  %xmm3,%xmm2
  movsd  %xmm2,0x10(%rsp)
  call   <pow@plt>
  movsd  0x18(%rsp),%xmm1
  cmp    %r14,%rbx
  movsd  0x10(%rsp),%xmm2
  mulsd  %xmm0,%xmm1
  addsd  0x8(%rsp),%xmm1
  movsd  %xmm1,0x8(%rsp)
  jne    L0
L62:
  movapd %xmm2,%xmm0
  mov    $0x2,%edi
  movsd  %xmm2,0x10(%rsp)
  call   <pow@plt>
  movq   %r15,%xmm6
  movsd  0x10(%rsp),%xmm2
  movapd %xmm0,%xmm1
  movsd  0x8(%rsp),%xmm0
  subsd  %xmm1,%xmm0
  ucomisd %xmm0,%xmm6
  ja     L55
  sqrtsd %xmm0,%xmm0
L77:
  test   %r12d,%r12d
  jle    L127
  cmp    $0x1,%r12d
  je     L45
  mov    %r12d,%edx
  movapd %xmm2,%xmm4
  movapd %xmm0,%xmm3
  mov    %rbp,%rax
  shr    %edx
  unpcklpd %xmm4,%xmm4
  unpcklpd %xmm3,%xmm3
  sub    $0x1,%edx
  shl    $0x4,%rdx
  lea    0x10(%rbp,%rdx,1),%rdx
  nopw   0x0(%rax,%rax,1)
L21:
  movupd (%rax),%xmm1
  add    $0x10,%rax
  subpd  %xmm4,%xmm1
  divpd  %xmm3,%xmm1
  movups %xmm1,-0x10(%rax)
  cmp    %rax,%rdx
  jne    L21
  mov    %r12d,%eax
  and    $0xfffffffe,%eax
  and    $0x1,%r12d
  je     L127
L64:
  cltq
  lea    0x0(%rbp,%rax,8),%rax
  movsd  (%rax),%xmm1
  subsd  %xmm2,%xmm1
  divsd  %xmm0,%xmm1
  movsd  %xmm1,(%rax)
L127:
  add    $0x28,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax,%rax,1)
L147:
  test   %edi,%edi
  jle    L96
  pxor   %xmm7,%xmm7
  lea    -0x1(%rdi),%eax
  mov    %rsi,%rbx
  lea    0x8(%rsi,%rax,8),%r13
  movq   %xmm7,%r15
  movapd %xmm7,%xmm1
  movapd %xmm7,%xmm2
  nopl   0x0(%rax)
L137:
  movsd  (%rbx),%xmm0
  mov    $0x2,%edi
  movsd  %xmm1,0x10(%rsp)
  add    $0x8,%rbx
  addsd  %xmm0,%xmm2
  movsd  %xmm2,0x8(%rsp)
  call   <pow@plt>
  movsd  0x10(%rsp),%xmm1
  cmp    %r13,%rbx
  movsd  0x8(%rsp),%xmm2
  addsd  %xmm0,%xmm1
  jne    L137
L17:
  pxor   %xmm0,%xmm0
  cvtsi2sd %r12d,%xmm0
  divsd  %xmm0,%xmm1
  divsd  %xmm0,%xmm2
  movsd  %xmm1,0x8(%rsp)
  jmp    L62
L45:
  xor    %eax,%eax
  jmp    L64
L122:
  pxor   %xmm2,%xmm2
  movq   %xmm2,%r15
  movsd  %xmm2,0x8(%rsp)
  jmp    L62
L96:
  pxor   %xmm7,%xmm7
  movq   %xmm7,%r15
  movapd %xmm7,%xmm1
  movapd %xmm7,%xmm2
  jmp    L17
L55:
  movsd  %xmm2,0x8(%rsp)
  call   <sqrt@plt>
  movsd  0x8(%rsp),%xmm2
  jmp    L77
```

assistant: ```c
void NormalizeVector(int const size, double vector[], double prob_vec[]) {
  int i;
  double mean = 0;
  double stdev = 0;
  if (prob_vec == NULL) {
    for (i = 0; i < size; i++) {
      mean += vector[i];
      stdev += pow(vector[i], 2);
    }
    mean /= (double)size;
    stdev /= (double)size;
  } else {
    for (i = 0; i < size; i++) {
      mean += prob_vec[i] * vector[i];
      stdev += prob_vec[i] * pow(vector[i], 2);
    }
  }
  stdev = sqrt(stdev - pow(mean, 2));
  for (i = 0; i < size; i++)
    vector[i] = (vector[i] - mean) / stdev;
}
```