void revbin_permute_4(double _Complex *f) {
  {
    double _Complex t = f[1];
    f[1] = f[2];
    f[2] = t;
  };
}


x86 assembly (clang, -O0):
<revbin_permute_4>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movsd  0x10(%rax),%xmm1
movsd  0x18(%rax),%xmm0
movsd  %xmm1,-0x18(%rbp)
movsd  %xmm0,-0x10(%rbp)
mov    -0x8(%rbp),%rax
movsd  0x20(%rax),%xmm1
movsd  0x28(%rax),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm1,0x10(%rax)
movsd  %xmm0,0x18(%rax)
movsd  -0x18(%rbp),%xmm1
movsd  -0x10(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm1,0x20(%rax)
movsd  %xmm0,0x28(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<revbin_permute_4>:
movups 0x10(%rdi),%xmm0
movups 0x20(%rdi),%xmm1
movups %xmm1,0x10(%rdi)
movups %xmm0,0x20(%rdi)
ret

LLVM IR (-O0):
define void @revbin_permute_4({ double, double }* %0) {
%2 = alloca { double, double }*
%3 = alloca { double, double }
store { double, double }* %0, { double, double }** %2
%4 = load { double, double }*, { double, double }** %2
%5 = getelementptr inbounds { double, double }, { double, double }* %4, i64 1
%6 = getelementptr inbounds { double, double }, { double, double }* %5, i32 0, i32 0
%7 = load double, double* %6
%8 = getelementptr inbounds { double, double }, { double, double }* %5, i32 0, i32 1
%9 = load double, double* %8
%10 = getelementptr inbounds { double, double }, { double, double }* %3, i32 0, i32 0
%11 = getelementptr inbounds { double, double }, { double, double }* %3, i32 0, i32 1
store double %7, double* %10
store double %9, double* %11
%12 = load { double, double }*, { double, double }** %2
%13 = getelementptr inbounds { double, double }, { double, double }* %12, i64 2
%14 = getelementptr inbounds { double, double }, { double, double }* %13, i32 0, i32 0
%15 = load double, double* %14
%16 = getelementptr inbounds { double, double }, { double, double }* %13, i32 0, i32 1
%17 = load double, double* %16
%18 = load { double, double }*, { double, double }** %2
%19 = getelementptr inbounds { double, double }, { double, double }* %18, i64 1
%20 = getelementptr inbounds { double, double }, { double, double }* %19, i32 0, i32 0
%21 = getelementptr inbounds { double, double }, { double, double }* %19, i32 0, i32 1
store double %15, double* %20
store double %17, double* %21
%22 = getelementptr inbounds { double, double }, { double, double }* %3, i32 0, i32 0
%23 = load double, double* %22
%24 = getelementptr inbounds { double, double }, { double, double }* %3, i32 0, i32 1
%25 = load double, double* %24
%26 = load { double, double }*, { double, double }** %2
%27 = getelementptr inbounds { double, double }, { double, double }* %26, i64 2
%28 = getelementptr inbounds { double, double }, { double, double }* %27, i32 0, i32 0
%29 = getelementptr inbounds { double, double }, { double, double }* %27, i32 0, i32 1
store double %23, double* %28
store double %25, double* %29
ret void
}

LLVM IR (-O2):
define void @revbin_permute_4({ double, double }* nocapture %0) {
%2 = getelementptr inbounds { double, double }, { double, double }* %0, i64 1, i32 0
%3 = bitcast double* %2 to <2 x double>*
%4 = load <2 x double>, <2 x double>* %3
%5 = getelementptr inbounds { double, double }, { double, double }* %0, i64 2, i32 0
%6 = bitcast double* %5 to <2 x double>*
%7 = load <2 x double>, <2 x double>* %6
%8 = bitcast double* %2 to <2 x double>*
store <2 x double> %7, <2 x double>* %8
%9 = bitcast double* %5 to <2 x double>*
store <2 x double> %4, <2 x double>* %9
ret void
}