#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 htxcmd_display_usage(char *error_text) {
  if (error_text != NULL) {
    printf("%s\n", error_text);
  }
  printf("Usage: htxd [-sut <host name>] [-port <port number>] OPTIONS\n");
  printf("\tFollowing are the OPTIONS\n");
  printf("\t-set_eeh [<EEH flag( 1 0r 0)>]\n");
  printf("\t-set_kdblevel [<kdb level flag ( 1 or 0)>]\n");
  printf("\t-set_hxecom\n");
  printf("\t-bootme [ on | off | status ]\n");
  printf("\t-createmdt\n");
  printf("\t-listmdt\n");
  printf("\t-refresh\n");
  printf("\t-select [-ecg <ecg_name>]\n");
  printf("\t-run [-ecg <ecg_name>]\n");
  printf("\t-shutdown [-ecg <ecg_name>]\n");
  printf("\t-getactecg\n");
  printf("\t-query [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\n");
  printf("\t-activate [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\n");
  printf("\t-suspend [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\n");
  printf(
      "\t-terminate [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\n");
  printf("\t-restart [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\n");
  printf("\t-coe [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\n");
  printf("\t-soe [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\n");
  printf("\t-status [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\n");
  printf("\t-getstats [-ecg <ecg_name>]\n");
  printf("\t-getecgsum [-ecg <ecg_name>]\n");
  printf("\t-exersetupinfo [-ecg <ecg_name>]\n");
  printf("\t-getecglist\n");
  printf("\t-geterrlog\n");
  printf("\t-clrerrlog\n");
  printf("\t-getvpd\n");
  printf("\t-cmd <command to execute>\n");
}


x86 assembly (clang, -O0):
<htxcmd_display_usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
cmpq   $0x0,-0x8(%rbp)
je     1139 <htxcmd_display_usage+0x29>
mov    -0x8(%rbp),%rsi
lea    0xece(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xec4(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xef4(%rip),%rdi
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    0xf34(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf34(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf46(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf45(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf42(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf3f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf4d(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf58(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf68(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf67(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf98(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xfcc(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xfff(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x1034(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x1067(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x1096(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x10c5(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x10f7(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x1107(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x1118(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x112d(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x112d(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x112c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x112b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x1127(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<htxcmd_display_usage>:
push   %rax
test   %rdi,%rdi
je     111b <htxcmd_display_usage+0xb>
call   1030 <puts@plt>
lea    0xede(%rip),%rdi
call   1030 <puts@plt>
lea    0xf0f(%rip),%rdi
call   1030 <puts@plt>
lea    0xf1e(%rip),%rdi
call   1030 <puts@plt>
lea    0xf32(%rip),%rdi
call   1030 <puts@plt>
lea    0xf52(%rip),%rdi
call   1030 <puts@plt>
lea    0xf53(%rip),%rdi
call   1030 <puts@plt>
lea    0xf66(%rip),%rdi
call   1030 <puts@plt>
lea    0xf66(%rip),%rdi
call   1030 <puts@plt>
lea    0xf64(%rip),%rdi
call   1030 <puts@plt>
lea    0xf62(%rip),%rdi
call   1030 <puts@plt>
lea    0xf71(%rip),%rdi
call   1030 <puts@plt>
lea    0xf7d(%rip),%rdi
call   1030 <puts@plt>
lea    0xf8e(%rip),%rdi
call   1030 <puts@plt>
lea    0xf8e(%rip),%rdi
call   1030 <puts@plt>
lea    0xfc0(%rip),%rdi
call   1030 <puts@plt>
lea    0xff5(%rip),%rdi
call   1030 <puts@plt>
lea    0x1029(%rip),%rdi
call   1030 <puts@plt>
lea    0x105f(%rip),%rdi
call   1030 <puts@plt>
lea    0x1093(%rip),%rdi
call   1030 <puts@plt>
lea    0x10c3(%rip),%rdi
call   1030 <puts@plt>
lea    0x10f3(%rip),%rdi
call   1030 <puts@plt>
lea    0x1126(%rip),%rdi
call   1030 <puts@plt>
lea    0x1137(%rip),%rdi
call   1030 <puts@plt>
lea    0x1149(%rip),%rdi
call   1030 <puts@plt>
lea    0x115f(%rip),%rdi
call   1030 <puts@plt>
lea    0x1160(%rip),%rdi
call   1030 <puts@plt>
lea    0x1160(%rip),%rdi
call   1030 <puts@plt>
lea    0x1160(%rip),%rdi
call   1030 <puts@plt>
lea    0x115d(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [4 x i8] c"%s\0A\00"
@.str.1 = [62 x i8] c"Usage: htxd [-sut <host name>] [-port <port number>] OPTIONS\0A\00"
@.str.2 = [28 x i8] c"\09Following are the OPTIONS\0A\00"
@.str.3 = [33 x i8] c"\09-set_eeh [<EEH flag( 1 0r 0)>]\0A\00"
@.str.4 = [45 x i8] c"\09-set_kdblevel [<kdb level flag ( 1 or 0)>]\0A\00"
@.str.5 = [14 x i8] c"\09-set_hxecom\0A\00"
@.str.6 = [32 x i8] c"\09-bootme [ on | off | status ]\0A\00"
@.str.7 = [13 x i8] c"\09-createmdt\0A\00"
@.str.8 = [11 x i8] c"\09-listmdt\0A\00"
@.str.9 = [11 x i8] c"\09-refresh\0A\00"
@.str.10 = [28 x i8] c"\09-select [-ecg <ecg_name>]\0A\00"
@.str.11 = [25 x i8] c"\09-run [-ecg <ecg_name>]\0A\00"
@.str.12 = [30 x i8] c"\09-shutdown [-ecg <ecg_name>]\0A\00"
@.str.13 = [13 x i8] c"\09-getactecg\0A\00"
@.str.14 = [63 x i8] c"\09-query [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\0A\00"
@.str.15 = [66 x i8] c"\09-activate [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\0A\00"
@.str.16 = [65 x i8] c"\09-suspend [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\0A\00"
@.str.17 = [67 x i8] c"\09-terminate [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\0A\00"
@.str.18 = [65 x i8] c"\09-restart [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\0A\00"
@.str.19 = [61 x i8] c"\09-coe [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\0A\00"
@.str.20 = [61 x i8] c"\09-soe [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\0A\00"
@.str.21 = [64 x i8] c"\09-status [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\0A\00"
@.str.22 = [30 x i8] c"\09-getstats [-ecg <ecg_name>]\0A\00"
@.str.23 = [31 x i8] c"\09-getecgsum [-ecg <ecg_name>]\0A\00"
@.str.24 = [35 x i8] c"\09-exersetupinfo [-ecg <ecg_name>]\0A\00"
@.str.25 = [14 x i8] c"\09-getecglist\0A\00"
@.str.26 = [13 x i8] c"\09-geterrlog\0A\00"
@.str.27 = [13 x i8] c"\09-clrerrlog\0A\00"
@.str.28 = [10 x i8] c"\09-getvpd\0A\00"
@.str.29 = [28 x i8] c"\09-cmd <command to execute>\0A\00"
define void @htxcmd_display_usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = icmp ne i8* %3, null
br i1 %4, label %5, label %8
5: ; preds = %1
%6 = load i8*, i8** %2
%7 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %6)
br label %8
8: ; preds = %5, %1
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([62 x i8], [62 x i8]* @.str.1, i64 0, i64 0))
%10 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.2, i64 0, i64 0))
%11 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.3, i64 0, i64 0))
%12 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.4, i64 0, i64 0))
%13 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.5, i64 0, i64 0))
%14 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.6, i64 0, i64 0))
%15 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0))
%16 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.8, i64 0, i64 0))
%17 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.9, i64 0, i64 0))
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.10, i64 0, i64 0))
%19 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.11, i64 0, i64 0))
%20 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.12, i64 0, i64 0))
%21 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.13, i64 0, i64 0))
%22 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([63 x i8], [63 x i8]* @.str.14, i64 0, i64 0))
%23 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([66 x i8], [66 x i8]* @.str.15, i64 0, i64 0))
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str.16, i64 0, i64 0))
%25 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([67 x i8], [67 x i8]* @.str.17, i64 0, i64 0))
%26 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str.18, i64 0, i64 0))
%27 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([61 x i8], [61 x i8]* @.str.19, i64 0, i64 0))
%28 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([61 x i8], [61 x i8]* @.str.20, i64 0, i64 0))
%29 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([64 x i8], [64 x i8]* @.str.21, i64 0, i64 0))
%30 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.22, i64 0, i64 0))
%31 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.23, i64 0, i64 0))
%32 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.24, i64 0, i64 0))
%33 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.25, i64 0, i64 0))
%34 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.26, i64 0, i64 0))
%35 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.27, i64 0, i64 0))
%36 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.28, i64 0, i64 0))
%37 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.29, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [61 x i8] c"Usage: htxd [-sut <host name>] [-port <port number>] OPTIONS\00"
@str.30 = [27 x i8] c"\09Following are the OPTIONS\00"
@str.31 = [32 x i8] c"\09-set_eeh [<EEH flag( 1 0r 0)>]\00"
@str.32 = [44 x i8] c"\09-set_kdblevel [<kdb level flag ( 1 or 0)>]\00"
@str.33 = [13 x i8] c"\09-set_hxecom\00"
@str.34 = [31 x i8] c"\09-bootme [ on | off | status ]\00"
@str.35 = [12 x i8] c"\09-createmdt\00"
@str.36 = [10 x i8] c"\09-listmdt\00"
@str.37 = [10 x i8] c"\09-refresh\00"
@str.38 = [27 x i8] c"\09-select [-ecg <ecg_name>]\00"
@str.39 = [24 x i8] c"\09-run [-ecg <ecg_name>]\00"
@str.40 = [29 x i8] c"\09-shutdown [-ecg <ecg_name>]\00"
@str.41 = [12 x i8] c"\09-getactecg\00"
@str.42 = [62 x i8] c"\09-query [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\00"
@str.43 = [65 x i8] c"\09-activate [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\00"
@str.44 = [64 x i8] c"\09-suspend [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\00"
@str.45 = [66 x i8] c"\09-terminate [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\00"
@str.46 = [64 x i8] c"\09-restart [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\00"
@str.47 = [60 x i8] c"\09-coe [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\00"
@str.48 = [60 x i8] c"\09-soe [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\00"
@str.49 = [63 x i8] c"\09-status [<device_name1> <device_name2> ...] [-ecg <ecg_name>]\00"
@str.50 = [29 x i8] c"\09-getstats [-ecg <ecg_name>]\00"
@str.51 = [30 x i8] c"\09-getecgsum [-ecg <ecg_name>]\00"
@str.52 = [34 x i8] c"\09-exersetupinfo [-ecg <ecg_name>]\00"
@str.53 = [13 x i8] c"\09-getecglist\00"
@str.54 = [12 x i8] c"\09-geterrlog\00"
@str.55 = [12 x i8] c"\09-clrerrlog\00"
@str.56 = [9 x i8] c"\09-getvpd\00"
@str.57 = [27 x i8] c"\09-cmd <command to execute>\00"
define void @htxcmd_display_usage(i8* %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %5, label %3
3: ; preds = %1
%4 = tail call i32 @puts(i8* %0)
br label %5
5: ; preds = %3, %1
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([61 x i8], [61 x i8]* @str, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @str.30, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @str.31, i64 0, i64 0))
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([44 x i8], [44 x i8]* @str.32, i64 0, i64 0))
%10 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str.33, i64 0, i64 0))
%11 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @str.34, i64 0, i64 0))
%12 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.35, i64 0, i64 0))
%13 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str.36, i64 0, i64 0))
%14 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str.37, i64 0, i64 0))
%15 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @str.38, i64 0, i64 0))
%16 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([24 x i8], [24 x i8]* @str.39, i64 0, i64 0))
%17 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @str.40, i64 0, i64 0))
%18 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.41, i64 0, i64 0))
%19 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([62 x i8], [62 x i8]* @str.42, i64 0, i64 0))
%20 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([65 x i8], [65 x i8]* @str.43, i64 0, i64 0))
%21 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([64 x i8], [64 x i8]* @str.44, i64 0, i64 0))
%22 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([66 x i8], [66 x i8]* @str.45, i64 0, i64 0))
%23 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([64 x i8], [64 x i8]* @str.46, i64 0, i64 0))
%24 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([60 x i8], [60 x i8]* @str.47, i64 0, i64 0))
%25 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([60 x i8], [60 x i8]* @str.48, i64 0, i64 0))
%26 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([63 x i8], [63 x i8]* @str.49, i64 0, i64 0))
%27 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @str.50, i64 0, i64 0))
%28 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([30 x i8], [30 x i8]* @str.51, i64 0, i64 0))
%29 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([34 x i8], [34 x i8]* @str.52, i64 0, i64 0))
%30 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str.53, i64 0, i64 0))
%31 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.54, i64 0, i64 0))
%32 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @str.55, i64 0, i64 0))
%33 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @str.56, i64 0, i64 0))
%34 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @str.57, i64 0, i64 0))
ret void
}