#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 */
struct option {
  char *member_0;
  char member_3;
  char *name;
  int /*<<< orphan*/ member_2;
  int /*<<< orphan*/ const member_1;
};

/* Variables and functions */
int /*<<< orphan*/ EXIT_SUCCESS;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int getopt_long(int, char **, char *, struct option *, int *);
#define no_argument 129
char *optarg;
int optind;
int /*<<< orphan*/ printf(char *, ...);
#define required_argument 128
int main(int argc, char **argv) {
  int c;
  int digit_optind = 0;
  while (1) {
    int this_option_optind = optind ? optind : 1;
    int option_index = 0;
    static struct option long_options[] = {
        {"add", required_argument, 0, 0},
        {"append", no_argument, 0, 0},
        {"delete", required_argument, 0, 0},
        {"verbose", no_argument, 0, 0},
        {"create", required_argument, 0, 'c'},
        {"file", required_argument, 0, 0},
        {0, 0, 0, 0}};
    c = getopt_long(argc, argv, "abc:d:012", long_options, &option_index);
    printf("c %d, argc: %d\n", c, argc);
    if (c == -1)
      break;
    switch (c) {
    case 0:
      printf("option %s", long_options[option_index].name);
      if (optarg)
        printf(" with arg %s", optarg);
      printf("\n");
      break;
    case '0':
    case '1':
    case '2':
      if (digit_optind != 0 && digit_optind != this_option_optind)
        printf("digits occur in two different argv-elements.\n");
      digit_optind = this_option_optind;
      printf("option %c\n", c);
      break;
    case 'a':
      printf("option a\n");
      break;
    case 'b':
      printf("option b\n");
      break;
    case 'c':
      printf("option c with value '%s'\n", optarg);
      break;
    case 'd':
      printf("option d with value '%s'\n", optarg);
      break;
    case '?':
      break;
    default:
      printf("?? getopt returned character code 0%o ??\n", c);
    }
  }
  if (optind < argc) {
    printf("non-option ARGV-elements: ");
    while (optind < argc)
      printf("%s ", argv[optind++]);
    printf("\n");
  }
  exit(EXIT_SUCCESS);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x0,-0x18(%rbp)
mov    0x2e8c(%rip),%rax
cmpl   $0x0,(%rax)
je     116e <main+0x3e>
mov    0x2e7c(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x24(%rbp)
jmp    117b <main+0x4b>
mov    $0x1,%eax
mov    %eax,-0x24(%rbp)
jmp    117b <main+0x4b>
mov    -0x24(%rbp),%eax
mov    %eax,-0x1c(%rbp)
movl   $0x0,-0x20(%rbp)
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
lea    0xe90(%rip),%rdx
lea    0x2ea3(%rip),%rcx
lea    -0x20(%rbp),%r8
call   1030 <getopt_long@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%esi
mov    -0x8(%rbp),%edx
lea    0xe7a(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
cmpl   $0xffffffff,-0x14(%rbp)
jne    11cc <main+0x9c>
jmp    1363 <main+0x233>
mov    -0x14(%rbp),%eax
mov    %eax,-0x28(%rbp)
test   %eax,%eax
je     1248 <main+0x118>
jmp    11df <main+0xaf>
mov    -0x28(%rbp),%eax
add    $0xffffffd0,%eax
sub    $0x3,%eax
jb     12a8 <main+0x178>
jmp    11f3 <main+0xc3>
mov    -0x28(%rbp),%eax
sub    $0x3f,%eax
je     1348 <main+0x218>
jmp    1204 <main+0xd4>
mov    -0x28(%rbp),%eax
sub    $0x61,%eax
je     12e8 <main+0x1b8>
jmp    1215 <main+0xe5>
mov    -0x28(%rbp),%eax
sub    $0x62,%eax
je     12fb <main+0x1cb>
jmp    1226 <main+0xf6>
mov    -0x28(%rbp),%eax
sub    $0x63,%eax
je     130e <main+0x1de>
jmp    1237 <main+0x107>
mov    -0x28(%rbp),%eax
sub    $0x64,%eax
je     132b <main+0x1fb>
jmp    134d <main+0x21d>
movslq -0x20(%rbp),%rcx
lea    0x2ded(%rip),%rax
shl    $0x5,%rcx
add    %rcx,%rax
mov    0x10(%rax),%rsi
lea    0xddb(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    0x2d85(%rip),%rax
cmpq   $0x0,(%rax)
je     1295 <main+0x165>
mov    0x2d74(%rip),%rax
mov    (%rax),%rsi
lea    0xdbc(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    0xe20(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    135e <main+0x22e>
cmpl   $0x0,-0x18(%rbp)
je     12cc <main+0x19c>
mov    -0x18(%rbp),%eax
cmp    -0x1c(%rbp),%eax
je     12cc <main+0x19c>
lea    0xd92(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x1c(%rbp),%eax
mov    %eax,-0x18(%rbp)
mov    -0x14(%rbp),%esi
lea    0xda9(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    135e <main+0x22e>
lea    0xda1(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    135e <main+0x22e>
lea    0xd98(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    135e <main+0x22e>
mov    0x2ce3(%rip),%rax
mov    (%rax),%rsi
lea    0xd85(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    135e <main+0x22e>
mov    0x2cc6(%rip),%rax
mov    (%rax),%rsi
lea    0xd82(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    135e <main+0x22e>
jmp    135e <main+0x22e>
mov    -0x14(%rbp),%esi
lea    0xd81(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    114d <main+0x1d>
mov    0x2c76(%rip),%rax
mov    (%rax),%eax
cmp    -0x8(%rbp),%eax
jge    13d8 <main+0x2a8>
lea    0xd86(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    0x2c56(%rip),%rax
mov    (%rax),%eax
cmp    -0x8(%rbp),%eax
jge    13ca <main+0x29a>
mov    -0x10(%rbp),%rax
mov    0x2c40(%rip),%rcx
mov    (%rcx),%ecx
mov    %ecx,%esi
add    $0x1,%esi
mov    0x2c32(%rip),%rdx
mov    %esi,(%rdx)
movslq %ecx,%rcx
mov    (%rax,%rcx,8),%rsi
lea    0xd5f(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1383 <main+0x253>
lea    0xceb(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    0x2bf1(%rip),%rax
mov    (%rax),%edi
call   1050 <exit@plt>

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %rsi,%r12
mov    %edi,%ebp
mov    0x2e79(%rip),%rax
xor    %r15d,%r15d
jmp    1187 <main+0x37>
nopl   0x0(%rax)
lea    0xfb4(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1060 <printf@plt>
mov    %r13d,%r15d
mov    %rbx,%rax
mov    %rax,%rbx
mov    (%rax),%r13d
test   %r13d,%r13d
mov    $0x1,%eax
cmove  %eax,%r13d
movl   $0x0,0x4(%rsp)
mov    %ebp,%edi
mov    %r12,%rsi
lea    0xf4d(%rip),%rdx
lea    0x2e9c(%rip),%rcx
lea    0x4(%rsp),%r8
call   1050 <getopt_long@plt>
mov    %eax,%r14d
lea    0xf3c(%rip),%rdi
mov    %eax,%esi
mov    %ebp,%edx
xor    %eax,%eax
call   1060 <printf@plt>
lea    -0x30(%r14),%eax
cmp    $0x34,%eax
ja     120f <main+0xbf>
lea    0xe1d(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
test   %r15d,%r15d
je     1170 <main+0x20>
cmp    %r13d,%r15d
je     1170 <main+0x20>
lea    0xfc0(%rip),%rdi
call   1040 <puts@plt>
jmp    1170 <main+0x20>
test   %r14d,%r14d
je     1287 <main+0x137>
cmp    $0xffffffff,%r14d
je     12d9 <main+0x189>
lea    0xf45(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1060 <printf@plt>
mov    %rbx,%rax
jmp    1187 <main+0x37>
lea    0xf7e(%rip),%rdi
jmp    1247 <main+0xf7>
lea    0xf6c(%rip),%rdi
call   1040 <puts@plt>
mov    %rbx,%rax
jmp    1187 <main+0x37>
mov    0x2d9d(%rip),%rax
mov    (%rax),%rsi
lea    0xed1(%rip),%rdi
jmp    1278 <main+0x128>
mov    0x2d8a(%rip),%rax
mov    (%rax),%rsi
lea    0xed8(%rip),%rdi
xor    %eax,%eax
call   1060 <printf@plt>
mov    %rbx,%rax
jmp    1187 <main+0x37>
movslq 0x4(%rsp),%rax
shl    $0x5,%rax
lea    0x2db9(%rip),%rcx
mov    0x10(%rax,%rcx,1),%rsi
lea    0xe71(%rip),%rdi
xor    %eax,%eax
call   1060 <printf@plt>
mov    0x2d47(%rip),%rax
mov    (%rax),%rsi
test   %rsi,%rsi
je     12c7 <main+0x177>
lea    0xe5e(%rip),%rdi
xor    %eax,%eax
call   1060 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    %rbx,%rax
jmp    1187 <main+0x37>
cmp    %ebp,(%rbx)
jge    1325 <main+0x1d5>
lea    0xeb0(%rip),%rdi
xor    %eax,%eax
call   1060 <printf@plt>
mov    (%rbx),%eax
cmp    %ebp,%eax
jge    131b <main+0x1cb>
lea    0xeb7(%rip),%r14
nopl   0x0(%rax,%rax,1)
lea    0x1(%rax),%ecx
mov    %ecx,(%rbx)
cltq
mov    (%r12,%rax,8),%rsi
mov    %r14,%rdi
xor    %eax,%eax
call   1060 <printf@plt>
mov    (%rbx),%eax
cmp    %ebp,%eax
jl     1300 <main+0x1b0>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    0x2ca4(%rip),%rax
mov    (%rax),%edi
call   1070 <exit@plt>

LLVM IR (-O0):
%struct.option = type { i8*, i8, i8*, i32, i32 }
@optind = global i32 0
@main.long_options = internal global [7 x %struct.option] [%struct.option { i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i32 0, i32 0), i8 -128, i8* null, i32 0, i32 0 }, %struct.option { i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i32 0, i32 0), i8 -127, i8* null, i32 0, i32 0 }, %struct.option { i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.2, i32 0, i32 0), i8 -128, i8* null, i32 0, i32 0 }, %struct.option { i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i32 0, i32 0), i8 -127, i8* null, i32 0, i32 0 }, %struct.option { i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i32 0, i32 0), i8 -128, i8* null, i32 99, i32 0 }, %struct.option { i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i32 0, i32 0), i8 -128, i8* null, i32 0, i32 0 }, %struct.option zeroinitializer]
@.str = [4 x i8] c"add\00"
@.str.1 = [7 x i8] c"append\00"
@.str.2 = [7 x i8] c"delete\00"
@.str.3 = [8 x i8] c"verbose\00"
@.str.4 = [7 x i8] c"create\00"
@.str.5 = [5 x i8] c"file\00"
@.str.6 = [10 x i8] c"abc:d:012\00"
@.str.7 = [16 x i8] c"c %d, argc: %d\0A\00"
@.str.8 = [10 x i8] c"option %s\00"
@optarg = global i8* null
@.str.9 = [13 x i8] c" with arg %s\00"
@.str.10 = [2 x i8] c"\0A\00"
@.str.11 = [46 x i8] c"digits occur in two different argv-elements.\0A\00"
@.str.12 = [11 x i8] c"option %c\0A\00"
@.str.13 = [10 x i8] c"option a\0A\00"
@.str.14 = [10 x i8] c"option b\0A\00"
@.str.15 = [26 x i8] c"option c with value '%s'\0A\00"
@.str.16 = [26 x i8] c"option d with value '%s'\0A\00"
@.str.17 = [42 x i8] c"?? getopt returned character code 0%o ??\0A\00"
@.str.18 = [27 x i8] c"non-option ARGV-elements: \00"
@.str.19 = [4 x i8] c"%s \00"
@EXIT_SUCCESS = global i32 0
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 0, i32* %7
br label %10
10: ; preds = %2, %70
%11 = load i32, i32* @optind
%12 = icmp ne i32 %11, 0
br i1 %12, label %13, label %15
13: ; preds = %10
%14 = load i32, i32* @optind
br label %16
15: ; preds = %10
br label %16
16: ; preds = %15, %13
%17 = phi i32 [ %14, %13 ], [ 1, %15 ]
store i32 %17, i32* %8
store i32 0, i32* %9
%18 = load i32, i32* %4
%19 = load i8**, i8*** %5
%20 = call i32 @getopt_long(i32 %18, i8** %19, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.6, i64 0, i64 0), %struct.option* getelementptr inbounds ([7 x %struct.option], [7 x %struct.option]* @main.long_options, i64 0, i64 0), i32* %9)
store i32 %20, i32* %6
%21 = load i32, i32* %6
%22 = load i32, i32* %4
%23 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.7, i64 0, i64 0), i32 %21, i32 %22)
%24 = load i32, i32* %6
%25 = icmp eq i32 %24, -1
br i1 %25, label %26, label %27
26: ; preds = %16
br label %71
27: ; preds = %16
%28 = load i32, i32* %6
switch i32 %28, label %67 [
i32 0, label %29
i32 48, label %43
i32 49, label %43
i32 50, label %43
i32 97, label %56
i32 98, label %58
i32 99, label %60
i32 100, label %63
i32 63, label %66
]
29: ; preds = %27
%30 = load i32, i32* %9
%31 = sext i32 %30 to i64
%32 = getelementptr inbounds [7 x %struct.option], [7 x %struct.option]* @main.long_options, i64 0, i64 %31
%33 = getelementptr inbounds %struct.option, %struct.option* %32, i32 0, i32 2
%34 = load i8*, i8** %33
%35 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.8, i64 0, i64 0), i8* %34)
%36 = load i8*, i8** @optarg
%37 = icmp ne i8* %36, null
br i1 %37, label %38, label %41
38: ; preds = %29
%39 = load i8*, i8** @optarg
%40 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.9, i64 0, i64 0), i8* %39)
br label %41
41: ; preds = %38, %29
%42 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.10, i64 0, i64 0))
br label %70
43: ; preds = %27, %27, %27
%44 = load i32, i32* %7
%45 = icmp ne i32 %44, 0
br i1 %45, label %46, label %52
46: ; preds = %43
%47 = load i32, i32* %7
%48 = load i32, i32* %8
%49 = icmp ne i32 %47, %48
br i1 %49, label %50, label %52
50: ; preds = %46
%51 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.11, i64 0, i64 0))
br label %52
52: ; preds = %50, %46, %43
%53 = load i32, i32* %8
store i32 %53, i32* %7
%54 = load i32, i32* %6
%55 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.12, i64 0, i64 0), i32 %54)
br label %70
56: ; preds = %27
%57 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.13, i64 0, i64 0))
br label %70
58: ; preds = %27
%59 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.14, i64 0, i64 0))
br label %70
60: ; preds = %27
%61 = load i8*, i8** @optarg
%62 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.15, i64 0, i64 0), i8* %61)
br label %70
63: ; preds = %27
%64 = load i8*, i8** @optarg
%65 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str.16, i64 0, i64 0), i8* %64)
br label %70
66: ; preds = %27
br label %70
67: ; preds = %27
%68 = load i32, i32* %6
%69 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([42 x i8], [42 x i8]* @.str.17, i64 0, i64 0), i32 %68)
br label %70
70: ; preds = %67, %66, %63, %60, %58, %56, %52, %41
br label %10
71: ; preds = %26
%72 = load i32, i32* @optind
%73 = load i32, i32* %4
%74 = icmp slt i32 %72, %73
br i1 %74, label %75, label %91
75: ; preds = %71
%76 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.18, i64 0, i64 0))
br label %77
77: ; preds = %81, %75
%78 = load i32, i32* @optind
%79 = load i32, i32* %4
%80 = icmp slt i32 %78, %79
br i1 %80, label %81, label %89
81: ; preds = %77
%82 = load i8**, i8*** %5
%83 = load i32, i32* @optind
%84 = add nsw i32 %83, 1
store i32 %84, i32* @optind
%85 = sext i32 %83 to i64
%86 = getelementptr inbounds i8*, i8** %82, i64 %85
%87 = load i8*, i8** %86
%88 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.19, i64 0, i64 0), i8* %87)
br label %77
89: ; preds = %77
%90 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.10, i64 0, i64 0))
br label %91
91: ; preds = %89, %71
%92 = load i32, i32* @EXIT_SUCCESS
%93 = call i32 @exit(i32 %92)
unreachable
}

LLVM IR (-O2):
%struct.option = type { i8*, i8, i8*, i32, i32 }
@optind = global i32 0
@main.long_options = internal global [7 x %struct.option] [%struct.option { i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i32 0, i32 0), i8 -128, i8* null, i32 0, i32 0 }, %struct.option { i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i32 0, i32 0), i8 -127, i8* null, i32 0, i32 0 }, %struct.option { i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.2, i32 0, i32 0), i8 -128, i8* null, i32 0, i32 0 }, %struct.option { i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i32 0, i32 0), i8 -127, i8* null, i32 0, i32 0 }, %struct.option { i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.4, i32 0, i32 0), i8 -128, i8* null, i32 99, i32 0 }, %struct.option { i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i32 0, i32 0), i8 -128, i8* null, i32 0, i32 0 }, %struct.option zeroinitializer]
@.str = [4 x i8] c"add\00"
@.str.1 = [7 x i8] c"append\00"
@.str.2 = [7 x i8] c"delete\00"
@.str.3 = [8 x i8] c"verbose\00"
@.str.4 = [7 x i8] c"create\00"
@.str.5 = [5 x i8] c"file\00"
@.str.6 = [10 x i8] c"abc:d:012\00"
@.str.7 = [16 x i8] c"c %d, argc: %d\0A\00"
@.str.8 = [10 x i8] c"option %s\00"
@optarg = global i8* null
@.str.9 = [13 x i8] c" with arg %s\00"
@.str.12 = [11 x i8] c"option %c\0A\00"
@.str.15 = [26 x i8] c"option c with value '%s'\0A\00"
@.str.16 = [26 x i8] c"option d with value '%s'\0A\00"
@.str.17 = [42 x i8] c"?? getopt returned character code 0%o ??\0A\00"
@.str.18 = [27 x i8] c"non-option ARGV-elements: \00"
@.str.19 = [4 x i8] c"%s \00"
@EXIT_SUCCESS = global i32 0
@str = [9 x i8] c"option b\00"
@str.20 = [9 x i8] c"option a\00"
@str.21 = [45 x i8] c"digits occur in two different argv-elements.\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = bitcast i32* %3 to i8*
br label %5
5: ; preds = %44, %2
%6 = phi i32 [ 0, %2 ], [ %45, %44 ]
%7 = load i32, i32* @optind
%8 = icmp eq i32 %7, 0
%9 = select i1 %8, i32 1, i32 %7
store i32 0, i32* %3
%10 = call i32 @getopt_long(i32 %0, i8** %1, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.6, i64 0, i64 0), %struct.option* getelementptr inbounds ([7 x %struct.option], [7 x %struct.option]* @main.long_options, i64 0, i64 0), i32* %3)
%11 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @.str.7, i64 0, i64 0), i32 %10, i32 %0)
switch i32 %10, label %42 [
i32 -1, label %46
i32 0, label %12
i32 48, label %24
i32 49, label %24
i32 50, label %24
i32 97, label %32
i32 98, label %34
i32 99, label %36
i32 100, label %39
i32 63, label %44
]
12: ; preds = %5
%13 = load i32, i32* %3
%14 = sext i32 %13 to i64
%15 = getelementptr inbounds [7 x %struct.option], [7 x %struct.option]* @main.long_options, i64 0, i64 %14, i32 2
%16 = load i8*, i8** %15
%17 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.8, i64 0, i64 0), i8* %16)
%18 = load i8*, i8** @optarg
%19 = icmp eq i8* %18, null
br i1 %19, label %22, label %20
20: ; preds = %12
%21 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @.str.9, i64 0, i64 0), i8* %18)
br label %22
22: ; preds = %20, %12
%23 = call i32 @putchar(i32 10)
br label %44
24: ; preds = %5, %5, %5
%25 = icmp eq i32 %6, 0
%26 = icmp eq i32 %6, %9
%27 = select i1 %25, i1 true, i1 %26
br i1 %27, label %30, label %28
28: ; preds = %24
%29 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([45 x i8], [45 x i8]* @str.21, i64 0, i64 0))
br label %30
30: ; preds = %28, %24
%31 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.12, i64 0, i64 0), i32 %10)
br label %44
32: ; preds = %5
%33 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @str.20, i64 0, i64 0))
br label %44
34: ; preds = %5
%35 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @str, i64 0, i64 0))
br label %44
36: ; preds = %5
%37 = load i8*, i8** @optarg
%38 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([26 x i8], [26 x i8]* @.str.15, i64 0, i64 0), i8* %37)
br label %44
39: ; preds = %5
%40 = load i8*, i8** @optarg
%41 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([26 x i8], [26 x i8]* @.str.16, i64 0, i64 0), i8* %40)
br label %44
42: ; preds = %5
%43 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([42 x i8], [42 x i8]* @.str.17, i64 0, i64 0), i32 %10)
br label %44
44: ; preds = %22, %30, %32, %34, %36, %39, %42, %5
%45 = phi i32 [ %6, %42 ], [ %6, %39 ], [ %6, %36 ], [ %6, %34 ], [ %6, %32 ], [ %9, %30 ], [ %6, %22 ], [ %6, %5 ]
br label %5
46: ; preds = %5
%47 = load i32, i32* @optind
%48 = icmp slt i32 %47, %0
br i1 %48, label %49, label %64
49: ; preds = %46
%50 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @.str.18, i64 0, i64 0))
%51 = load i32, i32* @optind
%52 = icmp slt i32 %51, %0
br i1 %52, label %53, label %62
53: ; preds = %49, %53
%54 = phi i32 [ %60, %53 ], [ %51, %49 ]
%55 = add nsw i32 %54, 1
store i32 %55, i32* @optind
%56 = sext i32 %54 to i64
%57 = getelementptr inbounds i8*, i8** %1, i64 %56
%58 = load i8*, i8** %57
%59 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.19, i64 0, i64 0), i8* %58)
%60 = load i32, i32* @optind
%61 = icmp slt i32 %60, %0
br i1 %61, label %53, label %62
62: ; preds = %53, %49
%63 = call i32 @putchar(i32 10)
br label %64
64: ; preds = %62, %46
%65 = load i32, i32* @EXIT_SUCCESS
%66 = call i32 @exit(i32 %65)
unreachable
}