user: 请将这段汇编代码片段转换成等效的C代码:

```asm
<scale_internal_int>:
  endbr64
  push   %r15
  push   %r14
  push   %r13
  push   %r12
  push   %rbp
  push   %rbx
  sub    $0xc8,%rsp
  mov    %edi,%r12d
  mov    %edx,0x78(%rsp)
  mov    %rcx,0x18(%rsp)
  mov    %r8d,0x48(%rsp)
  mov    %r9d,0x84(%rsp)
  mov    0x100(%rsp),%rax
  mov    %rax,0x88(%rsp)
  mov    0x108(%rsp),%ebx
  mov    0x120(%rsp),%r13d
  mov    %fs:0x28,%rax
  mov    %rax,0xb8(%rsp)
  xor    %eax,%eax
  lea    (%r8,%r8,1),%eax
  cmp    %esi,%eax
  jne    L1123
  lea    (%r9,%r9,1),%eax
  cmp    %edx,%eax
  je     L84
L1123:
  pxor   %xmm0,%xmm0
  cvtsi2ssl 0x78(%rsp),%xmm0
  mov    0x84(%rsp),%ebp
  pxor   %xmm1,%xmm1
  cvtsi2ss %ebp,%xmm1
  movaps %xmm0,%xmm7
  divss  %xmm1,%xmm7
  pxor   %xmm1,%xmm1
  cvtsi2ss %esi,%xmm1
  mov    0x48(%rsp),%r14d
  pxor   %xmm0,%xmm0
  cvtsi2ss %r14d,%xmm0
  movaps %xmm1,%xmm4
  divss  %xmm0,%xmm4
  movss  %xmm4,0xc(%rsp)
  movss  %xmm7,0x8(%rsp)
  movaps %xmm7,%xmm0
  call   <floor@plt>
  mov    %eax,%r15d
  mov    %eax,0x98(%rsp)
  pxor   %xmm0,%xmm0
  cvtsi2ss %eax,%xmm0
  movss  0x8(%rsp),%xmm6
  subss  %xmm0,%xmm6
  movss  %xmm6,0x7c(%rsp)
  movss  0xc(%rsp),%xmm0
  call   <floor@plt>
  mov    %eax,0x58(%rsp)
  pxor   %xmm0,%xmm0
  cvtsi2ss %eax,%xmm0
  movss  0xc(%rsp),%xmm4
  movaps %xmm4,%xmm5
  subss  %xmm0,%xmm5
  movss  0x8(%rsp),%xmm3
  mulss  %xmm4,%xmm3
  test   %ebp,%ebp
  jle    L274
  imul   %r12d,%r14d
  mov    %r14d,0x9c(%rsp)
  movslq %r12d,%rax
  shl    $0x2,%rax
  mov    %rax,0x68(%rsp)
  lea    0xa0(%rsp),%r11
  lea    -0x1(%r12),%eax
  lea    0xa4(%rsp,%rax,4),%r14
  movslq %ebx,%r9
  add    $0x1,%rax
  imul   %r9,%rax
  mov    %rax,0x28(%rsp)
  movss  0x7c(%rsp),%xmm2
  mov    %r15d,%eax
  movl   $0x0,0x80(%rsp)
  pxor   %xmm4,%xmm4
  movl   $0x0,0x20(%rsp)
  movl   $0x0,0x5c(%rsp)
  movss  D23(%rip),%xmm9
  movaps %xmm9,%xmm8
  movaps %xmm9,%xmm7
  movaps %xmm9,%xmm6
  mov    %r9,%r15
  jmp    L435
L84:
  sub    $0x8,%rsp
  push   %r13
  mov    0x128(%rsp),%eax
  push   %rax
  mov    0x128(%rsp),%eax
  push   %rax
  mov    %ebx,%r9d
  mov    0xa8(%rsp),%r8
  mov    0x38(%rsp),%rcx
  mov    0x98(%rsp),%edx
  call   <halveImage_int@plt>
  add    $0x20,%rsp
L274:
  mov    0xb8(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L640
  add    $0xc8,%rsp
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
L1051:
  movaps %xmm7,%xmm11
  subss  %xmm4,%xmm11
  movslq %ebx,%rbx
  mov    %rbx,0x50(%rsp)
  add    0x40(%rsp),%rbx
  mov    %rbx,%r8
  add    0x18(%rsp),%r8
  movaps %xmm7,%xmm10
  subss  %xmm12,%xmm10
  movaps %xmm10,%xmm12
  mulss  %xmm11,%xmm12
  test   %r12d,%r12d
  jle    L1202
  mov    %r11,%rdx
  mov    %r8,%rcx
  jmp    L373
L296:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm12,%xmm0
  addss  (%rdx),%xmm0
L38:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L629
L373:
  test   %r13d,%r13d
  je     L296
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%edi
  shl    $0x10,%edi
  or     %edi,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%edi
  shl    $0x8,%edi
  or     %edi,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm12,%xmm0
  addss  (%rdx),%xmm0
  jmp    L38
L629:
  mov    0xc(%rsp),%ebx
  lea    0x1(%rbx),%ebp
  cmp    %eax,%ebp
  jge    L461
L982:
  mov    %ebp,%edi
  mov    %r8,%rbx
  jmp    L261
L1153:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
L1138:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L706
L894:
  test   %r13d,%r13d
  je     L1153
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%r10d
  shl    $0x10,%r10d
  or     %r10d,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%r10d
  shl    $0x8,%r10d
  or     %r10d,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
  jmp    L1138
L706:
  add    $0x1,%edi
  cmp    %eax,%edi
  je     L900
L261:
  add    %r9,%rbx
  test   %r12d,%r12d
  jle    L706
  mov    %r11,%rdx
  mov    %rbx,%rcx
  jmp    L894
L900:
  lea    -0x2(%rax),%edx
  sub    0xc(%rsp),%edx
  add    $0x1,%rdx
  imul   %r9,%rdx
  add    %r8,%rdx
L119:
  lea    (%rdx,%r9,1),%rbx
  mulss  %xmm1,%xmm11
  test   %r12d,%r12d
  jle    L428
  mov    %r11,%rdx
  mov    %rbx,%rcx
  jmp    L1024
L461:
  mov    %r8,%rdx
  jmp    L119
L939:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
L1129:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L258
L1024:
  test   %r13d,%r13d
  je     L939
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%edi
  shl    $0x10,%edi
  or     %edi,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%edi
  shl    $0x8,%edi
  or     %edi,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
  jmp    L1129
L1186:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
L371:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L634
L582:
  test   %r13d,%r13d
  je     L1186
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%edi
  shl    $0x10,%edi
  or     %edi,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%edi
  shl    $0x8,%edi
  or     %edi,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
  jmp    L371
L1011:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm2,%xmm0
  addss  (%rdx),%xmm0
L413:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L103
L1152:
  test   %r13d,%r13d
  je     L1011
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%edi
  shl    $0x10,%edi
  or     %edi,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%edi
  shl    $0x8,%edi
  or     %edi,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm2,%xmm0
  addss  (%rdx),%xmm0
  jmp    L413
L103:
  add    $0x1,%ebp
  cmp    %eax,%ebp
  je     L854
L1154:
  add    %r9,%r10
  test   %r12d,%r12d
  jle    L103
  mov    %r11,%rdx
  mov    %r10,%rcx
  jmp    L1152
L854:
  lea    -0x2(%rax),%edx
  sub    0xc(%rsp),%edx
  add    $0x1,%rdx
  imul   %r9,%rdx
  add    %rdx,0x30(%rsp)
L1198:
  mov    0x30(%rsp),%rcx
  add    %r9,%rcx
  movaps %xmm1,%xmm11
  mulss  %xmm2,%xmm11
  test   %r12d,%r12d
  jle    L897
L353:
  mov    %r11,%rdx
  jmp    L800
L282:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
L175:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L117
L800:
  test   %r13d,%r13d
  je     L282
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%edi
  shl    $0x10,%edi
  or     %edi,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%edi
  shl    $0x8,%edi
  or     %edi,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
  jmp    L175
L54:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rsi),%xmm0
  mulss  %xmm10,%xmm0
  pxor   %xmm11,%xmm11
  cvtsi2ssl (%rdi),%xmm11
  mulss  %xmm1,%xmm11
  addss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
L825:
  movss  %xmm0,(%rdx)
  add    %r15,%rsi
  add    %r15,%rdi
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L400
L143:
  test   %r13d,%r13d
  je     L54
  mov    0xc(%rsi),%ecx
  shl    $0x18,%ecx
  mov    0x8(%rsi),%r10d
  shl    $0x10,%r10d
  or     %r10d,%ecx
  or     (%rsi),%ecx
  mov    0x4(%rsi),%r10d
  shl    $0x8,%r10d
  or     %r10d,%ecx
  pxor   %xmm0,%xmm0
  cvtsi2ss %ecx,%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rdx),%xmm0
  mov    0xc(%rdi),%ecx
  shl    $0x18,%ecx
  mov    0x8(%rdi),%r10d
  shl    $0x10,%r10d
  or     %r10d,%ecx
  or     (%rdi),%ecx
  mov    0x4(%rdi),%r10d
  shl    $0x8,%r10d
  or     %r10d,%ecx
  pxor   %xmm11,%xmm11
  cvtsi2ss %ecx,%xmm11
  mulss  %xmm1,%xmm11
  addss  %xmm11,%xmm0
  jmp    L825
L400:
  mov    0x28(%rsp),%rdi
  add    %rdi,%r8
  add    %rdi,%rbx
L1134:
  add    $0x1,%ebp
  cmp    %ebp,%eax
  je     L57
L183:
  mov    0x10(%rsp),%rdi
  add    %rdi,%r8
  add    %rdi,%rbx
  test   %r12d,%r12d
  jle    L1134
  mov    %r11,%rdx
  mov    %rbx,%rdi
  mov    %r8,%rsi
  jmp    L143
L57:
  mov    0x30(%rsp),%eax
  mov    0x50(%rsp),%r10
  add    0x60(%rsp),%r10
  add    0x18(%rsp),%r10
  jmp    L958
L704:
  movaps %xmm1,%xmm10
  subss  %xmm12,%xmm10
  movaps %xmm8,%xmm11
  subss  %xmm4,%xmm11
  mulss  %xmm10,%xmm11
  movslq %ebx,%rdx
  add    0x40(%rsp),%rdx
  mov    0x18(%rsp),%rdi
  lea    (%rdi,%rdx,1),%rbp
  test   %r12d,%r12d
  jle    L95
  mov    %r11,%rdx
  mov    %rbp,%rcx
  jmp    L884
L912:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
L137:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L95
L884:
  test   %r13d,%r13d
  je     L912
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%edi
  shl    $0x10,%edi
  or     %edi,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%edi
  shl    $0x8,%edi
  or     %edi,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
  jmp    L137
L95:
  mov    0x20(%rsp),%edi
  add    $0x1,%edi
  cmp    %edi,0x8(%rsp)
  jle    L1124
  mov    %rbp,%r10
  jmp    L134
L641:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rsi),%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rdx),%xmm0
L1100:
  movss  %xmm0,(%rdx)
  add    %r15,%rsi
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L658
L20:
  test   %r13d,%r13d
  je     L641
  mov    0xc(%rsi),%ecx
  shl    $0x18,%ecx
  mov    0x8(%rsi),%r8d
  shl    $0x10,%r8d
  or     %r8d,%ecx
  or     (%rsi),%ecx
  mov    0x4(%rsi),%r8d
  shl    $0x8,%r8d
  or     %r8d,%ecx
  pxor   %xmm0,%xmm0
  cvtsi2ss %ecx,%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rdx),%xmm0
  jmp    L1100
L658:
  add    $0x1,%edi
  cmp    %edi,0x8(%rsp)
  je     L950
L134:
  add    0x10(%rsp),%r10
  test   %r12d,%r12d
  jle    L658
  mov    %r11,%rdx
  mov    %r10,%rsi
  jmp    L20
L950:
  add    0x90(%rsp),%rbp
L1124:
  mulss  %xmm2,%xmm10
  mov    0x10(%rsp),%rdi
  lea    0x0(%rbp,%rdi,1),%rcx
  test   %r12d,%r12d
  jle    L1017
  mov    %r11,%rdx
  jmp    L974
L812:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rdx),%xmm0
L335:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L874
L974:
  test   %r13d,%r13d
  je     L812
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%edi
  shl    $0x10,%edi
  or     %edi,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%edi
  shl    $0x8,%edi
  or     %edi,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rdx),%xmm0
  jmp    L335
L501:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
L843:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L815
L1042:
  test   %r13d,%r13d
  je     L501
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%edi
  shl    $0x10,%edi
  or     %edi,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%edi
  shl    $0x8,%edi
  or     %edi,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm11,%xmm0
  addss  (%rdx),%xmm0
  jmp    L843
L815:
  mov    0xc(%rsp),%edi
  add    $0x1,%edi
  cmp    %eax,%edi
  jge    L178
  mov    %rbp,%r8
  jmp    L895
L105:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rdx),%xmm0
L1214:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L1175
L1098:
  test   %r13d,%r13d
  je     L105
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%r10d
  shl    $0x10,%r10d
  or     %r10d,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%r10d
  shl    $0x8,%r10d
  or     %r10d,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rdx),%xmm0
  jmp    L1214
L1175:
  add    $0x1,%edi
  cmp    %eax,%edi
  je     L382
L895:
  add    %r9,%r8
  test   %r12d,%r12d
  jle    L1175
  mov    %r11,%rdx
  mov    %r8,%rcx
  jmp    L1098
L382:
  lea    -0x2(%rax),%edx
  sub    0xc(%rsp),%edx
  add    $0x1,%rdx
  imul   %r9,%rdx
  add    %rdx,%rbp
L178:
  lea    0x0(%rbp,%r9,1),%rcx
  mulss  %xmm1,%xmm10
  test   %r12d,%r12d
  jle    L1017
  mov    %r11,%rdx
  jmp    L433
L972:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rcx),%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rdx),%xmm0
L549:
  movss  %xmm0,(%rdx)
  add    %r15,%rcx
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L874
L433:
  test   %r13d,%r13d
  je     L972
  mov    0xc(%rcx),%esi
  shl    $0x18,%esi
  mov    0x8(%rcx),%edi
  shl    $0x10,%edi
  or     %edi,%esi
  or     (%rcx),%esi
  mov    0x4(%rcx),%edi
  shl    $0x8,%edi
  or     %edi,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rdx),%xmm0
  jmp    L549
L332:
  movaps %xmm1,%xmm0
  subss  %xmm12,%xmm0
  movaps %xmm2,%xmm10
  subss  %xmm4,%xmm10
  mulss  %xmm0,%xmm10
  movslq %ebx,%rdx
  add    0x40(%rsp),%rdx
  add    0x18(%rsp),%rdx
  test   %r12d,%r12d
  jle    L1017
  mov    %r11,%rcx
  jmp    L789
L207:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rdx),%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rcx),%xmm0
L410:
  movss  %xmm0,(%rcx)
  add    %r15,%rdx
  add    $0x4,%rcx
  cmp    %r14,%rcx
  je     L874
L789:
  test   %r13d,%r13d
  je     L207
  mov    0xc(%rdx),%esi
  shl    $0x18,%esi
  mov    0x8(%rdx),%edi
  shl    $0x10,%edi
  or     %edi,%esi
  or     (%rdx),%esi
  mov    0x4(%rdx),%edi
  shl    $0x8,%edi
  or     %edi,%esi
  pxor   %xmm0,%xmm0
  cvtsi2ss %esi,%xmm0
  mulss  %xmm10,%xmm0
  addss  (%rcx),%xmm0
  jmp    L410
L112:
  pxor   %xmm0,%xmm0
  cvtsi2ssl (%rsi),%xmm0
  addss  (%rdx),%xmm0
L1027:
  movss  %xmm0,(%rdx)
  add    %r15,%rsi
  add    $0x4,%rdx
  cmp    %r14,%rdx
  je     L17
L291:
  test   %r13d,%r13d
  je     L112
  mov    0xc(%rsi),%ecx
  shl    $0x18,%ecx
  mov    0x8(%rsi),%ebp
  shl    $0x10,%ebp
  or     %ebp,%ecx
  or     (%rsi),%ecx
  mov    0x4(%rsi),%ebp
  shl    $0x8,%ebp
  or     %ebp,%ecx
  pxor   %xmm0,%xmm0
  cvtsi2ss %ecx,%xmm0
  addss  (%rdx),%xmm0
  jmp    L1027
L17:
  add    %r9,%r8
  add    $0x1,%edi
  cmp    %eax,%edi
  je     L598
L795:
  mov    %r11,%rdx
  mov    %r8,%rsi
  test   %r12d,%r12d
  jg     L291
  jmp    L17
L598:
  add    0x10(%rsp),%r10
  add    $0x1,%ebx
  cmp    %ebx,0x8(%rsp)
  jle    L364
L229:
  mov    0xc(%rsp),%edi
  add    $0x1,%edi
  mov    %r10,%r8
  cmp    %eax,%edi
  jl     L795
  jmp    L598
L364:
  test   %r12d,%r12d
  jle    L1009
L41:
  mov    $0x0,%edx
  mov    0x38(%rsp),%rsi
L518:
  movss  0xa0(%rsp,%rdx,4),%xmm0
  divss  %xmm3,%xmm0
  cvttss2si %xmm0,%ecx
  mov    %ecx,(%rsi,%rdx,4)
  add    $0x1,%rdx
  cmp    %edx,%r12d
  jg     L518
L1009:
  mov    0x58(%rsp),%ebx
  lea    (%rbx,%rax,1),%edx
  movaps %xmm5,%xmm0
  addss  %xmm1,%xmm0
  comiss %xmm6,%xmm0
  jbe    L510
  subss  D23(%rip),%xmm0
  add    $0x1,%edx
L510:
  addl   $0x1,0x24(%rsp)
  mov    0x24(%rsp),%ebx
  mov    0x68(%rsp),%rsi
  add    %rsi,0x38(%rsp)
  mov    %eax,0xc(%rsp)
  movaps %xmm1,%xmm12
  cmp    %ebx,0x48(%rsp)
  je     L902
  movaps %xmm0,%xmm1
  mov    %edx,%eax
L808:
  movl   $0x0,0xac(%rsp)
  movl   $0x0,0xa8(%rsp)
  movl   $0x0,0xa4(%rsp)
  movl   $0x0,0xa0(%rsp)
  mov    0xc(%rsp),%edi
  mov    %edi,%ebx
  imul   0x118(%rsp),%ebx
  mov    0x20(%rsp),%edx
  cmp    %edx,0x8(%rsp)
  jle    L1087
  cmp    %eax,%edi
  jl     L1051
L1087:
  mov    0x20(%rsp),%esi
  cmp    %esi,0x8(%rsp)
  jg     L704
  cmp    %eax,0xc(%rsp)
  jge    L332
  movaps %xmm2,%xmm10
  subss  %xmm4,%xmm10
  movaps %xmm9,%xmm11
  subss  %xmm12,%xmm11
  mulss  %xmm10,%xmm11
  movslq %ebx,%rdx
  add    0x40(%rsp),%rdx
  mov    0x18(%rsp),%rdi
  lea    (%rdi,%rdx,1),%rbp
  test   %r12d,%r12d
  jle    L815
  mov    %r11,%rdx
  mov    %rbp,%rcx
  jmp    L1042
L902:
  mov    0x8(%rsp),%eax
  add    0x98(%rsp),%eax
  movss  0x7c(%rsp),%xmm0
  addss  %xmm2,%xmm0
  comiss D23(%rip),%xmm0
  jbe    L483
  subss  D23(%rip),%xmm0
  add    $0x1,%eax
L483:
  addl   $0x1,0x5c(%rsp)
  mov    0x5c(%rsp),%ebx
  mov    0x9c(%rsp),%esi
  add    %esi,0x80(%rsp)
  movaps %xmm2,%xmm4
  cmp    %ebx,0x84(%rsp)
  je     L274
  movaps %xmm0,%xmm2
  mov    0x8(%rsp),%ebx
  mov    %ebx,0x20(%rsp)
L435:
  mov    0x78(%rsp),%ebx
  lea    -0x1(%rbx),%edx
  cmp    %eax,%ebx
  cmovle %edx,%eax
  mov    %eax,%ebx
  mov    %eax,0x8(%rsp)
  cmpl   $0x0,0x48(%rsp)
  jle    L902
  mov    0x20(%rsp),%edi
  mov    %edi,%eax
  imul   0x110(%rsp),%eax
  cltq
  mov    %rax,0x40(%rsp)
  movslq 0x118(%rsp),%r9
  lea    0x1(%rdi),%eax
  mov    %eax,0x4c(%rsp)
  imul   0x110(%rsp),%eax
  cltq
  add    %r9,%rax
  mov    %rax,0x60(%rsp)
  mov    %ebx,%eax
  imul   0x110(%rsp),%eax
  cltq
  mov    %rax,0x70(%rsp)
  movslq 0x80(%rsp),%rax
  mov    0x88(%rsp),%rsi
  lea    (%rsi,%rax,4),%rax
  mov    %rax,0x38(%rsp)
  movslq 0x110(%rsp),%rsi
  mov    %rsi,0x10(%rsp)
  sub    %edi,%ebx
  lea    -0x2(%rbx),%eax
  add    $0x1,%rax
  imul   %rsi,%rax
  mov    %rax,0x90(%rsp)
  movaps %xmm5,%xmm1
  mov    0x58(%rsp),%eax
  pxor   %xmm12,%xmm12
  movl   $0x0,0xc(%rsp)
  movl   $0x0,0x24(%rsp)
  jmp    L808
L258:
  movaps %xmm10,%xmm11
  mulss  %xmm2,%xmm11
  mov    0x50(%rsp),%rdx
  add    0x70(%rsp),%rdx
  add    0x18(%rsp),%rdx
  mov    %rdx,%rcx
  mov    %rdx,0x30(%rsp)
  mov    %r11,%rdx
  jmp    L582
L117:
  mov    0x20(%rsp),%edi
  lea    0x1(%rdi),%ebp
  cmp    %ebp,0x8(%rsp)
  jle    L41
  mov    %eax,0x30(%rsp)
  mov    0x8(%rsp),%eax
  jmp    L183
L897:
  mov    0x20(%rsp),%edi
  lea    0x1(%rdi),%ebp
  cmp    %ebp,0x8(%rsp)
  jle    L1009
  mov    %eax,0x30(%rsp)
  mov    0x8(%rsp),%eax
  jmp    L183
L449:
  mov    0x30(%rsp),%rcx
  add    %r9,%rcx
  movaps %xmm1,%xmm11
  mulss  %xmm2,%xmm11
  jmp    L353
L634:
  cmp    %eax,%ebp
  jge    L449
L233:
  mov    0x30(%rsp),%r10
  jmp    L1154
L1202:
  mov    0xc(%rsp),%ebx
  lea    0x1(%rbx),%ebp
  cmp    %eax,%ebp
  jl     L982
  lea    (%r8,%r9,1),%rbx
L428:
  mov    0x50(%rsp),%rdx
  add    0x70(%rsp),%rdx
  add    0x18(%rsp),%rdx
  mov    %rdx,0x30(%rsp)
  cmp    %ebp,%eax
  jg     L233
  jmp    L1198
L874:
  movslq %ebx,%r10
  add    0x60(%rsp),%r10
  add    0x18(%rsp),%r10
  mov    0x8(%rsp),%edi
  cmp    %edi,0x4c(%rsp)
  jge    L41
L958:
  mov    0x4c(%rsp),%ebx
  jmp    L229
L1017:
  movslq %ebx,%r10
  add    0x60(%rsp),%r10
  add    0x18(%rsp),%r10
  mov    0x8(%rsp),%edi
  cmp    %edi,0x4c(%rsp)
  jl     L958
  jmp    L1009
L640:
  call   <__stack_chk_fail@plt>
```

tool_calls: name: extract_symbolic_data
arguments: tag: D23
data_type: f32

tool: D23: 1

assistant: ```c
void scale_internal_int(GLint components, GLint widthin, GLint heightin, const GLint *datain, GLint widthout, GLint heightout, GLint *dataout, GLint element_size, GLint ysize, GLint group_size, GLint myswap_bytes) {
  float convx;
  float convy;
  float percent;
  float totals[4];
  float area;
  int i, j, k, xindex;
  const char *temp, *temp0;
  const char *temp_index;
  int outindex;
  int lowx_int, highx_int, lowy_int, highy_int;
  float x_percent, y_percent;
  float lowx_float, highx_float, lowy_float, highy_float;
  float convy_float, convx_float;
  int convy_int, convx_int;
  int l, m;
  const char *left, *right;
  GLuint swapbuf;
  if (widthin == widthout * 2 && heightin == heightout * 2) {
    halveImage_int(components, widthin, heightin, (const GLint *)datain, (GLint *)dataout, element_size, ysize, group_size, myswap_bytes);
    return;
  }
  convy = (float)heightin / heightout;
  convx = (float)widthin / widthout;
  convy_int = floor(convy);
  convy_float = convy - convy_int;
  convx_int = floor(convx);
  convx_float = convx - convx_int;
  area = convx * convy;
  lowy_int = 0;
  lowy_float = 0;
  highy_int = convy_int;
  highy_float = convy_float;
  for (i = 0; i < heightout; i++) {
    if (highy_int >= heightin)
      highy_int = heightin - 1;
    lowx_int = 0;
    lowx_float = 0;
    highx_int = convx_int;
    highx_float = convx_float;
    for (j = 0; j < widthout; j++) {
      totals[0] = totals[1] = totals[2] = totals[3] = 0.0;
      xindex = lowx_int * group_size;
      if ((highy_int > lowy_int) && (highx_int > lowx_int)) {
        y_percent = 1 - lowy_float;
        temp = (const char *)datain + xindex + lowy_int * ysize;
        percent = y_percent * (1 - lowx_float);
        for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
          if (myswap_bytes) {
            swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
            totals[k] += *(const GLint *)&swapbuf * percent;
          } else {
            totals[k] += *(const GLint *)temp_index * percent;
          }
        }
        left = temp;
        for (l = lowx_int + 1; l < highx_int; l++) {
          temp += group_size;
          for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
            if (myswap_bytes) {
              swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
              totals[k] += *(const GLint *)&swapbuf * y_percent;
            } else {
              totals[k] += *(const GLint *)temp_index * y_percent;
            }
          }
        }
        temp += group_size;
        right = temp;
        percent = y_percent * highx_float;
        for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
          if (myswap_bytes) {
            swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
            totals[k] += *(const GLint *)&swapbuf * percent;
          } else {
            totals[k] += *(const GLint *)temp_index * percent;
          }
        }
        y_percent = highy_float;
        percent = y_percent * (1 - lowx_float);
        temp = (const char *)datain + xindex + highy_int * ysize;
        for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
          if (myswap_bytes) {
            swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
            totals[k] += *(const GLint *)&swapbuf * percent;
          } else {
            totals[k] += *(const GLint *)temp_index * percent;
          }
        }
        for (l = lowx_int + 1; l < highx_int; l++) {
          temp += group_size;
          for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
            if (myswap_bytes) {
              swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
              totals[k] += *(const GLint *)&swapbuf * y_percent;
            } else {
              totals[k] += *(const GLint *)temp_index * y_percent;
            }
          }
        }
        temp += group_size;
        percent = y_percent * highx_float;
        for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
          if (myswap_bytes) {
            swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
            totals[k] += *(const GLint *)&swapbuf * percent;
          } else {
            totals[k] += *(const GLint *)temp_index * percent;
          }
        }
        for (m = lowy_int + 1; m < highy_int; m++) {
          left += ysize;
          right += ysize;
          for (k = 0; k < components; k++, left += element_size, right += element_size) {
            if (myswap_bytes) {
              swapbuf = (GLuint)(((GLuint)((const GLubyte *)(left))[3]) << 24 | ((GLuint)((const GLubyte *)(left))[2]) << 16 | ((GLuint)((const GLubyte *)(left))[1]) << 8 | ((const GLubyte *)(left))[0]);
              totals[k] += *(const GLint *)&swapbuf * (1 - lowx_float);
              swapbuf = (GLuint)(((GLuint)((const GLubyte *)(right))[3]) << 24 | ((GLuint)((const GLubyte *)(right))[2]) << 16 | ((GLuint)((const GLubyte *)(right))[1]) << 8 | ((const GLubyte *)(right))[0]);
              totals[k] += *(const GLint *)&swapbuf * highx_float;
            } else {
              totals[k] += *(const GLint *)left * (1 - lowx_float) + *(const GLint *)right * highx_float;
            }
          }
        }
      } else if (highy_int > lowy_int) {
        x_percent = highx_float - lowx_float;
        percent = (1 - lowy_float) * x_percent;
        temp = (const char *)datain + xindex + lowy_int * ysize;
        for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
          if (myswap_bytes) {
            swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
            totals[k] += *(const GLint *)&swapbuf * percent;
          } else {
            totals[k] += *(const GLint *)temp_index * percent;
          }
        }
        for (m = lowy_int + 1; m < highy_int; m++) {
          temp += ysize;
          for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
            if (myswap_bytes) {
              swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
              totals[k] += *(const GLint *)&swapbuf * x_percent;
            } else {
              totals[k] += *(const GLint *)temp_index * x_percent;
            }
          }
        }
        percent = x_percent * highy_float;
        temp += ysize;
        for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
          if (myswap_bytes) {
            swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
            totals[k] += *(const GLint *)&swapbuf * percent;
          } else {
            totals[k] += *(const GLint *)temp_index * percent;
          }
        }
      } else if (highx_int > lowx_int) {
        y_percent = highy_float - lowy_float;
        percent = (1 - lowx_float) * y_percent;
        temp = (const char *)datain + xindex + lowy_int * ysize;
        for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
          if (myswap_bytes) {
            swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
            totals[k] += *(const GLint *)&swapbuf * percent;
          } else {
            totals[k] += *(const GLint *)temp_index * percent;
          }
        }
        for (l = lowx_int + 1; l < highx_int; l++) {
          temp += group_size;
          for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
            if (myswap_bytes) {
              swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
              totals[k] += *(const GLint *)&swapbuf * y_percent;
            } else {
              totals[k] += *(const GLint *)temp_index * y_percent;
            }
          }
        }
        temp += group_size;
        percent = y_percent * highx_float;
        for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
          if (myswap_bytes) {
            swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
            totals[k] += *(const GLint *)&swapbuf * percent;
          } else {
            totals[k] += *(const GLint *)temp_index * percent;
          }
        }
      } else {
        percent = (highy_float - lowy_float) * (highx_float - lowx_float);
        temp = (const char *)datain + xindex + lowy_int * ysize;
        for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
          if (myswap_bytes) {
            swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
            totals[k] += *(const GLint *)&swapbuf * percent;
          } else {
            totals[k] += *(const GLint *)temp_index * percent;
          }
        }
      }
      temp0 = (const char *)datain + xindex + group_size + (lowy_int + 1) * ysize;
      for (m = lowy_int + 1; m < highy_int; m++) {
        temp = temp0;
        for (l = lowx_int + 1; l < highx_int; l++) {
          for (k = 0, temp_index = temp; k < components; k++, temp_index += element_size) {
            if (myswap_bytes) {
              swapbuf = (GLuint)(((GLuint)((const GLubyte *)(temp_index))[3]) << 24 | ((GLuint)((const GLubyte *)(temp_index))[2]) << 16 | ((GLuint)((const GLubyte *)(temp_index))[1]) << 8 | ((const GLubyte *)(temp_index))[0]);
              totals[k] += *(const GLint *)&swapbuf;
            } else {
              totals[k] += *(const GLint *)temp_index;
            }
          }
          temp += group_size;
        }
        temp0 += ysize;
      }
      outindex = (j + (i * widthout)) * components;
      for (k = 0; k < components; k++) {
        dataout[outindex + k] = totals[k] / area;
      }
      lowx_int = highx_int;
      lowx_float = highx_float;
      highx_int += convx_int;
      highx_float += convx_float;
      if (highx_float > 1) {
        highx_float -= 1.0;
        highx_int++;
      }
    }
    lowy_int = highy_int;
    lowy_float = highy_float;
    highy_int += convy_int;
    highy_float += convy_float;
    if (highy_float > 1) {
      highy_float -= 1.0;
      highy_int++;
    }
  }
}
```