#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(int argc, char **argv) {
  printf("Usage:\n");
  printf("%s [options]\n", argv[0]);
  printf("-i input dir (REQUIRED)\n");
  printf("-o output dir (REQUIRED)\n");
  printf("\n");
  printf("-I Input format string (default  p_%%05d.tif)\n");
  printf("-O c-style string format for output files\n");
  printf("\n");
  printf("-S Settings folder (for log files etc) \n");
  printf("\n");
  printf("-C  crop start (left)\n");
  printf("-c  crop width \n");
  printf("-T  crop start (top)\n");
  printf("-t  crop length (vertical)\n");
  printf("\n");
  printf("-u  outlier detection parameter \n");
  printf("\n");
  printf("-s number of segments (default 1)\n");
  printf("-p number of images per segment (default 100) \n");
  printf("-n number of chunks (default 8)\n");
  printf("-m my chunk number (default 0)\n");
  printf("-a number of images in a batch (default 10 )\n");
  printf("-b input data type;  bytes per pixel (default 2)\n");
  printf("-Z timeout (default 3 seconds)\n");
  printf("-z check interval (default 1 second) \n");
  printf("-J job name (used to decorate output file names) \n");
  printf("-v verbose messages\n");
}


x86 assembly (clang, -O0):
<usage>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xeda(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x10(%rbp),%rax
mov    (%rax),%rsi
lea    0xecd(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xecd(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xed8(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x1034(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xed6(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xef7(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x100a(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf06(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xfee(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf13(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf1c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf1f(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf27(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xfa8(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf27(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf8c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf2d(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf42(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf64(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf77(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xf89(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xfa9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xfcd(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xfdf(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xff8(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0x101d(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<usage>:
push   %rbx
mov    %rsi,%rbx
lea    0xf02(%rip),%rdi
call   1040 <puts@plt>
mov    (%rbx),%rsi
lea    0xeb6(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xeec(%rip),%rdi
call   1040 <puts@plt>
lea    0xef8(%rip),%rdi
call   1040 <puts@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xe94(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xeed(%rip),%rdi
call   1040 <puts@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xf01(%rip),%rdi
call   1040 <puts@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xf13(%rip),%rdi
call   1040 <puts@plt>
lea    0xf1d(%rip),%rdi
call   1040 <puts@plt>
lea    0xf21(%rip),%rdi
call   1040 <puts@plt>
lea    0xf2a(%rip),%rdi
call   1040 <puts@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xf2f(%rip),%rdi
call   1040 <puts@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
lea    0xf3a(%rip),%rdi
call   1040 <puts@plt>
lea    0xf50(%rip),%rdi
call   1040 <puts@plt>
lea    0xf73(%rip),%rdi
call   1040 <puts@plt>
lea    0xf87(%rip),%rdi
call   1040 <puts@plt>
lea    0xf9a(%rip),%rdi
call   1040 <puts@plt>
lea    0xfbb(%rip),%rdi
call   1040 <puts@plt>
lea    0xfe0(%rip),%rdi
call   1040 <puts@plt>
lea    0xff3(%rip),%rdi
call   1040 <puts@plt>
lea    0x100d(%rip),%rdi
call   1040 <puts@plt>
lea    0x1033(%rip),%rdi
pop    %rbx
jmp    1040 <puts@plt>

LLVM IR (-O0):
@.str = [8 x i8] c"Usage:\0A\00"
@.str.1 = [14 x i8] c"%s [options]\0A\00"
@.str.2 = [25 x i8] c"-i input dir (REQUIRED)\0A\00"
@.str.3 = [26 x i8] c"-o output dir (REQUIRED)\0A\00"
@.str.4 = [2 x i8] c"\0A\00"
@.str.5 = [47 x i8] c"-I Input format string (default p_%%05d.tif)\0A\00"
@.str.6 = [43 x i8] c"-O c-style string format for output files\0A\00"
@.str.7 = [41 x i8] c"-S Settings folder (for log files etc) \0A\00"
@.str.8 = [23 x i8] c"-C crop start (left)\0A\00"
@.str.9 = [17 x i8] c"-c crop width \0A\00"
@.str.10 = [22 x i8] c"-T crop start (top)\0A\00"
@.str.11 = [28 x i8] c"-t crop length (vertical)\0A\00"
@.str.12 = [34 x i8] c"-u outlier detection parameter \0A\00"
@.str.13 = [35 x i8] c"-s number of segments (default 1)\0A\00"
@.str.14 = [48 x i8] c"-p number of images per segment (default 100) \0A\00"
@.str.15 = [33 x i8] c"-n number of chunks (default 8)\0A\00"
@.str.16 = [32 x i8] c"-m my chunk number (default 0)\0A\00"
@.str.17 = [46 x i8] c"-a number of images in a batch (default 10 )\0A\00"
@.str.18 = [50 x i8] c"-b input data type; bytes per pixel (default 2)\0A\00"
@.str.19 = [32 x i8] c"-Z timeout (default 3 seconds)\0A\00"
@.str.20 = [39 x i8] c"-z check interval (default 1 second) \0A\00"
@.str.21 = [51 x i8] c"-J job name (used to decorate output file names) \0A\00"
@.str.22 = [21 x i8] c"-v verbose messages\0A\00"
define void @usage(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i8**
store i32 %0, i32* %3
store i8** %1, i8*** %4
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str, i64 0, i64 0))
%6 = load i8**, i8*** %4
%7 = getelementptr inbounds i8*, i8** %6, i64 0
%8 = load i8*, i8** %7
%9 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0), i8* %8)
%10 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.2, i64 0, i64 0))
%11 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.3, i64 0, i64 0))
%12 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
%13 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str.5, i64 0, i64 0))
%14 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.6, i64 0, i64 0))
%15 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
%16 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.7, i64 0, i64 0))
%17 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.8, i64 0, i64 0))
%19 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.9, i64 0, i64 0))
%20 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.10, i64 0, i64 0))
%21 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.11, i64 0, i64 0))
%22 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
%23 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.12, i64 0, i64 0))
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
%25 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.13, i64 0, i64 0))
%26 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.14, i64 0, i64 0))
%27 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.15, i64 0, i64 0))
%28 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.16, i64 0, i64 0))
%29 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.17, i64 0, i64 0))
%30 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.18, i64 0, i64 0))
%31 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.19, i64 0, i64 0))
%32 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.20, i64 0, i64 0))
%33 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([51 x i8], [51 x i8]* @.str.21, i64 0, i64 0))
%34 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.22, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str.1 = [14 x i8] c"%s [options]\0A\00"
@.str.5 = [47 x i8] c"-I Input format string (default p_%%05d.tif)\0A\00"
@str = [7 x i8] c"Usage:\00"
@str.23 = [24 x i8] c"-i input dir (REQUIRED)\00"
@str.24 = [25 x i8] c"-o output dir (REQUIRED)\00"
@str.25 = [42 x i8] c"-O c-style string format for output files\00"
@str.26 = [40 x i8] c"-S Settings folder (for log files etc) \00"
@str.27 = [22 x i8] c"-C crop start (left)\00"
@str.28 = [16 x i8] c"-c crop width \00"
@str.29 = [21 x i8] c"-T crop start (top)\00"
@str.30 = [27 x i8] c"-t crop length (vertical)\00"
@str.31 = [33 x i8] c"-u outlier detection parameter \00"
@str.32 = [34 x i8] c"-s number of segments (default 1)\00"
@str.33 = [47 x i8] c"-p number of images per segment (default 100) \00"
@str.34 = [32 x i8] c"-n number of chunks (default 8)\00"
@str.35 = [31 x i8] c"-m my chunk number (default 0)\00"
@str.36 = [45 x i8] c"-a number of images in a batch (default 10 )\00"
@str.37 = [49 x i8] c"-b input data type; bytes per pixel (default 2)\00"
@str.38 = [31 x i8] c"-Z timeout (default 3 seconds)\00"
@str.39 = [38 x i8] c"-z check interval (default 1 second) \00"
@str.40 = [50 x i8] c"-J job name (used to decorate output file names) \00"
@str.41 = [20 x i8] c"-v verbose messages\00"
define void @usage(i32 %0, i8** nocapture %1) {
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([7 x i8], [7 x i8]* @str, i64 0, i64 0))
%4 = load i8*, i8** %1
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0), i8* %4)
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([24 x i8], [24 x i8]* @str.23, i64 0, i64 0))
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([25 x i8], [25 x i8]* @str.24, i64 0, i64 0))
%8 = tail call i32 @putchar(i32 10)
%9 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([47 x i8], [47 x i8]* @.str.5, i64 0, i64 0))
%10 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([42 x i8], [42 x i8]* @str.25, i64 0, i64 0))
%11 = tail call i32 @putchar(i32 10)
%12 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([40 x i8], [40 x i8]* @str.26, i64 0, i64 0))
%13 = tail call i32 @putchar(i32 10)
%14 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([22 x i8], [22 x i8]* @str.27, i64 0, i64 0))
%15 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @str.28, i64 0, i64 0))
%16 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @str.29, i64 0, i64 0))
%17 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @str.30, i64 0, i64 0))
%18 = tail call i32 @putchar(i32 10)
%19 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @str.31, i64 0, i64 0))
%20 = tail call i32 @putchar(i32 10)
%21 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([34 x i8], [34 x i8]* @str.32, i64 0, i64 0))
%22 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([47 x i8], [47 x i8]* @str.33, i64 0, i64 0))
%23 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @str.34, i64 0, i64 0))
%24 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @str.35, i64 0, i64 0))
%25 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([45 x i8], [45 x i8]* @str.36, i64 0, i64 0))
%26 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([49 x i8], [49 x i8]* @str.37, i64 0, i64 0))
%27 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @str.38, i64 0, i64 0))
%28 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([38 x i8], [38 x i8]* @str.39, i64 0, i64 0))
%29 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([50 x i8], [50 x i8]* @str.40, i64 0, i64 0))
%30 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @str.41, i64 0, i64 0))
ret void
}