void kernel_strsv_ln_inv_4_vs_lib4(int kmax, float *A, float *inv_diag_A,
                                   float *x, float *y, float *z, int km,
                                   int kn) {
  const int bs = 4;
  int k;
  float x_0, x_1, x_2, x_3, y_0 = 0, y_1 = 0, y_2 = 0, y_3 = 0;
  k = 0;
  for (; k < kmax - 3; k += 4) {
    x_0 = x[0];
    x_1 = x[1];
    x_2 = x[2];
    x_3 = x[3];
    y_0 -= A[0 + bs * 0] * x_0;
    y_1 -= A[1 + bs * 0] * x_0;
    y_2 -= A[2 + bs * 0] * x_0;
    y_3 -= A[3 + bs * 0] * x_0;
    y_0 -= A[0 + bs * 1] * x_1;
    y_1 -= A[1 + bs * 1] * x_1;
    y_2 -= A[2 + bs * 1] * x_1;
    y_3 -= A[3 + bs * 1] * x_1;
    y_0 -= A[0 + bs * 2] * x_2;
    y_1 -= A[1 + bs * 2] * x_2;
    y_2 -= A[2 + bs * 2] * x_2;
    y_3 -= A[3 + bs * 2] * x_2;
    y_0 -= A[0 + bs * 3] * x_3;
    y_1 -= A[1 + bs * 3] * x_3;
    y_2 -= A[2 + bs * 3] * x_3;
    y_3 -= A[3 + bs * 3] * x_3;
    A += 4 * bs;
    x += 4;
  }
  y_0 = y[0] + y_0;
  y_1 = y[1] + y_1;
  y_2 = y[2] + y_2;
  y_3 = y[3] + y_3;
  float a_00, a_10, a_20, a_30, a_11, a_21, a_31;
  a_00 = inv_diag_A[0];
  a_10 = A[1 + bs * 0];
  a_20 = A[2 + bs * 0];
  a_30 = A[3 + bs * 0];
  y_0 *= a_00;
  z[0] = y_0;
  y_1 -= a_10 * y_0;
  y_2 -= a_20 * y_0;
  y_3 -= a_30 * y_0;
  if (kn == 1) {
    if (km == 1)
      return;
    y[1] = y_1;
    if (km == 2)
      return;
    y[2] = y_2;
    if (km == 3)
      return;
    y[3] = y_3;
    return;
  }
  a_11 = inv_diag_A[1];
  a_21 = A[2 + bs * 1];
  a_31 = A[3 + bs * 1];
  y_1 *= a_11;
  z[1] = y_1;
  y_2 -= a_21 * y_1;
  y_3 -= a_31 * y_1;
  if (kn == 2) {
    if (km == 2)
      return;
    y[2] = y_2;
    if (km == 3)
      return;
    y[3] = y_3;
    return;
  }
  a_00 = inv_diag_A[2];
  a_10 = A[3 + bs * 2];
  y_2 *= a_00;
  z[2] = y_2;
  y_3 -= a_10 * y_2;
  if (kn == 3) {
    if (km == 3)
      return;
    y[3] = y_3;
    return;
  }
  a_11 = inv_diag_A[3];
  y_3 *= a_11;
  z[3] = y_3;
}


x86 assembly (clang, -O0):
<kernel_strsv_ln_inv_4_vs_lib4>:
push   %rbp
mov    %rsp,%rbp
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%eax
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
movl   $0x4,-0x34(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x4c(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x50(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x54(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x58(%rbp)
movl   $0x0,-0x38(%rbp)
mov    -0x38(%rbp),%eax
mov    -0x4(%rbp),%ecx
sub    $0x3,%ecx
cmp    %ecx,%eax
jge    148c <kernel_strsv_ln_inv_4_vs_lib4+0x38c>
mov    -0x20(%rbp),%rax
movss  (%rax),%xmm0
movss  %xmm0,-0x3c(%rbp)
mov    -0x20(%rbp),%rax
movss  0x4(%rax),%xmm0
movss  %xmm0,-0x40(%rbp)
mov    -0x20(%rbp),%rax
movss  0x8(%rax),%xmm0
movss  %xmm0,-0x44(%rbp)
mov    -0x20(%rbp),%rax
movss  0xc(%rax),%xmm0
movss  %xmm0,-0x48(%rbp)
mov    -0x10(%rbp),%rax
movss  (%rax),%xmm0
movss  -0x3c(%rbp),%xmm2
movss  -0x4c(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x4c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x4(%rax),%xmm0
movss  -0x3c(%rbp),%xmm2
movss  -0x50(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x50(%rbp)
mov    -0x10(%rbp),%rax
movss  0x8(%rax),%xmm0
movss  -0x3c(%rbp),%xmm2
movss  -0x54(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x54(%rbp)
mov    -0x10(%rbp),%rax
movss  0xc(%rax),%xmm0
movss  -0x3c(%rbp),%xmm2
movss  -0x58(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x58(%rbp)
mov    -0x10(%rbp),%rax
movss  0x10(%rax),%xmm0
movss  -0x40(%rbp),%xmm2
movss  -0x4c(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x4c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x14(%rax),%xmm0
movss  -0x40(%rbp),%xmm2
movss  -0x50(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x50(%rbp)
mov    -0x10(%rbp),%rax
movss  0x18(%rax),%xmm0
movss  -0x40(%rbp),%xmm2
movss  -0x54(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x54(%rbp)
mov    -0x10(%rbp),%rax
movss  0x1c(%rax),%xmm0
movss  -0x40(%rbp),%xmm2
movss  -0x58(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x58(%rbp)
mov    -0x10(%rbp),%rax
movss  0x20(%rax),%xmm0
movss  -0x44(%rbp),%xmm2
movss  -0x4c(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x4c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x24(%rax),%xmm0
movss  -0x44(%rbp),%xmm2
movss  -0x50(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x50(%rbp)
mov    -0x10(%rbp),%rax
movss  0x28(%rax),%xmm0
movss  -0x44(%rbp),%xmm2
movss  -0x54(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x54(%rbp)
mov    -0x10(%rbp),%rax
movss  0x2c(%rax),%xmm0
movss  -0x44(%rbp),%xmm2
movss  -0x58(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x58(%rbp)
mov    -0x10(%rbp),%rax
movss  0x30(%rax),%xmm0
movss  -0x48(%rbp),%xmm2
movss  -0x4c(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x4c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x34(%rax),%xmm0
movss  -0x48(%rbp),%xmm2
movss  -0x50(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x50(%rbp)
mov    -0x10(%rbp),%rax
movss  0x38(%rax),%xmm0
movss  -0x48(%rbp),%xmm2
movss  -0x54(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x54(%rbp)
mov    -0x10(%rbp),%rax
movss  0x3c(%rax),%xmm0
movss  -0x48(%rbp),%xmm2
movss  -0x58(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x58(%rbp)
mov    -0x10(%rbp),%rax
add    $0x40,%rax
mov    %rax,-0x10(%rbp)
mov    -0x20(%rbp),%rax
add    $0x10,%rax
mov    %rax,-0x20(%rbp)
mov    -0x38(%rbp),%eax
add    $0x4,%eax
mov    %eax,-0x38(%rbp)
jmp    114f <kernel_strsv_ln_inv_4_vs_lib4+0x4f>
mov    -0x28(%rbp),%rax
movss  (%rax),%xmm0
addss  -0x4c(%rbp),%xmm0
movss  %xmm0,-0x4c(%rbp)
mov    -0x28(%rbp),%rax
movss  0x4(%rax),%xmm0
addss  -0x50(%rbp),%xmm0
movss  %xmm0,-0x50(%rbp)
mov    -0x28(%rbp),%rax
movss  0x8(%rax),%xmm0
addss  -0x54(%rbp),%xmm0
movss  %xmm0,-0x54(%rbp)
mov    -0x28(%rbp),%rax
movss  0xc(%rax),%xmm0
addss  -0x58(%rbp),%xmm0
movss  %xmm0,-0x58(%rbp)
mov    -0x18(%rbp),%rax
movss  (%rax),%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x4(%rax),%xmm0
movss  %xmm0,-0x60(%rbp)
mov    -0x10(%rbp),%rax
movss  0x8(%rax),%xmm0
movss  %xmm0,-0x64(%rbp)
mov    -0x10(%rbp),%rax
movss  0xc(%rax),%xmm0
movss  %xmm0,-0x68(%rbp)
movss  -0x5c(%rbp),%xmm0
mulss  -0x4c(%rbp),%xmm0
movss  %xmm0,-0x4c(%rbp)
movss  -0x4c(%rbp),%xmm0
mov    -0x30(%rbp),%rax
movss  %xmm0,(%rax)
movss  -0x60(%rbp),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x50(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x50(%rbp)
movss  -0x64(%rbp),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x54(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x54(%rbp)
movss  -0x68(%rbp),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x58(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x58(%rbp)
cmpl   $0x1,0x18(%rbp)
jne    160b <kernel_strsv_ln_inv_4_vs_lib4+0x50b>
cmpl   $0x1,0x10(%rbp)
jne    15be <kernel_strsv_ln_inv_4_vs_lib4+0x4be>
jmp    17a6 <kernel_strsv_ln_inv_4_vs_lib4+0x6a6>
movss  -0x50(%rbp),%xmm0
mov    -0x28(%rbp),%rax
movss  %xmm0,0x4(%rax)
cmpl   $0x2,0x10(%rbp)
jne    15db <kernel_strsv_ln_inv_4_vs_lib4+0x4db>
jmp    17a6 <kernel_strsv_ln_inv_4_vs_lib4+0x6a6>
movss  -0x54(%rbp),%xmm0
mov    -0x28(%rbp),%rax
movss  %xmm0,0x8(%rax)
cmpl   $0x3,0x10(%rbp)
jne    15f8 <kernel_strsv_ln_inv_4_vs_lib4+0x4f8>
jmp    17a6 <kernel_strsv_ln_inv_4_vs_lib4+0x6a6>
movss  -0x58(%rbp),%xmm0
mov    -0x28(%rbp),%rax
movss  %xmm0,0xc(%rax)
jmp    17a6 <kernel_strsv_ln_inv_4_vs_lib4+0x6a6>
mov    -0x18(%rbp),%rax
movss  0x4(%rax),%xmm0
movss  %xmm0,-0x6c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x18(%rax),%xmm0
movss  %xmm0,-0x70(%rbp)
mov    -0x10(%rbp),%rax
movss  0x1c(%rax),%xmm0
movss  %xmm0,-0x74(%rbp)
movss  -0x6c(%rbp),%xmm0
mulss  -0x50(%rbp),%xmm0
movss  %xmm0,-0x50(%rbp)
movss  -0x50(%rbp),%xmm0
mov    -0x30(%rbp),%rax
movss  %xmm0,0x4(%rax)
movss  -0x70(%rbp),%xmm0
movss  -0x50(%rbp),%xmm2
movss  -0x54(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x54(%rbp)
movss  -0x74(%rbp),%xmm0
movss  -0x50(%rbp),%xmm2
movss  -0x58(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x58(%rbp)
cmpl   $0x2,0x18(%rbp)
jne    16ed <kernel_strsv_ln_inv_4_vs_lib4+0x5ed>
cmpl   $0x2,0x10(%rbp)
jne    16bd <kernel_strsv_ln_inv_4_vs_lib4+0x5bd>
jmp    17a6 <kernel_strsv_ln_inv_4_vs_lib4+0x6a6>
movss  -0x54(%rbp),%xmm0
mov    -0x28(%rbp),%rax
movss  %xmm0,0x8(%rax)
cmpl   $0x3,0x10(%rbp)
jne    16da <kernel_strsv_ln_inv_4_vs_lib4+0x5da>
jmp    17a6 <kernel_strsv_ln_inv_4_vs_lib4+0x6a6>
movss  -0x58(%rbp),%xmm0
mov    -0x28(%rbp),%rax
movss  %xmm0,0xc(%rax)
jmp    17a6 <kernel_strsv_ln_inv_4_vs_lib4+0x6a6>
mov    -0x18(%rbp),%rax
movss  0x8(%rax),%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x2c(%rax),%xmm0
movss  %xmm0,-0x60(%rbp)
movss  -0x5c(%rbp),%xmm0
mulss  -0x54(%rbp),%xmm0
movss  %xmm0,-0x54(%rbp)
movss  -0x54(%rbp),%xmm0
mov    -0x30(%rbp),%rax
movss  %xmm0,0x8(%rax)
movss  -0x60(%rbp),%xmm0
movss  -0x54(%rbp),%xmm2
movss  -0x58(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x58(%rbp)
cmpl   $0x3,0x18(%rbp)
jne    177b <kernel_strsv_ln_inv_4_vs_lib4+0x67b>
cmpl   $0x3,0x10(%rbp)
jne    1768 <kernel_strsv_ln_inv_4_vs_lib4+0x668>
jmp    17a6 <kernel_strsv_ln_inv_4_vs_lib4+0x6a6>
movss  -0x58(%rbp),%xmm0
mov    -0x28(%rbp),%rax
movss  %xmm0,0xc(%rax)
jmp    17a6 <kernel_strsv_ln_inv_4_vs_lib4+0x6a6>
mov    -0x18(%rbp),%rax
movss  0xc(%rax),%xmm0
movss  %xmm0,-0x6c(%rbp)
movss  -0x6c(%rbp),%xmm0
mulss  -0x58(%rbp),%xmm0
movss  %xmm0,-0x58(%rbp)
movss  -0x58(%rbp),%xmm0
mov    -0x30(%rbp),%rax
movss  %xmm0,0xc(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<kernel_strsv_ln_inv_4_vs_lib4>:
mov    0x10(%rsp),%r10d
xorps  %xmm9,%xmm9
cmp    $0x4,%edi
jl     11cb <kernel_strsv_ln_inv_4_vs_lib4+0xcb>
add    $0xfffffffd,%edi
xorps  %xmm4,%xmm4
xor    %eax,%eax
movaps 0xede(%rip),%xmm8
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
movaps %xmm4,%xmm10
movups (%rsi),%xmm1
movups 0x10(%rsi),%xmm2
movups 0x20(%rsi),%xmm11
movups 0x30(%rsi),%xmm9
movss  (%rcx,%rax,4),%xmm6
movss  0x4(%rcx,%rax,4),%xmm0
movss  0x8(%rcx,%rax,4),%xmm7
movss  0xc(%rcx,%rax,4),%xmm5
shufps $0x0,%xmm6,%xmm6
movaps %xmm1,%xmm3
mulps  %xmm6,%xmm3
subps  %xmm3,%xmm4
shufps $0x0,%xmm0,%xmm0
movaps %xmm2,%xmm3
mulps  %xmm0,%xmm3
subps  %xmm3,%xmm4
shufps $0x0,%xmm7,%xmm7
movaps %xmm11,%xmm3
mulps  %xmm7,%xmm3
subps  %xmm3,%xmm4
shufps $0x0,%xmm5,%xmm5
movaps %xmm9,%xmm3
mulps  %xmm5,%xmm3
subps  %xmm3,%xmm4
add    $0x40,%rsi
add    $0x4,%rax
cmp    %edi,%eax
jl     1130 <kernel_strsv_ln_inv_4_vs_lib4+0x30>
xorps  %xmm8,%xmm1
xorps  %xmm8,%xmm2
xorps  %xmm8,%xmm11
xorps  %xmm8,%xmm9
mulps  %xmm6,%xmm1
addps  %xmm10,%xmm1
mulps  %xmm0,%xmm2
addps  %xmm1,%xmm2
mulps  %xmm7,%xmm11
addps  %xmm2,%xmm11
mulps  %xmm5,%xmm9
addps  %xmm11,%xmm9
movss  (%r8),%xmm2
addss  %xmm9,%xmm2
movaps %xmm9,%xmm0
shufps $0x55,%xmm9,%xmm0
addss  0x4(%r8),%xmm0
movaps %xmm9,%xmm1
unpckhpd %xmm9,%xmm1
addss  0x8(%r8),%xmm1
shufps $0xff,%xmm9,%xmm9
addss  0xc(%r8),%xmm9
mulss  (%rdx),%xmm2
mov    0x8(%rsp),%ecx
movss  0x4(%rsi),%xmm3
mulss  %xmm2,%xmm3
subss  %xmm3,%xmm0
movss  0x8(%rsi),%xmm3
mulss  %xmm2,%xmm3
subss  %xmm3,%xmm1
movss  0xc(%rsi),%xmm3
mulss  %xmm2,%xmm3
subss  %xmm3,%xmm9
movss  %xmm2,(%r9)
cmp    $0x1,%r10d
jne    1267 <kernel_strsv_ln_inv_4_vs_lib4+0x167>
cmp    $0x1,%ecx
je     12e1 <kernel_strsv_ln_inv_4_vs_lib4+0x1e1>
movss  %xmm0,0x4(%r8)
cmp    $0x2,%ecx
je     12e1 <kernel_strsv_ln_inv_4_vs_lib4+0x1e1>
movss  %xmm1,0x8(%r8)
cmp    $0x3,%ecx
je     12e1 <kernel_strsv_ln_inv_4_vs_lib4+0x1e1>
movss  %xmm9,0xc(%r8)
ret
mulss  0x4(%rdx),%xmm0
movss  0x18(%rsi),%xmm2
mulss  %xmm0,%xmm2
movss  0x1c(%rsi),%xmm3
mulss  %xmm0,%xmm3
movss  %xmm0,0x4(%r9)
subss  %xmm2,%xmm1
subss  %xmm3,%xmm9
cmp    $0x2,%r10d
jne    12aa <kernel_strsv_ln_inv_4_vs_lib4+0x1aa>
cmp    $0x2,%ecx
je     12e1 <kernel_strsv_ln_inv_4_vs_lib4+0x1e1>
movss  %xmm1,0x8(%r8)
cmp    $0x3,%ecx
je     12e1 <kernel_strsv_ln_inv_4_vs_lib4+0x1e1>
movss  %xmm9,0xc(%r8)
ret
mulss  0x8(%rdx),%xmm1
movss  0x2c(%rsi),%xmm0
mulss  %xmm1,%xmm0
movss  %xmm1,0x8(%r9)
subss  %xmm0,%xmm9
cmp    $0x3,%r10d
jne    12d5 <kernel_strsv_ln_inv_4_vs_lib4+0x1d5>
cmp    $0x3,%ecx
je     12e1 <kernel_strsv_ln_inv_4_vs_lib4+0x1e1>
movss  %xmm9,0xc(%r8)
ret
mulss  0xc(%rdx),%xmm9
movss  %xmm9,0xc(%r9)
ret

LLVM IR (-O0):
define void @kernel_strsv_ln_inv_4_vs_lib4(i32 %0, float* %1, float* %2, float* %3, float* %4, float* %5, i32 %6, i32 %7) {
%9 = alloca i32
%10 = alloca float*
%11 = alloca float*
%12 = alloca float*
%13 = alloca float*
%14 = alloca float*
%15 = alloca i32
%16 = alloca i32
%17 = alloca i32
%18 = alloca i32
%19 = alloca float
%20 = alloca float
%21 = alloca float
%22 = alloca float
%23 = alloca float
%24 = alloca float
%25 = alloca float
%26 = alloca float
%27 = alloca float
%28 = alloca float
%29 = alloca float
%30 = alloca float
%31 = alloca float
%32 = alloca float
%33 = alloca float
store i32 %0, i32* %9
store float* %1, float** %10
store float* %2, float** %11
store float* %3, float** %12
store float* %4, float** %13
store float* %5, float** %14
store i32 %6, i32* %15
store i32 %7, i32* %16
store i32 4, i32* %17
store float 0.000000e+00, float* %23
store float 0.000000e+00, float* %24
store float 0.000000e+00, float* %25
store float 0.000000e+00, float* %26
store i32 0, i32* %18
br label %34
34: ; preds = %168, %8
%35 = load i32, i32* %18
%36 = load i32, i32* %9
%37 = sub nsw i32 %36, 3
%38 = icmp slt i32 %35, %37
br i1 %38, label %39, label %171
39: ; preds = %34
%40 = load float*, float** %12
%41 = getelementptr inbounds float, float* %40, i64 0
%42 = load float, float* %41
store float %42, float* %19
%43 = load float*, float** %12
%44 = getelementptr inbounds float, float* %43, i64 1
%45 = load float, float* %44
store float %45, float* %20
%46 = load float*, float** %12
%47 = getelementptr inbounds float, float* %46, i64 2
%48 = load float, float* %47
store float %48, float* %21
%49 = load float*, float** %12
%50 = getelementptr inbounds float, float* %49, i64 3
%51 = load float, float* %50
store float %51, float* %22
%52 = load float*, float** %10
%53 = getelementptr inbounds float, float* %52, i64 0
%54 = load float, float* %53
%55 = load float, float* %19
%56 = load float, float* %23
%57 = fneg float %54
%58 = call float @llvm.fmuladd.f32(float %57, float %55, float %56)
store float %58, float* %23
%59 = load float*, float** %10
%60 = getelementptr inbounds float, float* %59, i64 1
%61 = load float, float* %60
%62 = load float, float* %19
%63 = load float, float* %24
%64 = fneg float %61
%65 = call float @llvm.fmuladd.f32(float %64, float %62, float %63)
store float %65, float* %24
%66 = load float*, float** %10
%67 = getelementptr inbounds float, float* %66, i64 2
%68 = load float, float* %67
%69 = load float, float* %19
%70 = load float, float* %25
%71 = fneg float %68
%72 = call float @llvm.fmuladd.f32(float %71, float %69, float %70)
store float %72, float* %25
%73 = load float*, float** %10
%74 = getelementptr inbounds float, float* %73, i64 3
%75 = load float, float* %74
%76 = load float, float* %19
%77 = load float, float* %26
%78 = fneg float %75
%79 = call float @llvm.fmuladd.f32(float %78, float %76, float %77)
store float %79, float* %26
%80 = load float*, float** %10
%81 = getelementptr inbounds float, float* %80, i64 4
%82 = load float, float* %81
%83 = load float, float* %20
%84 = load float, float* %23
%85 = fneg float %82
%86 = call float @llvm.fmuladd.f32(float %85, float %83, float %84)
store float %86, float* %23
%87 = load float*, float** %10
%88 = getelementptr inbounds float, float* %87, i64 5
%89 = load float, float* %88
%90 = load float, float* %20
%91 = load float, float* %24
%92 = fneg float %89
%93 = call float @llvm.fmuladd.f32(float %92, float %90, float %91)
store float %93, float* %24
%94 = load float*, float** %10
%95 = getelementptr inbounds float, float* %94, i64 6
%96 = load float, float* %95
%97 = load float, float* %20
%98 = load float, float* %25
%99 = fneg float %96
%100 = call float @llvm.fmuladd.f32(float %99, float %97, float %98)
store float %100, float* %25
%101 = load float*, float** %10
%102 = getelementptr inbounds float, float* %101, i64 7
%103 = load float, float* %102
%104 = load float, float* %20
%105 = load float, float* %26
%106 = fneg float %103
%107 = call float @llvm.fmuladd.f32(float %106, float %104, float %105)
store float %107, float* %26
%108 = load float*, float** %10
%109 = getelementptr inbounds float, float* %108, i64 8
%110 = load float, float* %109
%111 = load float, float* %21
%112 = load float, float* %23
%113 = fneg float %110
%114 = call float @llvm.fmuladd.f32(float %113, float %111, float %112)
store float %114, float* %23
%115 = load float*, float** %10
%116 = getelementptr inbounds float, float* %115, i64 9
%117 = load float, float* %116
%118 = load float, float* %21
%119 = load float, float* %24
%120 = fneg float %117
%121 = call float @llvm.fmuladd.f32(float %120, float %118, float %119)
store float %121, float* %24
%122 = load float*, float** %10
%123 = getelementptr inbounds float, float* %122, i64 10
%124 = load float, float* %123
%125 = load float, float* %21
%126 = load float, float* %25
%127 = fneg float %124
%128 = call float @llvm.fmuladd.f32(float %127, float %125, float %126)
store float %128, float* %25
%129 = load float*, float** %10
%130 = getelementptr inbounds float, float* %129, i64 11
%131 = load float, float* %130
%132 = load float, float* %21
%133 = load float, float* %26
%134 = fneg float %131
%135 = call float @llvm.fmuladd.f32(float %134, float %132, float %133)
store float %135, float* %26
%136 = load float*, float** %10
%137 = getelementptr inbounds float, float* %136, i64 12
%138 = load float, float* %137
%139 = load float, float* %22
%140 = load float, float* %23
%141 = fneg float %138
%142 = call float @llvm.fmuladd.f32(float %141, float %139, float %140)
store float %142, float* %23
%143 = load float*, float** %10
%144 = getelementptr inbounds float, float* %143, i64 13
%145 = load float, float* %144
%146 = load float, float* %22
%147 = load float, float* %24
%148 = fneg float %145
%149 = call float @llvm.fmuladd.f32(float %148, float %146, float %147)
store float %149, float* %24
%150 = load float*, float** %10
%151 = getelementptr inbounds float, float* %150, i64 14
%152 = load float, float* %151
%153 = load float, float* %22
%154 = load float, float* %25
%155 = fneg float %152
%156 = call float @llvm.fmuladd.f32(float %155, float %153, float %154)
store float %156, float* %25
%157 = load float*, float** %10
%158 = getelementptr inbounds float, float* %157, i64 15
%159 = load float, float* %158
%160 = load float, float* %22
%161 = load float, float* %26
%162 = fneg float %159
%163 = call float @llvm.fmuladd.f32(float %162, float %160, float %161)
store float %163, float* %26
%164 = load float*, float** %10
%165 = getelementptr inbounds float, float* %164, i64 16
store float* %165, float** %10
%166 = load float*, float** %12
%167 = getelementptr inbounds float, float* %166, i64 4
store float* %167, float** %12
br label %168
168: ; preds = %39
%169 = load i32, i32* %18
%170 = add nsw i32 %169, 4
store i32 %170, i32* %18
br label %34
171: ; preds = %34
%172 = load float*, float** %13
%173 = getelementptr inbounds float, float* %172, i64 0
%174 = load float, float* %173
%175 = load float, float* %23
%176 = fadd float %174, %175
store float %176, float* %23
%177 = load float*, float** %13
%178 = getelementptr inbounds float, float* %177, i64 1
%179 = load float, float* %178
%180 = load float, float* %24
%181 = fadd float %179, %180
store float %181, float* %24
%182 = load float*, float** %13
%183 = getelementptr inbounds float, float* %182, i64 2
%184 = load float, float* %183
%185 = load float, float* %25
%186 = fadd float %184, %185
store float %186, float* %25
%187 = load float*, float** %13
%188 = getelementptr inbounds float, float* %187, i64 3
%189 = load float, float* %188
%190 = load float, float* %26
%191 = fadd float %189, %190
store float %191, float* %26
%192 = load float*, float** %11
%193 = getelementptr inbounds float, float* %192, i64 0
%194 = load float, float* %193
store float %194, float* %27
%195 = load float*, float** %10
%196 = getelementptr inbounds float, float* %195, i64 1
%197 = load float, float* %196
store float %197, float* %28
%198 = load float*, float** %10
%199 = getelementptr inbounds float, float* %198, i64 2
%200 = load float, float* %199
store float %200, float* %29
%201 = load float*, float** %10
%202 = getelementptr inbounds float, float* %201, i64 3
%203 = load float, float* %202
store float %203, float* %30
%204 = load float, float* %27
%205 = load float, float* %23
%206 = fmul float %205, %204
store float %206, float* %23
%207 = load float, float* %23
%208 = load float*, float** %14
%209 = getelementptr inbounds float, float* %208, i64 0
store float %207, float* %209
%210 = load float, float* %28
%211 = load float, float* %23
%212 = load float, float* %24
%213 = fneg float %210
%214 = call float @llvm.fmuladd.f32(float %213, float %211, float %212)
store float %214, float* %24
%215 = load float, float* %29
%216 = load float, float* %23
%217 = load float, float* %25
%218 = fneg float %215
%219 = call float @llvm.fmuladd.f32(float %218, float %216, float %217)
store float %219, float* %25
%220 = load float, float* %30
%221 = load float, float* %23
%222 = load float, float* %26
%223 = fneg float %220
%224 = call float @llvm.fmuladd.f32(float %223, float %221, float %222)
store float %224, float* %26
%225 = load i32, i32* %16
%226 = icmp eq i32 %225, 1
br i1 %226, label %227, label %249
227: ; preds = %171
%228 = load i32, i32* %15
%229 = icmp eq i32 %228, 1
br i1 %229, label %230, label %231
230: ; preds = %227
br label %330
231: ; preds = %227
%232 = load float, float* %24
%233 = load float*, float** %13
%234 = getelementptr inbounds float, float* %233, i64 1
store float %232, float* %234
%235 = load i32, i32* %15
%236 = icmp eq i32 %235, 2
br i1 %236, label %237, label %238
237: ; preds = %231
br label %330
238: ; preds = %231
%239 = load float, float* %25
%240 = load float*, float** %13
%241 = getelementptr inbounds float, float* %240, i64 2
store float %239, float* %241
%242 = load i32, i32* %15
%243 = icmp eq i32 %242, 3
br i1 %243, label %244, label %245
244: ; preds = %238
br label %330
245: ; preds = %238
%246 = load float, float* %26
%247 = load float*, float** %13
%248 = getelementptr inbounds float, float* %247, i64 3
store float %246, float* %248
br label %330
249: ; preds = %171
%250 = load float*, float** %11
%251 = getelementptr inbounds float, float* %250, i64 1
%252 = load float, float* %251
store float %252, float* %31
%253 = load float*, float** %10
%254 = getelementptr inbounds float, float* %253, i64 6
%255 = load float, float* %254
store float %255, float* %32
%256 = load float*, float** %10
%257 = getelementptr inbounds float, float* %256, i64 7
%258 = load float, float* %257
store float %258, float* %33
%259 = load float, float* %31
%260 = load float, float* %24
%261 = fmul float %260, %259
store float %261, float* %24
%262 = load float, float* %24
%263 = load float*, float** %14
%264 = getelementptr inbounds float, float* %263, i64 1
store float %262, float* %264
%265 = load float, float* %32
%266 = load float, float* %24
%267 = load float, float* %25
%268 = fneg float %265
%269 = call float @llvm.fmuladd.f32(float %268, float %266, float %267)
store float %269, float* %25
%270 = load float, float* %33
%271 = load float, float* %24
%272 = load float, float* %26
%273 = fneg float %270
%274 = call float @llvm.fmuladd.f32(float %273, float %271, float %272)
store float %274, float* %26
%275 = load i32, i32* %16
%276 = icmp eq i32 %275, 2
br i1 %276, label %277, label %292
277: ; preds = %249
%278 = load i32, i32* %15
%279 = icmp eq i32 %278, 2
br i1 %279, label %280, label %281
280: ; preds = %277
br label %330
281: ; preds = %277
%282 = load float, float* %25
%283 = load float*, float** %13
%284 = getelementptr inbounds float, float* %283, i64 2
store float %282, float* %284
%285 = load i32, i32* %15
%286 = icmp eq i32 %285, 3
br i1 %286, label %287, label %288
287: ; preds = %281
br label %330
288: ; preds = %281
%289 = load float, float* %26
%290 = load float*, float** %13
%291 = getelementptr inbounds float, float* %290, i64 3
store float %289, float* %291
br label %330
292: ; preds = %249
%293 = load float*, float** %11
%294 = getelementptr inbounds float, float* %293, i64 2
%295 = load float, float* %294
store float %295, float* %27
%296 = load float*, float** %10
%297 = getelementptr inbounds float, float* %296, i64 11
%298 = load float, float* %297
store float %298, float* %28
%299 = load float, float* %27
%300 = load float, float* %25
%301 = fmul float %300, %299
store float %301, float* %25
%302 = load float, float* %25
%303 = load float*, float** %14
%304 = getelementptr inbounds float, float* %303, i64 2
store float %302, float* %304
%305 = load float, float* %28
%306 = load float, float* %25
%307 = load float, float* %26
%308 = fneg float %305
%309 = call float @llvm.fmuladd.f32(float %308, float %306, float %307)
store float %309, float* %26
%310 = load i32, i32* %16
%311 = icmp eq i32 %310, 3
br i1 %311, label %312, label %320
312: ; preds = %292
%313 = load i32, i32* %15
%314 = icmp eq i32 %313, 3
br i1 %314, label %315, label %316
315: ; preds = %312
br label %330
316: ; preds = %312
%317 = load float, float* %26
%318 = load float*, float** %13
%319 = getelementptr inbounds float, float* %318, i64 3
store float %317, float* %319
br label %330
320: ; preds = %292
%321 = load float*, float** %11
%322 = getelementptr inbounds float, float* %321, i64 3
%323 = load float, float* %322
store float %323, float* %31
%324 = load float, float* %31
%325 = load float, float* %26
%326 = fmul float %325, %324
store float %326, float* %26
%327 = load float, float* %26
%328 = load float*, float** %14
%329 = getelementptr inbounds float, float* %328, i64 3
store float %327, float* %329
br label %330
330: ; preds = %320, %316, %315, %288, %287, %280, %245, %244, %237, %230
ret void
}

LLVM IR (-O2):
define void @kernel_strsv_ln_inv_4_vs_lib4(i32 %0, float* %1, float* nocapture %2, float* nocapture %3, float* nocapture %4, float* nocapture writeonly %5, i32 %6, i32 %7) {
%9 = add nsw i32 %0, -3
%10 = icmp sgt i32 %0, 3
br i1 %10, label %11, label %59
11: ; preds = %8, %11
%12 = phi float* [ %50, %11 ], [ %1, %8 ]
%13 = phi float* [ %51, %11 ], [ %3, %8 ]
%14 = phi i32 [ %52, %11 ], [ 0, %8 ]
%15 = phi <4 x float> [ %49, %11 ], [ zeroinitializer, %8 ]
%16 = load float, float* %13
%17 = getelementptr inbounds float, float* %13, i64 1
%18 = load float, float* %17
%19 = getelementptr inbounds float, float* %13, i64 2
%20 = load float, float* %19
%21 = getelementptr inbounds float, float* %13, i64 3
%22 = load float, float* %21
%23 = bitcast float* %12 to <4 x float>*
%24 = load <4 x float>, <4 x float>* %23
%25 = fneg <4 x float> %24
%26 = insertelement <4 x float> poison, float %16, i64 0
%27 = shufflevector <4 x float> %26, <4 x float> poison, <4 x i32> zeroinitializer
%28 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %25, <4 x float> %27, <4 x float> %15)
%29 = getelementptr inbounds float, float* %12, i64 4
%30 = bitcast float* %29 to <4 x float>*
%31 = load <4 x float>, <4 x float>* %30
%32 = fneg <4 x float> %31
%33 = insertelement <4 x float> poison, float %18, i64 0
%34 = shufflevector <4 x float> %33, <4 x float> poison, <4 x i32> zeroinitializer
%35 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %32, <4 x float> %34, <4 x float> %28)
%36 = getelementptr inbounds float, float* %12, i64 8
%37 = bitcast float* %36 to <4 x float>*
%38 = load <4 x float>, <4 x float>* %37
%39 = fneg <4 x float> %38
%40 = insertelement <4 x float> poison, float %20, i64 0
%41 = shufflevector <4 x float> %40, <4 x float> poison, <4 x i32> zeroinitializer
%42 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %39, <4 x float> %41, <4 x float> %35)
%43 = getelementptr inbounds float, float* %12, i64 12
%44 = bitcast float* %43 to <4 x float>*
%45 = load <4 x float>, <4 x float>* %44
%46 = fneg <4 x float> %45
%47 = insertelement <4 x float> poison, float %22, i64 0
%48 = shufflevector <4 x float> %47, <4 x float> poison, <4 x i32> zeroinitializer
%49 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %46, <4 x float> %48, <4 x float> %42)
%50 = getelementptr inbounds float, float* %12, i64 16
%51 = getelementptr inbounds float, float* %13, i64 4
%52 = add nuw nsw i32 %14, 4
%53 = icmp slt i32 %52, %9
br i1 %53, label %11, label %54
54: ; preds = %11
%55 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %25, <4 x float> %27, <4 x float> %15)
%56 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %32, <4 x float> %34, <4 x float> %55)
%57 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %39, <4 x float> %41, <4 x float> %56)
%58 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %46, <4 x float> %48, <4 x float> %57)
br label %59
59: ; preds = %54, %8
%60 = phi float* [ %1, %8 ], [ %50, %54 ]
%61 = phi <4 x float> [ zeroinitializer, %8 ], [ %58, %54 ]
%62 = load float, float* %4
%63 = extractelement <4 x float> %61, i64 0
%64 = fadd float %63, %62
%65 = getelementptr inbounds float, float* %4, i64 1
%66 = load float, float* %65
%67 = extractelement <4 x float> %61, i64 1
%68 = fadd float %67, %66
%69 = getelementptr inbounds float, float* %4, i64 2
%70 = load float, float* %69
%71 = extractelement <4 x float> %61, i64 2
%72 = fadd float %71, %70
%73 = getelementptr inbounds float, float* %4, i64 3
%74 = load float, float* %73
%75 = extractelement <4 x float> %61, i64 3
%76 = fadd float %75, %74
%77 = load float, float* %2
%78 = getelementptr inbounds float, float* %60, i64 1
%79 = load float, float* %78
%80 = getelementptr inbounds float, float* %60, i64 2
%81 = load float, float* %80
%82 = getelementptr inbounds float, float* %60, i64 3
%83 = load float, float* %82
%84 = fmul float %64, %77
store float %84, float* %5
%85 = fneg float %79
%86 = tail call float @llvm.fmuladd.f32(float %85, float %84, float %68)
%87 = fneg float %81
%88 = tail call float @llvm.fmuladd.f32(float %87, float %84, float %72)
%89 = fneg float %83
%90 = tail call float @llvm.fmuladd.f32(float %89, float %84, float %76)
%91 = icmp eq i32 %7, 1
br i1 %91, label %92, label %99
92: ; preds = %59
%93 = icmp eq i32 %6, 1
br i1 %93, label %136, label %94
94: ; preds = %92
store float %86, float* %65
%95 = icmp eq i32 %6, 2
br i1 %95, label %136, label %96
96: ; preds = %94
store float %88, float* %69
%97 = icmp eq i32 %6, 3
br i1 %97, label %136, label %98
98: ; preds = %96
store float %90, float* %73
br label %136
99: ; preds = %59
%100 = getelementptr inbounds float, float* %2, i64 1
%101 = load float, float* %100
%102 = getelementptr inbounds float, float* %60, i64 6
%103 = load float, float* %102
%104 = getelementptr inbounds float, float* %60, i64 7
%105 = load float, float* %104
%106 = fmul float %86, %101
%107 = getelementptr inbounds float, float* %5, i64 1
store float %106, float* %107
%108 = fneg float %103
%109 = tail call float @llvm.fmuladd.f32(float %108, float %106, float %88)
%110 = fneg float %105
%111 = tail call float @llvm.fmuladd.f32(float %110, float %106, float %90)
%112 = icmp eq i32 %7, 2
br i1 %112, label %113, label %118
113: ; preds = %99
%114 = icmp eq i32 %6, 2
br i1 %114, label %136, label %115
115: ; preds = %113
store float %109, float* %69
%116 = icmp eq i32 %6, 3
br i1 %116, label %136, label %117
117: ; preds = %115
store float %111, float* %73
br label %136
118: ; preds = %99
%119 = getelementptr inbounds float, float* %2, i64 2
%120 = load float, float* %119
%121 = getelementptr inbounds float, float* %60, i64 11
%122 = load float, float* %121
%123 = fmul float %109, %120
%124 = getelementptr inbounds float, float* %5, i64 2
store float %123, float* %124
%125 = fneg float %122
%126 = tail call float @llvm.fmuladd.f32(float %125, float %123, float %111)
%127 = icmp eq i32 %7, 3
br i1 %127, label %128, label %131
128: ; preds = %118
%129 = icmp eq i32 %6, 3
br i1 %129, label %136, label %130
130: ; preds = %128
store float %126, float* %73
br label %136
131: ; preds = %118
%132 = getelementptr inbounds float, float* %2, i64 3
%133 = load float, float* %132
%134 = fmul float %126, %133
%135 = getelementptr inbounds float, float* %5, i64 3
store float %134, float* %135
br label %136
136: ; preds = %128, %115, %113, %96, %94, %92, %131, %130, %117, %98
ret void
}