double _Complex my_fxcpmadd(double _Complex t, double _Complex x, double a) {
  double y[2];
  y[0] = my_creal(t) + a * my_creal(x);
  y[1] = my_cimag(t) + a * my_cimag(x);
  return ((double _Complex *)y)[0];
}


x86 assembly (clang, -O0):
<my_fxcpmadd>:
push   %rbp
mov    %rsp,%rbp
sub    $0xc0,%rsp
movsd  %xmm0,-0x20(%rbp)
movsd  %xmm1,-0x18(%rbp)
movsd  %xmm2,-0x30(%rbp)
movsd  %xmm3,-0x28(%rbp)
movsd  %xmm4,-0x38(%rbp)
movsd  -0x20(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm0
movsd  %xmm1,-0x60(%rbp)
movsd  %xmm0,-0x58(%rbp)
movsd  -0x60(%rbp),%xmm0
movsd  -0x58(%rbp),%xmm1
mov    $0x2,%al
mov    %al,-0xa1(%rbp)
call   1040 <my_creal@plt>
mov    %eax,%ecx
mov    -0xa1(%rbp),%al
cvtsi2sd %ecx,%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
movsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0xb8(%rbp)
ff
movsd  -0x30(%rbp),%xmm1
movsd  -0x28(%rbp),%xmm0
movsd  %xmm1,-0x70(%rbp)
movsd  %xmm0,-0x68(%rbp)
movsd  -0x70(%rbp),%xmm0
movsd  -0x68(%rbp),%xmm1
call   1040 <my_creal@plt>
movsd  -0xb8(%rbp),%xmm0
ff
movsd  -0xb0(%rbp),%xmm1
ff
mov    %eax,%ecx
mov    -0xa1(%rbp),%al
cvtsi2sd %ecx,%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x50(%rbp)
movsd  -0x20(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm0
movsd  %xmm1,-0x80(%rbp)
movsd  %xmm0,-0x78(%rbp)
movsd  -0x80(%rbp),%xmm0
movsd  -0x78(%rbp),%xmm1
call   1030 <my_cimag@plt>
mov    %eax,%ecx
mov    -0xa1(%rbp),%al
cvtsi2sd %ecx,%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0x38(%rbp),%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0x30(%rbp),%xmm1
movsd  -0x28(%rbp),%xmm0
movsd  %xmm1,-0x90(%rbp)
ff
movsd  %xmm0,-0x88(%rbp)
ff
movsd  -0x90(%rbp),%xmm0
ff
movsd  -0x88(%rbp),%xmm1
ff
call   1030 <my_cimag@plt>
movsd  -0xa0(%rbp),%xmm0
ff
movsd  -0x98(%rbp),%xmm1
ff
cvtsi2sd %eax,%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  -0x50(%rbp),%xmm1
movsd  -0x48(%rbp),%xmm0
movsd  %xmm1,-0x10(%rbp)
movsd  %xmm0,-0x8(%rbp)
movsd  -0x10(%rbp),%xmm0
movsd  -0x8(%rbp),%xmm1
add    $0xc0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<my_fxcpmadd>:
sub    $0x38,%rsp
movsd  %xmm4,0x28(%rsp)
movsd  %xmm3,0x20(%rsp)
movsd  %xmm2,0x18(%rsp)
movsd  %xmm1,0x8(%rsp)
movsd  %xmm0,0x30(%rsp)
mov    $0x2,%al
call   1040 <my_creal@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
movsd  %xmm0,0x10(%rsp)
movsd  0x18(%rsp),%xmm0
movsd  0x20(%rsp),%xmm1
mov    $0x2,%al
call   1040 <my_creal@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
mulsd  0x28(%rsp),%xmm0
addsd  0x10(%rsp),%xmm0
movsd  %xmm0,0x10(%rsp)
movsd  0x30(%rsp),%xmm0
movsd  0x8(%rsp),%xmm1
mov    $0x2,%al
call   1030 <my_cimag@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
movsd  %xmm0,0x8(%rsp)
movsd  0x18(%rsp),%xmm0
movsd  0x20(%rsp),%xmm1
mov    $0x2,%al
call   1030 <my_cimag@plt>
xorps  %xmm1,%xmm1
cvtsi2sd %eax,%xmm1
mulsd  0x28(%rsp),%xmm1
addsd  0x8(%rsp),%xmm1
movsd  0x10(%rsp),%xmm0
add    $0x38,%rsp
ret

LLVM IR (-O0):
define { double, double } @my_fxcpmadd(double %0, double %1, double %2, double %3, double %4) {
%6 = alloca { double, double }
%7 = alloca { double, double }
%8 = alloca { double, double }
%9 = alloca double
%10 = alloca [2 x double]
%11 = alloca { double, double }
%12 = alloca { double, double }
%13 = alloca { double, double }
%14 = alloca { double, double }
%15 = getelementptr inbounds { double, double }, { double, double }* %7, i32 0, i32 0
store double %0, double* %15
%16 = getelementptr inbounds { double, double }, { double, double }* %7, i32 0, i32 1
store double %1, double* %16
%17 = getelementptr inbounds { double, double }, { double, double }* %8, i32 0, i32 0
store double %2, double* %17
%18 = getelementptr inbounds { double, double }, { double, double }* %8, i32 0, i32 1
store double %3, double* %18
store double %4, double* %9
%19 = getelementptr inbounds { double, double }, { double, double }* %7, i32 0, i32 0
%20 = load double, double* %19
%21 = getelementptr inbounds { double, double }, { double, double }* %7, i32 0, i32 1
%22 = load double, double* %21
%23 = getelementptr inbounds { double, double }, { double, double }* %11, i32 0, i32 0
%24 = getelementptr inbounds { double, double }, { double, double }* %11, i32 0, i32 1
store double %20, double* %23
store double %22, double* %24
%25 = getelementptr inbounds { double, double }, { double, double }* %11, i32 0, i32 0
%26 = load double, double* %25
%27 = getelementptr inbounds { double, double }, { double, double }* %11, i32 0, i32 1
%28 = load double, double* %27
%29 = call i32 (double, double, ...) bitcast (i32 (...)* @my_creal to i32 (double, double, ...)*)(double %26, double %28)
%30 = sitofp i32 %29 to double
%31 = load double, double* %9
%32 = getelementptr inbounds { double, double }, { double, double }* %8, i32 0, i32 0
%33 = load double, double* %32
%34 = getelementptr inbounds { double, double }, { double, double }* %8, i32 0, i32 1
%35 = load double, double* %34
%36 = getelementptr inbounds { double, double }, { double, double }* %12, i32 0, i32 0
%37 = getelementptr inbounds { double, double }, { double, double }* %12, i32 0, i32 1
store double %33, double* %36
store double %35, double* %37
%38 = getelementptr inbounds { double, double }, { double, double }* %12, i32 0, i32 0
%39 = load double, double* %38
%40 = getelementptr inbounds { double, double }, { double, double }* %12, i32 0, i32 1
%41 = load double, double* %40
%42 = call i32 (double, double, ...) bitcast (i32 (...)* @my_creal to i32 (double, double, ...)*)(double %39, double %41)
%43 = sitofp i32 %42 to double
%44 = call double @llvm.fmuladd.f64(double %31, double %43, double %30)
%45 = getelementptr inbounds [2 x double], [2 x double]* %10, i64 0, i64 0
store double %44, double* %45
%46 = getelementptr inbounds { double, double }, { double, double }* %7, i32 0, i32 0
%47 = load double, double* %46
%48 = getelementptr inbounds { double, double }, { double, double }* %7, i32 0, i32 1
%49 = load double, double* %48
%50 = getelementptr inbounds { double, double }, { double, double }* %13, i32 0, i32 0
%51 = getelementptr inbounds { double, double }, { double, double }* %13, i32 0, i32 1
store double %47, double* %50
store double %49, double* %51
%52 = getelementptr inbounds { double, double }, { double, double }* %13, i32 0, i32 0
%53 = load double, double* %52
%54 = getelementptr inbounds { double, double }, { double, double }* %13, i32 0, i32 1
%55 = load double, double* %54
%56 = call i32 (double, double, ...) bitcast (i32 (...)* @my_cimag to i32 (double, double, ...)*)(double %53, double %55)
%57 = sitofp i32 %56 to double
%58 = load double, double* %9
%59 = getelementptr inbounds { double, double }, { double, double }* %8, i32 0, i32 0
%60 = load double, double* %59
%61 = getelementptr inbounds { double, double }, { double, double }* %8, i32 0, i32 1
%62 = load double, double* %61
%63 = getelementptr inbounds { double, double }, { double, double }* %14, i32 0, i32 0
%64 = getelementptr inbounds { double, double }, { double, double }* %14, i32 0, i32 1
store double %60, double* %63
store double %62, double* %64
%65 = getelementptr inbounds { double, double }, { double, double }* %14, i32 0, i32 0
%66 = load double, double* %65
%67 = getelementptr inbounds { double, double }, { double, double }* %14, i32 0, i32 1
%68 = load double, double* %67
%69 = call i32 (double, double, ...) bitcast (i32 (...)* @my_cimag to i32 (double, double, ...)*)(double %66, double %68)
%70 = sitofp i32 %69 to double
%71 = call double @llvm.fmuladd.f64(double %58, double %70, double %57)
%72 = getelementptr inbounds [2 x double], [2 x double]* %10, i64 0, i64 1
store double %71, double* %72
%73 = getelementptr inbounds [2 x double], [2 x double]* %10, i64 0, i64 0
%74 = bitcast double* %73 to { double, double }*
%75 = getelementptr inbounds { double, double }, { double, double }* %74, i64 0
%76 = getelementptr inbounds { double, double }, { double, double }* %75, i32 0, i32 0
%77 = load double, double* %76
%78 = getelementptr inbounds { double, double }, { double, double }* %75, i32 0, i32 1
%79 = load double, double* %78
%80 = getelementptr inbounds { double, double }, { double, double }* %6, i32 0, i32 0
%81 = getelementptr inbounds { double, double }, { double, double }* %6, i32 0, i32 1
store double %77, double* %80
store double %79, double* %81
%82 = load { double, double }, { double, double }* %6
ret { double, double } %82
}

LLVM IR (-O2):
define { double, double } @my_fxcpmadd(double %0, double %1, double %2, double %3, double %4) {
%6 = tail call i32 (double, double, ...) bitcast (i32 (...)* @my_creal to i32 (double, double, ...)*)(double %0, double %1)
%7 = sitofp i32 %6 to double
%8 = tail call i32 (double, double, ...) bitcast (i32 (...)* @my_creal to i32 (double, double, ...)*)(double %2, double %3)
%9 = sitofp i32 %8 to double
%10 = tail call double @llvm.fmuladd.f64(double %4, double %9, double %7)
%11 = tail call i32 (double, double, ...) bitcast (i32 (...)* @my_cimag to i32 (double, double, ...)*)(double %0, double %1)
%12 = sitofp i32 %11 to double
%13 = tail call i32 (double, double, ...) bitcast (i32 (...)* @my_cimag to i32 (double, double, ...)*)(double %2, double %3)
%14 = sitofp i32 %13 to double
%15 = tail call double @llvm.fmuladd.f64(double %4, double %14, double %12)
%16 = insertvalue { double, double } poison, double %10, 0
%17 = insertvalue { double, double } %16, double %15, 1
ret { double, double } %17
}