#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 help(void) {
  printf("gpiomon v0.1 By: smd75jr (smd75jr@gmail.com)\n\n\n");
  printf("gpiomon [options]\n\n");
  printf("-h print usage information\n\n");
  printf("-p PINNUM\n");
  printf("\tSpecify GPIO pin number\n");
  printf("\tValid pin numbers are:\n");
  printf(
      "\t0, 1, 2, 7, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26\n\n");
  printf("-v\n");
  printf("\tGet current state of pin specified with -p\n\n");
  printf("-w VAL\n");
  printf("\tWrite new value VAL to GPIO pin specified with -p\n");
  printf("\tValue given MUST be binary (0 or 1) value\n");
}


x86 assembly (clang, -O0):
<help>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    0xee1(%rip),%rdi
call   1030 <printf@plt>
lea    0xf05(%rip),%rdi
call   1030 <printf@plt>
lea    0xf0d(%rip),%rdi
call   1030 <printf@plt>
lea    0xf1e(%rip),%rdi
call   1030 <printf@plt>
lea    0xf1d(%rip),%rdi
call   1030 <printf@plt>
lea    0xf2b(%rip),%rdi
call   1030 <printf@plt>
lea    0xf38(%rip),%rdi
call   1030 <printf@plt>
lea    0xf6e(%rip),%rdi
call   1030 <printf@plt>
lea    0xf66(%rip),%rdi
call   1030 <printf@plt>
lea    0xf88(%rip),%rdi
call   1030 <printf@plt>
lea    0xf84(%rip),%rdi
call   1030 <printf@plt>
lea    0xfac(%rip),%rdi
call   1030 <printf@plt>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<help>:
push   %rax
lea    0xee8(%rip),%rdi
call   1030 <puts@plt>
lea    0xf0b(%rip),%rdi
call   1030 <puts@plt>
lea    0xf12(%rip),%rdi
call   1030 <puts@plt>
lea    0xf22(%rip),%rdi
call   1030 <puts@plt>
lea    0xf20(%rip),%rdi
call   1030 <puts@plt>
lea    0xf2d(%rip),%rdi
call   1030 <puts@plt>
lea    0xf39(%rip),%rdi
call   1030 <puts@plt>
lea    0xf6e(%rip),%rdi
call   1030 <puts@plt>
lea    0xf65(%rip),%rdi
call   1030 <puts@plt>
lea    0xf86(%rip),%rdi
call   1030 <puts@plt>
lea    0xf81(%rip),%rdi
call   1030 <puts@plt>
lea    0xfa8(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [48 x i8] c"gpiomon v0.1 By: smd75jr (smd75jr@gmail.com)\0A\0A\0A\00"
@.str.1 = [20 x i8] c"gpiomon [options]\0A\0A\00"
@.str.2 = [29 x i8] c"-h print usage information\0A\0A\00"
@.str.3 = [11 x i8] c"-p PINNUM\0A\00"
@.str.4 = [26 x i8] c"\09Specify GPIO pin number\0A\00"
@.str.5 = [25 x i8] c"\09Valid pin numbers are:\0A\00"
@.str.6 = [66 x i8] c"\090, 1, 2, 7, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26\0A\0A\00"
@.str.7 = [4 x i8] c"-v\0A\00"
@.str.8 = [46 x i8] c"\09Get current state of pin specified with -p\0A\0A\00"
@.str.9 = [8 x i8] c"-w VAL\0A\00"
@.str.10 = [52 x i8] c"\09Write new value VAL to GPIO pin specified with -p\0A\00"
@.str.11 = [44 x i8] c"\09Value given MUST be binary (0 or 1) value\0A\00"
define i32 @help() {
%1 = alloca i32
%2 = call i32 @printf(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str, i64 0, i64 0))
%3 = call i32 @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.1, i64 0, i64 0))
%4 = call i32 @printf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.2, i64 0, i64 0))
%5 = call i32 @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0))
%6 = call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.4, i64 0, i64 0))
%7 = call i32 @printf(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.5, i64 0, i64 0))
%8 = call i32 @printf(i8* getelementptr inbounds ([66 x i8], [66 x i8]* @.str.6, i64 0, i64 0))
%9 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.7, i64 0, i64 0))
%10 = call i32 @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.8, i64 0, i64 0))
%11 = call i32 @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.9, i64 0, i64 0))
%12 = call i32 @printf(i8* getelementptr inbounds ([52 x i8], [52 x i8]* @.str.10, i64 0, i64 0))
%13 = call i32 @printf(i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.11, i64 0, i64 0))
%14 = load i32, i32* %1
ret i32 %14
}

LLVM IR (-O2):
@str = [47 x i8] c"gpiomon v0.1 By: smd75jr (smd75jr@gmail.com)\0A\0A\00"
@str.12 = [19 x i8] c"gpiomon [options]\0A\00"
@str.13 = [28 x i8] c"-h print usage information\0A\00"
@str.14 = [10 x i8] c"-p PINNUM\00"
@str.15 = [25 x i8] c"\09Specify GPIO pin number\00"
@str.16 = [24 x i8] c"\09Valid pin numbers are:\00"
@str.17 = [65 x i8] c"\090, 1, 2, 7, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23, 24, 25, 26\0A\00"
@str.18 = [3 x i8] c"-v\00"
@str.19 = [45 x i8] c"\09Get current state of pin specified with -p\0A\00"
@str.20 = [7 x i8] c"-w VAL\00"
@str.21 = [51 x i8] c"\09Write new value VAL to GPIO pin specified with -p\00"
@str.22 = [43 x i8] c"\09Value given MUST be binary (0 or 1) value\00"
define i32 @help() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([47 x i8], [47 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([19 x i8], [19 x i8]* @str.12, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([28 x i8], [28 x i8]* @str.13, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str.14, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([25 x i8], [25 x i8]* @str.15, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([24 x i8], [24 x i8]* @str.16, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([65 x i8], [65 x i8]* @str.17, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @str.18, i64 0, i64 0))
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([45 x i8], [45 x i8]* @str.19, i64 0, i64 0))
%10 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @str.20, i64 0, i64 0))
%11 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([51 x i8], [51 x i8]* @str.21, i64 0, i64 0))
%12 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([43 x i8], [43 x i8]* @str.22, i64 0, i64 0))
ret i32 undef
}