#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*/ printHeader();
int /*<<< orphan*/ printf(char *);
void printUsage() {
  printHeader();
  printf("usage:\n");
  printf("--address=<0xaddr>    , -a <0xaddr>    =   Sets SMBus address for "
         "operation\n");
  printf("--command=<0xcommand> , -c <0xcommand> =   Sets SMBus command for "
         "operation\n");
  printf("--write=<0xdata>      , -w <0xdata>    =   Write operation\n");
  printf("--block-write         , -b             =   Force block-write "
         "regardless of data length\n");
  printf("--read=<# of bytes>   , -r <#>         =   Read operation (# of "
         "bytes determines read mode)\n");
  printf("--null-write          , -n             =   Start->addr->cmd->Stop\n");
  printf("--verbose             , -v             =   Print status messages\n");
  printf("--no-pec                               =   Disable SMBus Packet "
         "Error Checking\n");
  printf("examples:\n");
  printf("smbusb_comm -a 0x16 -c 0 -r 2 -s       =   Word Read Command 0 "
         "(Manufacturer Access in SBS)\n");
  printf("smbusb_comm -a 0x16 -c F -w 41ef010102 =   Block Write Command 0xF "
         "(0x is always optional)\n");
}


x86 assembly (clang, -O0):
<printUsage>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1040 <printHeader@plt>
lea    0xece(%rip),%rdi
call   1030 <printf@plt>
lea    0xeca(%rip),%rdi
call   1030 <printf@plt>
lea    0xf0b(%rip),%rdi
call   1030 <printf@plt>
lea    0xf4c(%rip),%rdi
call   1030 <printf@plt>
lea    0xf7c(%rip),%rdi
call   1030 <printf@plt>
lea    0xfc8(%rip),%rdi
call   1030 <printf@plt>
lea    0x1019(%rip),%rdi
call   1030 <printf@plt>
lea    0x1050(%rip),%rdi
call   1030 <printf@plt>
lea    0x1086(%rip),%rdi
call   1030 <printf@plt>
lea    0x10ca(%rip),%rdi
call   1030 <printf@plt>
lea    0x10c9(%rip),%rdi
call   1030 <printf@plt>
lea    0x111a(%rip),%rdi
call   1030 <printf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<printUsage>:
push   %rax
xor    %eax,%eax
call   1040 <printHeader@plt>
lea    0xed1(%rip),%rdi
call   1030 <puts@plt>
lea    0xecc(%rip),%rdi
call   1030 <puts@plt>
lea    0xf0c(%rip),%rdi
call   1030 <puts@plt>
lea    0xf4c(%rip),%rdi
call   1030 <puts@plt>
lea    0xf7b(%rip),%rdi
call   1030 <puts@plt>
lea    0xfc6(%rip),%rdi
call   1030 <puts@plt>
lea    0x1016(%rip),%rdi
call   1030 <puts@plt>
lea    0x104c(%rip),%rdi
call   1030 <puts@plt>
lea    0x1081(%rip),%rdi
call   1030 <puts@plt>
lea    0x10c4(%rip),%rdi
call   1030 <puts@plt>
lea    0x10c2(%rip),%rdi
call   1030 <puts@plt>
lea    0x1112(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [8 x i8] c"usage:\0A\00"
@.str.1 = [77 x i8] c"--address=<0xaddr> , -a <0xaddr> = Sets SMBus address for operation\0A\00"
@.str.2 = [77 x i8] c"--command=<0xcommand> , -c <0xcommand> = Sets SMBus command for operation\0A\00"
@.str.3 = [60 x i8] c"--write=<0xdata> , -w <0xdata> = Write operation\0A\00"
@.str.4 = [88 x i8] c"--block-write , -b = Force block-write regardless of data length\0A\00"
@.str.5 = [93 x i8] c"--read=<# of bytes> , -r <#> = Read operation (# of bytes determines read mode)\0A\00"
@.str.6 = [67 x i8] c"--null-write , -n = Start->addr->cmd->Stop\0A\00"
@.str.7 = [66 x i8] c"--verbose , -v = Print status messages\0A\00"
@.str.8 = [80 x i8] c"--no-pec = Disable SMBus Packet Error Checking\0A\00"
@.str.9 = [11 x i8] c"examples:\0A\00"
@.str.10 = [93 x i8] c"smbusb_comm -a 0x16 -c 0 -r 2 -s = Word Read Command 0 (Manufacturer Access in SBS)\0A\00"
@.str.11 = [92 x i8] c"smbusb_comm -a 0x16 -c F -w 41ef010102 = Block Write Command 0xF (0x is always optional)\0A\00"
define void @printUsage() {
%1 = call i32 (...) @printHeader()
%2 = call i32 @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0))
%3 = call i32 @printf(i8* getelementptr inbounds ([77 x i8], [77 x i8]* @.str.1, i64 0, i64 0))
%4 = call i32 @printf(i8* getelementptr inbounds ([77 x i8], [77 x i8]* @.str.2, i64 0, i64 0))
%5 = call i32 @printf(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @.str.3, i64 0, i64 0))
%6 = call i32 @printf(i8* getelementptr inbounds ([88 x i8], [88 x i8]* @.str.4, i64 0, i64 0))
%7 = call i32 @printf(i8* getelementptr inbounds ([93 x i8], [93 x i8]* @.str.5, i64 0, i64 0))
%8 = call i32 @printf(i8* getelementptr inbounds ([67 x i8], [67 x i8]* @.str.6, i64 0, i64 0))
%9 = call i32 @printf(i8* getelementptr inbounds ([66 x i8], [66 x i8]* @.str.7, i64 0, i64 0))
%10 = call i32 @printf(i8* getelementptr inbounds ([80 x i8], [80 x i8]* @.str.8, i64 0, i64 0))
%11 = call i32 @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.9, i64 0, i64 0))
%12 = call i32 @printf(i8* getelementptr inbounds ([93 x i8], [93 x i8]* @.str.10, i64 0, i64 0))
%13 = call i32 @printf(i8* getelementptr inbounds ([92 x i8], [92 x i8]* @.str.11, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [7 x i8] c"usage:\00"
@str.12 = [76 x i8] c"--address=<0xaddr> , -a <0xaddr> = Sets SMBus address for operation\00"
@str.13 = [76 x i8] c"--command=<0xcommand> , -c <0xcommand> = Sets SMBus command for operation\00"
@str.14 = [59 x i8] c"--write=<0xdata> , -w <0xdata> = Write operation\00"
@str.15 = [87 x i8] c"--block-write , -b = Force block-write regardless of data length\00"
@str.16 = [92 x i8] c"--read=<# of bytes> , -r <#> = Read operation (# of bytes determines read mode)\00"
@str.17 = [66 x i8] c"--null-write , -n = Start->addr->cmd->Stop\00"
@str.18 = [65 x i8] c"--verbose , -v = Print status messages\00"
@str.19 = [79 x i8] c"--no-pec = Disable SMBus Packet Error Checking\00"
@str.20 = [10 x i8] c"examples:\00"
@str.21 = [92 x i8] c"smbusb_comm -a 0x16 -c 0 -r 2 -s = Word Read Command 0 (Manufacturer Access in SBS)\00"
@str.22 = [91 x i8] c"smbusb_comm -a 0x16 -c F -w 41ef010102 = Block Write Command 0xF (0x is always optional)\00"
define void @printUsage() {
%1 = tail call i32 (...) @printHeader()
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @str, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([76 x i8], [76 x i8]* @str.12, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([76 x i8], [76 x i8]* @str.13, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([59 x i8], [59 x i8]* @str.14, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([87 x i8], [87 x i8]* @str.15, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([92 x i8], [92 x i8]* @str.16, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([66 x i8], [66 x i8]* @str.17, i64 0, i64 0))
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([65 x i8], [65 x i8]* @str.18, i64 0, i64 0))
%10 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([79 x i8], [79 x i8]* @str.19, i64 0, i64 0))
%11 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str.20, i64 0, i64 0))
%12 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([92 x i8], [92 x i8]* @str.21, i64 0, i64 0))
%13 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([91 x i8], [91 x i8]* @str.22, i64 0, i64 0))
ret void
}