#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 *a) {
  fprintf(stderr,
          "\nusage: %s [-b <block size>] [-r <rate>] { [-c <count>] %s | [-s] "
          "%s } <filename>\n\n",
          a, "split_input", "split_output");
  fprintf(stderr,
          "- in %s mode, the data sent to %s's input is copied to the given "
          "filename\n  which may possibly be a non permanent output (retrying "
          "to write in case of failure)\n",
          "split_output", a);
  fprintf(stderr,
          "- in %s mode, the data is read from the given filename which may "
          "possibly\n  be non permanent input (retrying to read in case of "
          "failure) and copied to\n  %s's output\n",
          "split_input", a);
  fprintf(stderr,
          "\nThe -s option for %s mode leads %s to make SYNC writes, this "
          "avoid\n  operating system's caching to wrongly report a write as "
          "successful. This flag\n  reduces write performances but may be "
          "necessary when the end of tape is not\n  properly detected by %s\n",
          "split_output", a, a);
  fprintf(stderr, "With -b option the amount of bytes sent per read or write "
                  "system call does\n  not exceed this amount in byte\n");
  fprintf(
      stderr,
      "With -r option the transfer is limited to the given byte/second rate\n");
  fprintf(stderr, "With -c option dar_split will assume there is at most "
                  "<count> tape and not ask\n   for further \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
mov    -0x8(%rbp),%rdx
lea    0xed0(%rip),%rsi
lea    0xf1d(%rip),%rcx
lea    0xf22(%rip),%r8
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e94(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rcx
lea    0xf14(%rip),%rsi
lea    0xf00(%rip),%rdx
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e72(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rcx
lea    0xf93(%rip),%rsi
lea    0xed2(%rip),%rdx
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e50(%rip),%rax
mov    (%rax),%edi
mov    -0x8(%rbp),%rcx
mov    -0x8(%rbp),%r8
lea    0x1013(%rip),%rsi
lea    0xeb8(%rip),%rdx
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e2a(%rip),%rax
mov    (%rax),%edi
lea    0x10f2(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2e13(%rip),%rax
mov    (%rax),%edi
lea    0x1148(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    0x2dfc(%rip),%rax
mov    (%rax),%edi
lea    0x1177(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
mov    %rdi,%rbx
mov    0x2ebe(%rip),%r12
mov    (%r12),%edi
lea    0xed3(%rip),%rsi
lea    0xf20(%rip),%r15
lea    0xf25(%rip),%r14
mov    %rbx,%rdx
mov    %r15,%rcx
mov    %r14,%r8
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r12),%edi
lea    0xf17(%rip),%rsi
mov    %r14,%rdx
mov    %rbx,%rcx
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r12),%edi
lea    0xfa0(%rip),%rsi
mov    %r15,%rdx
mov    %rbx,%rcx
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r12),%edi
lea    0x102e(%rip),%rsi
mov    %r14,%rdx
mov    %rbx,%rcx
mov    %rbx,%r8
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r12),%edi
lea    0x1110(%rip),%rsi
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r12),%edi
lea    0x116b(%rip),%rsi
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    (%r12),%edi
lea    0x119f(%rip),%rsi
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [84 x i8] c"\0Ausage: %s [-b <block size>] [-r <rate>] { [-c <count>] %s | [-s] %s } <filename>\0A\0A\00"
@.str.1 = [12 x i8] c"split_input\00"
@.str.2 = [13 x i8] c"split_output\00"
@.str.3 = [161 x i8] c"- in %s mode, the data sent to %s's input is copied to the given filename\0A which may possibly be a non permanent output (retrying to write in case of failure)\0A\00"
@.str.4 = [166 x i8] c"- in %s mode, the data is read from the given filename which may possibly\0A be non permanent input (retrying to read in case of failure) and copied to\0A %s's output\0A\00"
@.str.5 = [253 x i8] c"\0AThe -s option for %s mode leads %s to make SYNC writes, this avoid\0A operating system's caching to wrongly report a write as successful. This flag\0A reduces write performances but may be necessary when the end of tape is not\0A properly detected by %s\0A\00"
@.str.6 = [109 x i8] c"With -b option the amount of bytes sent per read or write system call does\0A not exceed this amount in byte\0A\00"
@.str.7 = [70 x i8] c"With -r option the transfer is limited to the given byte/second rate\0A\00"
@.str.8 = [96 x i8] c"With -c option dar_split will assume there is at most <count> tape and not ask\0A for further \0A\00"
define void @usage(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i32, i32* @stderr
%4 = load i8*, i8** %2
%5 = call i32 (i32, i8*, ...) @fprintf(i32 %3, i8* getelementptr inbounds ([84 x i8], [84 x i8]* @.str, i64 0, i64 0), i8* %4, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0))
%6 = load i32, i32* @stderr
%7 = load i8*, i8** %2
%8 = call i32 (i32, i8*, ...) @fprintf(i32 %6, i8* getelementptr inbounds ([161 x i8], [161 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i8* %7)
%9 = load i32, i32* @stderr
%10 = load i8*, i8** %2
%11 = call i32 (i32, i8*, ...) @fprintf(i32 %9, i8* getelementptr inbounds ([166 x i8], [166 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i8* %10)
%12 = load i32, i32* @stderr
%13 = load i8*, i8** %2
%14 = load i8*, i8** %2
%15 = call i32 (i32, i8*, ...) @fprintf(i32 %12, i8* getelementptr inbounds ([253 x i8], [253 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i8* %13, i8* %14)
%16 = load i32, i32* @stderr
%17 = call i32 (i32, i8*, ...) @fprintf(i32 %16, i8* getelementptr inbounds ([109 x i8], [109 x i8]* @.str.6, i64 0, i64 0))
%18 = load i32, i32* @stderr
%19 = call i32 (i32, i8*, ...) @fprintf(i32 %18, i8* getelementptr inbounds ([70 x i8], [70 x i8]* @.str.7, i64 0, i64 0))
%20 = load i32, i32* @stderr
%21 = call i32 (i32, i8*, ...) @fprintf(i32 %20, i8* getelementptr inbounds ([96 x i8], [96 x i8]* @.str.8, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [84 x i8] c"\0Ausage: %s [-b <block size>] [-r <rate>] { [-c <count>] %s | [-s] %s } <filename>\0A\0A\00"
@.str.1 = [12 x i8] c"split_input\00"
@.str.2 = [13 x i8] c"split_output\00"
@.str.3 = [161 x i8] c"- in %s mode, the data sent to %s's input is copied to the given filename\0A which may possibly be a non permanent output (retrying to write in case of failure)\0A\00"
@.str.4 = [166 x i8] c"- in %s mode, the data is read from the given filename which may possibly\0A be non permanent input (retrying to read in case of failure) and copied to\0A %s's output\0A\00"
@.str.5 = [253 x i8] c"\0AThe -s option for %s mode leads %s to make SYNC writes, this avoid\0A operating system's caching to wrongly report a write as successful. This flag\0A reduces write performances but may be necessary when the end of tape is not\0A properly detected by %s\0A\00"
@.str.6 = [109 x i8] c"With -b option the amount of bytes sent per read or write system call does\0A not exceed this amount in byte\0A\00"
@.str.7 = [70 x i8] c"With -r option the transfer is limited to the given byte/second rate\0A\00"
@.str.8 = [96 x i8] c"With -c option dar_split will assume there is at most <count> tape and not ask\0A for further \0A\00"
define void @usage(i8* %0) {
%2 = load i32, i32* @stderr
%3 = tail call i32 (i32, i8*, ...) @fprintf(i32 %2, i8* getelementptr inbounds ([84 x i8], [84 x i8]* @.str, i64 0, i64 0), i8* %0, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0))
%4 = load i32, i32* @stderr
%5 = tail call i32 (i32, i8*, ...) @fprintf(i32 %4, i8* getelementptr inbounds ([161 x i8], [161 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i8* %0)
%6 = load i32, i32* @stderr
%7 = tail call i32 (i32, i8*, ...) @fprintf(i32 %6, i8* getelementptr inbounds ([166 x i8], [166 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i8* %0)
%8 = load i32, i32* @stderr
%9 = tail call i32 (i32, i8*, ...) @fprintf(i32 %8, i8* getelementptr inbounds ([253 x i8], [253 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i8* %0, i8* %0)
%10 = load i32, i32* @stderr
%11 = tail call i32 (i32, i8*, ...) @fprintf(i32 %10, i8* getelementptr inbounds ([109 x i8], [109 x i8]* @.str.6, i64 0, i64 0))
%12 = load i32, i32* @stderr
%13 = tail call i32 (i32, i8*, ...) @fprintf(i32 %12, i8* getelementptr inbounds ([70 x i8], [70 x i8]* @.str.7, i64 0, i64 0))
%14 = load i32, i32* @stderr
%15 = tail call i32 (i32, i8*, ...) @fprintf(i32 %14, i8* getelementptr inbounds ([96 x i8], [96 x i8]* @.str.8, i64 0, i64 0))
ret void
}