void psnd_paperplot_labels(int vp, int vp_box, float *xreal, float xmin,
                           float xmax, float ymin, float ymax, float cminx,
                           float cmaxx, float cminy, float cmaxy, float thresh,
                           float sens, float avewidth, int sign, int npart,
                           float lheight, float box_height, float sfd,
                           float swhold, int nsiz, float xref, float aref,
                           float bref, int irc, int unitx) {
  int i, npick, npurged = 0;
  int *labpos, *picked, *purged;
  float *ppml;
  int nlabel;
  labpos = (int *)malloc(sizeof(int) * 512);
  picked = (int *)malloc(sizeof(int) * 512);
  purged = (int *)malloc(sizeof(int) * 512);
  ppml = (float *)malloc(sizeof(float) * 512);
  nlabel = (int)floor((cmaxx - cminx) / (lheight));
  pkpick(xreal, xmin - 1, xmax - 1, avewidth, thresh, sens, sign, &npick,
         picked, purged, npurged, nlabel, npart);
  expand_label(picked, npick, labpos, nlabel, xmin - 1, xmax - 1);
  if (unitx == 0)
    for (i = 0; i < npick; i++)
      ppml[i] =
          psnd_chan2ppm(picked[i], sfd, swhold, nsiz, xref, aref, bref, irc);
  else if (unitx == 1)
    for (i = 0; i < npick; i++)
      ppml[i] = psnd_chan2hz(picked[i], swhold, nsiz, xref, aref, bref, irc);
  else if (unitx == 2)
    for (i = 0; i < npick; i++)
      ppml[i] = psnd_chan2sec(picked[i], swhold);
  else
    for (i = 0; i < npick; i++)
      ppml[i] = picked[i];
  for (i = 0; i < nlabel; i++)
    if (labpos[i] != 0)
      labplot(vp, vp_box, picked, labpos, ppml, i, nlabel, lheight, box_height,
              xreal, xmin, xmax, ymin, ymax);
  free(labpos);
  free(picked);
  free(purged);
  free(ppml);
}


x86 assembly (clang, -O0):
<psnd_paperplot_labels>:
push   %rbp
mov    %rsp,%rbp
sub    $0x80,%rsp
mov    0x68(%rbp),%eax
mov    0x60(%rbp),%eax
movss  0x58(%rbp),%xmm8
movss  0x50(%rbp),%xmm8
movss  0x48(%rbp),%xmm8
movss  0x40(%rbp),%xmm8
movss  0x38(%rbp),%xmm8
movss  0x30(%rbp),%xmm8
movss  0x28(%rbp),%xmm8
movss  0x20(%rbp),%xmm8
movss  0x18(%rbp),%xmm8
movss  0x10(%rbp),%xmm8
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %rdx,-0x10(%rbp)
movss  %xmm0,-0x14(%rbp)
movss  %xmm1,-0x18(%rbp)
movss  %xmm2,-0x1c(%rbp)
movss  %xmm3,-0x20(%rbp)
movss  %xmm4,-0x24(%rbp)
movss  %xmm5,-0x28(%rbp)
movss  %xmm6,-0x2c(%rbp)
movss  %xmm7,-0x30(%rbp)
mov    %ecx,-0x34(%rbp)
mov    %r8d,-0x38(%rbp)
mov    %r9d,-0x3c(%rbp)
movl   $0x0,-0x48(%rbp)
mov    $0x800,%edi
call   1070 <malloc@plt>
mov    %rax,-0x50(%rbp)
mov    $0x800,%edi
call   1070 <malloc@plt>
mov    %rax,-0x58(%rbp)
mov    $0x800,%edi
call   1070 <malloc@plt>
mov    %rax,-0x60(%rbp)
mov    $0x800,%edi
call   1070 <malloc@plt>
mov    %rax,-0x68(%rbp)
movss  -0x28(%rbp),%xmm0
subss  -0x24(%rbp),%xmm0
divss  0x28(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
call   10b0 <floor@plt>
cvttsd2si %xmm0,%eax
mov    %eax,-0x6c(%rbp)
mov    -0x10(%rbp),%rdi
movss  -0x14(%rbp),%xmm0
movss  0xd77(%rip),%xmm1
subss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x18(%rbp),%xmm1
movss  0xd62(%rip),%xmm2
subss  %xmm2,%xmm1
cvtss2sd %xmm1,%xmm1
movss  0x20(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
movss  0x10(%rbp),%xmm3
cvtss2sd %xmm3,%xmm3
movss  0x18(%rbp),%xmm4
cvtss2sd %xmm4,%xmm4
mov    -0x34(%rbp),%esi
mov    -0x58(%rbp),%rcx
mov    -0x60(%rbp),%r8
mov    -0x48(%rbp),%r9d
mov    -0x6c(%rbp),%r10d
mov    -0x38(%rbp),%eax
lea    -0x44(%rbp),%rdx
mov    %r10d,(%rsp)
mov    %eax,0x8(%rsp)
mov    $0x5,%al
call   1090 <pkpick@plt>
mov    -0x58(%rbp),%rdi
mov    -0x44(%rbp),%esi
mov    -0x50(%rbp),%rdx
mov    -0x6c(%rbp),%ecx
movss  -0x14(%rbp),%xmm0
movss  0xcfb(%rip),%xmm1
subss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x18(%rbp),%xmm1
movss  0xce6(%rip),%xmm2
subss  %xmm2,%xmm1
cvtss2sd %xmm1,%xmm1
mov    $0x2,%al
call   1050 <expand_label@plt>
cmpl   $0x0,0x68(%rbp)
jne    13af <psnd_paperplot_labels+0x21f>
movl   $0x0,-0x40(%rbp)
mov    -0x40(%rbp),%eax
cmp    -0x44(%rbp),%eax
jge    13aa <psnd_paperplot_labels+0x21a>
mov    -0x58(%rbp),%rax
movslq -0x40(%rbp),%rcx
mov    (%rax,%rcx,4),%edi
movss  0x38(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  0x40(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
mov    -0x3c(%rbp),%esi
movss  0x48(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
movss  0x50(%rbp),%xmm3
cvtss2sd %xmm3,%xmm3
movss  0x58(%rbp),%xmm4
cvtss2sd %xmm4,%xmm4
mov    0x60(%rbp),%edx
mov    $0x5,%al
call   1060 <psnd_chan2ppm@plt>
cvtsi2ss %eax,%xmm0
mov    -0x68(%rbp),%rax
movslq -0x40(%rbp),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x40(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x40(%rbp)
jmp    133a <psnd_paperplot_labels+0x1aa>
jmp    14d2 <psnd_paperplot_labels+0x342>
cmpl   $0x1,0x68(%rbp)
jne    142c <psnd_paperplot_labels+0x29c>
movl   $0x0,-0x40(%rbp)
mov    -0x40(%rbp),%eax
cmp    -0x44(%rbp),%eax
jge    1427 <psnd_paperplot_labels+0x297>
mov    -0x58(%rbp),%rax
movslq -0x40(%rbp),%rcx
mov    (%rax,%rcx,4),%edi
movss  0x40(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
mov    -0x3c(%rbp),%esi
movss  0x48(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
movss  0x50(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
movss  0x58(%rbp),%xmm3
cvtss2sd %xmm3,%xmm3
mov    0x60(%rbp),%edx
mov    $0x4,%al
call   1080 <psnd_chan2hz@plt>
cvtsi2ss %eax,%xmm0
mov    -0x68(%rbp),%rax
movslq -0x40(%rbp),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x40(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x40(%rbp)
jmp    13c0 <psnd_paperplot_labels+0x230>
jmp    14cd <psnd_paperplot_labels+0x33d>
cmpl   $0x2,0x68(%rbp)
jne    1488 <psnd_paperplot_labels+0x2f8>
movl   $0x0,-0x40(%rbp)
mov    -0x40(%rbp),%eax
cmp    -0x44(%rbp),%eax
jge    1483 <psnd_paperplot_labels+0x2f3>
mov    -0x58(%rbp),%rax
movslq -0x40(%rbp),%rcx
mov    (%rax,%rcx,4),%edi
movss  0x40(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
mov    $0x1,%al
call   1040 <psnd_chan2sec@plt>
cvtsi2ss %eax,%xmm0
mov    -0x68(%rbp),%rax
movslq -0x40(%rbp),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x40(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x40(%rbp)
jmp    143d <psnd_paperplot_labels+0x2ad>
jmp    14c8 <psnd_paperplot_labels+0x338>
movl   $0x0,-0x40(%rbp)
mov    -0x40(%rbp),%eax
cmp    -0x44(%rbp),%eax
jge    14c3 <psnd_paperplot_labels+0x333>
mov    -0x58(%rbp),%rax
movslq -0x40(%rbp),%rcx
cvtsi2ssl (%rax,%rcx,4),%xmm0
mov    -0x68(%rbp),%rax
movslq -0x40(%rbp),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x40(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x40(%rbp)
jmp    148f <psnd_paperplot_labels+0x2ff>
jmp    14c8 <psnd_paperplot_labels+0x338>
jmp    14cd <psnd_paperplot_labels+0x33d>
jmp    14d2 <psnd_paperplot_labels+0x342>
movl   $0x0,-0x40(%rbp)
mov    -0x40(%rbp),%eax
cmp    -0x6c(%rbp),%eax
jge    156e <psnd_paperplot_labels+0x3de>
mov    -0x50(%rbp),%rax
movslq -0x40(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
je     155b <psnd_paperplot_labels+0x3cb>
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    -0x58(%rbp),%rdx
mov    -0x50(%rbp),%rcx
mov    -0x68(%rbp),%r8
mov    -0x40(%rbp),%r9d
mov    -0x6c(%rbp),%r10d
movss  0x28(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  0x30(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
mov    -0x10(%rbp),%rax
movss  -0x14(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
movss  -0x18(%rbp),%xmm3
cvtss2sd %xmm3,%xmm3
movss  -0x1c(%rbp),%xmm4
cvtss2sd %xmm4,%xmm4
movss  -0x20(%rbp),%xmm5
cvtss2sd %xmm5,%xmm5
mov    %r10d,(%rsp)
mov    %rax,0x8(%rsp)
mov    $0x6,%al
call   10a0 <labplot@plt>
jmp    1560 <psnd_paperplot_labels+0x3d0>
mov    -0x40(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x40(%rbp)
jmp    14d9 <psnd_paperplot_labels+0x349>
mov    -0x50(%rbp),%rdi
call   1030 <free@plt>
mov    -0x58(%rbp),%rdi
call   1030 <free@plt>
mov    -0x60(%rbp),%rdi
call   1030 <free@plt>
mov    -0x68(%rbp),%rdi
call   1030 <free@plt>
add    $0x80,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<psnd_paperplot_labels>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x68,%rsp
mov    %r9d,%r12d
mov    %r8,0x18(%rsp)
mov    %ecx,0x20(%rsp)
movss  %xmm5,0x10(%rsp)
movss  %xmm4,0x8(%rsp)
movss  %xmm3,0x44(%rsp)
movss  %xmm2,0x40(%rsp)
movss  %xmm1,0x30(%rsp)
movss  %xmm0,0x2c(%rsp)
mov    %rdx,0x50(%rsp)
mov    %esi,0x4c(%rsp)
mov    %edi,0x48(%rsp)
mov    $0x800,%edi
call   1080 <malloc@plt>
mov    %rax,%rbx
mov    $0x800,%edi
call   1080 <malloc@plt>
mov    %rax,%r15
mov    $0x800,%edi
call   1080 <malloc@plt>
mov    %rax,%rbp
mov    $0x800,%edi
call   1080 <malloc@plt>
mov    %rax,%r13
movss  0x10(%rsp),%xmm0
subss  0x8(%rsp),%xmm0
divss  0xb8(%rsp),%xmm0
call   1050 <floorf@plt>
cvttss2si %xmm0,%r14d
movss  0xdca(%rip),%xmm0
movss  0x2c(%rsp),%xmm1
addss  %xmm0,%xmm1
xorps  %xmm5,%xmm5
cvtss2sd %xmm1,%xmm5
movsd  %xmm5,0x10(%rsp)
addss  0x30(%rsp),%xmm0
xorps  %xmm1,%xmm1
cvtss2sd %xmm0,%xmm1
movsd  %xmm1,0x8(%rsp)
movss  0xb0(%rsp),%xmm0
xorps  %xmm2,%xmm2
cvtss2sd %xmm0,%xmm2
movss  0xa0(%rsp),%xmm0
xorps  %xmm3,%xmm3
cvtss2sd %xmm0,%xmm3
movss  0xa8(%rsp),%xmm0
cvtss2sd %xmm0,%xmm4
lea    0x4(%rsp),%rdx
mov    0x50(%rsp),%rdi
movaps %xmm5,%xmm0
mov    0x20(%rsp),%esi
mov    %r15,%rcx
mov    %rbp,0x60(%rsp)
mov    %rbp,%r8
xor    %r9d,%r9d
mov    $0x5,%al
push   0x18(%rsp)
push   %r14
call   10a0 <pkpick@plt>
add    $0x10,%rsp
mov    0x4(%rsp),%esi
mov    %r15,%rdi
mov    %rbx,%rdx
mov    %r14d,%ecx
movsd  0x10(%rsp),%xmm0
movsd  0x8(%rsp),%xmm1
mov    $0x2,%al
call   1060 <expand_label@plt>
mov    0xf8(%rsp),%eax
test   %eax,%eax
mov    %rbx,0x58(%rsp)
je     1352 <psnd_paperplot_labels+0x1c2>
cmp    $0x1,%eax
je     141f <psnd_paperplot_labels+0x28f>
cmp    $0x2,%eax
jne    14d9 <psnd_paperplot_labels+0x349>
cmpl   $0x0,0x4(%rsp)
jle    15a9 <psnd_paperplot_labels+0x419>
movss  0xd0(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x18(%rsp)
xor    %ebp,%ebp
nop
mov    (%r15,%rbp,4),%edi
movsd  0x18(%rsp),%xmm0
mov    $0x1,%al
call   1040 <psnd_chan2sec@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
movss  %xmm0,0x0(%r13,%rbp,4)
add    $0x1,%rbp
movslq 0x4(%rsp),%rax
cmp    %rax,%rbp
jl     1320 <psnd_paperplot_labels+0x190>
jmp    15a9 <psnd_paperplot_labels+0x419>
cmpl   $0x0,0x4(%rsp)
mov    0xf0(%rsp),%ebx
jle    15a9 <psnd_paperplot_labels+0x419>
movss  0xc8(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x18(%rsp)
movss  0xd0(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x20(%rsp)
movss  0xd8(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x10(%rsp)
movss  0xe0(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x8(%rsp)
movss  0xe8(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x38(%rsp)
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nop
mov    (%r15,%rbp,4),%edi
movsd  0x18(%rsp),%xmm0
movsd  0x20(%rsp),%xmm1
mov    %r12d,%esi
movsd  0x10(%rsp),%xmm2
movsd  0x8(%rsp),%xmm3
movsd  0x38(%rsp),%xmm4
mov    %ebx,%edx
mov    $0x5,%al
call   1070 <psnd_chan2ppm@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
movss  %xmm0,0x0(%r13,%rbp,4)
add    $0x1,%rbp
movslq 0x4(%rsp),%rax
cmp    %rax,%rbp
jl     13d0 <psnd_paperplot_labels+0x240>
jmp    15a9 <psnd_paperplot_labels+0x419>
cmpl   $0x0,0x4(%rsp)
mov    0xf0(%rsp),%eax
jle    15a9 <psnd_paperplot_labels+0x419>
mov    %r12d,%ebx
mov    %eax,%r12d
movss  0xd0(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x18(%rsp)
movss  0xd8(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x20(%rsp)
movss  0xe0(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x10(%rsp)
movss  0xe8(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x8(%rsp)
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nop
mov    (%r15,%rbp,4),%edi
movsd  0x18(%rsp),%xmm0
mov    %ebx,%esi
movsd  0x20(%rsp),%xmm1
movsd  0x10(%rsp),%xmm2
movsd  0x8(%rsp),%xmm3
mov    %r12d,%edx
mov    $0x4,%al
call   1090 <psnd_chan2hz@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
movss  %xmm0,0x0(%r13,%rbp,4)
add    $0x1,%rbp
movslq 0x4(%rsp),%rax
cmp    %rax,%rbp
jl     1490 <psnd_paperplot_labels+0x300>
jmp    15a9 <psnd_paperplot_labels+0x419>
mov    0x4(%rsp),%eax
test   %eax,%eax
jle    15a9 <psnd_paperplot_labels+0x419>
cmp    $0x8,%eax
jae    14f1 <psnd_paperplot_labels+0x361>
xor    %ecx,%ecx
jmp    1590 <psnd_paperplot_labels+0x400>
mov    %eax,%ecx
and    $0xfffffff8,%ecx
lea    -0x8(%rcx),%rsi
mov    %rsi,%rdx
shr    $0x3,%rdx
add    $0x1,%rdx
test   %rsi,%rsi
je     16b9 <psnd_paperplot_labels+0x529>
mov    %rdx,%rdi
and    $0xfffffffffffffffe,%rdi
xor    %esi,%esi
nopw   0x0(%rax,%rax,1)
movups (%r15,%rsi,4),%xmm0
movups 0x10(%r15,%rsi,4),%xmm1
cvtdq2ps %xmm0,%xmm0
cvtdq2ps %xmm1,%xmm1
movups %xmm0,0x0(%r13,%rsi,4)
movups %xmm1,0x10(%r13,%rsi,4)
movups 0x20(%r15,%rsi,4),%xmm0
movups 0x30(%r15,%rsi,4),%xmm1
cvtdq2ps %xmm0,%xmm0
cvtdq2ps %xmm1,%xmm1
movups %xmm0,0x20(%r13,%rsi,4)
movups %xmm1,0x30(%r13,%rsi,4)
add    $0x10,%rsi
add    $0xfffffffffffffffe,%rdi
jne    1520 <psnd_paperplot_labels+0x390>
test   $0x1,%dl
je     1587 <psnd_paperplot_labels+0x3f7>
movups (%r15,%rsi,4),%xmm0
movups 0x10(%r15,%rsi,4),%xmm1
cvtdq2ps %xmm0,%xmm0
cvtdq2ps %xmm1,%xmm1
movups %xmm0,0x0(%r13,%rsi,4)
movups %xmm1,0x10(%r13,%rsi,4)
cmp    %rax,%rcx
je     15a9 <psnd_paperplot_labels+0x419>
nopl   0x0(%rax)
xorps  %xmm0,%xmm0
cvtsi2ssl (%r15,%rcx,4),%xmm0
movss  %xmm0,0x0(%r13,%rcx,4)
add    $0x1,%rcx
cmp    %rcx,%rax
jne    1590 <psnd_paperplot_labels+0x400>
test   %r14d,%r14d
mov    0x50(%rsp),%r12
mov    0x58(%rsp),%rbx
jle    1688 <psnd_paperplot_labels+0x4f8>
movss  0xc0(%rsp),%xmm0
movss  0xb8(%rsp),%xmm1
cvtss2sd %xmm1,%xmm1
movsd  %xmm1,0x18(%rsp)
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x20(%rsp)
movss  0x2c(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x10(%rsp)
movss  0x30(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x8(%rsp)
movss  0x40(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x38(%rsp)
movss  0x44(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,0x30(%rsp)
xor    %ebp,%ebp
jmp    1639 <psnd_paperplot_labels+0x4a9>
cs nopw 0x0(%rax,%rax,1)
add    $0x1,%rbp
cmp    %rbp,%r14
je     1688 <psnd_paperplot_labels+0x4f8>
cmpl   $0x0,(%rbx,%rbp,4)
je     1630 <psnd_paperplot_labels+0x4a0>
mov    0x48(%rsp),%edi
mov    0x4c(%rsp),%esi
mov    %r15,%rdx
mov    %rbx,%rcx
mov    %r13,%r8
mov    %ebp,%r9d
movsd  0x18(%rsp),%xmm0
movsd  0x20(%rsp),%xmm1
movsd  0x10(%rsp),%xmm2
movsd  0x8(%rsp),%xmm3
movsd  0x38(%rsp),%xmm4
movsd  0x30(%rsp),%xmm5
mov    $0x6,%al
push   %r12
push   %r14
call   10b0 <labplot@plt>
add    $0x10,%rsp
jmp    1630 <psnd_paperplot_labels+0x4a0>
mov    %rbx,%rdi
call   1030 <free@plt>
mov    %r15,%rdi
call   1030 <free@plt>
mov    0x60(%rsp),%rdi
call   1030 <free@plt>
mov    %r13,%rdi
call   1030 <free@plt>
add    $0x68,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
xor    %esi,%esi
test   $0x1,%dl
jne    156a <psnd_paperplot_labels+0x3da>
jmp    1587 <psnd_paperplot_labels+0x3f7>

LLVM IR (-O0):
define void @psnd_paperplot_labels(i32 %0, i32 %1, float* %2, float %3, float %4, float %5, float %6, float %7, float %8, float %9, float %10, float %11, float %12, float %13, i32 %14, i32 %15, float %16, float %17, float %18, float %19, i32 %20, float %21, float %22, float %23, i32 %24, i32 %25) {
%27 = alloca i32
%28 = alloca i32
%29 = alloca float*
%30 = alloca float
%31 = alloca float
%32 = alloca float
%33 = alloca float
%34 = alloca float
%35 = alloca float
%36 = alloca float
%37 = alloca float
%38 = alloca float
%39 = alloca float
%40 = alloca float
%41 = alloca i32
%42 = alloca i32
%43 = alloca float
%44 = alloca float
%45 = alloca float
%46 = alloca float
%47 = alloca i32
%48 = alloca float
%49 = alloca float
%50 = alloca float
%51 = alloca i32
%52 = alloca i32
%53 = alloca i32
%54 = alloca i32
%55 = alloca i32
%56 = alloca i32*
%57 = alloca i32*
%58 = alloca i32*
%59 = alloca float*
%60 = alloca i32
store i32 %0, i32* %27
store i32 %1, i32* %28
store float* %2, float** %29
store float %3, float* %30
store float %4, float* %31
store float %5, float* %32
store float %6, float* %33
store float %7, float* %34
store float %8, float* %35
store float %9, float* %36
store float %10, float* %37
store float %11, float* %38
store float %12, float* %39
store float %13, float* %40
store i32 %14, i32* %41
store i32 %15, i32* %42
store float %16, float* %43
store float %17, float* %44
store float %18, float* %45
store float %19, float* %46
store i32 %20, i32* %47
store float %21, float* %48
store float %22, float* %49
store float %23, float* %50
store i32 %24, i32* %51
store i32 %25, i32* %52
store i32 0, i32* %55
%61 = call i8* @malloc(i64 2048)
%62 = bitcast i8* %61 to i32*
store i32* %62, i32** %56
%63 = call i8* @malloc(i64 2048)
%64 = bitcast i8* %63 to i32*
store i32* %64, i32** %57
%65 = call i8* @malloc(i64 2048)
%66 = bitcast i8* %65 to i32*
store i32* %66, i32** %58
%67 = call i8* @malloc(i64 2048)
%68 = bitcast i8* %67 to float*
store float* %68, float** %59
%69 = load float, float* %35
%70 = load float, float* %34
%71 = fsub float %69, %70
%72 = load float, float* %43
%73 = fdiv float %71, %72
%74 = fpext float %73 to double
%75 = call double @llvm.floor.f64(double %74)
%76 = fptosi double %75 to i32
store i32 %76, i32* %60
%77 = load float*, float** %29
%78 = load float, float* %30
%79 = fsub float %78, 1.000000e+00
%80 = fpext float %79 to double
%81 = load float, float* %31
%82 = fsub float %81, 1.000000e+00
%83 = fpext float %82 to double
%84 = load float, float* %40
%85 = fpext float %84 to double
%86 = load float, float* %38
%87 = fpext float %86 to double
%88 = load float, float* %39
%89 = fpext float %88 to double
%90 = load i32, i32* %41
%91 = load i32*, i32** %57
%92 = load i32*, i32** %58
%93 = load i32, i32* %55
%94 = load i32, i32* %60
%95 = load i32, i32* %42
%96 = call i32 (float*, double, double, double, double, double, i32, i32*, i32*, i32*, i32, i32, i32, ...) bitcast (i32 (...)* @pkpick to i32 (float*, double, double, double, double, double, i32, i32*, i32*, i32*, i32, i32, i32, ...)*)(float* %77, double %80, double %83, double %85, double %87, double %89, i32 %90, i32* %54, i32* %91, i32* %92, i32 %93, i32 %94, i32 %95)
%97 = load i32*, i32** %57
%98 = load i32, i32* %54
%99 = load i32*, i32** %56
%100 = load i32, i32* %60
%101 = load float, float* %30
%102 = fsub float %101, 1.000000e+00
%103 = fpext float %102 to double
%104 = load float, float* %31
%105 = fsub float %104, 1.000000e+00
%106 = fpext float %105 to double
%107 = call i32 (i32*, i32, i32*, i32, double, double, ...) bitcast (i32 (...)* @expand_label to i32 (i32*, i32, i32*, i32, double, double, ...)*)(i32* %97, i32 %98, i32* %99, i32 %100, double %103, double %106)
%108 = load i32, i32* %52
%109 = icmp eq i32 %108, 0
br i1 %109, label %110, label %143
110: ; preds = %26
store i32 0, i32* %53
br label %111
111: ; preds = %139, %110
%112 = load i32, i32* %53
%113 = load i32, i32* %54
%114 = icmp slt i32 %112, %113
br i1 %114, label %115, label %142
115: ; preds = %111
%116 = load i32*, i32** %57
%117 = load i32, i32* %53
%118 = sext i32 %117 to i64
%119 = getelementptr inbounds i32, i32* %116, i64 %118
%120 = load i32, i32* %119
%121 = load float, float* %45
%122 = fpext float %121 to double
%123 = load float, float* %46
%124 = fpext float %123 to double
%125 = load i32, i32* %47
%126 = load float, float* %48
%127 = fpext float %126 to double
%128 = load float, float* %49
%129 = fpext float %128 to double
%130 = load float, float* %50
%131 = fpext float %130 to double
%132 = load i32, i32* %51
%133 = call i32 (i32, double, double, i32, double, double, double, i32, ...) bitcast (i32 (...)* @psnd_chan2ppm to i32 (i32, double, double, i32, double, double, double, i32, ...)*)(i32 %120, double %122, double %124, i32 %125, double %127, double %129, double %131, i32 %132)
%134 = sitofp i32 %133 to float
%135 = load float*, float** %59
%136 = load i32, i32* %53
%137 = sext i32 %136 to i64
%138 = getelementptr inbounds float, float* %135, i64 %137
store float %134, float* %138
br label %139
139: ; preds = %115
%140 = load i32, i32* %53
%141 = add nsw i32 %140, 1
store i32 %141, i32* %53
br label %111
142: ; preds = %111
br label %225
143: ; preds = %26
%144 = load i32, i32* %52
%145 = icmp eq i32 %144, 1
br i1 %145, label %146, label %177
146: ; preds = %143
store i32 0, i32* %53
br label %147
147: ; preds = %173, %146
%148 = load i32, i32* %53
%149 = load i32, i32* %54
%150 = icmp slt i32 %148, %149
br i1 %150, label %151, label %176
151: ; preds = %147
%152 = load i32*, i32** %57
%153 = load i32, i32* %53
%154 = sext i32 %153 to i64
%155 = getelementptr inbounds i32, i32* %152, i64 %154
%156 = load i32, i32* %155
%157 = load float, float* %46
%158 = fpext float %157 to double
%159 = load i32, i32* %47
%160 = load float, float* %48
%161 = fpext float %160 to double
%162 = load float, float* %49
%163 = fpext float %162 to double
%164 = load float, float* %50
%165 = fpext float %164 to double
%166 = load i32, i32* %51
%167 = call i32 (i32, double, i32, double, double, double, i32, ...) bitcast (i32 (...)* @psnd_chan2hz to i32 (i32, double, i32, double, double, double, i32, ...)*)(i32 %156, double %158, i32 %159, double %161, double %163, double %165, i32 %166)
%168 = sitofp i32 %167 to float
%169 = load float*, float** %59
%170 = load i32, i32* %53
%171 = sext i32 %170 to i64
%172 = getelementptr inbounds float, float* %169, i64 %171
store float %168, float* %172
br label %173
173: ; preds = %151
%174 = load i32, i32* %53
%175 = add nsw i32 %174, 1
store i32 %175, i32* %53
br label %147
176: ; preds = %147
br label %224
177: ; preds = %143
%178 = load i32, i32* %52
%179 = icmp eq i32 %178, 2
br i1 %179, label %180, label %203
180: ; preds = %177
store i32 0, i32* %53
br label %181
181: ; preds = %199, %180
%182 = load i32, i32* %53
%183 = load i32, i32* %54
%184 = icmp slt i32 %182, %183
br i1 %184, label %185, label %202
185: ; preds = %181
%186 = load i32*, i32** %57
%187 = load i32, i32* %53
%188 = sext i32 %187 to i64
%189 = getelementptr inbounds i32, i32* %186, i64 %188
%190 = load i32, i32* %189
%191 = load float, float* %46
%192 = fpext float %191 to double
%193 = call i32 (i32, double, ...) bitcast (i32 (...)* @psnd_chan2sec to i32 (i32, double, ...)*)(i32 %190, double %192)
%194 = sitofp i32 %193 to float
%195 = load float*, float** %59
%196 = load i32, i32* %53
%197 = sext i32 %196 to i64
%198 = getelementptr inbounds float, float* %195, i64 %197
store float %194, float* %198
br label %199
199: ; preds = %185
%200 = load i32, i32* %53
%201 = add nsw i32 %200, 1
store i32 %201, i32* %53
br label %181
202: ; preds = %181
br label %223
203: ; preds = %177
store i32 0, i32* %53
br label %204
204: ; preds = %219, %203
%205 = load i32, i32* %53
%206 = load i32, i32* %54
%207 = icmp slt i32 %205, %206
br i1 %207, label %208, label %222
208: ; preds = %204
%209 = load i32*, i32** %57
%210 = load i32, i32* %53
%211 = sext i32 %210 to i64
%212 = getelementptr inbounds i32, i32* %209, i64 %211
%213 = load i32, i32* %212
%214 = sitofp i32 %213 to float
%215 = load float*, float** %59
%216 = load i32, i32* %53
%217 = sext i32 %216 to i64
%218 = getelementptr inbounds float, float* %215, i64 %217
store float %214, float* %218
br label %219
219: ; preds = %208
%220 = load i32, i32* %53
%221 = add nsw i32 %220, 1
store i32 %221, i32* %53
br label %204
222: ; preds = %204
br label %223
223: ; preds = %222, %202
br label %224
224: ; preds = %223, %176
br label %225
225: ; preds = %224, %142
store i32 0, i32* %53
br label %226
226: ; preds = %260, %225
%227 = load i32, i32* %53
%228 = load i32, i32* %60
%229 = icmp slt i32 %227, %228
br i1 %229, label %230, label %263
230: ; preds = %226
%231 = load i32*, i32** %56
%232 = load i32, i32* %53
%233 = sext i32 %232 to i64
%234 = getelementptr inbounds i32, i32* %231, i64 %233
%235 = load i32, i32* %234
%236 = icmp ne i32 %235, 0
br i1 %236, label %237, label %259
237: ; preds = %230
%238 = load i32, i32* %27
%239 = load i32, i32* %28
%240 = load i32*, i32** %57
%241 = load i32*, i32** %56
%242 = load float*, float** %59
%243 = load i32, i32* %53
%244 = load i32, i32* %60
%245 = load float, float* %43
%246 = fpext float %245 to double
%247 = load float, float* %44
%248 = fpext float %247 to double
%249 = load float*, float** %29
%250 = load float, float* %30
%251 = fpext float %250 to double
%252 = load float, float* %31
%253 = fpext float %252 to double
%254 = load float, float* %32
%255 = fpext float %254 to double
%256 = load float, float* %33
%257 = fpext float %256 to double
%258 = call i32 (i32, i32, i32*, i32*, float*, i32, i32, double, double, float*, double, double, double, double, ...) bitcast (i32 (...)* @labplot to i32 (i32, i32, i32*, i32*, float*, i32, i32, double, double, float*, double, double, double, double, ...)*)(i32 %238, i32 %239, i32* %240, i32* %241, float* %242, i32 %243, i32 %244, double %246, double %248, float* %249, double %251, double %253, double %255, double %257)
br label %259
259: ; preds = %237, %230
br label %260
260: ; preds = %259
%261 = load i32, i32* %53
%262 = add nsw i32 %261, 1
store i32 %262, i32* %53
br label %226
263: ; preds = %226
%264 = load i32*, i32** %56
%265 = bitcast i32* %264 to i8*
%266 = load i32*, i32** %57
%267 = bitcast i32* %266 to i8*
%268 = load i32*, i32** %58
%269 = bitcast i32* %268 to i8*
%270 = load float*, float** %59
%271 = bitcast float* %270 to i8*
ret void
}

LLVM IR (-O2):
define void @psnd_paperplot_labels(i32 %0, i32 %1, float* %2, float %3, float %4, float %5, float %6, float %7, float %8, float %9, float %10, float %11, float %12, float %13, i32 %14, i32 %15, float %16, float %17, float %18, float %19, i32 %20, float %21, float %22, float %23, i32 %24, i32 %25) {
%27 = alloca i32
%28 = bitcast i32* %27 to i8*
%29 = tail call dereferenceable_or_null(2048) i8* @malloc(i64 2048)
%30 = bitcast i8* %29 to i32*
%31 = tail call dereferenceable_or_null(2048) i8* @malloc(i64 2048)
%32 = bitcast i8* %31 to i32*
%33 = tail call dereferenceable_or_null(2048) i8* @malloc(i64 2048)
%34 = bitcast i8* %33 to i32*
%35 = tail call dereferenceable_or_null(2048) i8* @malloc(i64 2048)
%36 = bitcast i8* %35 to float*
%37 = fsub float %8, %7
%38 = fdiv float %37, %16
%39 = tail call float @llvm.floor.f32(float %38)
%40 = fptosi float %39 to i32
%41 = fadd float %3, -1.000000e+00
%42 = fpext float %41 to double
%43 = fadd float %4, -1.000000e+00
%44 = fpext float %43 to double
%45 = fpext float %13 to double
%46 = fpext float %11 to double
%47 = fpext float %12 to double
%48 = call i32 (float*, double, double, double, double, double, i32, i32*, i32*, i32*, i32, i32, i32, ...) bitcast (i32 (...)* @pkpick to i32 (float*, double, double, double, double, double, i32, i32*, i32*, i32*, i32, i32, i32, ...)*)(float* %2, double %42, double %44, double %45, double %46, double %47, i32 %14, i32* %27, i32* %32, i32* %34, i32 0, i32 %40, i32 %15)
%49 = load i32, i32* %27
%50 = call i32 (i32*, i32, i32*, i32, double, double, ...) bitcast (i32 (...)* @expand_label to i32 (i32*, i32, i32*, i32, double, double, ...)*)(i32* %32, i32 %49, i32* %30, i32 %40, double %42, double %44)
switch i32 %25, label %73 [
i32 0, label %64
i32 1, label %56
i32 2, label %51
]
51: ; preds = %26
%52 = load i32, i32* %27
%53 = icmp sgt i32 %52, 0
br i1 %53, label %54, label %180
54: ; preds = %51
%55 = fpext float %19 to double
br label %161
56: ; preds = %26
%57 = load i32, i32* %27
%58 = icmp sgt i32 %57, 0
br i1 %58, label %59, label %180
59: ; preds = %56
%60 = fpext float %19 to double
%61 = fpext float %21 to double
%62 = fpext float %22 to double
%63 = fpext float %23 to double
br label %150
64: ; preds = %26
%65 = load i32, i32* %27
%66 = icmp sgt i32 %65, 0
br i1 %66, label %67, label %180
67: ; preds = %64
%68 = fpext float %18 to double
%69 = fpext float %19 to double
%70 = fpext float %21 to double
%71 = fpext float %22 to double
%72 = fpext float %23 to double
br label %139
73: ; preds = %26
%74 = load i32, i32* %27
%75 = icmp sgt i32 %74, 0
br i1 %75, label %76, label %180
76: ; preds = %73
%77 = zext i32 %74 to i64
%78 = icmp ult i32 %74, 8
br i1 %78, label %137, label %79
79: ; preds = %76
%80 = and i64 %77, 4294967288
%81 = add nsw i64 %80, -8
%82 = lshr exact i64 %81, 3
%83 = add nuw nsw i64 %82, 1
%84 = and i64 %83, 1
%85 = icmp eq i64 %81, 0
br i1 %85, label %119, label %86
86: ; preds = %79
%87 = and i64 %83, 4611686018427387902
br label %88
88: ; preds = %88, %86
%89 = phi i64 [ 0, %86 ], [ %116, %88 ]
%90 = phi i64 [ 0, %86 ], [ %117, %88 ]
%91 = getelementptr inbounds i32, i32* %32, i64 %89
%92 = bitcast i32* %91 to <4 x i32>*
%93 = load <4 x i32>, <4 x i32>* %92
%94 = getelementptr inbounds i32, i32* %91, i64 4
%95 = bitcast i32* %94 to <4 x i32>*
%96 = load <4 x i32>, <4 x i32>* %95
%97 = sitofp <4 x i32> %93 to <4 x float>
%98 = sitofp <4 x i32> %96 to <4 x float>
%99 = getelementptr inbounds float, float* %36, i64 %89
%100 = bitcast float* %99 to <4 x float>*
store <4 x float> %97, <4 x float>* %100
%101 = getelementptr inbounds float, float* %99, i64 4
%102 = bitcast float* %101 to <4 x float>*
store <4 x float> %98, <4 x float>* %102
%103 = or i64 %89, 8
%104 = getelementptr inbounds i32, i32* %32, i64 %103
%105 = bitcast i32* %104 to <4 x i32>*
%106 = load <4 x i32>, <4 x i32>* %105
%107 = getelementptr inbounds i32, i32* %104, i64 4
%108 = bitcast i32* %107 to <4 x i32>*
%109 = load <4 x i32>, <4 x i32>* %108
%110 = sitofp <4 x i32> %106 to <4 x float>
%111 = sitofp <4 x i32> %109 to <4 x float>
%112 = getelementptr inbounds float, float* %36, i64 %103
%113 = bitcast float* %112 to <4 x float>*
store <4 x float> %110, <4 x float>* %113
%114 = getelementptr inbounds float, float* %112, i64 4
%115 = bitcast float* %114 to <4 x float>*
store <4 x float> %111, <4 x float>* %115
%116 = add nuw i64 %89, 16
%117 = add i64 %90, 2
%118 = icmp eq i64 %117, %87
br i1 %118, label %119, label %88
119: ; preds = %88, %79
%120 = phi i64 [ 0, %79 ], [ %116, %88 ]
%121 = icmp eq i64 %84, 0
br i1 %121, label %135, label %122
122: ; preds = %119
%123 = getelementptr inbounds i32, i32* %32, i64 %120
%124 = bitcast i32* %123 to <4 x i32>*
%125 = load <4 x i32>, <4 x i32>* %124
%126 = getelementptr inbounds i32, i32* %123, i64 4
%127 = bitcast i32* %126 to <4 x i32>*
%128 = load <4 x i32>, <4 x i32>* %127
%129 = sitofp <4 x i32> %125 to <4 x float>
%130 = sitofp <4 x i32> %128 to <4 x float>
%131 = getelementptr inbounds float, float* %36, i64 %120
%132 = bitcast float* %131 to <4 x float>*
store <4 x float> %129, <4 x float>* %132
%133 = getelementptr inbounds float, float* %131, i64 4
%134 = bitcast float* %133 to <4 x float>*
store <4 x float> %130, <4 x float>* %134
br label %135
135: ; preds = %119, %122
%136 = icmp eq i64 %80, %77
br i1 %136, label %180, label %137
137: ; preds = %76, %135
%138 = phi i64 [ 0, %76 ], [ %80, %135 ]
br label %172
139: ; preds = %67, %139
%140 = phi i64 [ 0, %67 ], [ %146, %139 ]
%141 = getelementptr inbounds i32, i32* %32, i64 %140
%142 = load i32, i32* %141
%143 = call i32 (i32, double, double, i32, double, double, double, i32, ...) bitcast (i32 (...)* @psnd_chan2ppm to i32 (i32, double, double, i32, double, double, double, i32, ...)*)(i32 %142, double %68, double %69, i32 %20, double %70, double %71, double %72, i32 %24)
%144 = sitofp i32 %143 to float
%145 = getelementptr inbounds float, float* %36, i64 %140
store float %144, float* %145
%146 = add nuw nsw i64 %140, 1
%147 = load i32, i32* %27
%148 = sext i32 %147 to i64
%149 = icmp slt i64 %146, %148
br i1 %149, label %139, label %180
150: ; preds = %59, %150
%151 = phi i64 [ 0, %59 ], [ %157, %150 ]
%152 = getelementptr inbounds i32, i32* %32, i64 %151
%153 = load i32, i32* %152
%154 = call i32 (i32, double, i32, double, double, double, i32, ...) bitcast (i32 (...)* @psnd_chan2hz to i32 (i32, double, i32, double, double, double, i32, ...)*)(i32 %153, double %60, i32 %20, double %61, double %62, double %63, i32 %24)
%155 = sitofp i32 %154 to float
%156 = getelementptr inbounds float, float* %36, i64 %151
store float %155, float* %156
%157 = add nuw nsw i64 %151, 1
%158 = load i32, i32* %27
%159 = sext i32 %158 to i64
%160 = icmp slt i64 %157, %159
br i1 %160, label %150, label %180
161: ; preds = %54, %161
%162 = phi i64 [ 0, %54 ], [ %168, %161 ]
%163 = getelementptr inbounds i32, i32* %32, i64 %162
%164 = load i32, i32* %163
%165 = call i32 (i32, double, ...) bitcast (i32 (...)* @psnd_chan2sec to i32 (i32, double, ...)*)(i32 %164, double %55)
%166 = sitofp i32 %165 to float
%167 = getelementptr inbounds float, float* %36, i64 %162
store float %166, float* %167
%168 = add nuw nsw i64 %162, 1
%169 = load i32, i32* %27
%170 = sext i32 %169 to i64
%171 = icmp slt i64 %168, %170
br i1 %171, label %161, label %180
172: ; preds = %137, %172
%173 = phi i64 [ %178, %172 ], [ %138, %137 ]
%174 = getelementptr inbounds i32, i32* %32, i64 %173
%175 = load i32, i32* %174
%176 = sitofp i32 %175 to float
%177 = getelementptr inbounds float, float* %36, i64 %173
store float %176, float* %177
%178 = add nuw nsw i64 %173, 1
%179 = icmp eq i64 %178, %77
br i1 %179, label %180, label %172
180: ; preds = %161, %150, %139, %172, %135, %51, %56, %64, %73
%181 = icmp sgt i32 %40, 0
br i1 %181, label %182, label %201
182: ; preds = %180
%183 = fpext float %16 to double
%184 = fpext float %17 to double
%185 = fpext float %3 to double
%186 = fpext float %4 to double
%187 = fpext float %5 to double
%188 = fpext float %6 to double
%189 = zext i32 %40 to i64
br label %190
190: ; preds = %182, %198
%191 = phi i64 [ 0, %182 ], [ %199, %198 ]
%192 = getelementptr inbounds i32, i32* %30, i64 %191
%193 = load i32, i32* %192
%194 = icmp eq i32 %193, 0
br i1 %194, label %198, label %195
195: ; preds = %190
%196 = trunc i64 %191 to i32
%197 = call i32 (i32, i32, i32*, i32*, float*, i32, i32, double, double, float*, double, double, double, double, ...) bitcast (i32 (...)* @labplot to i32 (i32, i32, i32*, i32*, float*, i32, i32, double, double, float*, double, double, double, double, ...)*)(i32 %0, i32 %1, i32* %32, i32* %30, float* %36, i32 %196, i32 %40, double %183, double %184, float* %2, double %185, double %186, double %187, double %188)
br label %198
198: ; preds = %190, %195
%199 = add nuw nsw i64 %191, 1
%200 = icmp eq i64 %199, %189
br i1 %200, label %201, label %190
201: ; preds = %198, %180
ret void
}