#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*/ printf(char *);
void usage() {
  printf("Usage: sg_modes [--all] [--control=PC] [--dbd] [--dbout] "
         "[--examine]\n"
         "                [--flexible] [--help] [--hex] [--list] "
         "[--llbaa]\n"
         "                [--maxlen=LEN] [--page=PG[,SPG]] [--raw] [-R] "
         "[--six]\n"
         "                [--verbose] [--version] [DEVICE]\n"
         "  where:\n"
         "    --all|-a        get all mode pages supported by device\n"
         "                    use twice to get all mode pages and subpages\n"
         "    --control=PC|-c PC    page control (default: 0)\n"
         "                       0: current, 1: changeable,\n"
         "                       2: (manufacturer's) defaults, "
         "3: saved\n"
         "    --dbd|-d        disable block descriptors (DBD field in cdb)\n"
         "    --dbout|-D      disable block descriptor output\n"
         "    --examine|-e    examine pages # 0 through to 0x3e, note if "
         "found\n"
         "    --flexible|-f    be flexible, cope with MODE SENSE 6/10 "
         "response mixup\n");
  printf("    --help|-h       print usage message then exit\n"
         "    --hex|-H        output full response in hex\n"
         "                    use twice to output page number and header "
         "in hex\n"
         "    --list|-l       list common page codes for device peripheral "
         "type,\n"
         "                    if no device given then assume disk type\n"
         "    --llbaa|-L      set Long LBA Accepted (LLBAA field in mode "
         "sense (10) cdb)\n"
         "    --maxlen=LEN|-m LEN    max response length (allocation "
         "length in cdb)\n"
         "                           (def: 0 -> 4096 or 252 (for MODE SENSE 6) "
         "bytes)\n"
         "    --page=PG|-p PG    page code to fetch (def: 63)\n"
         "    --page=PG,SPG|-p PG,SPG\n"
         "                       page code and subpage code to fetch "
         "(defs: 63,0)\n"
         "    --raw|-r        output response in binary to stdout\n"
         "    -R              mode page response to stdout, a byte per "
         "line in ASCII\n"
         "                    hex (same result as '--raw --raw')\n"
         "    --six|-6        use MODE SENSE(6), by default uses MODE "
         "SENSE(10)\n"
         "    --verbose|-v    increase verbosity\n"
         "    --version|-V    output version string then exit\n\n"
         "Performs a SCSI MODE SENSE (10 or 6) command\n");
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
call   1030 <printf@plt>
lea    0x1205(%rip),%rdi
call   1030 <printf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
push   %rax
lea    0xee8(%rip),%rdi
call   1030 <puts@plt>
lea    0x1207(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [812 x i8] c"Usage: sg_modes [--all] [--control=PC] [--dbd] [--dbout] [--examine]\0A [--flexible] [--help] [--hex] [--list] [--llbaa]\0A [--maxlen=LEN] [--page=PG[,SPG]] [--raw] [-R] [--six]\0A [--verbose] [--version] [DEVICE]\0A where:\0A --all|-a get all mode pages supported by device\0A use twice to get all mode pages and subpages\0A --control=PC|-c PC page control (default: 0)\0A 0: current, 1: changeable,\0A 2: (manufacturer's) defaults, 3: saved\0A --dbd|-d disable block descriptors (DBD field in cdb)\0A --dbout|-D disable block descriptor output\0A --examine|-e examine pages # 0 through to 0x3e, note if found\0A --flexible|-f be flexible, cope with MODE SENSE 6/10 response mixup\0A\00"
@.str.1 = [1075 x i8] c" --help|-h print usage message then exit\0A --hex|-H output full response in hex\0A use twice to output page number and header in hex\0A --list|-l list common page codes for device peripheral type,\0A if no device given then assume disk type\0A --llbaa|-L set Long LBA Accepted (LLBAA field in mode sense (10) cdb)\0A --maxlen=LEN|-m LEN max response length (allocation length in cdb)\0A (def: 0 -> 4096 or 252 (for MODE SENSE 6) bytes)\0A --page=PG|-p PG page code to fetch (def: 63)\0A --page=PG,SPG|-p PG,SPG\0A page code and subpage code to fetch (defs: 63,0)\0A --raw|-r output response in binary to stdout\0A -R mode page response to stdout, a byte per line in ASCII\0A hex (same result as '--raw --raw')\0A --six|-6 use MODE SENSE(6), by default uses MODE SENSE(10)\0A --verbose|-v increase verbosity\0A --version|-V output version string then exit\0A\0APerforms a SCSI MODE SENSE (10 or 6) command\0A\00"
define void @usage() {
%1 = call i32 @printf(i8* getelementptr inbounds ([812 x i8], [812 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @printf(i8* getelementptr inbounds ([1075 x i8], [1075 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [811 x i8] c"Usage: sg_modes [--all] [--control=PC] [--dbd] [--dbout] [--examine]\0A [--flexible] [--help] [--hex] [--list] [--llbaa]\0A [--maxlen=LEN] [--page=PG[,SPG]] [--raw] [-R] [--six]\0A [--verbose] [--version] [DEVICE]\0A where:\0A --all|-a get all mode pages supported by device\0A use twice to get all mode pages and subpages\0A --control=PC|-c PC page control (default: 0)\0A 0: current, 1: changeable,\0A 2: (manufacturer's) defaults, 3: saved\0A --dbd|-d disable block descriptors (DBD field in cdb)\0A --dbout|-D disable block descriptor output\0A --examine|-e examine pages # 0 through to 0x3e, note if found\0A --flexible|-f be flexible, cope with MODE SENSE 6/10 response mixup\00"
@str.2 = [1074 x i8] c" --help|-h print usage message then exit\0A --hex|-H output full response in hex\0A use twice to output page number and header in hex\0A --list|-l list common page codes for device peripheral type,\0A if no device given then assume disk type\0A --llbaa|-L set Long LBA Accepted (LLBAA field in mode sense (10) cdb)\0A --maxlen=LEN|-m LEN max response length (allocation length in cdb)\0A (def: 0 -> 4096 or 252 (for MODE SENSE 6) bytes)\0A --page=PG|-p PG page code to fetch (def: 63)\0A --page=PG,SPG|-p PG,SPG\0A page code and subpage code to fetch (defs: 63,0)\0A --raw|-r output response in binary to stdout\0A -R mode page response to stdout, a byte per line in ASCII\0A hex (same result as '--raw --raw')\0A --six|-6 use MODE SENSE(6), by default uses MODE SENSE(10)\0A --verbose|-v increase verbosity\0A --version|-V output version string then exit\0A\0APerforms a SCSI MODE SENSE (10 or 6) command\00"
define void @usage() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([811 x i8], [811 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([1074 x i8], [1074 x i8]* @str.2, i64 0, i64 0))
ret void
}