#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 help() {
  printf("%s (client) v%s for testing puroses\n\n", "modbus-master", "0.1b");
  printf("Usage: %s [OPTIONS]\n", "modbus-master");
  printf("\t-h\t\tDisplay this help message.\n");
  printf("\t-p [tcp|rtu]\tProtocol. Default - TCP.\n");
  printf("\t-m [test|echo]\tClient mode. Default - test.\n");
  printf("\t-i [ip addr]\tIP address. TCP mode only. Default - 192.168.1.1.\n");
  printf("\t-o [1 .. 65535]\tPort. TCP mode only.\n");
  printf("\t-d [dev]\tSpecify serial device. RTU mode only.\n");
  printf("\t-s [0 .. 247]\tSpecify slave ID. RTU mode only.\n");
  printf("\t-v\t\tDisplay version.\n");
}


x86 assembly (clang, -O0):
<help>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
lea    0xf04(%rip),%rsi
lea    0xf0b(%rip),%rdx
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf02(%rip),%rdi
lea    0xee8(%rip),%rsi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf02(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf15(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf2f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf4f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf82(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf9b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xfbe(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xfe1(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<help>:
push   %rbx
lea    0xed8(%rip),%rdi
lea    0xef7(%rip),%rbx
lea    0xefe(%rip),%rdx
mov    %rbx,%rsi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xef2(%rip),%rdi
mov    %rbx,%rsi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xef6(%rip),%rdi
call   1030 <puts@plt>
lea    0xf0a(%rip),%rdi
call   1030 <puts@plt>
lea    0xf25(%rip),%rdi
call   1030 <puts@plt>
lea    0xf46(%rip),%rdi
call   1030 <puts@plt>
lea    0xf7a(%rip),%rdi
call   1030 <puts@plt>
lea    0xf94(%rip),%rdi
call   1030 <puts@plt>
lea    0xfb8(%rip),%rdi
call   1030 <puts@plt>
lea    0xfdc(%rip),%rdi
pop    %rbx
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [38 x i8] c"%s (client) v%s for testing puroses\0A\0A\00"
@.str.1 = [14 x i8] c"modbus-master\00"
@.str.2 = [5 x i8] c"0.1b\00"
@.str.3 = [21 x i8] c"Usage: %s [OPTIONS]\0A\00"
@.str.4 = [33 x i8] c"\09-h\09\09Display this help message.\0A\00"
@.str.5 = [40 x i8] c"\09-p [tcp|rtu]\09Protocol. Default - TCP.\0A\00"
@.str.6 = [46 x i8] c"\09-m [test|echo]\09Client mode. Default - test.\0A\00"
@.str.7 = [65 x i8] c"\09-i [ip addr]\09IP address. TCP mode only. Default - 192.168.1.1.\0A\00"
@.str.8 = [39 x i8] c"\09-o [1 .. 65535]\09Port. TCP mode only.\0A\00"
@.str.9 = [49 x i8] c"\09-d [dev]\09Specify serial device. RTU mode only.\0A\00"
@.str.10 = [49 x i8] c"\09-s [0 .. 247]\09Specify slave ID. RTU mode only.\0A\00"
@.str.11 = [23 x i8] c"\09-v\09\09Display version.\0A\00"
define void @help() {
%1 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%2 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.4, i64 0, i64 0))
%4 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.5, i64 0, i64 0))
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.6, i64 0, i64 0))
%6 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str.7, i64 0, i64 0))
%7 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.8, i64 0, i64 0))
%8 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str.9, i64 0, i64 0))
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str.10, i64 0, i64 0))
%10 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.11, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [38 x i8] c"%s (client) v%s for testing puroses\0A\0A\00"
@.str.1 = [14 x i8] c"modbus-master\00"
@.str.2 = [5 x i8] c"0.1b\00"
@.str.3 = [21 x i8] c"Usage: %s [OPTIONS]\0A\00"
@str = [32 x i8] c"\09-h\09\09Display this help message.\00"
@str.12 = [39 x i8] c"\09-p [tcp|rtu]\09Protocol. Default - TCP.\00"
@str.13 = [45 x i8] c"\09-m [test|echo]\09Client mode. Default - test.\00"
@str.14 = [64 x i8] c"\09-i [ip addr]\09IP address. TCP mode only. Default - 192.168.1.1.\00"
@str.15 = [38 x i8] c"\09-o [1 .. 65535]\09Port. TCP mode only.\00"
@str.16 = [48 x i8] c"\09-d [dev]\09Specify serial device. RTU mode only.\00"
@str.17 = [48 x i8] c"\09-s [0 .. 247]\09Specify slave ID. RTU mode only.\00"
@str.18 = [22 x i8] c"\09-v\09\09Display version.\00"
define void @help() {
%1 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([38 x i8], [38 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%2 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @str, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([39 x i8], [39 x i8]* @str.12, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([45 x i8], [45 x i8]* @str.13, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([64 x i8], [64 x i8]* @str.14, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([38 x i8], [38 x i8]* @str.15, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([48 x i8], [48 x i8]* @str.16, i64 0, i64 0))
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([48 x i8], [48 x i8]* @str.17, i64 0, i64 0))
%10 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @str.18, i64 0, i64 0))
ret void
}