void kernel_strsv_lt_inv_4_lib4(int kmax, float *A, int sda, float *inv_diag_A,
                                float *x, float *y, float *z) {
  const int bs = 4;
  int k;
  float *tA, *tx;
  tA = A;
  tx = x;
  float x_0, x_1, x_2, x_3, y_0 = 0, y_1 = 0, y_2 = 0, y_3 = 0;
  k = 4;
  A += 4 + (sda - 1) * bs;
  x += 4;
  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[0 + bs * 1] * x_0;
    y_2 -= A[0 + bs * 2] * x_0;
    y_3 -= A[0 + bs * 3] * x_0;
    y_0 -= A[1 + bs * 0] * x_1;
    y_1 -= A[1 + bs * 1] * x_1;
    y_2 -= A[1 + bs * 2] * x_1;
    y_3 -= A[1 + bs * 3] * x_1;
    y_0 -= A[2 + bs * 0] * x_2;
    y_1 -= A[2 + bs * 1] * x_2;
    y_2 -= A[2 + bs * 2] * x_2;
    y_3 -= A[2 + bs * 3] * x_2;
    y_0 -= A[3 + bs * 0] * x_3;
    y_1 -= A[3 + bs * 1] * x_3;
    y_2 -= A[3 + bs * 2] * x_3;
    y_3 -= A[3 + bs * 3] * x_3;
    A += sda * bs;
    x += 4;
  }
  for (; k < kmax; k++) {
    x_0 = x[0];
    y_0 -= A[0 + bs * 0] * x_0;
    y_1 -= A[0 + bs * 1] * x_0;
    y_2 -= A[0 + bs * 2] * x_0;
    y_3 -= A[0 + bs * 3] * x_0;
    A += 1;
    x += 1;
  }
  y_0 = y[0] + y_0;
  y_1 = y[1] + y_1;
  y_2 = y[2] + y_2;
  y_3 = y[3] + y_3;
  A = tA;
  x = tx;
  y_3 *= inv_diag_A[3];
  z[3] = y_3;
  y_2 -= A[3 + bs * 2] * y_3;
  y_2 *= inv_diag_A[2];
  z[2] = y_2;
  y_0 -= A[2 + bs * 0] * y_2 + A[3 + bs * 0] * y_3;
  y_1 -= A[2 + bs * 1] * y_2 + A[3 + bs * 1] * y_3;
  y_1 *= inv_diag_A[1];
  z[1] = y_1;
  y_0 -= A[1 + bs * 0] * y_1;
  y_0 *= inv_diag_A[0];
  z[0] = y_0;
}


x86 assembly (clang, -O0):
<kernel_strsv_lt_inv_4_lib4>:
push   %rbp
mov    %rsp,%rbp
mov    0x10(%rbp),%rax
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
movl   $0x4,-0x34(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x40(%rbp)
mov    -0x28(%rbp),%rax
mov    %rax,-0x48(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x5c(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x60(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x64(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x68(%rbp)
movl   $0x4,-0x38(%rbp)
mov    -0x14(%rbp),%ecx
sub    $0x1,%ecx
shl    $0x2,%ecx
add    $0x4,%ecx
mov    -0x10(%rbp),%rax
movslq %ecx,%rcx
shl    $0x2,%rcx
add    %rcx,%rax
mov    %rax,-0x10(%rbp)
mov    -0x28(%rbp),%rax
add    $0x10,%rax
mov    %rax,-0x28(%rbp)
mov    -0x38(%rbp),%eax
mov    -0x4(%rbp),%ecx
sub    $0x3,%ecx
cmp    %ecx,%eax
jge    14cf <kernel_strsv_lt_inv_4_lib4+0x3cf>
mov    -0x28(%rbp),%rax
movss  (%rax),%xmm0
movss  %xmm0,-0x4c(%rbp)
mov    -0x28(%rbp),%rax
movss  0x4(%rax),%xmm0
movss  %xmm0,-0x50(%rbp)
mov    -0x28(%rbp),%rax
movss  0x8(%rax),%xmm0
movss  %xmm0,-0x54(%rbp)
mov    -0x28(%rbp),%rax
movss  0xc(%rax),%xmm0
movss  %xmm0,-0x58(%rbp)
mov    -0x10(%rbp),%rax
movss  (%rax),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x5c(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x10(%rax),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x60(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x60(%rbp)
mov    -0x10(%rbp),%rax
movss  0x20(%rax),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x64(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x64(%rbp)
mov    -0x10(%rbp),%rax
movss  0x30(%rax),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x68(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x68(%rbp)
mov    -0x10(%rbp),%rax
movss  0x4(%rax),%xmm0
movss  -0x50(%rbp),%xmm2
movss  -0x5c(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x14(%rax),%xmm0
movss  -0x50(%rbp),%xmm2
movss  -0x60(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x60(%rbp)
mov    -0x10(%rbp),%rax
movss  0x24(%rax),%xmm0
movss  -0x50(%rbp),%xmm2
movss  -0x64(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x64(%rbp)
mov    -0x10(%rbp),%rax
movss  0x34(%rax),%xmm0
movss  -0x50(%rbp),%xmm2
movss  -0x68(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x68(%rbp)
mov    -0x10(%rbp),%rax
movss  0x8(%rax),%xmm0
movss  -0x54(%rbp),%xmm2
movss  -0x5c(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x18(%rax),%xmm0
movss  -0x54(%rbp),%xmm2
movss  -0x60(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x60(%rbp)
mov    -0x10(%rbp),%rax
movss  0x28(%rax),%xmm0
movss  -0x54(%rbp),%xmm2
movss  -0x64(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x64(%rbp)
mov    -0x10(%rbp),%rax
movss  0x38(%rax),%xmm0
movss  -0x54(%rbp),%xmm2
movss  -0x68(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x68(%rbp)
mov    -0x10(%rbp),%rax
movss  0xc(%rax),%xmm0
movss  -0x58(%rbp),%xmm2
movss  -0x5c(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x1c(%rax),%xmm0
movss  -0x58(%rbp),%xmm2
movss  -0x60(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x60(%rbp)
mov    -0x10(%rbp),%rax
movss  0x2c(%rax),%xmm0
movss  -0x58(%rbp),%xmm2
movss  -0x64(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x64(%rbp)
mov    -0x10(%rbp),%rax
movss  0x3c(%rax),%xmm0
movss  -0x58(%rbp),%xmm2
movss  -0x68(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x68(%rbp)
mov    -0x14(%rbp),%ecx
shl    $0x2,%ecx
mov    -0x10(%rbp),%rax
movslq %ecx,%rcx
shl    $0x2,%rcx
add    %rcx,%rax
mov    %rax,-0x10(%rbp)
mov    -0x28(%rbp),%rax
add    $0x10,%rax
mov    %rax,-0x28(%rbp)
mov    -0x38(%rbp),%eax
add    $0x4,%eax
mov    %eax,-0x38(%rbp)
jmp    1186 <kernel_strsv_lt_inv_4_lib4+0x86>
jmp    14d4 <kernel_strsv_lt_inv_4_lib4+0x3d4>
mov    -0x38(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    15c6 <kernel_strsv_lt_inv_4_lib4+0x4c6>
mov    -0x28(%rbp),%rax
movss  (%rax),%xmm0
movss  %xmm0,-0x4c(%rbp)
mov    -0x10(%rbp),%rax
movss  (%rax),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x5c(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x10(%rax),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x60(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x60(%rbp)
mov    -0x10(%rbp),%rax
movss  0x20(%rax),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x64(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x64(%rbp)
mov    -0x10(%rbp),%rax
movss  0x30(%rax),%xmm0
movss  -0x4c(%rbp),%xmm2
movss  -0x68(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x68(%rbp)
mov    -0x10(%rbp),%rax
add    $0x4,%rax
mov    %rax,-0x10(%rbp)
mov    -0x28(%rbp),%rax
add    $0x4,%rax
mov    %rax,-0x28(%rbp)
mov    -0x38(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x38(%rbp)
jmp    14d4 <kernel_strsv_lt_inv_4_lib4+0x3d4>
mov    -0x30(%rbp),%rax
movss  (%rax),%xmm0
addss  -0x5c(%rbp),%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x30(%rbp),%rax
movss  0x4(%rax),%xmm0
addss  -0x60(%rbp),%xmm0
movss  %xmm0,-0x60(%rbp)
mov    -0x30(%rbp),%rax
movss  0x8(%rax),%xmm0
addss  -0x64(%rbp),%xmm0
movss  %xmm0,-0x64(%rbp)
mov    -0x30(%rbp),%rax
movss  0xc(%rax),%xmm0
addss  -0x68(%rbp),%xmm0
movss  %xmm0,-0x68(%rbp)
mov    -0x40(%rbp),%rax
mov    %rax,-0x10(%rbp)
mov    -0x48(%rbp),%rax
mov    %rax,-0x28(%rbp)
mov    -0x20(%rbp),%rax
movss  0xc(%rax),%xmm0
mulss  -0x68(%rbp),%xmm0
movss  %xmm0,-0x68(%rbp)
movss  -0x68(%rbp),%xmm0
mov    0x10(%rbp),%rax
movss  %xmm0,0xc(%rax)
mov    -0x10(%rbp),%rax
movss  0x2c(%rax),%xmm0
movss  -0x68(%rbp),%xmm2
movss  -0x64(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x64(%rbp)
mov    -0x20(%rbp),%rax
movss  0x8(%rax),%xmm0
mulss  -0x64(%rbp),%xmm0
movss  %xmm0,-0x64(%rbp)
movss  -0x64(%rbp),%xmm0
mov    0x10(%rbp),%rax
movss  %xmm0,0x8(%rax)
mov    -0x10(%rbp),%rax
movss  0x8(%rax),%xmm1
movss  -0x64(%rbp),%xmm2
mov    -0x10(%rbp),%rax
movss  0xc(%rax),%xmm0
mulss  -0x68(%rbp),%xmm0
mulss  %xmm2,%xmm1
addss  %xmm0,%xmm1
movss  -0x5c(%rbp),%xmm0
subss  %xmm1,%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x10(%rbp),%rax
movss  0x18(%rax),%xmm1
movss  -0x64(%rbp),%xmm2
mov    -0x10(%rbp),%rax
movss  0x1c(%rax),%xmm0
mulss  -0x68(%rbp),%xmm0
mulss  %xmm2,%xmm1
addss  %xmm0,%xmm1
movss  -0x60(%rbp),%xmm0
subss  %xmm1,%xmm0
movss  %xmm0,-0x60(%rbp)
mov    -0x20(%rbp),%rax
movss  0x4(%rax),%xmm0
mulss  -0x60(%rbp),%xmm0
movss  %xmm0,-0x60(%rbp)
movss  -0x60(%rbp),%xmm0
mov    0x10(%rbp),%rax
movss  %xmm0,0x4(%rax)
mov    -0x10(%rbp),%rax
movss  0x4(%rax),%xmm0
movss  -0x60(%rbp),%xmm2
movss  -0x5c(%rbp),%xmm1
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x5c(%rbp)
mov    -0x20(%rbp),%rax
movss  (%rax),%xmm0
mulss  -0x5c(%rbp),%xmm0
movss  %xmm0,-0x5c(%rbp)
movss  -0x5c(%rbp),%xmm0
mov    0x10(%rbp),%rax
movss  %xmm0,(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<kernel_strsv_lt_inv_4_lib4>:
shl    $0x2,%edx
movslq %edx,%r11
lea    (%rsi,%r11,4),%rax
add    $0x10,%r8
cmp    $0x8,%edi
jl     1240 <kernel_strsv_lt_inv_4_lib4+0x140>
lea    -0x3(%rdi),%r10d
shl    $0x2,%r11
xorps  %xmm6,%xmm6
mov    $0x4,%edx
movaps 0xed1(%rip),%xmm8
nop
movaps %xmm6,%xmm9
movss  0x30(%rax),%xmm0
movss  0x20(%rax),%xmm1
unpcklps %xmm0,%xmm1
movss  0x10(%rax),%xmm0
movss  (%rax),%xmm2
unpcklps %xmm0,%xmm2
movlhps %xmm1,%xmm2
movss  0x4(%rax),%xmm5
movss  0x8(%rax),%xmm3
movss  0xc(%rax),%xmm0
movss  (%r8),%xmm7
movss  0x4(%r8),%xmm13
movss  0x8(%r8),%xmm11
movss  0xc(%r8),%xmm10
shufps $0x0,%xmm7,%xmm7
movaps %xmm2,%xmm4
mulps  %xmm7,%xmm4
subps  %xmm4,%xmm6
movss  0x34(%rax),%xmm12
movss  0x24(%rax),%xmm4
unpcklps %xmm12,%xmm4
movss  0x14(%rax),%xmm1
unpcklps %xmm1,%xmm5
movlhps %xmm4,%xmm5
shufps $0x0,%xmm13,%xmm13
movaps %xmm5,%xmm1
mulps  %xmm13,%xmm1
subps  %xmm1,%xmm6
movss  0x38(%rax),%xmm1
movss  0x28(%rax),%xmm4
unpcklps %xmm1,%xmm4
movss  0x18(%rax),%xmm1
unpcklps %xmm1,%xmm3
movlhps %xmm4,%xmm3
shufps $0x0,%xmm11,%xmm11
movaps %xmm3,%xmm1
mulps  %xmm11,%xmm1
subps  %xmm1,%xmm6
movss  0x3c(%rax),%xmm1
movss  0x2c(%rax),%xmm4
unpcklps %xmm1,%xmm4
movss  0x1c(%rax),%xmm1
unpcklps %xmm1,%xmm0
movlhps %xmm4,%xmm0
shufps $0x0,%xmm10,%xmm10
movaps %xmm0,%xmm1
mulps  %xmm10,%xmm1
subps  %xmm1,%xmm6
add    $0x4,%edx
add    $0x10,%r8
add    %r11,%rax
cmp    %r10d,%edx
jl     1130 <kernel_strsv_lt_inv_4_lib4+0x30>
xorps  %xmm8,%xmm2
xorps  %xmm8,%xmm5
xorps  %xmm8,%xmm3
xorps  %xmm8,%xmm0
mulps  %xmm7,%xmm2
addps  %xmm9,%xmm2
mulps  %xmm13,%xmm5
addps  %xmm2,%xmm5
mulps  %xmm11,%xmm3
addps  %xmm5,%xmm3
mulps  %xmm10,%xmm0
addps  %xmm3,%xmm0
mov    %edi,%edx
and    $0xfffffffc,%edx
jmp    1248 <kernel_strsv_lt_inv_4_lib4+0x148>
xorps  %xmm0,%xmm0
mov    $0x4,%edx
mov    0x8(%rsp),%r10
cmp    %edi,%edx
jge    12aa <kernel_strsv_lt_inv_4_lib4+0x1aa>
sub    %edx,%edi
xor    %edx,%edx
movaps 0xda4(%rip),%xmm1
nopl   0x0(%rax)
movaps %xmm0,%xmm2
movss  (%rax,%rdx,4),%xmm3
movss  0x10(%rax,%rdx,4),%xmm4
unpcklps %xmm4,%xmm3
movss  0x20(%rax,%rdx,4),%xmm4
movss  0x30(%rax,%rdx,4),%xmm5
unpcklps %xmm5,%xmm4
movlhps %xmm4,%xmm3
movss  (%r8,%rdx,4),%xmm4
shufps $0x0,%xmm4,%xmm4
movaps %xmm3,%xmm5
mulps  %xmm4,%xmm5
subps  %xmm5,%xmm0
add    $0x1,%rdx
cmp    %edx,%edi
jne    1260 <kernel_strsv_lt_inv_4_lib4+0x160>
xorps  %xmm1,%xmm3
mulps  %xmm4,%xmm3
addps  %xmm2,%xmm3
movaps %xmm3,%xmm0
movss  (%r9),%xmm1
addss  %xmm0,%xmm1
movaps %xmm0,%xmm2
shufps $0x55,%xmm0,%xmm2
addss  0x4(%r9),%xmm2
movaps %xmm0,%xmm3
unpckhpd %xmm0,%xmm3
addss  0x8(%r9),%xmm3
shufps $0xff,%xmm0,%xmm0
addss  0xc(%r9),%xmm0
mulss  0xc(%rcx),%xmm0
movss  %xmm0,0xc(%r10)
movss  0x2c(%rsi),%xmm4
mulss  %xmm0,%xmm4
subss  %xmm4,%xmm3
mulss  0x8(%rcx),%xmm3
movss  %xmm3,0x8(%r10)
movss  0xc(%rsi),%xmm4
mulss  %xmm0,%xmm4
movss  0x8(%rsi),%xmm5
mulss  %xmm3,%xmm5
addss  %xmm4,%xmm5
mulss  0x1c(%rsi),%xmm0
mulss  0x18(%rsi),%xmm3
addss  %xmm0,%xmm3
subss  %xmm3,%xmm2
mulss  0x4(%rcx),%xmm2
subss  %xmm5,%xmm1
movss  %xmm2,0x4(%r10)
mulss  0x4(%rsi),%xmm2
subss  %xmm2,%xmm1
mulss  (%rcx),%xmm1
movss  %xmm1,(%r10)
ret

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

LLVM IR (-O2):
define void @kernel_strsv_lt_inv_4_lib4(i32 %0, float* nocapture %1, i32 %2, float* nocapture %3, float* nocapture %4, float* nocapture %5, float* nocapture writeonly %6) {
%8 = shl i32 %2, 2
%9 = sext i32 %8 to i64
%10 = add nsw i32 %0, -3
%11 = getelementptr inbounds float, float* %1, i64 %9
%12 = getelementptr inbounds float, float* %4, i64 4
%13 = icmp sgt i32 %0, 7
br i1 %13, label %26, label %20
14: ; preds = %26
%15 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %50, <4 x float> %52, <4 x float> %31)
%16 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %66, <4 x float> %68, <4 x float> %15)
%17 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %82, <4 x float> %84, <4 x float> %16)
%18 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %98, <4 x float> %100, <4 x float> %17)
%19 = and i32 %0, -4
br label %20
20: ; preds = %14, %7
%21 = phi i32 [ 4, %7 ], [ %19, %14 ]
%22 = phi float* [ %11, %7 ], [ %103, %14 ]
%23 = phi float* [ %12, %7 ], [ %104, %14 ]
%24 = phi <4 x float> [ zeroinitializer, %7 ], [ %18, %14 ]
%25 = icmp slt i32 %21, %0
br i1 %25, label %106, label %133
26: ; preds = %7, %26
%27 = phi float* [ %104, %26 ], [ %12, %7 ]
%28 = phi float* [ %103, %26 ], [ %11, %7 ]
%29 = phi float* [ %27, %26 ], [ %4, %7 ]
%30 = phi i32 [ %102, %26 ], [ 4, %7 ]
%31 = phi <4 x float> [ %101, %26 ], [ zeroinitializer, %7 ]
%32 = load float, float* %27
%33 = getelementptr inbounds float, float* %29, i64 5
%34 = load float, float* %33
%35 = getelementptr inbounds float, float* %29, i64 6
%36 = load float, float* %35
%37 = getelementptr inbounds float, float* %29, i64 7
%38 = load float, float* %37
%39 = load float, float* %28
%40 = getelementptr inbounds float, float* %28, i64 4
%41 = load float, float* %40
%42 = getelementptr inbounds float, float* %28, i64 8
%43 = load float, float* %42
%44 = getelementptr inbounds float, float* %28, i64 12
%45 = load float, float* %44
%46 = insertelement <4 x float> poison, float %39, i64 0
%47 = insertelement <4 x float> %46, float %41, i64 1
%48 = insertelement <4 x float> %47, float %43, i64 2
%49 = insertelement <4 x float> %48, float %45, i64 3
%50 = fneg <4 x float> %49
%51 = insertelement <4 x float> poison, float %32, i64 0
%52 = shufflevector <4 x float> %51, <4 x float> poison, <4 x i32> zeroinitializer
%53 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %50, <4 x float> %52, <4 x float> %31)
%54 = getelementptr inbounds float, float* %28, i64 1
%55 = load float, float* %54
%56 = getelementptr inbounds float, float* %28, i64 5
%57 = load float, float* %56
%58 = getelementptr inbounds float, float* %28, i64 9
%59 = load float, float* %58
%60 = getelementptr inbounds float, float* %28, i64 13
%61 = load float, float* %60
%62 = insertelement <4 x float> poison, float %55, i64 0
%63 = insertelement <4 x float> %62, float %57, i64 1
%64 = insertelement <4 x float> %63, float %59, i64 2
%65 = insertelement <4 x float> %64, float %61, i64 3
%66 = fneg <4 x float> %65
%67 = insertelement <4 x float> poison, float %34, i64 0
%68 = shufflevector <4 x float> %67, <4 x float> poison, <4 x i32> zeroinitializer
%69 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %66, <4 x float> %68, <4 x float> %53)
%70 = getelementptr inbounds float, float* %28, i64 2
%71 = load float, float* %70
%72 = getelementptr inbounds float, float* %28, i64 6
%73 = load float, float* %72
%74 = getelementptr inbounds float, float* %28, i64 10
%75 = load float, float* %74
%76 = getelementptr inbounds float, float* %28, i64 14
%77 = load float, float* %76
%78 = insertelement <4 x float> poison, float %71, i64 0
%79 = insertelement <4 x float> %78, float %73, i64 1
%80 = insertelement <4 x float> %79, float %75, i64 2
%81 = insertelement <4 x float> %80, float %77, i64 3
%82 = fneg <4 x float> %81
%83 = insertelement <4 x float> poison, float %36, i64 0
%84 = shufflevector <4 x float> %83, <4 x float> poison, <4 x i32> zeroinitializer
%85 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %82, <4 x float> %84, <4 x float> %69)
%86 = getelementptr inbounds float, float* %28, i64 3
%87 = load float, float* %86
%88 = getelementptr inbounds float, float* %28, i64 7
%89 = load float, float* %88
%90 = getelementptr inbounds float, float* %28, i64 11
%91 = load float, float* %90
%92 = getelementptr inbounds float, float* %28, i64 15
%93 = load float, float* %92
%94 = insertelement <4 x float> poison, float %87, i64 0
%95 = insertelement <4 x float> %94, float %89, i64 1
%96 = insertelement <4 x float> %95, float %91, i64 2
%97 = insertelement <4 x float> %96, float %93, i64 3
%98 = fneg <4 x float> %97
%99 = insertelement <4 x float> poison, float %38, i64 0
%100 = shufflevector <4 x float> %99, <4 x float> poison, <4 x i32> zeroinitializer
%101 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %98, <4 x float> %100, <4 x float> %85)
%102 = add nuw nsw i32 %30, 4
%103 = getelementptr inbounds float, float* %28, i64 %9
%104 = getelementptr inbounds float, float* %27, i64 4
%105 = icmp slt i32 %102, %10
br i1 %105, label %26, label %14
106: ; preds = %20, %106
%107 = phi float* [ %127, %106 ], [ %22, %20 ]
%108 = phi float* [ %128, %106 ], [ %23, %20 ]
%109 = phi i32 [ %129, %106 ], [ %21, %20 ]
%110 = phi <4 x float> [ %126, %106 ], [ %24, %20 ]
%111 = load float, float* %108
%112 = load float, float* %107
%113 = getelementptr inbounds float, float* %107, i64 4
%114 = load float, float* %113
%115 = getelementptr inbounds float, float* %107, i64 8
%116 = load float, float* %115
%117 = getelementptr inbounds float, float* %107, i64 12
%118 = load float, float* %117
%119 = insertelement <4 x float> poison, float %112, i64 0
%120 = insertelement <4 x float> %119, float %114, i64 1
%121 = insertelement <4 x float> %120, float %116, i64 2
%122 = insertelement <4 x float> %121, float %118, i64 3
%123 = fneg <4 x float> %122
%124 = insertelement <4 x float> poison, float %111, i64 0
%125 = shufflevector <4 x float> %124, <4 x float> poison, <4 x i32> zeroinitializer
%126 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %123, <4 x float> %125, <4 x float> %110)
%127 = getelementptr inbounds float, float* %107, i64 1
%128 = getelementptr inbounds float, float* %108, i64 1
%129 = add nuw nsw i32 %109, 1
%130 = icmp eq i32 %129, %0
br i1 %130, label %131, label %106
131: ; preds = %106
%132 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %123, <4 x float> %125, <4 x float> %110)
br label %133
133: ; preds = %131, %20
%134 = phi <4 x float> [ %24, %20 ], [ %132, %131 ]
%135 = load float, float* %5
%136 = extractelement <4 x float> %134, i64 0
%137 = fadd float %136, %135
%138 = getelementptr inbounds float, float* %5, i64 1
%139 = load float, float* %138
%140 = extractelement <4 x float> %134, i64 1
%141 = fadd float %140, %139
%142 = getelementptr inbounds float, float* %5, i64 2
%143 = load float, float* %142
%144 = extractelement <4 x float> %134, i64 2
%145 = fadd float %144, %143
%146 = getelementptr inbounds float, float* %5, i64 3
%147 = load float, float* %146
%148 = extractelement <4 x float> %134, i64 3
%149 = fadd float %148, %147
%150 = getelementptr inbounds float, float* %3, i64 3
%151 = load float, float* %150
%152 = fmul float %149, %151
%153 = getelementptr inbounds float, float* %6, i64 3
store float %152, float* %153
%154 = getelementptr inbounds float, float* %1, i64 11
%155 = load float, float* %154
%156 = fneg float %155
%157 = tail call float @llvm.fmuladd.f32(float %156, float %152, float %145)
%158 = getelementptr inbounds float, float* %3, i64 2
%159 = load float, float* %158
%160 = fmul float %157, %159
%161 = getelementptr inbounds float, float* %6, i64 2
store float %160, float* %161
%162 = getelementptr inbounds float, float* %1, i64 2
%163 = load float, float* %162
%164 = getelementptr inbounds float, float* %1, i64 3
%165 = load float, float* %164
%166 = fmul float %152, %165
%167 = tail call float @llvm.fmuladd.f32(float %163, float %160, float %166)
%168 = fsub float %137, %167
%169 = getelementptr inbounds float, float* %1, i64 6
%170 = load float, float* %169
%171 = getelementptr inbounds float, float* %1, i64 7
%172 = load float, float* %171
%173 = fmul float %152, %172
%174 = tail call float @llvm.fmuladd.f32(float %170, float %160, float %173)
%175 = fsub float %141, %174
%176 = getelementptr inbounds float, float* %3, i64 1
%177 = load float, float* %176
%178 = fmul float %177, %175
%179 = getelementptr inbounds float, float* %6, i64 1
store float %178, float* %179
%180 = getelementptr inbounds float, float* %1, i64 1
%181 = load float, float* %180
%182 = fneg float %181
%183 = tail call float @llvm.fmuladd.f32(float %182, float %178, float %168)
%184 = load float, float* %3
%185 = fmul float %184, %183
store float %185, float* %6
ret void
}