user: Demonstrate the C code that generates the assembly output below:

```asm
<_reproject_slice_c>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x1e8,%rsp
  mov    %edx,%ebx
  mov    %edx,0xf8(%rsp)
  mov    %ecx,0xac(%rsp)
  mov    %r8d,0xb8(%rsp)
  mov    %r9d,0xbc(%rsp)
  mov    0x220(%rsp),%rdx
  mov    %rdx,0xc0(%rsp)
  mov    0x228(%rsp),%rdx
  mov    %rdx,0xc8(%rsp)
  mov    0x230(%rsp),%rdx
  mov    %rdx,0xd0(%rsp)
  mov    0x238(%rsp),%rdx
  mov    %rdx,0xd8(%rsp)
  mov    0x240(%rsp),%rdx
  mov    %rdx,0x68(%rsp)
  mov    0x248(%rsp),%rdx
  mov    %rdx,0x70(%rsp)
  mov    0x250(%rsp),%rdx
  mov    %rdx,0xe8(%rsp)
  mov    0x258(%rsp),%rdx
  mov    %rdx,0x78(%rsp)
  mov    0x260(%rsp),%rdx
  mov    %rdx,0x80(%rsp)
  mov    0x268(%rsp),%r15
  mov    0x270(%rsp),%rdx
  mov    %rdx,(%rsp)
  mov    0x278(%rsp),%rdx
  mov    %rdx,0x8(%rsp)
  mov    0x280(%rsp),%ecx
  mov    %fs:0x28,%rdx
  mov    %rdx,0x1d8(%rsp)
  xor    %edx,%edx
  cmp    %esi,%edi
  jge    L37
  mov    %esi,%eax
  mov    %ebx,%edx
  imul   %ecx,%edx
  movslq %edx,%rdx
  movslq %edi,%r10
  mov    %r10,0xa0(%rsp)
  lea    (%rdx,%r10,1),%rsi
  shl    $0x3,%rsi
  mov    %rsi,0xf0(%rsp)
  sub    $0x1,%eax
  sub    %edi,%eax
  lea    0x1(%r10,%rax,1),%rax
  mov    %rax,0x100(%rsp)
  mov    %ebx,%eax
  imul   0x290(%rsp),%eax
  mov    %eax,0xfc(%rsp)
  movslq %ecx,%rax
  shl    $0x3,%rax
  mov    %rax,0xb0(%rsp)
  lea    0x1(%rbx),%eax
  imul   %ecx,%eax
  cltq
  sub    %rdx,%rax
  shl    $0x3,%rax
  mov    %rax,0x108(%rsp)
  movslq 0x288(%rsp),%rax
  shl    $0x3,%rax
  mov    %rax,0x30(%rsp)
  movslq 0x298(%rsp),%rax
  shl    $0x3,%rax
  mov    %rax,0x38(%rsp)
  lea    0x170(%rsp),%rax
  mov    %rax,0x10(%rsp)
  jmp    L121
L114:
  mov    0x68(%rsp),%rbp
  mov    0x48(%rsp),%rax
  add    %rax,%rbp
  mov    0x70(%rsp),%rbx
  add    %rax,%rbx
  mov    0x78(%rsp),%r13
  mov    0x50(%rsp),%rax
  add    %rax,%r13
  mov    0x80(%rsp),%r12
  add    %rax,%r12
  mov    0x58(%rsp),%eax
  mov    %eax,0x20(%rsp)
L122:
  addl   $0x1,0x20(%rsp)
  movsd  0x0(%rbp),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x150(%rsp)
  movsd  0x8(%rbp),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x158(%rsp)
  movsd  0x8(%rbp,%r14,8),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x160(%rsp)
  movsd  0x0(%rbp,%r14,8),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x168(%rsp)
  movsd  (%rbx),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x170(%rsp)
  movsd  0x8(%rbx),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x178(%rsp)
  movsd  0x8(%rbx,%r14,8),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x180(%rsp)
  movsd  (%rbx,%r14,8),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x188(%rsp)
  lea    0x150(%rsp),%rsi
  lea    0x130(%rsp),%rcx
  lea    0x110(%rsp),%rdx
  mov    0x10(%rsp),%r9
  mov    %rsi,0x18(%rsp)
  mov    %rsi,%r8
  mov    (%rsp),%rsi
  mov    %r15,%rdi
  mov    $0x0,%eax
  call   <_compute_overlap@plt>
  mov    0x10(%rsp),%rcx
  mov    %rcx,%r9
  mov    0x18(%rsp),%rdx
  mov    %rdx,%r8
  mov    (%rsp),%rsi
  mov    0x8(%rsp),%rdi
  mov    $0x0,%eax
  call   <_compute_overlap@plt>
  movsd  (%r15),%xmm0
  mov    0x8(%rsp),%rdi
  divsd  (%rdi),%xmm0
  mov    0x28(%rsp),%rdx
  mulsd  (%rdx),%xmm0
  addsd  0x0(%r13),%xmm0
  movsd  %xmm0,0x0(%r13)
  movsd  (%r15),%xmm0
  divsd  (%rdi),%xmm0
  addsd  (%r12),%xmm0
  movsd  %xmm0,(%r12)
  mov    0x30(%rsp),%rcx
  add    %rcx,%rbp
  add    %rcx,%rbx
  mov    0x38(%rsp),%rsi
  add    %rsi,%r13
  add    %rsi,%r12
  mov    0x20(%rsp),%eax
  cmp    0x24(%rsp),%eax
  jle    L122
L71:
  addq   $0x1,0x40(%rsp)
  mov    0x40(%rsp),%rbx
  addq   $0x8,0x48(%rsp)
  addq   $0x8,0x50(%rsp)
  mov    0x88(%rsp),%eax
  sub    0x60(%rsp),%eax
  add    %ebx,%eax
  cmp    %eax,0x5c(%rsp)
  jl     L8
L66:
  mov    0x58(%rsp),%ebx
  cmp    %ebx,0x24(%rsp)
  jge    L114
  jmp    L71
L8:
  mov    0x290(%rsp),%ebx
  add    %ebx,0xa8(%rsp)
  mov    0xb0(%rsp),%rbx
  add    %rbx,0x90(%rsp)
  add    %rbx,0x98(%rsp)
  mov    0xac(%rsp),%ebx
  cmp    %ebx,0x8c(%rsp)
  je     L15
L14:
  mov    0xc0(%rsp),%rax
  mov    0x90(%rsp),%r14
  movsd  (%rax,%r14,1),%xmm0
  movsd  %xmm0,0x190(%rsp)
  movsd  0x8(%rax,%r14,1),%xmm0
  movsd  %xmm0,0x198(%rsp)
  addl   $0x1,0x8c(%rsp)
  mov    0x98(%rsp),%r13
  movsd  0x8(%rax,%r13,1),%xmm0
  movsd  %xmm0,0x1a0(%rsp)
  movsd  (%rax,%r13,1),%xmm0
  movsd  %xmm0,0x1a8(%rsp)
  mov    0xc8(%rsp),%rax
  movsd  (%rax,%r14,1),%xmm0
  movsd  %xmm0,0x1b0(%rsp)
  movsd  0x8(%rax,%r14,1),%xmm0
  movsd  %xmm0,0x1b8(%rsp)
  movsd  0x8(%rax,%r13,1),%xmm0
  movsd  %xmm0,0x1c0(%rsp)
  movsd  (%rax,%r13,1),%xmm0
  movsd  %xmm0,0x1c8(%rsp)
  mov    0xe0(%rsp),%rbx
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <min_4@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  addsd  D9(%rip),%xmm0
  cvttsd2si %xmm0,%ebp
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <max_4@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  addsd  D9(%rip),%xmm0
  cvttsd2si %xmm0,%ebx
  mov    %ebx,0x5c(%rsp)
  lea    0x1b0(%rsp),%rbx
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <min_4@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  addsd  D9(%rip),%xmm0
  cvttsd2si %xmm0,%r12d
  mov    %rbx,%rdi
  mov    $0x0,%eax
  call   <max_4@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  addsd  D9(%rip),%xmm0
  cvttsd2si %xmm0,%ecx
  mov    %ecx,0x24(%rsp)
  mov    0xd0(%rsp),%rbx
  movsd  (%rbx,%r13,1),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x110(%rsp)
  movsd  0x8(%rbx,%r13,1),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x118(%rsp)
  movsd  0x8(%rbx,%r14,1),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x120(%rsp)
  movsd  (%rbx,%r14,1),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x128(%rsp)
  mov    0xd8(%rsp),%rbx
  movsd  (%rbx,%r13,1),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x130(%rsp)
  movsd  0x8(%rbx,%r13,1),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x138(%rsp)
  movsd  0x8(%rbx,%r14,1),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x140(%rsp)
  movsd  (%rbx,%r14,1),%xmm0
  mov    $0x1,%eax
  call   <to_rad@plt>
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movsd  %xmm0,0x148(%rsp)
  test   %ebp,%ebp
  mov    $0x0,%eax
  cmovns %ebp,%eax
  mov    %eax,%edi
  mov    %eax,0x88(%rsp)
  mov    0xb8(%rsp),%edx
  lea    -0x1(%rdx),%eax
  mov    0x5c(%rsp),%ebx
  cmp    %edx,%ebx
  cmovl  %ebx,%eax
  mov    %eax,%edx
  mov    %eax,0x5c(%rsp)
  test   %r12d,%r12d
  mov    $0x0,%eax
  cmovns %r12d,%eax
  mov    %eax,%ebx
  mov    %eax,0x58(%rsp)
  mov    0xbc(%rsp),%esi
  lea    -0x1(%rsi),%eax
  mov    0x24(%rsp),%ecx
  cmp    %esi,%ecx
  cmovl  %ecx,%eax
  mov    %eax,0x24(%rsp)
  cmp    %edi,%edx
  jl     L8
  movslq 0xa8(%rsp),%rax
  add    0xa0(%rsp),%rax
  mov    0xe8(%rsp),%rdx
  lea    (%rdx,%rax,8),%rax
  mov    %rax,0x28(%rsp)
  movslq %edi,%rdi
  mov    %rdi,0x60(%rsp)
  lea    0x1(%rbx),%eax
  imul   0x288(%rsp),%eax
  cltq
  lea    (%rdi,%rax,1),%rdx
  shl    $0x3,%rdx
  mov    %rdx,0x48(%rsp)
  mov    %ebx,%edx
  imul   0x298(%rsp),%edx
  movslq %edx,%rdx
  add    %rdi,%rdx
  shl    $0x3,%rdx
  mov    %rdx,0x50(%rsp)
  imul   0x288(%rsp),%ebx
  movslq %ebx,%rdx
  sub    %rax,%rdx
  mov    %rdx,%r14
  mov    %rdi,0x40(%rsp)
  jmp    L66
L15:
  addq   $0x8,0xf0(%rsp)
  addq   $0x1,0xa0(%rsp)
  mov    0xa0(%rsp),%rax
  cmp    0x100(%rsp),%rax
  je     L37
L121:
  mov    0xac(%rsp),%ebx
  cmp    %ebx,0xf8(%rsp)
  jge    L15
  mov    0xf0(%rsp),%rax
  mov    %rax,%rbx
  add    0x108(%rsp),%rbx
  mov    %rbx,0x98(%rsp)
  mov    %rax,0x90(%rsp)
  mov    0xfc(%rsp),%eax
  mov    %eax,0xa8(%rsp)
  mov    0xf8(%rsp),%eax
  mov    %eax,0x8c(%rsp)
  lea    0x190(%rsp),%rax
  mov    %rax,0xe0(%rsp)
  jmp    L14
L37:
  mov    0x1d8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L118
  add    $0x1e8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L118:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: unpack_data
arguments: data_tag: D9
data_type: byte[8]

tool: {"D9": [0x00,0x00,0x00,0x00,0x00,0x00,0xe0,0x3f]}

assistant: ```c
void _reproject_slice_c(int startx, int endx, int starty, int endy, int nx_out, int ny_out, double *xp_inout, double *yp_inout, double *xw_in, double *yw_in, double *xw_out, double *yw_out, double *array, double *array_new, double *weights, double *overlap, double *area_ratio, double *original, int col_in, int col_out, int col_array, int col_new) {
  int i, j, ii, jj, xmin, xmax, ymin, ymax;
  double ilon[4], ilat[4], olon[4], olat[4], minmax_x[4], minmax_y[4];
  for (i = startx; i < endx; ++i) {
    for (j = starty; j < endy; ++j) {
      minmax_x[0] = *(xp_inout + (j) * (col_in) + (i));
      minmax_x[1] = *(xp_inout + (j) * (col_in) + (i + 1));
      minmax_x[2] = *(xp_inout + (j + 1) * (col_in) + (i + 1));
      minmax_x[3] = *(xp_inout + (j + 1) * (col_in) + (i));
      minmax_y[0] = *(yp_inout + (j) * (col_in) + (i));
      minmax_y[1] = *(yp_inout + (j) * (col_in) + (i + 1));
      minmax_y[2] = *(yp_inout + (j + 1) * (col_in) + (i + 1));
      minmax_y[3] = *(yp_inout + (j + 1) * (col_in) + (i));
      xmin = (int)(min_4(minmax_x) + .5);
      xmax = (int)(max_4(minmax_x) + .5);
      ymin = (int)(min_4(minmax_y) + .5);
      ymax = (int)(max_4(minmax_y) + .5);
      ilon[0] = to_rad(*(xw_in + (j + 1) * (col_in) + (i)));
      ilon[1] = to_rad(*(xw_in + (j + 1) * (col_in) + (i + 1)));
      ilon[2] = to_rad(*(xw_in + (j) * (col_in) + (i + 1)));
      ilon[3] = to_rad(*(xw_in + (j) * (col_in) + (i)));
      ilat[0] = to_rad(*(yw_in + (j + 1) * (col_in) + (i)));
      ilat[1] = to_rad(*(yw_in + (j + 1) * (col_in) + (i + 1)));
      ilat[2] = to_rad(*(yw_in + (j) * (col_in) + (i + 1)));
      ilat[3] = to_rad(*(yw_in + (j) * (col_in) + (i)));
      xmin = xmin > 0 ? xmin : 0;
      xmax = (nx_out - 1) < xmax ? (nx_out - 1) : xmax;
      ymin = ymin > 0 ? ymin : 0;
      ymax = (ny_out - 1) < ymax ? (ny_out - 1) : ymax;
      for (ii = xmin; ii < xmax + 1; ++ii) {
        for (jj = ymin; jj < ymax + 1; ++jj) {
          olon[0] = to_rad(*(xw_out + (jj + 1) * (col_out) + (ii)));
          olon[1] = to_rad(*(xw_out + (jj + 1) * (col_out) + (ii + 1)));
          olon[2] = to_rad(*(xw_out + (jj) * (col_out) + (ii + 1)));
          olon[3] = to_rad(*(xw_out + (jj) * (col_out) + (ii)));
          olat[0] = to_rad(*(yw_out + (jj + 1) * (col_out) + (ii)));
          olat[1] = to_rad(*(yw_out + (jj + 1) * (col_out) + (ii + 1)));
          olat[2] = to_rad(*(yw_out + (jj) * (col_out) + (ii + 1)));
          olat[3] = to_rad(*(yw_out + (jj) * (col_out) + (ii)));
          _compute_overlap(overlap, area_ratio, ilon, ilat, olon, olat);
          _compute_overlap(original, area_ratio, olon, olat, olon, olat);
          *(array_new + (jj) * (col_new) + (ii)) += *(array + (j) * (col_array) + (i)) * (overlap[0] / original[0]);
          *(weights + (jj) * (col_new) + (ii)) += (overlap[0] / original[0]);
        }
      }
    }
  }
}
```