#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 *, char const *,
                           char const *, char const *, char const *);
int /*<<< orphan*/ stdout;
void usage(const char *prog) {
  fprintf(
      stdout,
      "Usage: %s [OPTIONS]...\n"
      "\n"
      "Mandatory arguments to long options are mandatory for short options "
      "too.\n"
      "  -h, --help	      print usage information\n"
      "  -V, --version      print version\n"
      "  -C, --card=CARDNO\n"
      "  -f, --file=VPD.BIN\n"
      "  -d, --dump	      use multiple d to increase dump info\n"
      "  -u, --update	      set this flag for update VPD\n"
      "  -s, --show	      set this flag to display VPD from a card\n"
      "  -v, --verbose      verbose level, use multiple v's to increase\n"
      "\n"
      "This utility updates the Genwqes FLASH with new VPD\n"
      "information from a *.bin file. Do not disconnect the card from power\n"
      "while updating. Ensure you have the correct update\n"
      "image. Use of incorrect images or interrupting the update\n"
      "will make the card unusable. In this case you need a\n"
      "USB-Blaster utility or similar to get it working again.\n"
      "\n"
      "Example flashing new vpd to GenWQE card:\n"
      "  %s -C0 -f vpd.bin\n"
      "Example to display vpd from GenWQE card to stdout:\n"
      "  %s -C0 -s\n"
      "Example to display and dump vpd from GenWQE card to stdout:\n"
      "  %s -C0 -s -d\n"
      "\n",
      prog, prog, prog, prog);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ebd(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rdx
mov    -0x8(%rbp),%rcx
mov    -0x8(%rbp),%r8
mov    -0x8(%rbp),%r9
lea    0xec4(%rip),%rsi
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
mov    %rdi,%rcx
mov    0x2ec6(%rip),%rax
mov    (%rax),%edi
lea    0xedd(%rip),%rsi
mov    %rcx,%rdx
mov    %rcx,%r8
mov    %rcx,%r9
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stdout = global i32 0
@.str = [989 x i8] c"Usage: %s [OPTIONS]...\0A\0AMandatory arguments to long options are mandatory for short options too.\0A -h, --help\09 print usage information\0A -V, --version print version\0A -C, --card=CARDNO\0A -f, --file=VPD.BIN\0A -d, --dump\09 use multiple d to increase dump info\0A -u, --update\09 set this flag for update VPD\0A -s, --show\09 set this flag to display VPD from a card\0A -v, --verbose verbose level, use multiple v's to increase\0A\0AThis utility updates the Genwqes FLASH with new VPD\0Ainformation from a *.bin file. Do not disconnect the card from power\0Awhile updating. Ensure you have the correct update\0Aimage. Use of incorrect images or interrupting the update\0Awill make the card unusable. In this case you need a\0AUSB-Blaster utility or similar to get it working again.\0A\0AExample flashing new vpd to GenWQE card:\0A %s -C0 -f vpd.bin\0AExample to display vpd from GenWQE card to stdout:\0A %s -C0 -s\0AExample to display and dump vpd from GenWQE card to stdout:\0A %s -C0 -s -d\0A\0A\00"
define void @usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i32, i32* @stdout
%4 = load i8*, i8** %2
%5 = load i8*, i8** %2
%6 = load i8*, i8** %2
%7 = load i8*, i8** %2
%8 = call i32 @fprintf(i32 %3, i8* getelementptr inbounds ([989 x i8], [989 x i8]* @.str, i64 0, i64 0), i8* %4, i8* %5, i8* %6, i8* %7)
ret void
}

LLVM IR (-O2):
@stdout = global i32 0
@.str = [989 x i8] c"Usage: %s [OPTIONS]...\0A\0AMandatory arguments to long options are mandatory for short options too.\0A -h, --help\09 print usage information\0A -V, --version print version\0A -C, --card=CARDNO\0A -f, --file=VPD.BIN\0A -d, --dump\09 use multiple d to increase dump info\0A -u, --update\09 set this flag for update VPD\0A -s, --show\09 set this flag to display VPD from a card\0A -v, --verbose verbose level, use multiple v's to increase\0A\0AThis utility updates the Genwqes FLASH with new VPD\0Ainformation from a *.bin file. Do not disconnect the card from power\0Awhile updating. Ensure you have the correct update\0Aimage. Use of incorrect images or interrupting the update\0Awill make the card unusable. In this case you need a\0AUSB-Blaster utility or similar to get it working again.\0A\0AExample flashing new vpd to GenWQE card:\0A %s -C0 -f vpd.bin\0AExample to display vpd from GenWQE card to stdout:\0A %s -C0 -s\0AExample to display and dump vpd from GenWQE card to stdout:\0A %s -C0 -s -d\0A\0A\00"
define void @usage(i8* %0) {
%2 = load i32, i32* @stdout
%3 = tail call i32 @fprintf(i32 %2, i8* getelementptr inbounds ([989 x i8], [989 x i8]* @.str, i64 0, i64 0), i8* %0, i8* %0, i8* %0, i8* %0)
ret void
}