#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 *, ...);
int /*<<< orphan*/ stderr;
void usage(char **argv) {
  fprintf(stderr, "simple algorithm test bench\n");
  fprintf(stderr, "usage: %s [Options<default>]\n", argv[0]);
  fprintf(stderr, "\t\t-t number_of_threads<%d>\n", 10);
  fprintf(stderr, "\t\t-n number_of_items<%d>\n", 1000);
  fprintf(stderr, "\t\t-v               :verbose\n");
  fprintf(stderr, "\t\t-V               :debug mode\n");
  fprintf(stderr, "\t\t-h               :help\n");
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    0x2ebd(%rip),%rax
mov    (%rax),%edi
lea    0xed4(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2ea6(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rax
mov    (%rax),%rdx
lea    0xed3(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e88(%rip),%rax
mov    (%rax),%edi
lea    0xeda(%rip),%rsi
mov    $0xa,%edx
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e6c(%rip),%rax
mov    (%rax),%edi
lea    0xeda(%rip),%rsi
mov    $0x3e8,%edx
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e50(%rip),%rax
mov    (%rax),%edi
lea    0xed8(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e39(%rip),%rax
mov    (%rax),%edi
lea    0xede(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e22(%rip),%rax
mov    (%rax),%edi
lea    0xee7(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
push   %r14
push   %rbx
push   %rax
mov    %rdi,%rbx
mov    0x2ec2(%rip),%r14
mov    (%r14),%edi
lea    0xed8(%rip),%rsi
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
mov    (%rbx),%rdx
lea    0xee1(%rip),%rsi
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0xeee(%rip),%rsi
mov    $0xa,%edx
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0xef4(%rip),%rsi
mov    $0x3e8,%edx
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0xef8(%rip),%rsi
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0xf04(%rip),%rsi
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r14),%edi
lea    0xf13(%rip),%rsi
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [29 x i8] c"simple algorithm test bench\0A\00"
@.str.1 = [30 x i8] c"usage: %s [Options<default>]\0A\00"
@.str.2 = [28 x i8] c"\09\09-t number_of_threads<%d>\0A\00"
@.str.3 = [26 x i8] c"\09\09-n number_of_items<%d>\0A\00"
@.str.4 = [29 x i8] c"\09\09-v :verbose\0A\00"
@.str.5 = [32 x i8] c"\09\09-V :debug mode\0A\00"
@.str.6 = [26 x i8] c"\09\09-h :help\0A\00"
define void @usage(i8** %0) {
%2 = alloca i8**
store i8** %0, i8*** %2
%3 = load i32, i32* @stderr
%4 = call i32 (i32, i8*, ...) @fprintf(i32 %3, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0))
%5 = load i32, i32* @stderr
%6 = load i8**, i8*** %2
%7 = getelementptr inbounds i8*, i8** %6, i64 0
%8 = load i8*, i8** %7
%9 = call i32 (i32, i8*, ...) @fprintf(i32 %5, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.1, i64 0, i64 0), i8* %8)
%10 = load i32, i32* @stderr
%11 = call i32 (i32, i8*, ...) @fprintf(i32 %10, i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.2, i64 0, i64 0), i32 10)
%12 = load i32, i32* @stderr
%13 = call i32 (i32, i8*, ...) @fprintf(i32 %12, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.3, i64 0, i64 0), i32 1000)
%14 = load i32, i32* @stderr
%15 = call i32 (i32, i8*, ...) @fprintf(i32 %14, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.4, i64 0, i64 0))
%16 = load i32, i32* @stderr
%17 = call i32 (i32, i8*, ...) @fprintf(i32 %16, i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.5, i64 0, i64 0))
%18 = load i32, i32* @stderr
%19 = call i32 (i32, i8*, ...) @fprintf(i32 %18, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.6, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [29 x i8] c"simple algorithm test bench\0A\00"
@.str.1 = [30 x i8] c"usage: %s [Options<default>]\0A\00"
@.str.2 = [28 x i8] c"\09\09-t number_of_threads<%d>\0A\00"
@.str.3 = [26 x i8] c"\09\09-n number_of_items<%d>\0A\00"
@.str.4 = [29 x i8] c"\09\09-v :verbose\0A\00"
@.str.5 = [32 x i8] c"\09\09-V :debug mode\0A\00"
@.str.6 = [26 x i8] c"\09\09-h :help\0A\00"
define void @usage(i8** nocapture %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 (i32, i8*, ...) @fprintf(i32 %2, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0))
%4 = load i32, i32* @stderr
%5 = load i8*, i8** %0
%6 = tail call i32 (i32, i8*, ...) @fprintf(i32 %4, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.1, i64 0, i64 0), i8* %5)
%7 = load i32, i32* @stderr
%8 = tail call i32 (i32, i8*, ...) @fprintf(i32 %7, i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.2, i64 0, i64 0), i32 10)
%9 = load i32, i32* @stderr
%10 = tail call i32 (i32, i8*, ...) @fprintf(i32 %9, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.3, i64 0, i64 0), i32 1000)
%11 = load i32, i32* @stderr
%12 = tail call i32 (i32, i8*, ...) @fprintf(i32 %11, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.4, i64 0, i64 0))
%13 = load i32, i32* @stderr
%14 = tail call i32 (i32, i8*, ...) @fprintf(i32 %13, i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.5, i64 0, i64 0))
%15 = load i32, i32* @stderr
%16 = tail call i32 (i32, i8*, ...) @fprintf(i32 %15, i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.6, i64 0, i64 0))
ret void
}