#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 *, char *);
void usage(char **argv) {
  printf("Usage: %s -c <cpu> -b <BW [MB/s]> <operation type>\n"
         "Description:\n"
         "  -c, --cpu          cpu to generate B/W\n"
         "  -b, --bandwidth    memory B/W specified in MBps\n"
         "Operation types:\n"
         "  --prefetch-t0      prefetcht0\n"
         "  --prefetch-t1      prefetcht1\n"
         "  --prefetch-t2      prefetcht2\n"
         "  --prefetch-nta     prefetchtnta\n"
         "  --prefetch-w       prefetchw\n"
         "  --read             x86 loads\n"
         "  --read-sse         SSE loads\n"
         "  --nt-read-sse      SSE NT loads\n"
         "  --read-mod-write   x86 load XOR write\n"
         "  --write            x86 stores\n"
         "  --write-avx512     AVX512 stores\n"
         "  --write-clwb       x86 stores + clwb\n"
         "  --write-flush      x86 stores & clflush (naturally generates"
         " loads & stores)\n"
         "  --write-sse        SSE stores\n"
         "  --write-sse-flush  SSE stores & clflush (naturally generates "
         "loads & stores)\n"
         "  --nt-write         x86 NT stores\n"
         "  --nt-write-avx512  AVX512 NT stores\n"
         "  --nt-write-clwb    x86 NT stores + clwb\n"
         "  --nt-write-sse     SSE NT stores\n",
         argv[0]);
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%rsi
lea    0xed6(%rip),%rdi
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
mov    (%rdi),%rsi
lea    0xee6(%rip),%rdi
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [916 x i8] c"Usage: %s -c <cpu> -b <BW [MB/s]> <operation type>\0ADescription:\0A -c, --cpu cpu to generate B/W\0A -b, --bandwidth memory B/W specified in MBps\0AOperation types:\0A --prefetch-t0 prefetcht0\0A --prefetch-t1 prefetcht1\0A --prefetch-t2 prefetcht2\0A --prefetch-nta prefetchtnta\0A --prefetch-w prefetchw\0A --read x86 loads\0A --read-sse SSE loads\0A --nt-read-sse SSE NT loads\0A --read-mod-write x86 load XOR write\0A --write x86 stores\0A --write-avx512 AVX512 stores\0A --write-clwb x86 stores + clwb\0A --write-flush x86 stores & clflush (naturally generates loads & stores)\0A --write-sse SSE stores\0A --write-sse-flush SSE stores & clflush (naturally generates loads & stores)\0A --nt-write x86 NT stores\0A --nt-write-avx512 AVX512 NT stores\0A --nt-write-clwb x86 NT stores + clwb\0A --nt-write-sse SSE NT stores\0A\00"
define void @usage(i8** %0) {
%2 = alloca i8**
store i8** %0, i8*** %2
%3 = load i8**, i8*** %2
%4 = getelementptr inbounds i8*, i8** %3, i64 0
%5 = load i8*, i8** %4
%6 = call i32 @printf(i8* getelementptr inbounds ([916 x i8], [916 x i8]* @.str, i64 0, i64 0), i8* %5)
ret void
}

LLVM IR (-O2):
@.str = [916 x i8] c"Usage: %s -c <cpu> -b <BW [MB/s]> <operation type>\0ADescription:\0A -c, --cpu cpu to generate B/W\0A -b, --bandwidth memory B/W specified in MBps\0AOperation types:\0A --prefetch-t0 prefetcht0\0A --prefetch-t1 prefetcht1\0A --prefetch-t2 prefetcht2\0A --prefetch-nta prefetchtnta\0A --prefetch-w prefetchw\0A --read x86 loads\0A --read-sse SSE loads\0A --nt-read-sse SSE NT loads\0A --read-mod-write x86 load XOR write\0A --write x86 stores\0A --write-avx512 AVX512 stores\0A --write-clwb x86 stores + clwb\0A --write-flush x86 stores & clflush (naturally generates loads & stores)\0A --write-sse SSE stores\0A --write-sse-flush SSE stores & clflush (naturally generates loads & stores)\0A --nt-write x86 NT stores\0A --nt-write-avx512 AVX512 NT stores\0A --nt-write-clwb x86 NT stores + clwb\0A --nt-write-sse SSE NT stores\0A\00"
define void @usage(i8** nocapture %0) {
%2 = load i8*, i8** %0
%3 = tail call i32 @printf(i8* getelementptr inbounds ([916 x i8], [916 x i8]* @.str, i64 0, i64 0), i8* %2)
ret void
}