void mp_squh_f_save_infft(int n, int radix, int in[], int out[], int nfft,
                          char *f_name_infft, double outfft[]) {
  void f_swap_out(int bytesize, char *f_name, char *out);
  void rdft(int n, int isgn, double *a);
  void mp_mul_i2d(int n, int radix, int nfft, int shift, int in[],
                  double dout[]);
  void mp_mul_csqu(int nfft, double dinout[]);
  void mp_mul_d2i(int n, int radix, int nfft, double din[], int out[]);
  mp_mul_i2d(n, radix, nfft, 0, in, outfft);
  rdft(nfft, 1, &outfft[1]);
  f_swap_out((nfft + 2) * sizeof(double), f_name_infft, (char *)outfft);
  mp_mul_csqu(nfft, outfft);
  rdft(nfft, -1, &outfft[1]);
  mp_mul_d2i(n, radix, nfft, outfft, out);
}


x86 assembly (clang, -O0):
<mp_squh_f_save_infft>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    0x10(%rbp),%rax
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %rdx,-0x10(%rbp)
mov    %rcx,-0x18(%rbp)
mov    %r8d,-0x1c(%rbp)
mov    %r9,-0x28(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    -0x1c(%rbp),%edx
mov    -0x10(%rbp),%r8
mov    0x10(%rbp),%r9
xor    %ecx,%ecx
call   1030 <mp_mul_i2d@plt>
mov    -0x1c(%rbp),%edi
mov    0x10(%rbp),%rdx
add    $0x8,%rdx
mov    $0x1,%esi
call   1060 <rdft@plt>
mov    -0x1c(%rbp),%eax
add    $0x2,%eax
cltq
shl    $0x3,%rax
mov    %eax,%edi
mov    -0x28(%rbp),%rsi
mov    0x10(%rbp),%rdx
call   1040 <f_swap_out@plt>
mov    -0x1c(%rbp),%edi
mov    0x10(%rbp),%rsi
call   1050 <mp_mul_csqu@plt>
mov    -0x1c(%rbp),%edi
mov    0x10(%rbp),%rdx
add    $0x8,%rdx
mov    $0xffffffff,%esi
call   1060 <rdft@plt>
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
mov    -0x1c(%rbp),%edx
mov    0x10(%rbp),%rcx
mov    -0x18(%rbp),%r8
call   1070 <mp_mul_d2i@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<mp_squh_f_save_infft>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %r9,%r13
mov    %r8d,%ebx
mov    %rcx,(%rsp)
mov    %rdx,%r8
mov    %esi,%r15d
mov    %edi,%r12d
mov    0x40(%rsp),%rbp
mov    %ebx,%edx
xor    %ecx,%ecx
mov    %rbp,%r9
call   1030 <mp_mul_i2d@plt>
lea    0x8(%rbp),%r14
mov    %ebx,%edi
mov    $0x1,%esi
mov    %r14,%rdx
call   1060 <rdft@plt>
lea    0x10(,%rbx,8),%edi
mov    %r13,%rsi
mov    %rbp,%rdx
call   1040 <f_swap_out@plt>
mov    %ebx,%edi
mov    %rbp,%rsi
call   1050 <mp_mul_csqu@plt>
mov    %ebx,%edi
mov    $0xffffffff,%esi
mov    %r14,%rdx
call   1060 <rdft@plt>
mov    %r12d,%edi
mov    %r15d,%esi
mov    %ebx,%edx
mov    %rbp,%rcx
mov    (%rsp),%r8
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1070 <mp_mul_d2i@plt>

LLVM IR (-O0):
define void @mp_squh_f_save_infft(i32 %0, i32 %1, i32* %2, i32* %3, i32 %4, i8* %5, double* %6) {
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32*
%11 = alloca i32*
%12 = alloca i32
%13 = alloca i8*
%14 = alloca double*
store i32 %0, i32* %8
store i32 %1, i32* %9
store i32* %2, i32** %10
store i32* %3, i32** %11
store i32 %4, i32* %12
store i8* %5, i8** %13
store double* %6, double** %14
%15 = load i32, i32* %8
%16 = load i32, i32* %9
%17 = load i32, i32* %12
%18 = load i32*, i32** %10
%19 = load double*, double** %14
%20 = load i32, i32* %12
%21 = load double*, double** %14
%22 = getelementptr inbounds double, double* %21, i64 1
%23 = load i32, i32* %12
%24 = add nsw i32 %23, 2
%25 = sext i32 %24 to i64
%26 = mul i64 %25, 8
%27 = trunc i64 %26 to i32
%28 = load i8*, i8** %13
%29 = load double*, double** %14
%30 = bitcast double* %29 to i8*
%31 = load i32, i32* %12
%32 = load double*, double** %14
%33 = load i32, i32* %12
%34 = load double*, double** %14
%35 = getelementptr inbounds double, double* %34, i64 1
%36 = load i32, i32* %8
%37 = load i32, i32* %9
%38 = load i32, i32* %12
%39 = load double*, double** %14
%40 = load i32*, i32** %11
ret void
}

LLVM IR (-O2):
define void @mp_squh_f_save_infft(i32 %0, i32 %1, i32* %2, i32* %3, i32 %4, i8* %5, double* %6) {
tail call void @mp_mul_i2d(i32 %0, i32 %1, i32 %4, i32 0, i32* %2, double* %6)
%8 = getelementptr inbounds double, double* %6, i64 1
tail call void @rdft(i32 %4, i32 1, double* %8)
%9 = shl i32 %4, 3
%10 = add i32 %9, 16
%11 = bitcast double* %6 to i8*
tail call void @f_swap_out(i32 %10, i8* %5, i8* %11)
tail call void @mp_mul_csqu(i32 %4, double* %6)
tail call void @rdft(i32 %4, i32 -1, double* %8)
tail call void @mp_mul_d2i(i32 %0, i32 %1, i32 %4, double* %6, i32* %3)
ret void
}