#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*/ print_version(char *);
int /*<<< orphan*/ printf(char *);
void usage(char *text) {
  print_version(text);
  printf("\nThis program comes with ABSOLUTELY NO WARRANTY.\n");
  printf("This is free software, and you are welcome to redistribute it\n");
  printf("under certain conditions. See <http://www.gnu.org/licenses/>\n");
  printf("\nUsage:\n");
  printf("   pBlazASM -3|-6 [-k] [-v] [-f] [-c[<MEMfile>]] [-s[<MEMfile>]] "
         "[-l[<LSTfile>]] <input file> <input file> <input file> ...\n");
  printf("   where:\n");
  printf(
      "         -3      select Picoblaze-3, mandatory\n"
      "         -6      select Picoblaze-6, mandatory\n"
      "         -c/-C   creates a code (.MEM) file (not in combo with -x/-X)\n"
      "         -x/-X   creates a code (.HEX) file (not in combo with "
      "-c/-C)\n");
  printf("         -s/-S   creates a data (.SCR) file\n"
         "         -l      creates a LST file\n"
         "         -k      select KCPSM mode with limited expression handling "
         "(-3 only)\n"
         "         -v      generates verbose reporting\n"
         "         -f      with -l creates a list file without code to replace "
         "the source\n");
  printf("\nNote: All (max 255) input files are assembled to one output.");
  printf(
      "\nNote: Option -k (KCPSM mode) is not supported in Picoblaze-6 mode.");
  printf("\nNote: -C, -S and -X generate fully populated MEM files for "
         "'Data2Mem'.\n");
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <print_version@plt>
lea    0xec4(%rip),%rdi
call   1040 <printf@plt>
lea    0xeea(%rip),%rdi
call   1040 <printf@plt>
lea    0xf1d(%rip),%rdi
call   1040 <printf@plt>
lea    0xf4f(%rip),%rdi
call   1040 <printf@plt>
lea    0xf4c(%rip),%rdi
call   1040 <printf@plt>
lea    0xfbd(%rip),%rdi
call   1040 <printf@plt>
lea    0xfbc(%rip),%rdi
call   1040 <printf@plt>
lea    0x109b(%rip),%rdi
call   1040 <printf@plt>
lea    0x11ab(%rip),%rdi
call   1040 <printf@plt>
lea    0x11dd(%rip),%rdi
call   1040 <printf@plt>
lea    0x1215(%rip),%rdi
call   1040 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
push   %rax
call   1040 <print_version@plt>
lea    0xf45(%rip),%rdi
call   1030 <puts@plt>
lea    0xf6a(%rip),%rdi
call   1030 <puts@plt>
lea    0xf9c(%rip),%rdi
call   1030 <puts@plt>
lea    0xfcd(%rip),%rdi
call   1030 <puts@plt>
lea    0xfc9(%rip),%rdi
call   1030 <puts@plt>
lea    0x1039(%rip),%rdi
call   1030 <puts@plt>
lea    0x1037(%rip),%rdi
call   1030 <puts@plt>
lea    0x1115(%rip),%rdi
call   1030 <puts@plt>
lea    0xe63(%rip),%rdi
call   1050 <printf@plt>
lea    0xe95(%rip),%rdi
call   1050 <printf@plt>
lea    0x120c(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [50 x i8] c"\0AThis program comes with ABSOLUTELY NO WARRANTY.\0A\00"
@.str.1 = [63 x i8] c"This is free software, and you are welcome to redistribute it\0A\00"
@.str.2 = [62 x i8] c"under certain conditions. See <http://www.gnu.org/licenses/>\0A\00"
@.str.3 = [9 x i8] c"\0AUsage:\0A\00"
@.str.4 = [125 x i8] c" pBlazASM -3|-6 [-k] [-v] [-f] [-c[<MEMfile>]] [-s[<MEMfile>]] [-l[<LSTfile>]] <input file> <input file> <input file> ...\0A\00"
@.str.5 = [11 x i8] c" where:\0A\00"
@.str.6 = [235 x i8] c" -3 select Picoblaze-3, mandatory\0A -6 select Picoblaze-6, mandatory\0A -c/-C creates a code (.MEM) file (not in combo with -x/-X)\0A -x/-X creates a code (.HEX) file (not in combo with -c/-C)\0A\00"
@.str.7 = [284 x i8] c" -s/-S creates a data (.SCR) file\0A -l creates a LST file\0A -k select KCPSM mode with limited expression handling (-3 only)\0A -v generates verbose reporting\0A -f with -l creates a list file without code to replace the source\0A\00"
@.str.8 = [62 x i8] c"\0ANote: All (max 255) input files are assembled to one output.\00"
@.str.9 = [68 x i8] c"\0ANote: Option -k (KCPSM mode) is not supported in Picoblaze-6 mode.\00"
@.str.10 = [73 x i8] c"\0ANote: -C, -S and -X generate fully populated MEM files for 'Data2Mem'.\0A\00"
define void @usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i32 @print_version(i8* %3)
%5 = call i32 @printf(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str, i64 0, i64 0))
%6 = call i32 @printf(i8* getelementptr inbounds ([63 x i8], [63 x i8]* @.str.1, i64 0, i64 0))
%7 = call i32 @printf(i8* getelementptr inbounds ([62 x i8], [62 x i8]* @.str.2, i64 0, i64 0))
%8 = call i32 @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.3, i64 0, i64 0))
%9 = call i32 @printf(i8* getelementptr inbounds ([125 x i8], [125 x i8]* @.str.4, i64 0, i64 0))
%10 = call i32 @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.5, i64 0, i64 0))
%11 = call i32 @printf(i8* getelementptr inbounds ([235 x i8], [235 x i8]* @.str.6, i64 0, i64 0))
%12 = call i32 @printf(i8* getelementptr inbounds ([284 x i8], [284 x i8]* @.str.7, i64 0, i64 0))
%13 = call i32 @printf(i8* getelementptr inbounds ([62 x i8], [62 x i8]* @.str.8, i64 0, i64 0))
%14 = call i32 @printf(i8* getelementptr inbounds ([68 x i8], [68 x i8]* @.str.9, i64 0, i64 0))
%15 = call i32 @printf(i8* getelementptr inbounds ([73 x i8], [73 x i8]* @.str.10, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str.8 = [62 x i8] c"\0ANote: All (max 255) input files are assembled to one output.\00"
@.str.9 = [68 x i8] c"\0ANote: Option -k (KCPSM mode) is not supported in Picoblaze-6 mode.\00"
@str = [49 x i8] c"\0AThis program comes with ABSOLUTELY NO WARRANTY.\00"
@str.11 = [62 x i8] c"This is free software, and you are welcome to redistribute it\00"
@str.12 = [61 x i8] c"under certain conditions. See <http://www.gnu.org/licenses/>\00"
@str.13 = [8 x i8] c"\0AUsage:\00"
@str.14 = [124 x i8] c" pBlazASM -3|-6 [-k] [-v] [-f] [-c[<MEMfile>]] [-s[<MEMfile>]] [-l[<LSTfile>]] <input file> <input file> <input file> ...\00"
@str.15 = [10 x i8] c" where:\00"
@str.16 = [234 x i8] c" -3 select Picoblaze-3, mandatory\0A -6 select Picoblaze-6, mandatory\0A -c/-C creates a code (.MEM) file (not in combo with -x/-X)\0A -x/-X creates a code (.HEX) file (not in combo with -c/-C)\00"
@str.17 = [283 x i8] c" -s/-S creates a data (.SCR) file\0A -l creates a LST file\0A -k select KCPSM mode with limited expression handling (-3 only)\0A -v generates verbose reporting\0A -f with -l creates a list file without code to replace the source\00"
@str.18 = [72 x i8] c"\0ANote: -C, -S and -X generate fully populated MEM files for 'Data2Mem'.\00"
define void @usage(i8* %0) {
%2 = tail call i32 @print_version(i8* %0)
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([49 x i8], [49 x i8]* @str, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([62 x i8], [62 x i8]* @str.11, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([61 x i8], [61 x i8]* @str.12, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @str.13, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([124 x i8], [124 x i8]* @str.14, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str.15, i64 0, i64 0))
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([234 x i8], [234 x i8]* @str.16, i64 0, i64 0))
%10 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([283 x i8], [283 x i8]* @str.17, i64 0, i64 0))
%11 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([62 x i8], [62 x i8]* @.str.8, i64 0, i64 0))
%12 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([68 x i8], [68 x i8]* @.str.9, i64 0, i64 0))
%13 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([72 x i8], [72 x i8]* @str.18, i64 0, i64 0))
ret void
}