#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*/ gpioGet(int);
int /*<<< orphan*/ output(int, char *, ...);
void dumpAll() {
  int i;
  int gpio[] = {53, 71, 79, 81, 84, 114, 124};
  output(1, "GPIOS: ");
  for (i = 0; i < 7; i++) {
    output(0, "%i=%i ", gpio[i], gpioGet(gpio[i]));
  }
  output(0, "\n");
}


x86 assembly (clang, -O0):
<dumpAll>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    0xed1(%rip),%rax
mov    %rax,-0x20(%rbp)
mov    0xece(%rip),%rax
mov    %rax,-0x18(%rbp)
mov    0xecb(%rip),%rax
mov    %rax,-0x10(%rbp)
mov    0xec9(%rip),%eax
mov    %eax,-0x8(%rbp)
mov    $0x1,%edi
lea    0xebe(%rip),%rsi
mov    $0x0,%al
call   1030 <output@plt>
movl   $0x0,-0x4(%rbp)
cmpl   $0x7,-0x4(%rbp)
jge    11b1 <dumpAll+0x91>
movslq -0x4(%rbp),%rax
mov    -0x20(%rbp,%rax,4),%eax
mov    %eax,-0x24(%rbp)
movslq -0x4(%rbp),%rax
mov    -0x20(%rbp,%rax,4),%edi
call   1040 <gpioGet@plt>
mov    -0x24(%rbp),%edx
mov    %eax,%ecx
xor    %edi,%edi
lea    0xe88(%rip),%rsi
mov    $0x0,%al
call   1030 <output@plt>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    116c <dumpAll+0x4c>
xor    %edi,%edi
lea    0xe71(%rip),%rsi
mov    $0x0,%al
call   1030 <output@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dumpAll>:
push   %rbx
lea    0xed8(%rip),%rsi
mov    $0x1,%edi
xor    %eax,%eax
call   1030 <output@plt>
mov    $0x35,%edi
call   1040 <gpioGet@plt>
lea    0xec3(%rip),%rbx
xor    %edi,%edi
mov    %rbx,%rsi
mov    $0x35,%edx
mov    %eax,%ecx
xor    %eax,%eax
call   1030 <output@plt>
mov    $0x47,%edi
call   1040 <gpioGet@plt>
xor    %edi,%edi
mov    %rbx,%rsi
mov    $0x47,%edx
mov    %eax,%ecx
xor    %eax,%eax
call   1030 <output@plt>
mov    $0x4f,%edi
call   1040 <gpioGet@plt>
xor    %edi,%edi
mov    %rbx,%rsi
mov    $0x4f,%edx
mov    %eax,%ecx
xor    %eax,%eax
call   1030 <output@plt>
mov    $0x51,%edi
call   1040 <gpioGet@plt>
xor    %edi,%edi
mov    %rbx,%rsi
mov    $0x51,%edx
mov    %eax,%ecx
xor    %eax,%eax
call   1030 <output@plt>
mov    $0x54,%edi
call   1040 <gpioGet@plt>
xor    %edi,%edi
mov    %rbx,%rsi
mov    $0x54,%edx
mov    %eax,%ecx
xor    %eax,%eax
call   1030 <output@plt>
mov    $0x72,%edi
call   1040 <gpioGet@plt>
xor    %edi,%edi
mov    %rbx,%rsi
mov    $0x72,%edx
mov    %eax,%ecx
xor    %eax,%eax
call   1030 <output@plt>
mov    $0x7c,%edi
call   1040 <gpioGet@plt>
xor    %edi,%edi
mov    %rbx,%rsi
mov    $0x7c,%edx
mov    %eax,%ecx
xor    %eax,%eax
call   1030 <output@plt>
lea    0xe02(%rip),%rsi
xor    %edi,%edi
xor    %eax,%eax
pop    %rbx
jmp    1030 <output@plt>

LLVM IR (-O0):
@__const.dumpAll.gpio = [7 x i32] [i32 53, i32 71, i32 79, i32 81, i32 84, i32 114, i32 124]
@.str = [8 x i8] c"GPIOS: \00"
@.str.1 = [7 x i8] c"%i=%i \00"
@.str.2 = [2 x i8] c"\0A\00"
define void @dumpAll() {
%1 = alloca i32
%2 = alloca [7 x i32]
%3 = bitcast [7 x i32]* %2 to i8*
%4 = call i32 (i32, i8*, ...) @output(i32 1, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0))
store i32 0, i32* %1
br label %5
5: ; preds = %19, %0
%6 = load i32, i32* %1
%7 = icmp slt i32 %6, 7
br i1 %7, label %8, label %22
8: ; preds = %5
%9 = load i32, i32* %1
%10 = sext i32 %9 to i64
%11 = getelementptr inbounds [7 x i32], [7 x i32]* %2, i64 0, i64 %10
%12 = load i32, i32* %11
%13 = load i32, i32* %1
%14 = sext i32 %13 to i64
%15 = getelementptr inbounds [7 x i32], [7 x i32]* %2, i64 0, i64 %14
%16 = load i32, i32* %15
%17 = call i32 @gpioGet(i32 %16)
%18 = call i32 (i32, i8*, ...) @output(i32 0, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 %12, i32 %17)
br label %19
19: ; preds = %8
%20 = load i32, i32* %1
%21 = add nsw i32 %20, 1
store i32 %21, i32* %1
br label %5
22: ; preds = %5
%23 = call i32 (i32, i8*, ...) @output(i32 0, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [8 x i8] c"GPIOS: \00"
@.str.1 = [7 x i8] c"%i=%i \00"
@.str.2 = [2 x i8] c"\0A\00"
define void @dumpAll() {
%1 = tail call i32 (i32, i8*, ...) @output(i32 1, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @gpioGet(i32 53)
%3 = tail call i32 (i32, i8*, ...) @output(i32 0, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 53, i32 %2)
%4 = tail call i32 @gpioGet(i32 71)
%5 = tail call i32 (i32, i8*, ...) @output(i32 0, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 71, i32 %4)
%6 = tail call i32 @gpioGet(i32 79)
%7 = tail call i32 (i32, i8*, ...) @output(i32 0, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 79, i32 %6)
%8 = tail call i32 @gpioGet(i32 81)
%9 = tail call i32 (i32, i8*, ...) @output(i32 0, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 81, i32 %8)
%10 = tail call i32 @gpioGet(i32 84)
%11 = tail call i32 (i32, i8*, ...) @output(i32 0, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 84, i32 %10)
%12 = tail call i32 @gpioGet(i32 114)
%13 = tail call i32 (i32, i8*, ...) @output(i32 0, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 114, i32 %12)
%14 = tail call i32 @gpioGet(i32 124)
%15 = tail call i32 (i32, i8*, ...) @output(i32 0, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i64 0, i64 0), i32 124, i32 %14)
%16 = tail call i32 (i32, i8*, ...) @output(i32 0, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
ret void
}