#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*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ printf(char *, char *, char *, char *, char *);
void printUsage(char *programName) {
  printf(
      "Usage: %s (command | option | filename)*\n"
      "where valid commands are\n"
      "       --print-all                    Print data-tree for ENT file. "
      "Will abort if unhandled datatypes exists in files.\n"
      "       --print-from <string>          Searches for given 'struct tag' "
      "in file and starts printing from there.\n"
      "       --print-credits                Print credits for playerstate "
      "type ENT files\n"
      "       --set-credits <integer>        Sets the credits of playerstate "
      "type ENT files\n"
      "       --add-credits <integer>        Adds a given amount of credits "
      "(can be negative) to playerstate type ENT files\n"
      "       --mult-credits <float>         Multiplies credits by a constant\n"
      "       --print-block <id>             Prints number of blocks matching "
      "the ID that is found in the playerstate OR shop type ENT files\n"
      "       --set-block <id> <integer>     Sets the number of blocks of "
      "given ID that is found in the playerstate OR shop type ENT files\n"
      "       --add-block <id> <integer>     Adds the number of blocks of "
      "given ID (can be negative).\n"
      "       --mult-block <id> <float>      Multiplies the number of blocks "
      "of given ID in the playerstate OR shop type ENT files\n"
      "       --print-inventory              Prints each blockID and number "
      "that is found in the inventory on a new line.\n"
      "       --print-sector                 Prints <filename> : <x> <y> <z>  "
      "where xyz are the last known sector of the player.\n"
      "\n",
      "valid options are"
      "       --simulate                     Prevents any changes from beeing "
      "written to disk\n",
      "       --quiet                        Suppresses any informational "
      "printouts to simplify script processing\n",
      "       --max-slots <integer>          Highest slot-index when creating "
      "new block entries (default 45).\n",
      programName);
  exit(0);
}


x86 assembly (clang, -O0):
<printUsage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%r8
lea    0xec9(%rip),%rdi
lea    0x1421(%rip),%rsi
lea    0x1483(%rip),%rdx
lea    0x14e8(%rip),%rcx
call   1030 <printf@plt>
xor    %edi,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<printUsage>:
push   %rax
mov    %rdi,%r8
lea    0xed5(%rip),%rdi
lea    0x142d(%rip),%rsi
lea    0x148f(%rip),%rdx
lea    0x14f4(%rip),%rcx
call   1030 <printf@plt>
xor    %edi,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [1375 x i8] c"Usage: %s (command | option | filename)*\0Awhere valid commands are\0A --print-all Print data-tree for ENT file. Will abort if unhandled datatypes exists in files.\0A --print-from <string> Searches for given 'struct tag' in file and starts printing from there.\0A --print-credits Print credits for playerstate type ENT files\0A --set-credits <integer> Sets the credits of playerstate type ENT files\0A --add-credits <integer> Adds a given amount of credits (can be negative) to playerstate type ENT files\0A --mult-credits <float> Multiplies credits by a constant\0A --print-block <id> Prints number of blocks matching the ID that is found in the playerstate OR shop type ENT files\0A --set-block <id> <integer> Sets the number of blocks of given ID that is found in the playerstate OR shop type ENT files\0A --add-block <id> <integer> Adds the number of blocks of given ID (can be negative).\0A --mult-block <id> <float> Multiplies the number of blocks of given ID in the playerstate OR shop type ENT files\0A --print-inventory Prints each blockID and number that is found in the inventory on a new line.\0A --print-sector Prints <filename> : <x> <y> <z> where xyz are the last known sector of the player.\0A\0A\00"
@.str.1 = [105 x i8] c"valid options are --simulate Prevents any changes from beeing written to disk\0A\00"
@.str.2 = [108 x i8] c" --quiet Suppresses any informational printouts to simplify script processing\0A\00"
@.str.3 = [104 x i8] c" --max-slots <integer> Highest slot-index when creating new block entries (default 45).\0A\00"
define void @printUsage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @printf(i8* getelementptr inbounds ([1375 x i8], [1375 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([105 x i8], [105 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([108 x i8], [108 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([104 x i8], [104 x i8]* @.str.3, i64 0, i64 0), i8* %3)
%5 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
@.str = [1375 x i8] c"Usage: %s (command | option | filename)*\0Awhere valid commands are\0A --print-all Print data-tree for ENT file. Will abort if unhandled datatypes exists in files.\0A --print-from <string> Searches for given 'struct tag' in file and starts printing from there.\0A --print-credits Print credits for playerstate type ENT files\0A --set-credits <integer> Sets the credits of playerstate type ENT files\0A --add-credits <integer> Adds a given amount of credits (can be negative) to playerstate type ENT files\0A --mult-credits <float> Multiplies credits by a constant\0A --print-block <id> Prints number of blocks matching the ID that is found in the playerstate OR shop type ENT files\0A --set-block <id> <integer> Sets the number of blocks of given ID that is found in the playerstate OR shop type ENT files\0A --add-block <id> <integer> Adds the number of blocks of given ID (can be negative).\0A --mult-block <id> <float> Multiplies the number of blocks of given ID in the playerstate OR shop type ENT files\0A --print-inventory Prints each blockID and number that is found in the inventory on a new line.\0A --print-sector Prints <filename> : <x> <y> <z> where xyz are the last known sector of the player.\0A\0A\00"
@.str.1 = [105 x i8] c"valid options are --simulate Prevents any changes from beeing written to disk\0A\00"
@.str.2 = [108 x i8] c" --quiet Suppresses any informational printouts to simplify script processing\0A\00"
@.str.3 = [104 x i8] c" --max-slots <integer> Highest slot-index when creating new block entries (default 45).\0A\00"
define void @printUsage(i8* %0) {
%2 = tail call i32 @printf(i8* getelementptr inbounds ([1375 x i8], [1375 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([105 x i8], [105 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([108 x i8], [108 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([104 x i8], [104 x i8]* @.str.3, i64 0, i64 0), i8* %0)
%3 = tail call i32 @exit(i32 0)
unreachable
}