#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*/ printmsg(char *, int /*<<< orphan*/);
void usage() {
  printmsg("Usage: reversi [-h] [-s|t FILE] [-v] [-c] [-L] [-H] [-u] [-d] [-r] "
           "[-l] [-A|B [1-5]]",
           0);
  printmsg("       -"
           "\x1b[1m"
           "h "
           "\x1b[0m"
           "        show this help",
           0);
  printmsg("       -"
           "\x1b[1m"
           "s "
           "\x1b[0m"
           "FILE    read starting board from 'FILE' file (green plays)",
           0);
  printmsg("       -"
           "\x1b[1m"
           "t "
           "\x1b[0m"
           "FILE    read starting board from 'FILE' file (red plays)",
           0);
  printmsg("      Output options              ", 0);
  printmsg("       -"
           "\x1b[1m"
           "\x1b[33m"
           "v "
           "\x1b[0m"
           "        verbose output: print board after each move",
           0);
  printmsg("       -"
           "\x1b[1m"
           "\x1b[33m"
           "c "
           "\x1b[0m"
           "        color output",
           0);
  printmsg("       -"
           "\x1b[1m"
           "\x1b[33m"
           "L "
           "\x1b[0m"
           "        log everything to /tmp/reversilog",
           0);
  printmsg("       -"
           "\x1b[1m"
           "\x1b[33m"
           "H "
           "\x1b[0m"
           "        hint valid moves",
           0);
  printmsg("      Borders                     ", 0);
  printmsg("       -"
           "\x1b[1m"
           "\x1b[32m"
           "u "
           "\x1b[0m"
           "        (UP) show letters above board",
           0);
  printmsg("       -"
           "\x1b[1m"
           "\x1b[32m"
           "d "
           "\x1b[0m"
           "        (DOWN) show letters below board",
           0);
  printmsg("       -"
           "\x1b[1m"
           "\x1b[32m"
           "r "
           "\x1b[0m"
           "        (RIGHT) show numbers to the right of the board",
           0);
  printmsg("       -"
           "\x1b[1m"
           "\x1b[32m"
           "l "
           "\x1b[0m"
           "        (LEFT) show numbers to the left of the board",
           0);
  printmsg("      Single-Player mode          ", 0);
  printmsg("       -"
           "\x1b[1m"
           "\x1b[36m"
           "A "
           "\x1b[0m"
           "[1-5]   AI level, Computer plays green (default = 2)",
           0);
  printmsg("       -"
           "\x1b[1m"
           "\x1b[36m"
           "B "
           "\x1b[0m"
           "[1-5]   AI level, Computer plays red (default = 2)",
           0);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0xf2c(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0xf47(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0xf86(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0xfc3(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0xfd8(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1015(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1033(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1066(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1088(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x109d(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x10cc(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x10fd(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x113d(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x117b(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1190(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x11ce(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
push   %rax
lea    0xee8(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0xf2f(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0xf4a(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0xf89(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0xfc6(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0xfdb(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1018(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1036(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1069(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x108b(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x10a0(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x10cf(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1100(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1140(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x117e(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x1193(%rip),%rdi
xor    %esi,%esi
call   1030 <printmsg@plt>
lea    0x11d1(%rip),%rdi
xor    %esi,%esi
pop    %rax
jmp    1030 <printmsg@plt>

LLVM IR (-O0):
@.str = [85 x i8] c"Usage: reversi [-h] [-s|t FILE] [-v] [-c] [-L] [-H] [-u] [-d] [-r] [-l] [-A|B [1-5]]\00"
@.str.1 = [41 x i8] c" -\1B[1mh \1B[0m show this help\00"
@.str.2 = [77 x i8] c" -\1B[1ms \1B[0mFILE read starting board from 'FILE' file (green plays)\00"
@.str.3 = [75 x i8] c" -\1B[1mt \1B[0mFILE read starting board from 'FILE' file (red plays)\00"
@.str.4 = [35 x i8] c" Output options \00"
@.str.5 = [75 x i8] c" -\1B[1m\1B[33mv \1B[0m verbose output: print board after each move\00"
@.str.6 = [44 x i8] c" -\1B[1m\1B[33mc \1B[0m color output\00"
@.str.7 = [65 x i8] c" -\1B[1m\1B[33mL \1B[0m log everything to /tmp/reversilog\00"
@.str.8 = [48 x i8] c" -\1B[1m\1B[33mH \1B[0m hint valid moves\00"
@.str.9 = [35 x i8] c" Borders \00"
@.str.10 = [61 x i8] c" -\1B[1m\1B[32mu \1B[0m (UP) show letters above board\00"
@.str.11 = [63 x i8] c" -\1B[1m\1B[32md \1B[0m (DOWN) show letters below board\00"
@.str.12 = [78 x i8] c" -\1B[1m\1B[32mr \1B[0m (RIGHT) show numbers to the right of the board\00"
@.str.13 = [76 x i8] c" -\1B[1m\1B[32ml \1B[0m (LEFT) show numbers to the left of the board\00"
@.str.14 = [35 x i8] c" Single-Player mode \00"
@.str.15 = [76 x i8] c" -\1B[1m\1B[36mA \1B[0m[1-5] AI level, Computer plays green (default = 2)\00"
@.str.16 = [74 x i8] c" -\1B[1m\1B[36mB \1B[0m[1-5] AI level, Computer plays red (default = 2)\00"
define void @usage() {
%1 = call i32 @printmsg(i8* getelementptr inbounds ([85 x i8], [85 x i8]* @.str, i64 0, i64 0), i32 0)
%2 = call i32 @printmsg(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.1, i64 0, i64 0), i32 0)
%3 = call i32 @printmsg(i8* getelementptr inbounds ([77 x i8], [77 x i8]* @.str.2, i64 0, i64 0), i32 0)
%4 = call i32 @printmsg(i8* getelementptr inbounds ([75 x i8], [75 x i8]* @.str.3, i64 0, i64 0), i32 0)
%5 = call i32 @printmsg(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.4, i64 0, i64 0), i32 0)
%6 = call i32 @printmsg(i8* getelementptr inbounds ([75 x i8], [75 x i8]* @.str.5, i64 0, i64 0), i32 0)
%7 = call i32 @printmsg(i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.6, i64 0, i64 0), i32 0)
%8 = call i32 @printmsg(i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str.7, i64 0, i64 0), i32 0)
%9 = call i32 @printmsg(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.8, i64 0, i64 0), i32 0)
%10 = call i32 @printmsg(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.9, i64 0, i64 0), i32 0)
%11 = call i32 @printmsg(i8* getelementptr inbounds ([61 x i8], [61 x i8]* @.str.10, i64 0, i64 0), i32 0)
%12 = call i32 @printmsg(i8* getelementptr inbounds ([63 x i8], [63 x i8]* @.str.11, i64 0, i64 0), i32 0)
%13 = call i32 @printmsg(i8* getelementptr inbounds ([78 x i8], [78 x i8]* @.str.12, i64 0, i64 0), i32 0)
%14 = call i32 @printmsg(i8* getelementptr inbounds ([76 x i8], [76 x i8]* @.str.13, i64 0, i64 0), i32 0)
%15 = call i32 @printmsg(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.14, i64 0, i64 0), i32 0)
%16 = call i32 @printmsg(i8* getelementptr inbounds ([76 x i8], [76 x i8]* @.str.15, i64 0, i64 0), i32 0)
%17 = call i32 @printmsg(i8* getelementptr inbounds ([74 x i8], [74 x i8]* @.str.16, i64 0, i64 0), i32 0)
ret void
}

LLVM IR (-O2):
@.str = [85 x i8] c"Usage: reversi [-h] [-s|t FILE] [-v] [-c] [-L] [-H] [-u] [-d] [-r] [-l] [-A|B [1-5]]\00"
@.str.1 = [41 x i8] c" -\1B[1mh \1B[0m show this help\00"
@.str.2 = [77 x i8] c" -\1B[1ms \1B[0mFILE read starting board from 'FILE' file (green plays)\00"
@.str.3 = [75 x i8] c" -\1B[1mt \1B[0mFILE read starting board from 'FILE' file (red plays)\00"
@.str.4 = [35 x i8] c" Output options \00"
@.str.5 = [75 x i8] c" -\1B[1m\1B[33mv \1B[0m verbose output: print board after each move\00"
@.str.6 = [44 x i8] c" -\1B[1m\1B[33mc \1B[0m color output\00"
@.str.7 = [65 x i8] c" -\1B[1m\1B[33mL \1B[0m log everything to /tmp/reversilog\00"
@.str.8 = [48 x i8] c" -\1B[1m\1B[33mH \1B[0m hint valid moves\00"
@.str.9 = [35 x i8] c" Borders \00"
@.str.10 = [61 x i8] c" -\1B[1m\1B[32mu \1B[0m (UP) show letters above board\00"
@.str.11 = [63 x i8] c" -\1B[1m\1B[32md \1B[0m (DOWN) show letters below board\00"
@.str.12 = [78 x i8] c" -\1B[1m\1B[32mr \1B[0m (RIGHT) show numbers to the right of the board\00"
@.str.13 = [76 x i8] c" -\1B[1m\1B[32ml \1B[0m (LEFT) show numbers to the left of the board\00"
@.str.14 = [35 x i8] c" Single-Player mode \00"
@.str.15 = [76 x i8] c" -\1B[1m\1B[36mA \1B[0m[1-5] AI level, Computer plays green (default = 2)\00"
@.str.16 = [74 x i8] c" -\1B[1m\1B[36mB \1B[0m[1-5] AI level, Computer plays red (default = 2)\00"
define void @usage() {
%1 = tail call i32 @printmsg(i8* getelementptr inbounds ([85 x i8], [85 x i8]* @.str, i64 0, i64 0), i32 0)
%2 = tail call i32 @printmsg(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.1, i64 0, i64 0), i32 0)
%3 = tail call i32 @printmsg(i8* getelementptr inbounds ([77 x i8], [77 x i8]* @.str.2, i64 0, i64 0), i32 0)
%4 = tail call i32 @printmsg(i8* getelementptr inbounds ([75 x i8], [75 x i8]* @.str.3, i64 0, i64 0), i32 0)
%5 = tail call i32 @printmsg(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.4, i64 0, i64 0), i32 0)
%6 = tail call i32 @printmsg(i8* getelementptr inbounds ([75 x i8], [75 x i8]* @.str.5, i64 0, i64 0), i32 0)
%7 = tail call i32 @printmsg(i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.6, i64 0, i64 0), i32 0)
%8 = tail call i32 @printmsg(i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str.7, i64 0, i64 0), i32 0)
%9 = tail call i32 @printmsg(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.8, i64 0, i64 0), i32 0)
%10 = tail call i32 @printmsg(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.9, i64 0, i64 0), i32 0)
%11 = tail call i32 @printmsg(i8* getelementptr inbounds ([61 x i8], [61 x i8]* @.str.10, i64 0, i64 0), i32 0)
%12 = tail call i32 @printmsg(i8* getelementptr inbounds ([63 x i8], [63 x i8]* @.str.11, i64 0, i64 0), i32 0)
%13 = tail call i32 @printmsg(i8* getelementptr inbounds ([78 x i8], [78 x i8]* @.str.12, i64 0, i64 0), i32 0)
%14 = tail call i32 @printmsg(i8* getelementptr inbounds ([76 x i8], [76 x i8]* @.str.13, i64 0, i64 0), i32 0)
%15 = tail call i32 @printmsg(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.14, i64 0, i64 0), i32 0)
%16 = tail call i32 @printmsg(i8* getelementptr inbounds ([76 x i8], [76 x i8]* @.str.15, i64 0, i64 0), i32 0)
%17 = tail call i32 @printmsg(i8* getelementptr inbounds ([74 x i8], [74 x i8]* @.str.16, i64 0, i64 0), i32 0)
ret void
}