#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 */
char *comma();
char *point();
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ strcmp(char *, char *);
int main(int argc, char *argv[]) {
  if (argc > 1) {
    if (!strcmp(argv[1], "-r")) {
      printf("#define COMMA_VERSION %s\n", comma());
    } else if (!strcmp(argv[1], "-a32")) {
      printf("AppVerName=XChat-WDK %s (x86)\n", "1499-6");
    } else if (!strcmp(argv[1], "-a64")) {
      printf("AppVerName=XChat-WDK %s (x64)\n", "1499-6");
    } else if (!strcmp(argv[1], "-v")) {
      printf("AppVersion=%s\n", point());
    } else if (!strcmp(argv[1], "-i")) {
      printf("VersionInfoVersion=%s\n", point());
    } else if (!strcmp(argv[1], "-o32")) {
      printf("OutputBaseFilename=XChat-WDK %s x86\n", "1499-6");
    } else if (!strcmp(argv[1], "-o64")) {
      printf("OutputBaseFilename=XChat-WDK %s x64\n", "1499-6");
    } else if (!strcmp(argv[1], "-v")) {
      printf("%s", "1499-6");
    } else {
      printf("usage:\n\t-a\txchat-wdk.iss/AppVerName\n\t-i\txchat-wdk.iss/"
             "VersionInfoVersion\n\t-o\txchat-wdk.iss/"
             "OutputBaseFilename\n\t-r\txchat.rc/FILEVERSION, "
             "PRODUCTVERSION\n\t-v\txchat-wdk.iss/AppVersion\n");
    }
  } else {
    printf("usage:\n\t-a\txchat-wdk.iss/AppVerName\n\t-i\txchat-wdk.iss/"
           "VersionInfoVersion\n\t-o\txchat-wdk.iss/"
           "OutputBaseFilename\n\t-r\txchat.rc/FILEVERSION, "
           "PRODUCTVERSION\n\t-v\txchat-wdk.iss/AppVersion\n");
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x1,-0x8(%rbp)
jle    1357 <main+0x217>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xe91(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%eax
jne    119a <main+0x5a>
mov    $0x0,%al
call   1050 <comma@plt>
mov    %rax,%rsi
lea    0xe75(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1352 <main+0x212>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xe74(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%eax
jne    11d1 <main+0x91>
lea    0xe64(%rip),%rdi
lea    0xe7c(%rip),%rsi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    134d <main+0x20d>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xe68(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%eax
jne    1208 <main+0xc8>
lea    0xe58(%rip),%rdi
lea    0xe45(%rip),%rsi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1348 <main+0x208>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xe55(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%eax
jne    1242 <main+0x102>
mov    $0x0,%al
call   1060 <point@plt>
mov    %rax,%rsi
lea    0xe39(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1343 <main+0x203>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xe2d(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%eax
jne    127c <main+0x13c>
mov    $0x0,%al
call   1060 <point@plt>
mov    %rax,%rsi
lea    0xe11(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    133e <main+0x1fe>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xe0d(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%eax
jne    12b3 <main+0x173>
lea    0xdfd(%rip),%rdi
lea    0xd9a(%rip),%rsi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1339 <main+0x1f9>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xe00(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%eax
jne    12ea <main+0x1aa>
lea    0xdf0(%rip),%rdi
lea    0xd63(%rip),%rsi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1334 <main+0x1f4>
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xd73(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%eax
jne    1321 <main+0x1e1>
lea    0xdde(%rip),%rdi
lea    0xd2c(%rip),%rsi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    132f <main+0x1ef>
lea    0xdc7(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    1334 <main+0x1f4>
jmp    1339 <main+0x1f9>
jmp    133e <main+0x1fe>
jmp    1343 <main+0x203>
jmp    1348 <main+0x208>
jmp    134d <main+0x20d>
jmp    1352 <main+0x212>
jmp    1365 <main+0x225>
lea    0xd91(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
cmp    $0x2,%edi
jl     11eb <main+0x9b>
mov    0x8(%rsi),%rbx
lea    0xe9b(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %eax,%eax
je     11f9 <main+0xa9>
lea    0xea1(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %eax,%eax
je     120c <main+0xbc>
lea    0xeb5(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %eax,%eax
je     1215 <main+0xc5>
lea    0xec6(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %eax,%eax
je     122e <main+0xde>
lea    0xec5(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %eax,%eax
je     123e <main+0xee>
lea    0xecc(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %eax,%eax
je     124e <main+0xfe>
lea    0xee3(%rip),%rsi
mov    %rbx,%rdi
call   1050 <strcmp@plt>
test   %eax,%eax
je     1257 <main+0x107>
lea    0xefa(%rip),%rdi
call   1030 <puts@plt>
jmp    122a <main+0xda>
xor    %eax,%eax
call   1060 <comma@plt>
lea    0xdfc(%rip),%rdi
mov    %rax,%rsi
jmp    1223 <main+0xd3>
lea    0xe0f(%rip),%rdi
jmp    121c <main+0xcc>
lea    0xe31(%rip),%rdi
lea    0xe1e(%rip),%rsi
xor    %eax,%eax
call   1040 <printf@plt>
xor    %eax,%eax
pop    %rbx
ret
xor    %eax,%eax
call   1070 <point@plt>
lea    0xe33(%rip),%rdi
jmp    1207 <main+0xb7>
xor    %eax,%eax
call   1070 <point@plt>
lea    0xe35(%rip),%rdi
jmp    1207 <main+0xb7>
lea    0xe48(%rip),%rdi
jmp    121c <main+0xcc>
lea    0xe69(%rip),%rdi
jmp    121c <main+0xcc>

LLVM IR (-O0):
@.str = [3 x i8] c"-r\00"
@.str.1 = [26 x i8] c"#define COMMA_VERSION %s\0A\00"
@.str.2 = [5 x i8] c"-a32\00"
@.str.3 = [31 x i8] c"AppVerName=XChat-WDK %s (x86)\0A\00"
@.str.4 = [7 x i8] c"1499-6\00"
@.str.5 = [5 x i8] c"-a64\00"
@.str.6 = [31 x i8] c"AppVerName=XChat-WDK %s (x64)\0A\00"
@.str.7 = [3 x i8] c"-v\00"
@.str.8 = [15 x i8] c"AppVersion=%s\0A\00"
@.str.9 = [3 x i8] c"-i\00"
@.str.10 = [23 x i8] c"VersionInfoVersion=%s\0A\00"
@.str.11 = [5 x i8] c"-o32\00"
@.str.12 = [37 x i8] c"OutputBaseFilename=XChat-WDK %s x86\0A\00"
@.str.13 = [5 x i8] c"-o64\00"
@.str.14 = [37 x i8] c"OutputBaseFilename=XChat-WDK %s x64\0A\00"
@.str.15 = [3 x i8] c"%s\00"
@.str.16 = [181 x i8] c"usage:\0A\09-a\09xchat-wdk.iss/AppVerName\0A\09-i\09xchat-wdk.iss/VersionInfoVersion\0A\09-o\09xchat-wdk.iss/OutputBaseFilename\0A\09-r\09xchat.rc/FILEVERSION, PRODUCTVERSION\0A\09-v\09xchat-wdk.iss/AppVersion\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%6 = load i32, i32* %4
%7 = icmp sgt i32 %6, 1
br i1 %7, label %8, label %85
8: ; preds = %2
%9 = load i8**, i8*** %5
%10 = getelementptr inbounds i8*, i8** %9, i64 1
%11 = load i8*, i8** %10
%12 = call i32 @strcmp(i8* %11, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%13 = icmp ne i32 %12, 0
br i1 %13, label %17, label %14
14: ; preds = %8
%15 = call i8* (...) @comma()
%16 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0), i8* %15)
br label %84
17: ; preds = %8
%18 = load i8**, i8*** %5
%19 = getelementptr inbounds i8*, i8** %18, i64 1
%20 = load i8*, i8** %19
%21 = call i32 @strcmp(i8* %20, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%22 = icmp ne i32 %21, 0
br i1 %22, label %25, label %23
23: ; preds = %17
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i64 0, i64 0))
br label %83
25: ; preds = %17
%26 = load i8**, i8*** %5
%27 = getelementptr inbounds i8*, i8** %26, i64 1
%28 = load i8*, i8** %27
%29 = call i32 @strcmp(i8* %28, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0))
%30 = icmp ne i32 %29, 0
br i1 %30, label %33, label %31
31: ; preds = %25
%32 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.6, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i64 0, i64 0))
br label %82
33: ; preds = %25
%34 = load i8**, i8*** %5
%35 = getelementptr inbounds i8*, i8** %34, i64 1
%36 = load i8*, i8** %35
%37 = call i32 @strcmp(i8* %36, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.7, i64 0, i64 0))
%38 = icmp ne i32 %37, 0
br i1 %38, label %42, label %39
39: ; preds = %33
%40 = call i8* (...) @point()
%41 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.8, i64 0, i64 0), i8* %40)
br label %81
42: ; preds = %33
%43 = load i8**, i8*** %5
%44 = getelementptr inbounds i8*, i8** %43, i64 1
%45 = load i8*, i8** %44
%46 = call i32 @strcmp(i8* %45, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.9, i64 0, i64 0))
%47 = icmp ne i32 %46, 0
br i1 %47, label %51, label %48
48: ; preds = %42
%49 = call i8* (...) @point()
%50 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.10, i64 0, i64 0), i8* %49)
br label %80
51: ; preds = %42
%52 = load i8**, i8*** %5
%53 = getelementptr inbounds i8*, i8** %52, i64 1
%54 = load i8*, i8** %53
%55 = call i32 @strcmp(i8* %54, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.11, i64 0, i64 0))
%56 = icmp ne i32 %55, 0
br i1 %56, label %59, label %57
57: ; preds = %51
%58 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.12, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i64 0, i64 0))
br label %79
59: ; preds = %51
%60 = load i8**, i8*** %5
%61 = getelementptr inbounds i8*, i8** %60, i64 1
%62 = load i8*, i8** %61
%63 = call i32 @strcmp(i8* %62, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.13, i64 0, i64 0))
%64 = icmp ne i32 %63, 0
br i1 %64, label %67, label %65
65: ; preds = %59
%66 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.14, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i64 0, i64 0))
br label %78
67: ; preds = %59
%68 = load i8**, i8*** %5
%69 = getelementptr inbounds i8*, i8** %68, i64 1
%70 = load i8*, i8** %69
%71 = call i32 @strcmp(i8* %70, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.7, i64 0, i64 0))
%72 = icmp ne i32 %71, 0
br i1 %72, label %75, label %73
73: ; preds = %67
%74 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.15, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i64 0, i64 0))
br label %77
75: ; preds = %67
%76 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([181 x i8], [181 x i8]* @.str.16, i64 0, i64 0))
br label %77
77: ; preds = %75, %73
br label %78
78: ; preds = %77, %65
br label %79
79: ; preds = %78, %57
br label %80
80: ; preds = %79, %48
br label %81
81: ; preds = %80, %39
br label %82
82: ; preds = %81, %31
br label %83
83: ; preds = %82, %23
br label %84
84: ; preds = %83, %14
br label %87
85: ; preds = %2
%86 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([181 x i8], [181 x i8]* @.str.16, i64 0, i64 0))
br label %87
87: ; preds = %85, %84
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"-r\00"
@.str.1 = [26 x i8] c"#define COMMA_VERSION %s\0A\00"
@.str.2 = [5 x i8] c"-a32\00"
@.str.3 = [31 x i8] c"AppVerName=XChat-WDK %s (x86)\0A\00"
@.str.4 = [7 x i8] c"1499-6\00"
@.str.5 = [5 x i8] c"-a64\00"
@.str.6 = [31 x i8] c"AppVerName=XChat-WDK %s (x64)\0A\00"
@.str.7 = [3 x i8] c"-v\00"
@.str.8 = [15 x i8] c"AppVersion=%s\0A\00"
@.str.9 = [3 x i8] c"-i\00"
@.str.10 = [23 x i8] c"VersionInfoVersion=%s\0A\00"
@.str.11 = [5 x i8] c"-o32\00"
@.str.12 = [37 x i8] c"OutputBaseFilename=XChat-WDK %s x86\0A\00"
@.str.13 = [5 x i8] c"-o64\00"
@.str.14 = [37 x i8] c"OutputBaseFilename=XChat-WDK %s x64\0A\00"
@str.17 = [180 x i8] c"usage:\0A\09-a\09xchat-wdk.iss/AppVerName\0A\09-i\09xchat-wdk.iss/VersionInfoVersion\0A\09-o\09xchat-wdk.iss/OutputBaseFilename\0A\09-r\09xchat.rc/FILEVERSION, PRODUCTVERSION\0A\09-v\09xchat-wdk.iss/AppVersion\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = icmp sgt i32 %0, 1
br i1 %3, label %4, label %46
4: ; preds = %2
%5 = getelementptr inbounds i8*, i8** %1, i64 1
%6 = load i8*, i8** %5
%7 = tail call i32 @strcmp(i8* dereferenceable(1) %6, i8* dereferenceable(3) getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%8 = icmp eq i32 %7, 0
br i1 %8, label %9, label %12
9: ; preds = %4
%10 = tail call i8* (...) @comma()
%11 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([26 x i8], [26 x i8]* @.str.1, i64 0, i64 0), i8* %10)
br label %48
12: ; preds = %4
%13 = tail call i32 @strcmp(i8* dereferenceable(1) %6, i8* dereferenceable(5) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%14 = icmp eq i32 %13, 0
br i1 %14, label %15, label %17
15: ; preds = %12
%16 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i64 0, i64 0))
br label %48
17: ; preds = %12
%18 = tail call i32 @strcmp(i8* dereferenceable(1) %6, i8* dereferenceable(5) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0))
%19 = icmp eq i32 %18, 0
br i1 %19, label %20, label %22
20: ; preds = %17
%21 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @.str.6, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i64 0, i64 0))
br label %48
22: ; preds = %17
%23 = tail call i32 @strcmp(i8* dereferenceable(1) %6, i8* dereferenceable(3) getelementptr inbounds ([3 x i8], [3 x i8]* @.str.7, i64 0, i64 0))
%24 = icmp eq i32 %23, 0
br i1 %24, label %25, label %28
25: ; preds = %22
%26 = tail call i8* (...) @point()
%27 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @.str.8, i64 0, i64 0), i8* %26)
br label %48
28: ; preds = %22
%29 = tail call i32 @strcmp(i8* dereferenceable(1) %6, i8* dereferenceable(3) getelementptr inbounds ([3 x i8], [3 x i8]* @.str.9, i64 0, i64 0))
%30 = icmp eq i32 %29, 0
br i1 %30, label %31, label %34
31: ; preds = %28
%32 = tail call i8* (...) @point()
%33 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([23 x i8], [23 x i8]* @.str.10, i64 0, i64 0), i8* %32)
br label %48
34: ; preds = %28
%35 = tail call i32 @strcmp(i8* dereferenceable(1) %6, i8* dereferenceable(5) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.11, i64 0, i64 0))
%36 = icmp eq i32 %35, 0
br i1 %36, label %37, label %39
37: ; preds = %34
%38 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @.str.12, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i64 0, i64 0))
br label %48
39: ; preds = %34
%40 = tail call i32 @strcmp(i8* dereferenceable(1) %6, i8* dereferenceable(5) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.13, i64 0, i64 0))
%41 = icmp eq i32 %40, 0
br i1 %41, label %42, label %44
42: ; preds = %39
%43 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @.str.14, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i64 0, i64 0))
br label %48
44: ; preds = %39
%45 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([180 x i8], [180 x i8]* @str.17, i64 0, i64 0))
br label %48
46: ; preds = %2
%47 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([180 x i8], [180 x i8]* @str.17, i64 0, i64 0))
br label %48
48: ; preds = %9, %20, %31, %42, %44, %37, %25, %15, %46
ret i32 0
}