#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*/ fprintf(int /*<<< orphan*/, char *, ...);
int /*<<< orphan*/ stderr;
void report_usage(char *program_name) {
  fprintf(stderr,
          "VNC Reflector %s.  Copyright (C) 2001-2003 HorizonLive.com, Inc."
          "\n\n",
          "1.2.4");
  fprintf(stderr, "Usage: %s [OPTIONS...] HOST_INFO_FILE\n\n", program_name);
  fprintf(stderr, "Options:\n"
                  "  -i PID_FILE     - write pid file, appending listening port"
                  " to the filename\n"
                  "  -p PASSWD_FILE  - read a plaintext client password file"
                  " [default: passwd]\n"
                  "  -a ACTIVE_FILE  - create file during times when a host is"
                  " connected\n"
                  "  -c ACTIONS_FILE - on events, execute commands specified in"
                  " a file\n"
                  "  -l LISTEN_PORT  - port to listen for client connections"
                  " [default: 5999]\n"
                  "  -b IP_ADDRESS   - bind listening sockets to a specific IP"
                  " [default: any]\n");
  fprintf(stderr,
          "  -s FBS_PREFIX   - save host sessions in rfbproxy-compatible"
          " files\n"
          "                    (optionally appending 3-digit session IDs"
          " to the\n"
          "                    filename prefix, only if used without the"
          " -j option)\n"
          "  -j              - join saved sessions (see -s option) in one"
          " session file\n"
          "  -t              - use Tight encoding for host communications"
          " if possible\n"
          "  -T COMPR_LEVEL  - like -t, but use the specified compression"
          " level (1..9)\n");
  fprintf(stderr,
          "  -g LOG_FILE     - write logs to the specified file"
          " [default: reflector.log]\n"
          "  -v LOG_LEVEL    - set verbosity level for the log file (0..%d)"
          " [default: %d]\n"
          "  -f LOG_LEVEL    - run in foreground, show logs on stderr"
          " at the specified\n"
          "                    verbosity level (0..%d) [note: use %d for"
          " normal output]\n"
          "  -q              - suppress printing copyright banner at startup\n"
          "  -h              - print this help message\n\n",
          6, 4, 6, 3);
  fprintf(stderr,
          "Please refer to the README file for a description of the file"
          " formats for\n"
          "  HOST_INFO_FILE and PASSWD_FILE files mentioned above in this"
          " help text.\n\n");
}


x86 assembly (clang, -O0):
<report_usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ebd(%rip),%rax
mov    (%rax),%edi
lea    0xed4(%rip),%rsi
lea    0xf10(%rip),%rdx
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e9f(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rdx
lea    0xefb(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e84(%rip),%rax
mov    (%rax),%edi
lea    0xf0c(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e6d(%rip),%rax
mov    (%rax),%edi
lea    0x10b7(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e56(%rip),%rax
mov    (%rax),%edi
lea    0x1256(%rip),%rsi
mov    $0x6,%r8d
mov    $0x4,%ecx
mov    $0x3,%r9d
mov    %r8d,%edx
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e2b(%rip),%rax
mov    (%rax),%edi
lea    0x13d1(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<report_usage>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%rbx
mov    0x2ec2(%rip),%r14
mov    (%r14),%edi
lea    0xed8(%rip),%rsi
lea    0xf14(%rip),%rdx
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0xf09(%rip),%rsi
mov    %rbx,%rdx
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0xf1d(%rip),%rsi
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0x10ce(%rip),%rsi
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0x1273(%rip),%rsi
mov    $0x6,%edx
mov    $0x4,%ecx
mov    $0x6,%r8d
mov    $0x3,%r9d
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0x13f2(%rip),%rsi
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [67 x i8] c"VNC Reflector %s. Copyright (C) 2001-2003 HorizonLive.com, Inc.\0A\0A\00"
@.str.1 = [6 x i8] c"1.2.4\00"
@.str.2 = [40 x i8] c"Usage: %s [OPTIONS...] HOST_INFO_FILE\0A\0A\00"
@.str.3 = [450 x i8] c"Options:\0A -i PID_FILE - write pid file, appending listening port to the filename\0A -p PASSWD_FILE - read a plaintext client password file [default: passwd]\0A -a ACTIVE_FILE - create file during times when a host is connected\0A -c ACTIONS_FILE - on events, execute commands specified in a file\0A -l LISTEN_PORT - port to listen for client connections [default: 5999]\0A -b IP_ADDRESS - bind listening sockets to a specific IP [default: any]\0A\00"
@.str.4 = [438 x i8] c" -s FBS_PREFIX - save host sessions in rfbproxy-compatible files\0A (optionally appending 3-digit session IDs to the\0A filename prefix, only if used without the -j option)\0A -j - join saved sessions (see -s option) in one session file\0A -t - use Tight encoding for host communications if possible\0A -T COMPR_LEVEL - like -t, but use the specified compression level (1..9)\0A\00"
@.str.5 = [422 x i8] c" -g LOG_FILE - write logs to the specified file [default: reflector.log]\0A -v LOG_LEVEL - set verbosity level for the log file (0..%d) [default: %d]\0A -f LOG_LEVEL - run in foreground, show logs on stderr at the specified\0A verbosity level (0..%d) [note: use %d for normal output]\0A -q - suppress printing copyright banner at startup\0A -h - print this help message\0A\0A\00"
@.str.6 = [150 x i8] c"Please refer to the README file for a description of the file formats for\0A HOST_INFO_FILE and PASSWD_FILE files mentioned above in this help text.\0A\0A\00"
define void @report_usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i32, i32* @stderr
%4 = call i32 (i32, i8*, ...) @fprintf(i32 %3, i8* getelementptr inbounds ([67 x i8], [67 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0))
%5 = load i32, i32* @stderr
%6 = load i8*, i8** %2
%7 = call i32 (i32, i8*, ...) @fprintf(i32 %5, i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.2, i64 0, i64 0), i8* %6)
%8 = load i32, i32* @stderr
%9 = call i32 (i32, i8*, ...) @fprintf(i32 %8, i8* getelementptr inbounds ([450 x i8], [450 x i8]* @.str.3, i64 0, i64 0))
%10 = load i32, i32* @stderr
%11 = call i32 (i32, i8*, ...) @fprintf(i32 %10, i8* getelementptr inbounds ([438 x i8], [438 x i8]* @.str.4, i64 0, i64 0))
%12 = load i32, i32* @stderr
%13 = call i32 (i32, i8*, ...) @fprintf(i32 %12, i8* getelementptr inbounds ([422 x i8], [422 x i8]* @.str.5, i64 0, i64 0), i32 6, i32 4, i32 6, i32 3)
%14 = load i32, i32* @stderr
%15 = call i32 (i32, i8*, ...) @fprintf(i32 %14, i8* getelementptr inbounds ([150 x i8], [150 x i8]* @.str.6, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [67 x i8] c"VNC Reflector %s. Copyright (C) 2001-2003 HorizonLive.com, Inc.\0A\0A\00"
@.str.1 = [6 x i8] c"1.2.4\00"
@.str.2 = [40 x i8] c"Usage: %s [OPTIONS...] HOST_INFO_FILE\0A\0A\00"
@.str.3 = [450 x i8] c"Options:\0A -i PID_FILE - write pid file, appending listening port to the filename\0A -p PASSWD_FILE - read a plaintext client password file [default: passwd]\0A -a ACTIVE_FILE - create file during times when a host is connected\0A -c ACTIONS_FILE - on events, execute commands specified in a file\0A -l LISTEN_PORT - port to listen for client connections [default: 5999]\0A -b IP_ADDRESS - bind listening sockets to a specific IP [default: any]\0A\00"
@.str.4 = [438 x i8] c" -s FBS_PREFIX - save host sessions in rfbproxy-compatible files\0A (optionally appending 3-digit session IDs to the\0A filename prefix, only if used without the -j option)\0A -j - join saved sessions (see -s option) in one session file\0A -t - use Tight encoding for host communications if possible\0A -T COMPR_LEVEL - like -t, but use the specified compression level (1..9)\0A\00"
@.str.5 = [422 x i8] c" -g LOG_FILE - write logs to the specified file [default: reflector.log]\0A -v LOG_LEVEL - set verbosity level for the log file (0..%d) [default: %d]\0A -f LOG_LEVEL - run in foreground, show logs on stderr at the specified\0A verbosity level (0..%d) [note: use %d for normal output]\0A -q - suppress printing copyright banner at startup\0A -h - print this help message\0A\0A\00"
@.str.6 = [150 x i8] c"Please refer to the README file for a description of the file formats for\0A HOST_INFO_FILE and PASSWD_FILE files mentioned above in this help text.\0A\0A\00"
define void @report_usage(i8* %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 (i32, i8*, ...) @fprintf(i32 %2, i8* getelementptr inbounds ([67 x i8], [67 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0))
%4 = load i32, i32* @stderr
%5 = tail call i32 (i32, i8*, ...) @fprintf(i32 %4, i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.2, i64 0, i64 0), i8* %0)
%6 = load i32, i32* @stderr
%7 = tail call i32 (i32, i8*, ...) @fprintf(i32 %6, i8* getelementptr inbounds ([450 x i8], [450 x i8]* @.str.3, i64 0, i64 0))
%8 = load i32, i32* @stderr
%9 = tail call i32 (i32, i8*, ...) @fprintf(i32 %8, i8* getelementptr inbounds ([438 x i8], [438 x i8]* @.str.4, i64 0, i64 0))
%10 = load i32, i32* @stderr
%11 = tail call i32 (i32, i8*, ...) @fprintf(i32 %10, i8* getelementptr inbounds ([422 x i8], [422 x i8]* @.str.5, i64 0, i64 0), i32 6, i32 4, i32 6, i32 3)
%12 = load i32, i32* @stderr
%13 = tail call i32 (i32, i8*, ...) @fprintf(i32 %12, i8* getelementptr inbounds ([150 x i8], [150 x i8]* @.str.6, i64 0, i64 0))
ret void
}