#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 *, int, ...);
extern int Bar10(int one, int two, int three, int four, int five, int six,
                 int seven, int eight, int nine, int zero) {
  int sum = 0;
  printf(" Hello from Bar10: one = %d, two = %d\n ", one, two);
  printf(" three = %d, four = %d, five = %d, six = %d\n ", three, four, five,
         six);
  printf(" seven = %d, eight = %d, nine = %d, zero = %d\n ", seven, eight, nine,
         zero);
  sum = one + two + three + four + five + six + seven + eight + nine + zero;
  printf(" sum = %d\n", sum);
  return sum;
}


x86 assembly (clang, -O0):
<Bar10>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    0x28(%rbp),%eax
mov    0x20(%rbp),%eax
mov    0x18(%rbp),%eax
mov    0x10(%rbp),%eax
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %edx,-0xc(%rbp)
mov    %ecx,-0x10(%rbp)
mov    %r8d,-0x14(%rbp)
mov    %r9d,-0x18(%rbp)
movl   $0x0,-0x1c(%rbp)
mov    -0x4(%rbp),%esi
mov    -0x8(%rbp),%edx
lea    0xeb4(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0xc(%rbp),%esi
mov    -0x10(%rbp),%edx
mov    -0x14(%rbp),%ecx
mov    -0x18(%rbp),%r8d
lea    0xec1(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    0x10(%rbp),%esi
mov    0x18(%rbp),%edx
mov    0x20(%rbp),%ecx
mov    0x28(%rbp),%r8d
lea    0xed4(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x4(%rbp),%eax
add    -0x8(%rbp),%eax
add    -0xc(%rbp),%eax
add    -0x10(%rbp),%eax
add    -0x14(%rbp),%eax
add    -0x18(%rbp),%eax
add    0x10(%rbp),%eax
add    0x18(%rbp),%eax
add    0x20(%rbp),%eax
add    0x28(%rbp),%eax
mov    %eax,-0x1c(%rbp)
mov    -0x1c(%rbp),%esi
lea    0xed2(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x1c(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Bar10>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %r9d,%r12d
mov    %r8d,%ebp
mov    %ecx,%r15d
mov    %edx,%r13d
mov    %esi,%ebx
mov    %edi,%r14d
lea    0xecd(%rip),%rdi
mov    %r14d,%esi
mov    %ebx,%edx
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xee2(%rip),%rdi
mov    %r13d,%esi
mov    %r15d,%edx
mov    %ebp,%ecx
mov    %r12d,%r8d
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xef7(%rip),%rdi
mov    0x40(%rsp),%esi
mov    0x48(%rsp),%edx
mov    0x50(%rsp),%ecx
mov    0x58(%rsp),%r8d
xor    %eax,%eax
call   1030 <printf@plt>
add    %r14d,%ebx
add    %r13d,%ebx
add    %r15d,%ebx
add    %ebp,%ebx
add    %r12d,%ebx
add    0x40(%rsp),%ebx
add    0x48(%rsp),%ebx
add    0x50(%rsp),%ebx
add    0x58(%rsp),%ebx
lea    0xeea(%rip),%rdi
mov    %ebx,%esi
xor    %eax,%eax
call   1030 <printf@plt>
mov    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [40 x i8] c" Hello from Bar10: one = %d, two = %d\0A \00"
@.str.1 = [46 x i8] c" three = %d, four = %d, five = %d, six = %d\0A \00"
@.str.2 = [48 x i8] c" seven = %d, eight = %d, nine = %d, zero = %d\0A \00"
@.str.3 = [11 x i8] c" sum = %d\0A\00"
define i32 @Bar10(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, i32 %8, i32 %9) {
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
%17 = alloca i32
%18 = alloca i32
%19 = alloca i32
%20 = alloca i32
%21 = alloca i32
store i32 %0, i32* %11
store i32 %1, i32* %12
store i32 %2, i32* %13
store i32 %3, i32* %14
store i32 %4, i32* %15
store i32 %5, i32* %16
store i32 %6, i32* %17
store i32 %7, i32* %18
store i32 %8, i32* %19
store i32 %9, i32* %20
store i32 0, i32* %21
%22 = load i32, i32* %11
%23 = load i32, i32* %12
%24 = call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0), i32 %22, i32 %23)
%25 = load i32, i32* %13
%26 = load i32, i32* %14
%27 = load i32, i32* %15
%28 = load i32, i32* %16
%29 = call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.1, i64 0, i64 0), i32 %25, i32 %26, i32 %27, i32 %28)
%30 = load i32, i32* %17
%31 = load i32, i32* %18
%32 = load i32, i32* %19
%33 = load i32, i32* %20
%34 = call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.2, i64 0, i64 0), i32 %30, i32 %31, i32 %32, i32 %33)
%35 = load i32, i32* %11
%36 = load i32, i32* %12
%37 = add nsw i32 %35, %36
%38 = load i32, i32* %13
%39 = add nsw i32 %37, %38
%40 = load i32, i32* %14
%41 = add nsw i32 %39, %40
%42 = load i32, i32* %15
%43 = add nsw i32 %41, %42
%44 = load i32, i32* %16
%45 = add nsw i32 %43, %44
%46 = load i32, i32* %17
%47 = add nsw i32 %45, %46
%48 = load i32, i32* %18
%49 = add nsw i32 %47, %48
%50 = load i32, i32* %19
%51 = add nsw i32 %49, %50
%52 = load i32, i32* %20
%53 = add nsw i32 %51, %52
store i32 %53, i32* %21
%54 = load i32, i32* %21
%55 = call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0), i32 %54)
%56 = load i32, i32* %21
ret i32 %56
}

LLVM IR (-O2):
@.str = [40 x i8] c" Hello from Bar10: one = %d, two = %d\0A \00"
@.str.1 = [46 x i8] c" three = %d, four = %d, five = %d, six = %d\0A \00"
@.str.2 = [48 x i8] c" seven = %d, eight = %d, nine = %d, zero = %d\0A \00"
@.str.3 = [11 x i8] c" sum = %d\0A\00"
define i32 @Bar10(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6, i32 %7, i32 %8, i32 %9) {
%11 = tail call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0), i32 %0, i32 %1)
%12 = tail call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.1, i64 0, i64 0), i32 %2, i32 %3, i32 %4, i32 %5)
%13 = tail call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.2, i64 0, i64 0), i32 %6, i32 %7, i32 %8, i32 %9)
%14 = add nsw i32 %1, %0
%15 = add nsw i32 %14, %2
%16 = add nsw i32 %15, %3
%17 = add nsw i32 %16, %4
%18 = add nsw i32 %17, %5
%19 = add nsw i32 %18, %6
%20 = add nsw i32 %19, %7
%21 = add nsw i32 %20, %8
%22 = add nsw i32 %21, %9
%23 = tail call i32 (i8*, i32, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0), i32 %22)
ret i32 %22
}