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

```asm
<imResize>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0x18,%rsp
  mov    %edi,%r13d
  mov    %esi,%r15d
  mov    %rdx,0x8(%rsp)
  mov    %ecx,%r14d
  mov    %r8d,(%rsp)
  mov    %r9,%rbx
  movslq %ecx,%rbp
  lea    0x0(,%rbp,4),%rdi
  call   <malloc@plt>
  mov    %rax,%r12
  lea    0x0(,%rbp,8),%rdi
  call   <malloc@plt>
  mov    %rax,%rbp
  lea    -0x1(%r13),%r11d
  pxor   %xmm4,%xmm4
  cvtsi2sd %r11d,%xmm4
  lea    -0x1(%r14),%eax
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  divsd  %xmm0,%xmm4
  test   %r14d,%r14d
  jle    L30
  mov    %r14d,%ecx
  mov    $0x0,%eax
  movsd  D19(%rip),%xmm5
  movsd  D53(%rip),%xmm3
  movsd  D23(%rip),%xmm6
  jmp    L67
L38:
  cvttsd2si %xmm2,%edx
  pxor   %xmm1,%xmm1
  cvtsi2sd %edx,%xmm1
  subsd  %xmm1,%xmm0
  movsd  %xmm0,0x0(%rbp,%rax,8)
  mov    %edx,(%r12,%rax,4)
  add    $0x1,%rax
  cmp    %rcx,%rax
  je     L30
L67:
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  mulsd  %xmm4,%xmm0
  movapd %xmm0,%xmm2
  movapd %xmm0,%xmm1
  andpd  %xmm3,%xmm1
  ucomisd %xmm1,%xmm5
  jbe    L38
  cvttsd2si %xmm0,%rdx
  pxor   %xmm1,%xmm1
  cvtsi2sd %rdx,%xmm1
  movapd %xmm1,%xmm2
  cmpnlesd %xmm0,%xmm2
  andpd  %xmm6,%xmm2
  subsd  %xmm2,%xmm1
  movapd %xmm3,%xmm2
  andnpd %xmm0,%xmm2
  orpd   %xmm1,%xmm2
  jmp    L38
L30:
  lea    -0x1(%r15),%eax
  mov    %eax,0x4(%rsp)
  pxor   %xmm5,%xmm5
  cvtsi2sd %eax,%xmm5
  mov    (%rsp),%edi
  lea    -0x1(%rdi),%eax
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  divsd  %xmm0,%xmm5
  test   %edi,%edi
  jle    L74
  mov    $0x0,%r15d
  movsd  D19(%rip),%xmm6
  movsd  D53(%rip),%xmm4
  movsd  D23(%rip),%xmm7
  mov    %r14d,%r10d
  jmp    L32
L117:
  cvttsd2si %xmm1,%r8d
  cmp    %r8d,0x4(%rsp)
  setne  %r9b
  movzbl %r9b,%r9d
  add    %r8d,%r9d
  pxor   %xmm0,%xmm0
  cvtsi2sd %r8d,%xmm0
  subsd  %xmm0,%xmm2
  imul   %r13d,%r8d
  movslq %r8d,%r8
  mov    0x8(%rsp),%rax
  add    %rax,%r8
  imul   %r13d,%r9d
  movslq %r9d,%r9
  add    %rax,%r9
  test   %r14d,%r14d
  jle    L88
  mov    $0x0,%edx
L39:
  mov    (%r12,%rdx,4),%esi
  cmp    %esi,%r11d
  setne  %al
  movzbl %al,%eax
  add    %esi,%eax
  movsd  0x0(%rbp,%rdx,8),%xmm3
  movslq %esi,%rsi
  movzbl (%r8,%rsi,1),%ecx
  cltq
  movzbl (%r8,%rax,1),%edi
  movzbl (%r9,%rsi,1),%esi
  movzbl (%r9,%rax,1),%eax
  sub    %esi,%eax
  sub    %edi,%eax
  add    %ecx,%eax
  pxor   %xmm0,%xmm0
  cvtsi2sd %eax,%xmm0
  movapd %xmm2,%xmm1
  mulsd  %xmm3,%xmm1
  mulsd  %xmm1,%xmm0
  sub    %ecx,%edi
  pxor   %xmm1,%xmm1
  cvtsi2sd %edi,%xmm1
  mulsd  %xmm3,%xmm1
  addsd  %xmm1,%xmm0
  sub    %ecx,%esi
  pxor   %xmm1,%xmm1
  cvtsi2sd %esi,%xmm1
  mulsd  %xmm2,%xmm1
  addsd  %xmm1,%xmm0
  pxor   %xmm1,%xmm1
  cvtsi2sd %ecx,%xmm1
  addsd  %xmm1,%xmm0
  cvttsd2si %xmm0,%eax
  mov    %al,(%rbx,%rdx,1)
  add    $0x1,%rdx
  cmp    %rdx,%r10
  jne    L39
  add    %r10,%rbx
L88:
  add    $0x1,%r15d
  cmp    %r15d,(%rsp)
  je     L74
L32:
  pxor   %xmm2,%xmm2
  cvtsi2sd %r15d,%xmm2
  mulsd  %xmm5,%xmm2
  movapd %xmm2,%xmm1
  movapd %xmm2,%xmm0
  andpd  %xmm4,%xmm0
  ucomisd %xmm0,%xmm6
  jbe    L117
  cvttsd2si %xmm2,%rax
  pxor   %xmm0,%xmm0
  cvtsi2sd %rax,%xmm0
  movapd %xmm0,%xmm1
  cmpnlesd %xmm2,%xmm1
  andpd  %xmm7,%xmm1
  subsd  %xmm1,%xmm0
  movapd %xmm4,%xmm1
  andnpd %xmm2,%xmm1
  orpd   %xmm0,%xmm1
  jmp    L117
L74:
  mov    %r12,%rdi
  call   <free@plt>
  mov    %rbp,%rdi
  call   <free@plt>
  add    $0x18,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
```

tool_calls: name: retrieve_data
arguments: data_tag: D19
datatype: byte[8]
name: retrieve_data
arguments: data_tag: D53
datatype: byte[8]
name: retrieve_data
arguments: data_tag: D23
datatype: byte[8]

tool: {"D19": [0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x43]}

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

tool: {"D23": [0x00,0x00,0x00,0x00,0x00,0x00,0xf0,0x3f]}

assistant: ```c
void imResize(int src_width, int src_height, unsigned char *src_map, int dst_width, int dst_height, unsigned char *dst_map) {
  unsigned char *line_mapl, *line_maph;
  double t, u, src_x, src_y, factor;
  int fhh, fll, fhl, flh, xl, yl, xh, yh, x, y;
  int *XL = (int *)malloc(dst_width * sizeof(int));
  double *T = (double *)malloc(dst_width * sizeof(double));
  factor = (double)(src_width - 1) / (double)(dst_width - 1);
  for (x = 0; x < dst_width; x++) {
    src_x = x * factor;
    xl = (int)floor(src_x);
    T[x] = src_x - xl;
    XL[x] = xl;
  }
  factor = (double)(src_height - 1) / (double)(dst_height - 1);
  for (y = 0; y < dst_height; y++) {
    src_y = y * factor;
    yl = (int)floor(src_y);
    yh = (yl == src_height - 1) ? yl : yl + 1;
    u = src_y - yl;
    line_mapl = src_map + yl * src_width;
    line_maph = src_map + yh * src_width;
    for (x = 0; x < dst_width; x++) {
      xl = XL[x];
      xh = (xl == src_width - 1) ? xl : xl + 1;
      t = T[x];
      fll = line_mapl[xl];
      fhl = line_mapl[xh];
      flh = line_maph[xl];
      fhh = line_maph[xh];
      *(dst_map++) = (unsigned char)(u * t * (fhh - flh - fhl + fll) + t * (fhl - fll) + u * (flh - fll) + fll);
    }
  }
  free(XL);
  free(T);
}
```