user: What is the c source code of the assembly code below:

```asm
<powspec2d>:
  endbr64
  push   %r15
  mov    %rsi,%r15
  push   %r14
  mov    %rdi,%r14
  push   %r13
  mov    %rdx,%r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x68,%rsp
  cmp    %ecx,%r8d
  mov    %ecx,0x8(%rsp)
  cmovle %r8d,%ecx
  mov    %r8d,(%rsp)
  mov    %ecx,%ebx
  mov    %ecx,0x14(%rsp)
  mov    %ecx,%r12d
  shr    $0x1f,%ebx
  add    %ecx,%ebx
  sar    %ebx
  lea    0x1(%rbx),%edi
  movslq %edi,%rdi
  shl    $0x2,%rdi
  call   <malloc@plt>
  mov    %rax,%rbp
  cmp    $0xffffffff,%r12d
  jl     L327
  xor    %r12d,%r12d
  test   %ebx,%ebx
  mov    %r13,%rdi
  cmovns %ebx,%r12d
  xor    %esi,%esi
  add    $0x1,%r12d
  movslq %r12d,%r12
  shl    $0x2,%r12
  mov    %r12,%rdx
  call   <memset@plt>
  mov    %r12,%rdx
  xor    %esi,%esi
  mov    %rbp,%rdi
  call   <memset@plt>
L327:
  mov    0x8(%rsp),%esi
  mov    %esi,%eax
  shr    $0x1f,%eax
  add    %esi,%eax
  sar    %eax
  mov    %eax,0x10(%rsp)
  cmp    $0x1,%esi
  jle    L21
  mov    (%rsp),%eax
  mov    %eax,%r8d
  shr    $0x1f,%r8d
  add    %eax,%r8d
  sar    %r8d
  cmp    $0x1,%eax
  jle    L379
  movslq 0x8(%rsp),%rdi
  mov    0x10(%rsp),%r9d
  xor    %r10d,%r10d
  pxor   %xmm3,%xmm3
  movss  D19(%rip),%xmm1
  movsd  D209(%rip),%xmm2
  movss  D11(%rip),%xmm4
  movss  D7(%rip),%xmm6
  shl    $0x2,%rdi
  nopl   0x0(%rax,%rax,1)
L84:
  lea    0x0(,%r10,4),%rdx
  mov    %r10d,%esi
  xor    %r12d,%r12d
  imul   %r10d,%esi
  lea    (%r14,%rdx,1),%rcx
  add    %r15,%rdx
  jmp    L350
  nopl   0x0(%rax,%rax,1)
L396:
  cvttss2si %xmm7,%eax
L442:
  movss  (%rcx),%xmm0
  movss  (%rdx),%xmm5
  cmp    %ebx,%eax
  cmovg  %ebx,%eax
  add    $0x1,%r12d
  add    %rdi,%rcx
  add    %rdi,%rdx
  mulss  %xmm0,%xmm0
  cltq
  mulss  %xmm5,%xmm5
  shl    $0x2,%rax
  lea    0x0(%r13,%rax,1),%r11
  addl   $0x1,0x0(%rbp,%rax,1)
  addss  %xmm5,%xmm0
  addss  (%r11),%xmm0
  movss  %xmm0,(%r11)
  cmp    %r8d,%r12d
  jge    L75
L350:
  mov    %r12d,%eax
  pxor   %xmm0,%xmm0
  imul   %r12d,%eax
  add    %esi,%eax
  cvtsi2ss %eax,%xmm0
  ucomiss %xmm0,%xmm3
  ja     L98
  sqrtss %xmm0,%xmm0
L456:
  movaps %xmm0,%xmm5
  movaps %xmm0,%xmm7
  andps  %xmm4,%xmm5
  ucomiss %xmm5,%xmm1
  jbe    L244
  cvttss2si %xmm0,%eax
  pxor   %xmm5,%xmm5
  cvtsi2ss %eax,%xmm5
  movaps %xmm5,%xmm7
  cmpnless %xmm0,%xmm7
  andps  %xmm6,%xmm7
  subss  %xmm7,%xmm5
  movaps %xmm4,%xmm7
  andnps %xmm0,%xmm7
  orps   %xmm5,%xmm7
L244:
  pxor   %xmm5,%xmm5
  pxor   %xmm8,%xmm8
  cvtss2sd %xmm0,%xmm5
  cvtss2sd %xmm7,%xmm8
  subsd  %xmm8,%xmm5
  comisd %xmm5,%xmm2
  ja     L396
  movaps %xmm0,%xmm5
  andps  %xmm4,%xmm5
  ucomiss %xmm5,%xmm1
  jbe    L304
  cvttss2si %xmm0,%eax
  pxor   %xmm5,%xmm5
  movaps %xmm0,%xmm7
  cvtsi2ss %eax,%xmm5
  cmpnless %xmm5,%xmm7
  andps  %xmm6,%xmm7
  addss  %xmm7,%xmm5
  movaps %xmm4,%xmm7
  andnps %xmm0,%xmm7
  movaps %xmm5,%xmm0
  orps   %xmm7,%xmm0
L304:
  cvttss2si %xmm0,%eax
  jmp    L442
  cs nopw 0x0(%rax,%rax,1)
L75:
  add    $0x1,%r10
  cmp    %r10d,%r9d
  jg     L84
L379:
  cmp    %r8d,(%rsp)
  jle    L21
  movslq 0x8(%rsp),%rdi
  xor    %r10d,%r10d
  pxor   %xmm3,%xmm3
  movss  D19(%rip),%xmm1
  movsd  D209(%rip),%xmm2
  movss  D7(%rip),%xmm6
  movss  D11(%rip),%xmm4
  mov    %edi,%r11d
  shl    $0x2,%rdi
  imul   %r8d,%r11d
  movslq %r11d,%r11
  shl    $0x2,%r11
  nopl   (%rax)
L192:
  mov    %r10d,%r9d
  lea    (%r14,%r11,1),%rcx
  lea    (%r15,%r11,1),%rdx
  mov    %r8d,%r12d
  imul   %r10d,%r9d
  sub    (%rsp),%r12d
  jmp    L130
L364:
  cvttss2si %xmm7,%eax
L131:
  movss  (%rcx),%xmm0
  movss  (%rdx),%xmm5
  cmp    %ebx,%eax
  cmovg  %ebx,%eax
  add    %rdi,%rcx
  add    %rdi,%rdx
  mulss  %xmm0,%xmm0
  cltq
  mulss  %xmm5,%xmm5
  shl    $0x2,%rax
  lea    0x0(%r13,%rax,1),%rsi
  addl   $0x1,0x0(%rbp,%rax,1)
  addss  %xmm5,%xmm0
  addss  (%rsi),%xmm0
  movss  %xmm0,(%rsi)
  add    $0x1,%r12d
  je     L294
L130:
  mov    %r12d,%eax
  pxor   %xmm0,%xmm0
  imul   %r12d,%eax
  add    %r9d,%eax
  cvtsi2ss %eax,%xmm0
  ucomiss %xmm0,%xmm3
  ja     L121
  sqrtss %xmm0,%xmm0
L0:
  movaps %xmm0,%xmm5
  movaps %xmm0,%xmm7
  andps  %xmm4,%xmm5
  ucomiss %xmm5,%xmm1
  jbe    L453
  cvttss2si %xmm0,%eax
  pxor   %xmm5,%xmm5
  cvtsi2ss %eax,%xmm5
  movaps %xmm5,%xmm7
  cmpnless %xmm0,%xmm7
  andps  %xmm6,%xmm7
  subss  %xmm7,%xmm5
  movaps %xmm4,%xmm7
  andnps %xmm0,%xmm7
  orps   %xmm5,%xmm7
L453:
  pxor   %xmm5,%xmm5
  pxor   %xmm8,%xmm8
  cvtss2sd %xmm0,%xmm5
  cvtss2sd %xmm7,%xmm8
  subsd  %xmm8,%xmm5
  comisd %xmm5,%xmm2
  ja     L364
  movaps %xmm0,%xmm5
  andps  %xmm4,%xmm5
  ucomiss %xmm5,%xmm1
  jbe    L156
  cvttss2si %xmm0,%eax
  pxor   %xmm5,%xmm5
  movaps %xmm0,%xmm7
  cvtsi2ss %eax,%xmm5
  cmpnless %xmm5,%xmm7
  andps  %xmm6,%xmm7
  addss  %xmm7,%xmm5
  movaps %xmm4,%xmm7
  andnps %xmm0,%xmm7
  movaps %xmm5,%xmm0
  orps   %xmm7,%xmm0
L156:
  cvttss2si %xmm0,%eax
  jmp    L131
  nopw   0x0(%rax,%rax,1)
L294:
  add    $0x1,%r10d
  add    $0x4,%r11
  cmp    0x10(%rsp),%r10d
  jl     L192
L21:
  mov    0x10(%rsp),%ecx
  cmp    %ecx,0x8(%rsp)
  jle    L97
  mov    (%rsp),%eax
  mov    %eax,%r8d
  shr    $0x1f,%r8d
  add    %eax,%r8d
  sar    %r8d
  cmp    %r8d,%eax
  jle    L11
  movslq 0x8(%rsp),%rdi
  movslq %ecx,%rax
  movss  D19(%rip),%xmm1
  pxor   %xmm3,%xmm3
  mov    %eax,%r10d
  movsd  D209(%rip),%xmm2
  movss  D7(%rip),%xmm6
  movss  D11(%rip),%xmm4
  mov    %edi,%r11d
  sub    %edi,%r10d
  shl    $0x2,%rdi
  imul   %r8d,%r11d
  movslq %r11d,%r11
  add    %rax,%r11
  shl    $0x2,%r11
  nopl   0x0(%rax)
L149:
  mov    %r10d,%r9d
  lea    (%r14,%r11,1),%rcx
  lea    (%r15,%r11,1),%rdx
  mov    %r8d,%r12d
  imul   %r10d,%r9d
  sub    (%rsp),%r12d
  jmp    L207
  nopl   0x0(%rax,%rax,1)
L123:
  cvttss2si %xmm7,%eax
L295:
  movss  (%rcx),%xmm0
  movss  (%rdx),%xmm5
  cmp    %ebx,%eax
  cmovg  %ebx,%eax
  add    %rdi,%rcx
  add    %rdi,%rdx
  mulss  %xmm0,%xmm0
  cltq
  mulss  %xmm5,%xmm5
  shl    $0x2,%rax
  lea    0x0(%r13,%rax,1),%rsi
  addl   $0x1,0x0(%rbp,%rax,1)
  addss  %xmm5,%xmm0
  addss  (%rsi),%xmm0
  movss  %xmm0,(%rsi)
  add    $0x1,%r12d
  je     L260
L207:
  mov    %r12d,%eax
  pxor   %xmm0,%xmm0
  imul   %r12d,%eax
  add    %r9d,%eax
  cvtsi2ss %eax,%xmm0
  ucomiss %xmm0,%xmm3
  ja     L247
  sqrtss %xmm0,%xmm0
L265:
  movaps %xmm0,%xmm5
  movaps %xmm0,%xmm7
  andps  %xmm4,%xmm5
  ucomiss %xmm5,%xmm1
  jbe    L213
  cvttss2si %xmm0,%eax
  pxor   %xmm5,%xmm5
  cvtsi2ss %eax,%xmm5
  movaps %xmm5,%xmm7
  cmpnless %xmm0,%xmm7
  andps  %xmm6,%xmm7
  subss  %xmm7,%xmm5
  movaps %xmm4,%xmm7
  andnps %xmm0,%xmm7
  orps   %xmm5,%xmm7
L213:
  pxor   %xmm5,%xmm5
  pxor   %xmm8,%xmm8
  cvtss2sd %xmm0,%xmm5
  cvtss2sd %xmm7,%xmm8
  subsd  %xmm8,%xmm5
  comisd %xmm5,%xmm2
  ja     L123
  movaps %xmm0,%xmm5
  andps  %xmm4,%xmm5
  ucomiss %xmm5,%xmm1
  jbe    L435
  cvttss2si %xmm0,%eax
  pxor   %xmm5,%xmm5
  movaps %xmm0,%xmm7
  cvtsi2ss %eax,%xmm5
  cmpnless %xmm5,%xmm7
  andps  %xmm6,%xmm7
  addss  %xmm7,%xmm5
  movaps %xmm4,%xmm7
  andnps %xmm0,%xmm7
  movaps %xmm5,%xmm0
  orps   %xmm7,%xmm0
L435:
  cvttss2si %xmm0,%eax
  jmp    L295
  nopw   0x0(%rax,%rax,1)
L260:
  add    $0x4,%r11
  add    $0x1,%r10d
  jne    L149
L11:
  cmpl   $0x1,(%rsp)
  jle    L97
  movslq 0x10(%rsp),%r10
  movslq 0x8(%rsp),%rdi
  pxor   %xmm3,%xmm3
  movss  D11(%rip),%xmm4
  movss  D19(%rip),%xmm1
  movsd  D209(%rip),%xmm2
  mov    %r10d,%r9d
  movss  D7(%rip),%xmm6
  shl    $0x2,%r10
  sub    %edi,%r9d
  shl    $0x2,%rdi
  nopl   0x0(%rax)
L245:
  mov    %r9d,%esi
  lea    (%r14,%r10,1),%rcx
  lea    (%r15,%r10,1),%rdx
  xor    %r12d,%r12d
  imul   %r9d,%esi
  jmp    L43
  nopl   0x0(%rax)
L383:
  cvttss2si %xmm7,%eax
L105:
  movss  (%rcx),%xmm0
  movss  (%rdx),%xmm5
  cmp    %ebx,%eax
  cmovg  %ebx,%eax
  add    $0x1,%r12d
  add    %rdi,%rcx
  add    %rdi,%rdx
  mulss  %xmm0,%xmm0
  cltq
  mulss  %xmm5,%xmm5
  shl    $0x2,%rax
  lea    0x0(%r13,%rax,1),%r11
  addl   $0x1,0x0(%rbp,%rax,1)
  addss  %xmm5,%xmm0
  addss  (%r11),%xmm0
  movss  %xmm0,(%r11)
  cmp    %r8d,%r12d
  jge    L132
L43:
  mov    %r12d,%eax
  pxor   %xmm0,%xmm0
  imul   %r12d,%eax
  add    %esi,%eax
  cvtsi2ss %eax,%xmm0
  ucomiss %xmm0,%xmm3
  ja     L444
  sqrtss %xmm0,%xmm0
L157:
  movaps %xmm0,%xmm5
  movaps %xmm0,%xmm7
  andps  %xmm4,%xmm5
  ucomiss %xmm5,%xmm1
  jbe    L173
  cvttss2si %xmm0,%eax
  pxor   %xmm5,%xmm5
  cvtsi2ss %eax,%xmm5
  movaps %xmm5,%xmm7
  cmpnless %xmm0,%xmm7
  andps  %xmm6,%xmm7
  subss  %xmm7,%xmm5
  movaps %xmm4,%xmm7
  andnps %xmm0,%xmm7
  orps   %xmm5,%xmm7
L173:
  pxor   %xmm5,%xmm5
  pxor   %xmm8,%xmm8
  cvtss2sd %xmm0,%xmm5
  cvtss2sd %xmm7,%xmm8
  subsd  %xmm8,%xmm5
  comisd %xmm5,%xmm2
  ja     L383
  movaps %xmm0,%xmm5
  andps  %xmm4,%xmm5
  ucomiss %xmm5,%xmm1
  jbe    L37
  cvttss2si %xmm0,%eax
  pxor   %xmm5,%xmm5
  movaps %xmm0,%xmm7
  cvtsi2ss %eax,%xmm5
  cmpnless %xmm5,%xmm7
  andps  %xmm6,%xmm7
  addss  %xmm7,%xmm5
  movaps %xmm4,%xmm7
  andnps %xmm0,%xmm7
  movaps %xmm5,%xmm0
  orps   %xmm7,%xmm0
L37:
  cvttss2si %xmm0,%eax
  jmp    L105
  xchg   %ax,%ax
L132:
  add    $0x4,%r10
  add    $0x1,%r9d
  jne    L245
L97:
  xor    %eax,%eax
  cmpl   $0xffffffff,0x14(%rsp)
  jl     L283
  nopw   0x0(%rax,%rax,1)
L19:
  mov    0x0(%rbp,%rax,4),%edx
  test   %edx,%edx
  je     L286
  pxor   %xmm0,%xmm0
  pxor   %xmm1,%xmm1
  cvtsi2ss %eax,%xmm0
  mulss  0x0(%r13,%rax,4),%xmm0
  cvtsi2ss %edx,%xmm1
  divss  %xmm1,%xmm0
  movss  %xmm0,0x0(%r13,%rax,4)
L286:
  add    $0x1,%rax
  cmp    %eax,%ebx
  jge    L19
L283:
  add    $0x68,%rsp
  mov    %rbp,%rdi
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  jmp    1080 <free@plt>
L98:
  mov    %r8d,0x48(%rsp)
  mov    %r9d,0x40(%rsp)
  mov    %rcx,0x38(%rsp)
  mov    %rdi,0x30(%rsp)
  mov    %rdx,0x28(%rsp)
  mov    %r10,0x20(%rsp)
  mov    %esi,0x18(%rsp)
  movsd  %xmm2,0x58(%rsp)
  movss  %xmm1,0x54(%rsp)
  movss  %xmm3,0x50(%rsp)
  call   <sqrtf@plt>
  movsd  0x58(%rsp),%xmm2
  movss  0x54(%rsp),%xmm1
  movss  0x50(%rsp),%xmm3
  mov    0x48(%rsp),%r8d
  mov    0x40(%rsp),%r9d
  mov    0x38(%rsp),%rcx
  mov    0x30(%rsp),%rdi
  mov    0x28(%rsp),%rdx
  mov    0x20(%rsp),%r10
  mov    0x18(%rsp),%esi
  movss  D7(%rip),%xmm6
  movss  D11(%rip),%xmm4
  jmp    L456
L444:
  mov    %r8d,0x30(%rsp)
  mov    %rdx,0x28(%rsp)
  mov    %r9d,0x20(%rsp)
  mov    %r10,0x18(%rsp)
  mov    %rdi,0x8(%rsp)
  mov    %esi,0x10(%rsp)
  mov    %rcx,(%rsp)
  movsd  %xmm2,0x48(%rsp)
  movss  %xmm1,0x40(%rsp)
  movss  %xmm3,0x38(%rsp)
  call   <sqrtf@plt>
  movsd  0x48(%rsp),%xmm2
  movss  0x40(%rsp),%xmm1
  movss  0x38(%rsp),%xmm3
  mov    0x30(%rsp),%r8d
  mov    0x28(%rsp),%rdx
  mov    0x20(%rsp),%r9d
  mov    0x18(%rsp),%r10
  mov    0x8(%rsp),%rdi
  mov    0x10(%rsp),%esi
  mov    (%rsp),%rcx
  movss  D7(%rip),%xmm6
  movss  D11(%rip),%xmm4
  jmp    L157
L247:
  mov    %r8d,0x48(%rsp)
  mov    %rcx,0x40(%rsp)
  mov    %rdi,0x38(%rsp)
  mov    %rdx,0x30(%rsp)
  mov    %r10d,0x28(%rsp)
  mov    %r11,0x20(%rsp)
  mov    %r9d,0x18(%rsp)
  movsd  %xmm2,0x58(%rsp)
  movss  %xmm1,0x54(%rsp)
  movss  %xmm3,0x50(%rsp)
  call   <sqrtf@plt>
  movsd  0x58(%rsp),%xmm2
  movss  0x54(%rsp),%xmm1
  movss  0x50(%rsp),%xmm3
  mov    0x48(%rsp),%r8d
  mov    0x40(%rsp),%rcx
  mov    0x38(%rsp),%rdi
  mov    0x30(%rsp),%rdx
  mov    0x28(%rsp),%r10d
  mov    0x20(%rsp),%r11
  mov    0x18(%rsp),%r9d
  movss  D7(%rip),%xmm6
  movss  D11(%rip),%xmm4
  jmp    L265
L121:
  mov    %r8d,0x48(%rsp)
  mov    %rcx,0x40(%rsp)
  mov    %rdi,0x38(%rsp)
  mov    %rdx,0x30(%rsp)
  mov    %r11,0x28(%rsp)
  mov    %r10d,0x20(%rsp)
  mov    %r9d,0x18(%rsp)
  movsd  %xmm2,0x58(%rsp)
  movss  %xmm1,0x54(%rsp)
  movss  %xmm3,0x50(%rsp)
  call   <sqrtf@plt>
  movsd  0x58(%rsp),%xmm2
  movss  0x54(%rsp),%xmm1
  movss  0x50(%rsp),%xmm3
  mov    0x48(%rsp),%r8d
  mov    0x40(%rsp),%rcx
  mov    0x38(%rsp),%rdi
  mov    0x30(%rsp),%rdx
  mov    0x28(%rsp),%r11
  mov    0x20(%rsp),%r10d
  mov    0x18(%rsp),%r9d
  movss  D7(%rip),%xmm6
  movss  D11(%rip),%xmm4
  jmp    L0
```

tool_calls: name: read_data
arguments: data_tag: D19
data_type: byte[4]
name: read_data
arguments: data_tag: D209
data_type: f64
name: read_data
arguments: data_tag: D11
data_type: byte[4]
name: read_data
arguments: data_tag: D7
data_type: byte[4]

tool: {"D19": [0x00,0x00,0x00,0x4b]}

tool: D209: 0.5

tool: {"D11": [0xff,0xff,0xff,0x7f]}

tool: {"D7": [0x00,0x00,0x80,0x3f]}

assistant: ```c
void powspec2d(float *Fr, float *Fi, float *PS2d, int N1, int N2) {
  int i, j, n, a, b;
  int ind, ind2, *number;
  float val;
  n = (N1 < N2 ? N1 : N2) / 2;
  number = (int *)malloc((n + 1) * sizeof(int));
  for (i = 0; i <= n; i++) {
    PS2d[i] = 0;
    number[i] = 0;
  }
  for (i = 0; i < N1 / 2; i++)
    for (j = 0; j < N2 / 2; j++) {
      a = i;
      b = j;
      ind2 = i + j * N1;
      val = sqrt((float)(a * a + b * b));
      if ((val - floor(val)) < 0.5)
        ind = (int)floor(val);
      else
        ind = (int)ceil(val);
      if (ind > n)
        ind = n;
      PS2d[ind] += Fr[ind2] * Fr[ind2] + Fi[ind2] * Fi[ind2];
      number[ind]++;
    }
  for (i = 0; i < N1 / 2; i++)
    for (j = N2 / 2; j < N2; j++) {
      a = i;
      b = j - N2;
      ind2 = i + j * N1;
      val = sqrt((float)(a * a + b * b));
      if ((val - floor(val)) < 0.5)
        ind = (int)floor(val);
      else
        ind = (int)ceil(val);
      if (ind > n)
        ind = n;
      PS2d[ind] += Fr[ind2] * Fr[ind2] + Fi[ind2] * Fi[ind2];
      number[ind]++;
    }
  for (i = N1 / 2; i < N1; i++)
    for (j = N2 / 2; j < N2; j++) {
      a = i - N1;
      b = j - N2;
      ind2 = i + j * N1;
      val = sqrt((float)(a * a + b * b));
      if ((val - floor(val)) < 0.5)
        ind = (int)floor(val);
      else
        ind = (int)ceil(val);
      if (ind > n)
        ind = n;
      PS2d[ind] += Fr[ind2] * Fr[ind2] + Fi[ind2] * Fi[ind2];
      number[ind]++;
    }
  for (i = N1 / 2; i < N1; i++)
    for (j = 0; j < N2 / 2; j++) {
      a = i - N1;
      b = j;
      ind2 = i + j * N1;
      val = sqrt((float)(a * a + b * b));
      if ((val - floor(val)) < 0.5)
        ind = (int)floor(val);
      else
        ind = (int)ceil(val);
      if (ind > n)
        ind = n;
      PS2d[ind] += Fr[ind2] * Fr[ind2] + Fi[ind2] * Fi[ind2];
      number[ind]++;
    }
  for (i = 0; i <= n; i++) {
    if (number[i] != 0)
      PS2d[i] = (float)(i)*PS2d[i] / (float)number[i];
  }
  free(number);
}
```