#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*/ assert(int);
void foo(int a, int b, int c, int d, int e, int f, int g) {
  assert(a == 1);
  assert(b == 1);
  assert(c == 1);
  assert(d == 1);
  assert(e == 1);
  assert(f == 1);
  assert(g == 1);
}


x86 assembly (clang, -O0):
<foo>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
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)
cmpl   $0x1,-0x4(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
cmpl   $0x1,-0x8(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
cmpl   $0x1,-0xc(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
cmpl   $0x1,-0x10(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
cmpl   $0x1,-0x14(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
cmpl   $0x1,-0x18(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
cmpl   $0x1,0x10(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<foo>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %r9d,%r14d
mov    %r8d,%r15d
mov    %ecx,%r12d
mov    %edx,%ebp
mov    %esi,%ebx
mov    0x40(%rsp),%r13d
xor    %eax,%eax
cmp    $0x1,%edi
sete   %al
mov    %eax,%edi
call   1030 <assert@plt>
xor    %edi,%edi
cmp    $0x1,%ebx
sete   %dil
call   1030 <assert@plt>
xor    %edi,%edi
cmp    $0x1,%ebp
sete   %dil
call   1030 <assert@plt>
xor    %edi,%edi
cmp    $0x1,%r12d
sete   %dil
call   1030 <assert@plt>
xor    %edi,%edi
cmp    $0x1,%r15d
sete   %dil
call   1030 <assert@plt>
xor    %edi,%edi
cmp    $0x1,%r14d
sete   %dil
call   1030 <assert@plt>
xor    %edi,%edi
cmp    $0x1,%r13d
sete   %dil
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <assert@plt>

LLVM IR (-O0):
define void @foo(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6) {
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
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 i32 %5, i32* %13
store i32 %6, i32* %14
%15 = load i32, i32* %8
%16 = icmp eq i32 %15, 1
%17 = zext i1 %16 to i32
%18 = call i32 @assert(i32 %17)
%19 = load i32, i32* %9
%20 = icmp eq i32 %19, 1
%21 = zext i1 %20 to i32
%22 = call i32 @assert(i32 %21)
%23 = load i32, i32* %10
%24 = icmp eq i32 %23, 1
%25 = zext i1 %24 to i32
%26 = call i32 @assert(i32 %25)
%27 = load i32, i32* %11
%28 = icmp eq i32 %27, 1
%29 = zext i1 %28 to i32
%30 = call i32 @assert(i32 %29)
%31 = load i32, i32* %12
%32 = icmp eq i32 %31, 1
%33 = zext i1 %32 to i32
%34 = call i32 @assert(i32 %33)
%35 = load i32, i32* %13
%36 = icmp eq i32 %35, 1
%37 = zext i1 %36 to i32
%38 = call i32 @assert(i32 %37)
%39 = load i32, i32* %14
%40 = icmp eq i32 %39, 1
%41 = zext i1 %40 to i32
%42 = call i32 @assert(i32 %41)
ret void
}

LLVM IR (-O2):
define void @foo(i32 %0, i32 %1, i32 %2, i32 %3, i32 %4, i32 %5, i32 %6) {
%8 = icmp eq i32 %0, 1
%9 = zext i1 %8 to i32
%10 = tail call i32 @assert(i32 %9)
%11 = icmp eq i32 %1, 1
%12 = zext i1 %11 to i32
%13 = tail call i32 @assert(i32 %12)
%14 = icmp eq i32 %2, 1
%15 = zext i1 %14 to i32
%16 = tail call i32 @assert(i32 %15)
%17 = icmp eq i32 %3, 1
%18 = zext i1 %17 to i32
%19 = tail call i32 @assert(i32 %18)
%20 = icmp eq i32 %4, 1
%21 = zext i1 %20 to i32
%22 = tail call i32 @assert(i32 %21)
%23 = icmp eq i32 %5, 1
%24 = zext i1 %23 to i32
%25 = tail call i32 @assert(i32 %24)
%26 = icmp eq i32 %6, 1
%27 = zext i1 %26 to i32
%28 = tail call i32 @assert(i32 %27)
ret void
}