#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(void) {
  printf("Usage: rwmsr [-h | --help] [-V | --version]\n"
         "       rwmsr [-v] [-s <system>] [-p <paths>] [-c <cores>] "
         "<commands...>\n"
         "Read and write Machine Specific Registers.\n"
         "Allow the user to read and write MSRs instantly or "
         "perdiodically throught a set\n"
         "of commands. Each command is in the following form:\n"
         "\n"
         "  commands ::= [':'[':']] <address> ['=' <value] ['@' <delay> "
         "['-' <repeat>]]\n"
         "\n");
  printf("The <address> is the MSR address and the optional <value> is "
         "what to write in\n"
         "the MSR if specified. For more informations about MSR "
         "addresses and values they\n"
         "can contain, please refer to the constructor documentation.\n"
         "Both <address> and <value> can be specified either in decimal "
         "form, or in\n");
  printf("hexadecimal form. In the last case, they should start with "
         "'0x' or 'x'.\n"
         "\n"
         "The leading ':' or '::' optional characters indicate if the "
         "value of the\n"
         "register should be printed. ':' indicates to print it in "
         "decimal form whereas\n"
         "'::' indicates hexadecimal form is required.\n"
         "\n");
  printf("The optional <delay> value is an amount of millisecond to "
         "wait before to\n"
         "actually execute the command. This can be usefull for MSR "
         "multiplexing.\n"
         "Finally the <repeat> value is another amout of millisecond to "
         "wait between to\n"
         "execute the command again. When this value is specified, the "
         "command is\n"
         "executed periodically until the user kills the program.\n"
         "\n"
         "\n");
  printf("By default, the MSR of the current core are used. This "
         "behavior can be changed\n"
         "with the '-c' (or '--cores') option. It indicates the set of "
         "core on which to\n"
         "execute the commands. The option value takes the following "
         "form:\n"
         "\n"
         "  cores ::= <id> [',' <cores>]\n"
         "            <id> '-' <id> [',' <cores>]\n"
         "\n");
  printf("An <id> is simply the core number as specified by the "
         "underlying system.\n"
         "Multiple ids can be specified and separated by commas, and "
         "ranges of ids can\n"
         "be specified with hyphens. Additionally, the '--cores' "
         "options can be specified\n"
         "several times.\n"
         "\n"
         "\n");
  printf("This program can run on multiple systems. Currently, it can "
         "work under\n"
         "bare-metal GNU/Linux (codename 'linux'), or under Xen "
         "vritualized GNU/Linux\n"
         "(codename 'xen'). The program should be able to detect "
         "automatically which is\n"
         "the current system, but user can override this with the '-s' "
         "(or '--system')\n"
         "option.\n"
         "\n");
  printf("Once the system has been detected (or provided), the program "
         "searches an\n"
         "appropriate module to communicate with the system. For this, "
         "it tries all files\n"
         "in an internal path list. By default, this list only contains "
         "the '.' path.\n"
         "More paths can be specified either with the '-p' "
         "(or '--path') option, or with\n"
         "the RWMSR_PATH environment variable.\n");
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
call   1030 <printf@plt>
lea    0x104d(%rip),%rdi
call   1030 <printf@plt>
lea    0x1166(%rip),%rdi
call   1030 <printf@plt>
lea    0x1269(%rip),%rdi
call   1030 <printf@plt>
lea    0x13bf(%rip),%rdi
call   1030 <printf@plt>
lea    0x14db(%rip),%rdi
call   1030 <printf@plt>
lea    0x15c7(%rip),%rdi
call   1030 <printf@plt>
lea    0x16f3(%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    0x104f(%rip),%rdi
call   1030 <puts@plt>
lea    0x1167(%rip),%rdi
call   1030 <puts@plt>
lea    0x1269(%rip),%rdi
call   1030 <puts@plt>
lea    0x13be(%rip),%rdi
call   1030 <puts@plt>
lea    0x14d9(%rip),%rdi
call   1030 <puts@plt>
lea    0x15c4(%rip),%rdi
call   1030 <puts@plt>
lea    0x16ef(%rip),%rdi
pop    %rax
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [372 x i8] c"Usage: rwmsr [-h | --help] [-V | --version]\0A rwmsr [-v] [-s <system>] [-p <paths>] [-c <cores>] <commands...>\0ARead and write Machine Specific Registers.\0AAllow the user to read and write MSRs instantly or perdiodically throught a set\0Aof commands. Each command is in the following form:\0A\0A commands ::= [':'[':']] <address> ['=' <value] ['@' <delay> ['-' <repeat>]]\0A\0A\00"
@.str.1 = [293 x i8] c"The <address> is the MSR address and the optional <value> is what to write in\0Athe MSR if specified. For more informations about MSR addresses and values they\0Acan contain, please refer to the constructor documentation.\0ABoth <address> and <value> can be specified either in decimal form, or in\0A\00"
@.str.2 = [271 x i8] c"hexadecimal form. In the last case, they should start with '0x' or 'x'.\0A\0AThe leading ':' or '::' optional characters indicate if the value of the\0Aregister should be printed. ':' indicates to print it in decimal form whereas\0A'::' indicates hexadecimal form is required.\0A\0A\00"
@.str.3 = [354 x i8] c"The optional <delay> value is an amount of millisecond to wait before to\0Aactually execute the command. This can be usefull for MSR multiplexing.\0AFinally the <repeat> value is another amout of millisecond to wait between to\0Aexecute the command again. When this value is specified, the command is\0Aexecuted periodically until the user kills the program.\0A\0A\0A\00"
@.str.4 = [296 x i8] c"By default, the MSR of the current core are used. This behavior can be changed\0Awith the '-c' (or '--cores') option. It indicates the set of core on which to\0Aexecute the commands. The option value takes the following form:\0A\0A cores ::= <id> [',' <cores>]\0A <id> '-' <id> [',' <cores>]\0A\0A\00"
@.str.5 = [248 x i8] c"An <id> is simply the core number as specified by the underlying system.\0AMultiple ids can be specified and separated by commas, and ranges of ids can\0Abe specified with hyphens. Additionally, the '--cores' options can be specified\0Aseveral times.\0A\0A\0A\00"
@.str.6 = [312 x i8] c"This program can run on multiple systems. Currently, it can work under\0Abare-metal GNU/Linux (codename 'linux'), or under Xen vritualized GNU/Linux\0A(codename 'xen'). The program should be able to detect automatically which is\0Athe current system, but user can override this with the '-s' (or '--system')\0Aoption.\0A\0A\00"
@.str.7 = [346 x i8] c"Once the system has been detected (or provided), the program searches an\0Aappropriate module to communicate with the system. For this, it tries all files\0Ain an internal path list. By default, this list only contains the '.' path.\0AMore paths can be specified either with the '-p' (or '--path') option, or with\0Athe RWMSR_PATH environment variable.\0A\00"
define void @usage() {
%1 = call i32 @printf(i8* getelementptr inbounds ([372 x i8], [372 x i8]* @.str, i64 0, i64 0))
%2 = call i32 @printf(i8* getelementptr inbounds ([293 x i8], [293 x i8]* @.str.1, i64 0, i64 0))
%3 = call i32 @printf(i8* getelementptr inbounds ([271 x i8], [271 x i8]* @.str.2, i64 0, i64 0))
%4 = call i32 @printf(i8* getelementptr inbounds ([354 x i8], [354 x i8]* @.str.3, i64 0, i64 0))
%5 = call i32 @printf(i8* getelementptr inbounds ([296 x i8], [296 x i8]* @.str.4, i64 0, i64 0))
%6 = call i32 @printf(i8* getelementptr inbounds ([248 x i8], [248 x i8]* @.str.5, i64 0, i64 0))
%7 = call i32 @printf(i8* getelementptr inbounds ([312 x i8], [312 x i8]* @.str.6, i64 0, i64 0))
%8 = call i32 @printf(i8* getelementptr inbounds ([346 x i8], [346 x i8]* @.str.7, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [371 x i8] c"Usage: rwmsr [-h | --help] [-V | --version]\0A rwmsr [-v] [-s <system>] [-p <paths>] [-c <cores>] <commands...>\0ARead and write Machine Specific Registers.\0AAllow the user to read and write MSRs instantly or perdiodically throught a set\0Aof commands. Each command is in the following form:\0A\0A commands ::= [':'[':']] <address> ['=' <value] ['@' <delay> ['-' <repeat>]]\0A\00"
@str.8 = [292 x i8] c"The <address> is the MSR address and the optional <value> is what to write in\0Athe MSR if specified. For more informations about MSR addresses and values they\0Acan contain, please refer to the constructor documentation.\0ABoth <address> and <value> can be specified either in decimal form, or in\00"
@str.9 = [270 x i8] c"hexadecimal form. In the last case, they should start with '0x' or 'x'.\0A\0AThe leading ':' or '::' optional characters indicate if the value of the\0Aregister should be printed. ':' indicates to print it in decimal form whereas\0A'::' indicates hexadecimal form is required.\0A\00"
@str.10 = [353 x i8] c"The optional <delay> value is an amount of millisecond to wait before to\0Aactually execute the command. This can be usefull for MSR multiplexing.\0AFinally the <repeat> value is another amout of millisecond to wait between to\0Aexecute the command again. When this value is specified, the command is\0Aexecuted periodically until the user kills the program.\0A\0A\00"
@str.11 = [295 x i8] c"By default, the MSR of the current core are used. This behavior can be changed\0Awith the '-c' (or '--cores') option. It indicates the set of core on which to\0Aexecute the commands. The option value takes the following form:\0A\0A cores ::= <id> [',' <cores>]\0A <id> '-' <id> [',' <cores>]\0A\00"
@str.12 = [247 x i8] c"An <id> is simply the core number as specified by the underlying system.\0AMultiple ids can be specified and separated by commas, and ranges of ids can\0Abe specified with hyphens. Additionally, the '--cores' options can be specified\0Aseveral times.\0A\0A\00"
@str.13 = [311 x i8] c"This program can run on multiple systems. Currently, it can work under\0Abare-metal GNU/Linux (codename 'linux'), or under Xen vritualized GNU/Linux\0A(codename 'xen'). The program should be able to detect automatically which is\0Athe current system, but user can override this with the '-s' (or '--system')\0Aoption.\0A\00"
@str.14 = [345 x i8] c"Once the system has been detected (or provided), the program searches an\0Aappropriate module to communicate with the system. For this, it tries all files\0Ain an internal path list. By default, this list only contains the '.' path.\0AMore paths can be specified either with the '-p' (or '--path') option, or with\0Athe RWMSR_PATH environment variable.\00"
define void @usage() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([371 x i8], [371 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([292 x i8], [292 x i8]* @str.8, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([270 x i8], [270 x i8]* @str.9, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([353 x i8], [353 x i8]* @str.10, i64 0, i64 0))
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([295 x i8], [295 x i8]* @str.11, i64 0, i64 0))
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([247 x i8], [247 x i8]* @str.12, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([311 x i8], [311 x i8]* @str.13, i64 0, i64 0))
%8 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([345 x i8], [345 x i8]* @str.14, i64 0, i64 0))
ret void
}