#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 usage(char *name) {
  printf("The right way to use this driver is\n");
  printf("\033[1m\033[37m"
         "%s -d <UIO_DEV_FILE> -c <CHANNEL> -i|-o <VALUE>\n"
         "\033[0m",
         name);
  printf("Please, pay attention:\n");
  printf("\033[1m\033[37m"
         "\t-d"
         "\033[0m"
         "\033[32m"
         "\t<UIO_DEV_FILE>"
         "\033[0m"
         "\n\t\tThe mandatory parameter <UIO_DEV_FILE>\n\t\tspecifies the uio "
         "device file corrisponding\n\t\t to GPIO, for example /dev/uio0.\n");
  printf("\033[1m\033[37m"
         "\n\t-c"
         "\033[0m"
         "\033[32m"
         "\t<CHANNEL>"
         "\033[0m"
         "\n\t\tThe mandatory parameter <CHANNEL> specify\n\t\tthe GPIO "
         "channel to use \n\t\tThis number must be 1 or 2");
  printf("\033[1m\033[37m"
         "\n\t-i"
         "\033[0m"
         "\n\t\tSpecifies the input value of GPIO \n\t\tcorrisponding to "
         "<UIO_DEV_FILE> \n");
  printf("\033[1m\033[37m"
         "\n\t-o"
         "\033[0m"
         "\033[32m"
         "\t<VALUE>"
         "\033[0m"
         "\n\t\tThe mandatory parameter <VALUE> specify\n\t\tthe value must be "
         "write on GPIO output \n");
  return;
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
lea    0xedd(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x8(%rbp),%rsi
lea    0xef0(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf20(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf2a(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xfc0(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x103b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x1088(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
push   %rbx
mov    %rdi,%rbx
lea    0xf9c(%rip),%rdi
call   1030 <puts@plt>
lea    0xec9(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xfa3(%rip),%rdi
call   1030 <puts@plt>
lea    0xfae(%rip),%rdi
call   1030 <puts@plt>
lea    0xede(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0x1037(%rip),%rdi
call   1030 <puts@plt>
lea    0x1085(%rip),%rdi
pop    %rbx
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [37 x i8] c"The right way to use this driver is\0A\00"
@.str.1 = [62 x i8] c"\1B[1m\1B[37m%s -d <UIO_DEV_FILE> -c <CHANNEL> -i|-o <VALUE>\0A\1B[0m\00"
@.str.2 = [24 x i8] c"Please, pay attention:\0A\00"
@.str.3 = [164 x i8] c"\1B[1m\1B[37m\09-d\1B[0m\1B[32m\09<UIO_DEV_FILE>\1B[0m\0A\09\09The mandatory parameter <UIO_DEV_FILE>\0A\09\09specifies the uio device file corrisponding\0A\09\09 to GPIO, for example /dev/uio0.\0A\00"
@.str.4 = [137 x i8] c"\1B[1m\1B[37m\0A\09-c\1B[0m\1B[32m\09<CHANNEL>\1B[0m\0A\09\09The mandatory parameter <CHANNEL> specify\0A\09\09the GPIO channel to use \0A\09\09This number must be 1 or 2\00"
@.str.5 = [91 x i8] c"\1B[1m\1B[37m\0A\09-i\1B[0m\0A\09\09Specifies the input value of GPIO \0A\09\09corrisponding to <UIO_DEV_FILE> \0A\00"
@.str.6 = [120 x i8] c"\1B[1m\1B[37m\0A\09-o\1B[0m\1B[32m\09<VALUE>\1B[0m\0A\09\09The mandatory parameter <VALUE> specify\0A\09\09the value must be write on GPIO output \0A\00"
define void @usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0))
%4 = load i8*, i8** %2
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([62 x i8], [62 x i8]* @.str.1, i64 0, i64 0), i8* %4)
%6 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([24 x i8], [24 x i8]* @.str.2, i64 0, i64 0))
%7 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([164 x i8], [164 x i8]* @.str.3, i64 0, i64 0))
%8 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([137 x i8], [137 x i8]* @.str.4, i64 0, i64 0))
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([91 x i8], [91 x i8]* @.str.5, i64 0, i64 0))
%10 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([120 x i8], [120 x i8]* @.str.6, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str.1 = [62 x i8] c"\1B[1m\1B[37m%s -d <UIO_DEV_FILE> -c <CHANNEL> -i|-o <VALUE>\0A\1B[0m\00"
@.str.4 = [137 x i8] c"\1B[1m\1B[37m\0A\09-c\1B[0m\1B[32m\09<CHANNEL>\1B[0m\0A\09\09The mandatory parameter <CHANNEL> specify\0A\09\09the GPIO channel to use \0A\09\09This number must be 1 or 2\00"
@str = [36 x i8] c"The right way to use this driver is\00"
@str.7 = [23 x i8] c"Please, pay attention:\00"
@str.8 = [163 x i8] c"\1B[1m\1B[37m\09-d\1B[0m\1B[32m\09<UIO_DEV_FILE>\1B[0m\0A\09\09The mandatory parameter <UIO_DEV_FILE>\0A\09\09specifies the uio device file corrisponding\0A\09\09 to GPIO, for example /dev/uio0.\00"
@str.9 = [90 x i8] c"\1B[1m\1B[37m\0A\09-i\1B[0m\0A\09\09Specifies the input value of GPIO \0A\09\09corrisponding to <UIO_DEV_FILE> \00"
@str.10 = [119 x i8] c"\1B[1m\1B[37m\0A\09-o\1B[0m\1B[32m\09<VALUE>\1B[0m\0A\09\09The mandatory parameter <VALUE> specify\0A\09\09the value must be write on GPIO output \00"
define void @usage(i8* %0) {
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([36 x i8], [36 x i8]* @str, i64 0, i64 0))
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([62 x i8], [62 x i8]* @.str.1, i64 0, i64 0), i8* %0)
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @str.7, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([163 x i8], [163 x i8]* @str.8, i64 0, i64 0))
%6 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([137 x i8], [137 x i8]* @.str.4, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([90 x i8], [90 x i8]* @str.9, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([119 x i8], [119 x i8]* @str.10, i64 0, i64 0))
ret void
}