#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 *);
void print_help() {
  printf("\nUsage: eeinfo [function] [option ...]\n");
  printf("\nFunctions:\n");
  printf(" -h\tshow this help text and exit\n");
  printf(" -r\tread data from EEPROM\n");
  printf(" -w\twrite data to EEPROM\n");
  printf("\nOptions:\n");
  printf(" -n<name>\tproduct name (max 8 characters)\n");
  printf(" -v<revision>\trevision (4 characters e.g. R1A1)\n");
  printf(" -s<serial>\tserial number (32bit value)\n");
  printf(" -p<pdate>\tproduction date (yyyymmdd)\n");
  printf(" -a<apikey>\tapi key (max 64 characters)\n\n");
}


x86 assembly (clang, -O0):
<print_help>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
call   1030 <printf@plt>
lea    0xf01(%rip),%rdi
call   1030 <printf@plt>
lea    0xf02(%rip),%rdi
call   1030 <printf@plt>
lea    0xf18(%rip),%rdi
call   1030 <printf@plt>
lea    0xf27(%rip),%rdi
call   1030 <printf@plt>
lea    0xf35(%rip),%rdi
call   1030 <printf@plt>
lea    0xf34(%rip),%rdi
call   1030 <printf@plt>
lea    0xf53(%rip),%rdi
call   1030 <printf@plt>
lea    0xf78(%rip),%rdi
call   1030 <printf@plt>
lea    0xf95(%rip),%rdi
call   1030 <printf@plt>
lea    0xfb0(%rip),%rdi
call   1030 <printf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_help>:
push   %rax
lea    0xee8(%rip),%rdi
call   1030 <puts@plt>
lea    0xf03(%rip),%rdi
call   1030 <puts@plt>
lea    0xf03(%rip),%rdi
call   1030 <puts@plt>
lea    0xf18(%rip),%rdi
call   1030 <puts@plt>
lea    0xf26(%rip),%rdi
call   1030 <puts@plt>
lea    0xf33(%rip),%rdi
call   1030 <puts@plt>
lea    0xf31(%rip),%rdi
call   1030 <puts@plt>
lea    0xf4f(%rip),%rdi
call   1030 <puts@plt>
lea    0xf73(%rip),%rdi
call   1030 <puts@plt>
lea    0xf8f(%rip),%rdi
call   1030 <puts@plt>
lea    0xfa9(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [40 x i8] c"\0AUsage: eeinfo [function] [option ...]\0A\00"
@.str.1 = [13 x i8] c"\0AFunctions:\0A\00"
@.str.2 = [34 x i8] c" -h\09show this help text and exit\0A\00"
@.str.3 = [27 x i8] c" -r\09read data from EEPROM\0A\00"
@.str.4 = [26 x i8] c" -w\09write data to EEPROM\0A\00"
@.str.5 = [11 x i8] c"\0AOptions:\0A\00"
@.str.6 = [43 x i8] c" -n<name>\09product name (max 8 characters)\0A\00"
@.str.7 = [49 x i8] c" -v<revision>\09revision (4 characters e.g. R1A1)\0A\00"
@.str.8 = [41 x i8] c" -s<serial>\09serial number (32bit value)\0A\00"
@.str.9 = [39 x i8] c" -p<pdate>\09production date (yyyymmdd)\0A\00"
@.str.10 = [42 x i8] c" -a<apikey>\09api key (max 64 characters)\0A\0A\00"
define void @print_help() {
%1 = call i32 @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.2, i64 0, i64 0))
%4 = call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.3, i64 0, i64 0))
%5 = call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.4, i64 0, i64 0))
%6 = call i32 @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.5, i64 0, i64 0))
%7 = call i32 @printf(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.6, i64 0, i64 0))
%8 = call i32 @printf(i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str.7, i64 0, i64 0))
%9 = call i32 @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.8, i64 0, i64 0))
%10 = call i32 @printf(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.9, i64 0, i64 0))
%11 = call i32 @printf(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.10, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [39 x i8] c"\0AUsage: eeinfo [function] [option ...]\00"
@str.11 = [12 x i8] c"\0AFunctions:\00"
@str.12 = [33 x i8] c" -h\09show this help text and exit\00"
@str.13 = [26 x i8] c" -r\09read data from EEPROM\00"
@str.14 = [25 x i8] c" -w\09write data to EEPROM\00"
@str.15 = [10 x i8] c"\0AOptions:\00"
@str.16 = [42 x i8] c" -n<name>\09product name (max 8 characters)\00"
@str.17 = [48 x i8] c" -v<revision>\09revision (4 characters e.g. R1A1)\00"
@str.18 = [40 x i8] c" -s<serial>\09serial number (32bit value)\00"
@str.19 = [38 x i8] c" -p<pdate>\09production date (yyyymmdd)\00"
@str.20 = [41 x i8] c" -a<apikey>\09api key (max 64 characters)\0A\00"
define void @print_help() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.11, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @str.12, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([26 x i8], [26 x i8]* @str.13, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([25 x i8], [25 x i8]* @str.14, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str.15, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([42 x i8], [42 x i8]* @str.16, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([48 x i8], [48 x i8]* @str.17, i64 0, i64 0))
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([40 x i8], [40 x i8]* @str.18, i64 0, i64 0))
%10 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([38 x i8], [38 x i8]* @str.19, i64 0, i64 0))
%11 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @str.20, i64 0, i64 0))
ret void
}