#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ printf(char *, long, long, ...);
double test_testd(long i0, long i1, long i2, long i3, long i4, long i5,
                  double d0, double d1, double d2, double d3, double d4,
                  double d5, double d6, double d7, double d8, double d9,
                  long i6, long i7) {
  printf("%ld %ld %ld\n", i0, i1, i2);
  printf("%ld %ld %ld\n", i3, i4, i5);
  printf("%lf %lf %lf %lf\n", d0, d1, d2, d3);
  printf("%lf %lf %lf %lf\n", d4, d5, d6, d7);
  printf("%lf %lf\n", d8, d9);
  printf("%ld %ld\n", i6, i7);
  return 1.23456;
}


x86 assembly (clang, -O0):
<test_testd>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
movsd  0x18(%rbp),%xmm8
movsd  0x10(%rbp),%xmm8
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
movsd  %xmm0,-0x38(%rbp)
movsd  %xmm1,-0x40(%rbp)
movsd  %xmm2,-0x48(%rbp)
movsd  %xmm3,-0x50(%rbp)
movsd  %xmm4,-0x58(%rbp)
movsd  %xmm5,-0x60(%rbp)
movsd  %xmm6,-0x68(%rbp)
movsd  %xmm7,-0x70(%rbp)
mov    -0x8(%rbp),%rsi
mov    -0x10(%rbp),%rdx
mov    -0x18(%rbp),%rcx
lea    0xe89(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x20(%rbp),%rsi
mov    -0x28(%rbp),%rdx
mov    -0x30(%rbp),%rcx
lea    0xe6f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
cvttsd2si -0x38(%rbp),%rsi
cvttsd2si -0x40(%rbp),%rdx
movsd  -0x48(%rbp),%xmm0
movsd  -0x50(%rbp),%xmm1
lea    0xe58(%rip),%rdi
mov    $0x2,%al
call   1030 <printf@plt>
cvttsd2si -0x58(%rbp),%rsi
cvttsd2si -0x60(%rbp),%rdx
movsd  -0x68(%rbp),%xmm0
movsd  -0x70(%rbp),%xmm1
lea    0xe34(%rip),%rdi
mov    $0x2,%al
call   1030 <printf@plt>
cvttsd2si 0x10(%rbp),%rsi
cvttsd2si 0x18(%rbp),%rdx
lea    0xe22(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    0x20(%rbp),%rsi
mov    0x28(%rbp),%rdx
lea    0xdfb(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movsd  0xde0(%rip),%xmm0
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_testd>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x48,%rsp
movsd  %xmm7,0x40(%rsp)
movsd  %xmm6,0x38(%rsp)
movsd  %xmm5,0x30(%rsp)
movsd  %xmm4,0x28(%rsp)
movsd  %xmm3,0x20(%rsp)
movsd  %xmm2,0x18(%rsp)
movsd  %xmm1,0x10(%rsp)
movsd  %xmm0,0x8(%rsp)
mov    %r9,%r12
mov    %r8,%r13
mov    %rcx,%rbx
mov    %rdx,%rcx
mov    %rsi,%rdx
mov    %rdi,%rsi
mov    0x90(%rsp),%r15
mov    0x98(%rsp),%r14
lea    0xe91(%rip),%rbp
mov    %rbp,%rdi
xor    %eax,%eax
call   1030 <printf@plt>
mov    %rbp,%rdi
mov    %rbx,%rsi
mov    %r13,%rdx
mov    %r12,%rcx
xor    %eax,%eax
call   1030 <printf@plt>
cvttsd2si 0x8(%rsp),%rsi
cvttsd2si 0x10(%rsp),%rdx
lea    0xe6c(%rip),%rbx
mov    %rbx,%rdi
movsd  0x18(%rsp),%xmm0
movsd  0x20(%rsp),%xmm1
mov    $0x2,%al
call   1030 <printf@plt>
cvttsd2si 0x28(%rsp),%rsi
cvttsd2si 0x30(%rsp),%rdx
mov    %rbx,%rdi
movsd  0x38(%rsp),%xmm0
movsd  0x40(%rsp),%xmm1
mov    $0x2,%al
call   1030 <printf@plt>
cvttsd2si 0x80(%rsp),%rsi
cvttsd2si 0x88(%rsp),%rdx
lea    0xe1f(%rip),%rdi
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xe00(%rip),%rdi
mov    %r15,%rsi
mov    %r14,%rdx
xor    %eax,%eax
call   1030 <printf@plt>
movsd  0xddf(%rip),%xmm0
add    $0x48,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [13 x i8] c"%ld %ld %ld\0A\00"
@.str.1 = [17 x i8] c"%lf %lf %lf %lf\0A\00"
@.str.2 = [9 x i8] c"%lf %lf\0A\00"
@.str.3 = [9 x i8] c"%ld %ld\0A\00"
define double @test_testd(i64 %0, i64 %1, i64 %2, i64 %3, i64 %4, i64 %5, double %6, double %7, double %8, double %9, double %10, double %11, double %12, double %13, double %14, double %15, i64 %16, i64 %17) {
%19 = alloca i64
%20 = alloca i64
%21 = alloca i64
%22 = alloca i64
%23 = alloca i64
%24 = alloca i64
%25 = alloca double
%26 = alloca double
%27 = alloca double
%28 = alloca double
%29 = alloca double
%30 = alloca double
%31 = alloca double
%32 = alloca double
%33 = alloca double
%34 = alloca double
%35 = alloca i64
%36 = alloca i64
store i64 %0, i64* %19
store i64 %1, i64* %20
store i64 %2, i64* %21
store i64 %3, i64* %22
store i64 %4, i64* %23
store i64 %5, i64* %24
store double %6, double* %25
store double %7, double* %26
store double %8, double* %27
store double %9, double* %28
store double %10, double* %29
store double %11, double* %30
store double %12, double* %31
store double %13, double* %32
store double %14, double* %33
store double %15, double* %34
store i64 %16, i64* %35
store i64 %17, i64* %36
%37 = load i64, i64* %19
%38 = load i64, i64* %20
%39 = load i64, i64* %21
%40 = call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i64 %37, i64 %38, i64 %39)
%41 = load i64, i64* %22
%42 = load i64, i64* %23
%43 = load i64, i64* %24
%44 = call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i64 %41, i64 %42, i64 %43)
%45 = load double, double* %25
%46 = fptosi double %45 to i64
%47 = load double, double* %26
%48 = fptosi double %47 to i64
%49 = load double, double* %27
%50 = load double, double* %28
%51 = call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i64 %46, i64 %48, double %49, double %50)
%52 = load double, double* %29
%53 = fptosi double %52 to i64
%54 = load double, double* %30
%55 = fptosi double %54 to i64
%56 = load double, double* %31
%57 = load double, double* %32
%58 = call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i64 %53, i64 %55, double %56, double %57)
%59 = load double, double* %33
%60 = fptosi double %59 to i64
%61 = load double, double* %34
%62 = fptosi double %61 to i64
%63 = call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.2, i64 0, i64 0), i64 %60, i64 %62)
%64 = load i64, i64* %35
%65 = load i64, i64* %36
%66 = call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.3, i64 0, i64 0), i64 %64, i64 %65)
ret double 1.234560e+00
}

LLVM IR (-O2):
@.str = [13 x i8] c"%ld %ld %ld\0A\00"
@.str.1 = [17 x i8] c"%lf %lf %lf %lf\0A\00"
@.str.2 = [9 x i8] c"%lf %lf\0A\00"
@.str.3 = [9 x i8] c"%ld %ld\0A\00"
define double @test_testd(i64 %0, i64 %1, i64 %2, i64 %3, i64 %4, i64 %5, double %6, double %7, double %8, double %9, double %10, double %11, double %12, double %13, double %14, double %15, i64 %16, i64 %17) {
%19 = tail call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i64 %0, i64 %1, i64 %2)
%20 = tail call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i64 %3, i64 %4, i64 %5)
%21 = fptosi double %6 to i64
%22 = fptosi double %7 to i64
%23 = tail call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i64 %21, i64 %22, double %8, double %9)
%24 = fptosi double %10 to i64
%25 = fptosi double %11 to i64
%26 = tail call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0), i64 %24, i64 %25, double %12, double %13)
%27 = fptosi double %14 to i64
%28 = fptosi double %15 to i64
%29 = tail call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.2, i64 0, i64 0), i64 %27, i64 %28)
%30 = tail call i32 (i8*, i64, i64, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.3, i64 0, i64 0), i64 %16, i64 %17)
ret double 1.234560e+00
}