void __attribute__((noipa)) f_7(double *restrict a, double *restrict b,
                                double *restrict c, double *restrict d) {
  for (int i = 0; i < (128 * 11 / 64 + 3); ++i) {
    double mb = (7 & 1 ? -b[i] : b[i]);
    double mc = c[i];
    double md = (7 & 2 ? -d[i] : d[i]);
    double fma = __builtin_fma(mb, mc, md);
    double truev = (7 & 4 ? -fma : fma);
    a[i] = b[i] < 10 ? truev : 10.0;
  }
}


x86 assembly (clang, -O0):
<f_7>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
movl   $0x0,-0x24(%rbp)
cmpl   $0x19,-0x24(%rbp)
jge    1233 <f_7+0x123>
mov    -0x10(%rbp),%rax
movslq -0x24(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x30(%rbp)
mov    -0x18(%rbp),%rax
movslq -0x24(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movsd  %xmm0,-0x38(%rbp)
mov    -0x20(%rbp),%rax
movslq -0x24(%rbp),%rcx
movsd  (%rax,%rcx,8),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x30(%rbp),%xmm0
movsd  -0x38(%rbp),%xmm1
movsd  -0x40(%rbp),%xmm2
call   1030 <fma@plt>
movsd  %xmm0,-0x48(%rbp)
movsd  -0x48(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x50(%rbp)
mov    -0x10(%rbp),%rax
movslq -0x24(%rbp),%rcx
movsd  0xe19(%rip),%xmm0
ucomisd (%rax,%rcx,8),%xmm0
jbe    1201 <f_7+0xf1>
movsd  -0x50(%rbp),%xmm0
movsd  %xmm0,-0x58(%rbp)
jmp    1213 <f_7+0x103>
movsd  0xdf7(%rip),%xmm0
movsd  %xmm0,-0x58(%rbp)
jmp    1213 <f_7+0x103>
movsd  -0x58(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movslq -0x24(%rbp),%rcx
movsd  %xmm0,(%rax,%rcx,8)
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
jmp    112f <f_7+0x1f>
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<f_7>:
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x50,%rsp
mov    %rcx,%r15
mov    %rdx,%r12
mov    %rsi,%r13
mov    %rdi,%r14
xor    %ebx,%ebx
nopl   0x0(%rax,%rax,1)
movups 0x0(%r13,%rbx,8),%xmm3
movaps %xmm3,(%rsp)
movaps 0xebf(%rip),%xmm0
xorps  %xmm0,%xmm3
movaps %xmm3,0x30(%rsp)
movups (%r12,%rbx,8),%xmm1
movaps %xmm1,0x10(%rsp)
movups (%r15,%rbx,8),%xmm2
xorps  %xmm0,%xmm2
movaps %xmm2,0x20(%rsp)
movaps %xmm3,%xmm0
call   1030 <fma@plt>
movaps %xmm0,0x40(%rsp)
movaps 0x10(%rsp),%xmm1
movhlps %xmm1,%xmm1
pshufd $0xee,0x30(%rsp),%xmm0
pshufd $0xee,0x20(%rsp),%xmm2
call   1030 <fma@plt>
movdqa 0x40(%rsp),%xmm2
punpcklqdq %xmm0,%xmm2
pxor   0xe66(%rip),%xmm2
movapd 0xe6e(%rip),%xmm0
movapd (%rsp),%xmm1
cmpltpd %xmm0,%xmm1
pand   %xmm1,%xmm2
andnpd %xmm0,%xmm1
orpd   %xmm2,%xmm1
movupd %xmm1,(%r14,%rbx,8)
add    $0x2,%rbx
cmp    $0x18,%rbx
jne    1130 <f_7+0x20>
movsd  0xc0(%r13),%xmm0
movapd %xmm0,(%rsp)
movapd 0xe1e(%rip),%xmm3
xorpd  %xmm3,%xmm0
movsd  0xc0(%r12),%xmm1
movsd  0xc0(%r15),%xmm2
xorpd  %xmm3,%xmm2
call   1030 <fma@plt>
xorpd  0xdf6(%rip),%xmm0
movsd  0xe0e(%rip),%xmm1
movapd (%rsp),%xmm2
cmpltsd %xmm1,%xmm2
andpd  %xmm2,%xmm0
andnpd %xmm1,%xmm2
orpd   %xmm0,%xmm2
movlpd %xmm2,0xc0(%r14)
add    $0x50,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define void @f_7(double* noalias %0, double* noalias %1, double* noalias %2, double* noalias %3) {
%5 = alloca double*
%6 = alloca double*
%7 = alloca double*
%8 = alloca double*
%9 = alloca i32
%10 = alloca double
%11 = alloca double
%12 = alloca double
%13 = alloca double
%14 = alloca double
store double* %0, double** %5
store double* %1, double** %6
store double* %2, double** %7
store double* %3, double** %8
store i32 0, i32* %9
br label %15
15: ; preds = %57, %4
%16 = load i32, i32* %9
%17 = icmp slt i32 %16, 25
br i1 %17, label %18, label %60
18: ; preds = %15
%19 = load double*, double** %6
%20 = load i32, i32* %9
%21 = sext i32 %20 to i64
%22 = getelementptr inbounds double, double* %19, i64 %21
%23 = load double, double* %22
%24 = fneg double %23
store double %24, double* %10
%25 = load double*, double** %7
%26 = load i32, i32* %9
%27 = sext i32 %26 to i64
%28 = getelementptr inbounds double, double* %25, i64 %27
%29 = load double, double* %28
store double %29, double* %11
%30 = load double*, double** %8
%31 = load i32, i32* %9
%32 = sext i32 %31 to i64
%33 = getelementptr inbounds double, double* %30, i64 %32
%34 = load double, double* %33
%35 = fneg double %34
store double %35, double* %12
%36 = load double, double* %10
%37 = load double, double* %11
%38 = load double, double* %12
%39 = call double @llvm.fma.f64(double %36, double %37, double %38)
store double %39, double* %13
%40 = load double, double* %13
%41 = fneg double %40
store double %41, double* %14
%42 = load double*, double** %6
%43 = load i32, i32* %9
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds double, double* %42, i64 %44
%46 = load double, double* %45
%47 = fcmp olt double %46, 1.000000e+01
br i1 %47, label %48, label %50
48: ; preds = %18
%49 = load double, double* %14
br label %51
50: ; preds = %18
br label %51
51: ; preds = %50, %48
%52 = phi double [ %49, %48 ], [ 1.000000e+01, %50 ]
%53 = load double*, double** %5
%54 = load i32, i32* %9
%55 = sext i32 %54 to i64
%56 = getelementptr inbounds double, double* %53, i64 %55
store double %52, double* %56
br label %57
57: ; preds = %51
%58 = load i32, i32* %9
%59 = add nsw i32 %58, 1
store i32 %59, i32* %9
br label %15
60: ; preds = %15
ret void
}

LLVM IR (-O2):
define void @f_7(double* noalias nocapture writeonly %0, double* noalias nocapture %1, double* noalias nocapture %2, double* noalias nocapture %3) {
br label %5
5: ; preds = %5, %4
%6 = phi i64 [ 0, %4 ], [ %24, %5 ]
%7 = getelementptr inbounds double, double* %1, i64 %6
%8 = bitcast double* %7 to <2 x double>*
%9 = load <2 x double>, <2 x double>* %8
%10 = fneg <2 x double> %9
%11 = getelementptr inbounds double, double* %2, i64 %6
%12 = bitcast double* %11 to <2 x double>*
%13 = load <2 x double>, <2 x double>* %12
%14 = getelementptr inbounds double, double* %3, i64 %6
%15 = bitcast double* %14 to <2 x double>*
%16 = load <2 x double>, <2 x double>* %15
%17 = fneg <2 x double> %16
%18 = call <2 x double> @llvm.fma.v2f64(<2 x double> %10, <2 x double> %13, <2 x double> %17)
%19 = fneg <2 x double> %18
%20 = fcmp olt <2 x double> %9, <double 1.000000e+01, double 1.000000e+01>
%21 = select <2 x i1> %20, <2 x double> %19, <2 x double> <double 1.000000e+01, double 1.000000e+01>
%22 = getelementptr inbounds double, double* %0, i64 %6
%23 = bitcast double* %22 to <2 x double>*
store <2 x double> %21, <2 x double>* %23
%24 = add nuw i64 %6, 2
%25 = icmp eq i64 %24, 24
br i1 %25, label %26, label %5
26: ; preds = %5
%27 = getelementptr inbounds double, double* %1, i64 24
%28 = load double, double* %27
%29 = fneg double %28
%30 = getelementptr inbounds double, double* %2, i64 24
%31 = load double, double* %30
%32 = getelementptr inbounds double, double* %3, i64 24
%33 = load double, double* %32
%34 = fneg double %33
%35 = tail call double @llvm.fma.f64(double %29, double %31, double %34)
%36 = fneg double %35
%37 = fcmp olt double %28, 1.000000e+01
%38 = select i1 %37, double %36, double 1.000000e+01
%39 = getelementptr inbounds double, double* %0, i64 24
store double %38, double* %39
ret void
}