#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);
int /*<<< orphan*/ puts(char *);
void usage(void) {
  puts(("usage: rdev [ -rv ] [ -o OFFSET ] [ IMAGE [ VALUE [ OFFSET ] ] ]"));
  puts(("  rdev /dev/fd0  (or rdev /linux, etc.) displays the current ROOT "
        "device"));
  puts(("  rdev /dev/fd0 /dev/hda2         sets ROOT to /dev/hda2"));
  puts((
      "  rdev -R /dev/fd0 1              set the ROOTFLAGS (readonly status)"));
  puts(("  rdev -r /dev/fd0 627            set the RAMDISK size"));
  puts(("  rdev -v /dev/fd0 1              set the bootup VIDEOMODE"));
  puts(("  rdev -o N ...                   use the byte offset N"));
  puts(("  rootflags ...                   same as rdev -R"));
  puts(("  ramsize ...                     same as rdev -r"));
  puts(("  vidmode ...                     same as rdev -v"));
  puts(("Note: video modes are: -3=Ask, -2=Extended, -1=NormalVga, 1=key1, "
        "2=key2,..."));
  puts(("      use -R 1 to mount root readonly, -R 0 for read/write."));
  exit(-1);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
lea    0xed5(%rip),%rdi
call   1030 <puts@plt>
lea    0xf0a(%rip),%rdi
call   1030 <puts@plt>
lea    0xf47(%rip),%rdi
call   1030 <puts@plt>
lea    0xf74(%rip),%rdi
call   1030 <puts@plt>
lea    0xfae(%rip),%rdi
call   1030 <puts@plt>
lea    0xfd9(%rip),%rdi
call   1030 <puts@plt>
lea    0x1008(%rip),%rdi
call   1030 <puts@plt>
lea    0x1034(%rip),%rdi
call   1030 <puts@plt>
lea    0x105a(%rip),%rdi
call   1030 <puts@plt>
lea    0x1080(%rip),%rdi
call   1030 <puts@plt>
lea    0x10a6(%rip),%rdi
call   1030 <puts@plt>
lea    0x10e7(%rip),%rdi
call   1030 <puts@plt>
mov    $0xffffffff,%edi
call   1040 <exit@plt>

x86 assembly (clang, -O2):
<usage>:
push   %rax
lea    0xed8(%rip),%rdi
call   1030 <puts@plt>
lea    0xf0d(%rip),%rdi
call   1030 <puts@plt>
lea    0xf4a(%rip),%rdi
call   1030 <puts@plt>
lea    0xf77(%rip),%rdi
call   1030 <puts@plt>
lea    0xfb1(%rip),%rdi
call   1030 <puts@plt>
lea    0xfdc(%rip),%rdi
call   1030 <puts@plt>
lea    0x100b(%rip),%rdi
call   1030 <puts@plt>
lea    0x1037(%rip),%rdi
call   1030 <puts@plt>
lea    0x105d(%rip),%rdi
call   1030 <puts@plt>
lea    0x1083(%rip),%rdi
call   1030 <puts@plt>
lea    0x10a9(%rip),%rdi
call   1030 <puts@plt>
lea    0x10ea(%rip),%rdi
call   1030 <puts@plt>
mov    $0xffffffff,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@.str = [65 x i8] c"usage: rdev [ -rv ] [ -o OFFSET ] [ IMAGE [ VALUE [ OFFSET ] ] ]\00"
@.str.1 = [73 x i8] c" rdev /dev/fd0 (or rdev /linux, etc.) displays the current ROOT device\00"
@.str.2 = [57 x i8] c" rdev /dev/fd0 /dev/hda2 sets ROOT to /dev/hda2\00"
@.str.3 = [70 x i8] c" rdev -R /dev/fd0 1 set the ROOTFLAGS (readonly status)\00"
@.str.4 = [55 x i8] c" rdev -r /dev/fd0 627 set the RAMDISK size\00"
@.str.5 = [59 x i8] c" rdev -v /dev/fd0 1 set the bootup VIDEOMODE\00"
@.str.6 = [56 x i8] c" rdev -o N ... use the byte offset N\00"
@.str.7 = [50 x i8] c" rootflags ... same as rdev -R\00"
@.str.8 = [50 x i8] c" ramsize ... same as rdev -r\00"
@.str.9 = [50 x i8] c" vidmode ... same as rdev -v\00"
@.str.10 = [77 x i8] c"Note: video modes are: -3=Ask, -2=Extended, -1=NormalVga, 1=key1, 2=key2,...\00"
@.str.11 = [60 x i8] c" use -R 1 to mount root, -R 0 for read/write.\00"
define void @usage() {
%1 = call i32 @puts(i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @puts(i8* getelementptr inbounds ([73 x i8], [73 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 @puts(i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str.2, i64 0, i64 0))
%4 = call i32 @puts(i8* getelementptr inbounds ([70 x i8], [70 x i8]* @.str.3, i64 0, i64 0))
%5 = call i32 @puts(i8* getelementptr inbounds ([55 x i8], [55 x i8]* @.str.4, i64 0, i64 0))
%6 = call i32 @puts(i8* getelementptr inbounds ([59 x i8], [59 x i8]* @.str.5, i64 0, i64 0))
%7 = call i32 @puts(i8* getelementptr inbounds ([56 x i8], [56 x i8]* @.str.6, i64 0, i64 0))
%8 = call i32 @puts(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.7, i64 0, i64 0))
%9 = call i32 @puts(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.8, i64 0, i64 0))
%10 = call i32 @puts(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.9, i64 0, i64 0))
%11 = call i32 @puts(i8* getelementptr inbounds ([77 x i8], [77 x i8]* @.str.10, i64 0, i64 0))
%12 = call i32 @puts(i8* getelementptr inbounds ([60 x i8], [60 x i8]* @.str.11, i64 0, i64 0))
%13 = call i32 @exit(i32 -1)
unreachable
}

LLVM IR (-O2):
@.str = [65 x i8] c"usage: rdev [ -rv ] [ -o OFFSET ] [ IMAGE [ VALUE [ OFFSET ] ] ]\00"
@.str.1 = [73 x i8] c" rdev /dev/fd0 (or rdev /linux, etc.) displays the current ROOT device\00"
@.str.2 = [57 x i8] c" rdev /dev/fd0 /dev/hda2 sets ROOT to /dev/hda2\00"
@.str.3 = [70 x i8] c" rdev -R /dev/fd0 1 set the ROOTFLAGS (readonly status)\00"
@.str.4 = [55 x i8] c" rdev -r /dev/fd0 627 set the RAMDISK size\00"
@.str.5 = [59 x i8] c" rdev -v /dev/fd0 1 set the bootup VIDEOMODE\00"
@.str.6 = [56 x i8] c" rdev -o N ... use the byte offset N\00"
@.str.7 = [50 x i8] c" rootflags ... same as rdev -R\00"
@.str.8 = [50 x i8] c" ramsize ... same as rdev -r\00"
@.str.9 = [50 x i8] c" vidmode ... same as rdev -v\00"
@.str.10 = [77 x i8] c"Note: video modes are: -3=Ask, -2=Extended, -1=NormalVga, 1=key1, 2=key2,...\00"
@.str.11 = [60 x i8] c" use -R 1 to mount root, -R 0 for read/write.\00"
define void @usage() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([65 x i8], [65 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([73 x i8], [73 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([57 x i8], [57 x i8]* @.str.2, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([70 x i8], [70 x i8]* @.str.3, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([55 x i8], [55 x i8]* @.str.4, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([59 x i8], [59 x i8]* @.str.5, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([56 x i8], [56 x i8]* @.str.6, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([50 x i8], [50 x i8]* @.str.7, i64 0, i64 0))
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([50 x i8], [50 x i8]* @.str.8, i64 0, i64 0))
%10 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([50 x i8], [50 x i8]* @.str.9, i64 0, i64 0))
%11 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([77 x i8], [77 x i8]* @.str.10, i64 0, i64 0))
%12 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([60 x i8], [60 x i8]* @.str.11, i64 0, i64 0))
%13 = tail call i32 @exit(i32 -1)
unreachable
}