#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*/ print_format0(char *, int /*<<< orphan*/);
int /*<<< orphan*/ print_format1(char *, int /*<<< orphan*/, char *);
void printf5(char *s, char *a1, char *a2, char *a3, char *a4, char *a5) {
  print_format0(
      s, print_format1(
             s,
             print_format1(
                 s,
                 print_format1(s, print_format1(s, print_format1(s, 0, a1), a2),
                               a3),
                 a4),
             a5));
}


x86 assembly (clang, -O0):
<printf5>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
mov    %r8,-0x28(%rbp)
mov    %r9,-0x30(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x38(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x40(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x48(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x50(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x58(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rdx
xor    %esi,%esi
call   1030 <print_format1@plt>
mov    -0x58(%rbp),%rdi
mov    %eax,%esi
mov    -0x18(%rbp),%rdx
call   1030 <print_format1@plt>
mov    -0x50(%rbp),%rdi
mov    %eax,%esi
mov    -0x20(%rbp),%rdx
call   1030 <print_format1@plt>
mov    -0x48(%rbp),%rdi
mov    %eax,%esi
mov    -0x28(%rbp),%rdx
call   1030 <print_format1@plt>
mov    -0x40(%rbp),%rdi
mov    %eax,%esi
mov    -0x30(%rbp),%rdx
call   1030 <print_format1@plt>
mov    -0x38(%rbp),%rdi
mov    %eax,%esi
call   1040 <print_format0@plt>
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<printf5>:
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
mov    %r9,%r14
mov    %r8,%r15
mov    %rcx,%r12
mov    %rdx,%r13
mov    %rsi,%rdx
mov    %rdi,%rbx
xor    %esi,%esi
call   1030 <print_format1@plt>
mov    %rbx,%rdi
mov    %eax,%esi
mov    %r13,%rdx
call   1030 <print_format1@plt>
mov    %rbx,%rdi
mov    %eax,%esi
mov    %r12,%rdx
call   1030 <print_format1@plt>
mov    %rbx,%rdi
mov    %eax,%esi
mov    %r15,%rdx
call   1030 <print_format1@plt>
mov    %rbx,%rdi
mov    %eax,%esi
mov    %r14,%rdx
call   1030 <print_format1@plt>
mov    %rbx,%rdi
mov    %eax,%esi
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
jmp    1040 <print_format0@plt>

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

LLVM IR (-O2):
define void @printf5(i8* %0, i8* %1, i8* %2, i8* %3, i8* %4, i8* %5) {
%7 = tail call i32 @print_format1(i8* %0, i32 0, i8* %1)
%8 = tail call i32 @print_format1(i8* %0, i32 %7, i8* %2)
%9 = tail call i32 @print_format1(i8* %0, i32 %8, i8* %3)
%10 = tail call i32 @print_format1(i8* %0, i32 %9, i8* %4)
%11 = tail call i32 @print_format1(i8* %0, i32 %10, i8* %5)
%12 = tail call i32 @print_format0(i8* %0, i32 %11)
ret void
}