#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*/ *get_boolean_option(char *, int, char **);
char *get_option(char *, int, char **);
int help(int, char **);
int hide(int, char **);
int recover(int, char **);
scalar_t__ strcmp(char *, char *);
int main(int argc, char **argv) {
  char *task = NULL;
  if (get_boolean_option("help", argc, argv) != NULL) {
    return help(argc, argv);
  }
  task = get_option("task", argc, argv);
  if (task != NULL && strcmp(task, "hide") == 0) {
    return hide(argc, argv);
  } else if (task != NULL && strcmp(task, "recover") == 0) {
    return recover(argc, argv);
  }
  return help(argc, argv);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movq   $0x0,-0x18(%rbp)
mov    -0x8(%rbp),%esi
mov    -0x10(%rbp),%rdx
lea    0xe74(%rip),%rdi
call   1030 <get_boolean_option@plt>
cmp    $0x0,%rax
je     11af <main+0x4f>
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
call   1070 <help@plt>
mov    %eax,-0x4(%rbp)
jmp    124c <main+0xec>
mov    -0x8(%rbp),%esi
mov    -0x10(%rbp),%rdx
lea    0xe48(%rip),%rdi
call   1080 <get_option@plt>
mov    %rax,-0x18(%rbp)
cmpq   $0x0,-0x18(%rbp)
je     11ff <main+0x9f>
mov    -0x18(%rbp),%rdi
lea    0xe2e(%rip),%rsi
call   1050 <strcmp@plt>
cmp    $0x0,%rax
jne    11ff <main+0x9f>
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
call   1040 <hide@plt>
mov    %eax,-0x4(%rbp)
jmp    124c <main+0xec>
cmpq   $0x0,-0x18(%rbp)
je     1238 <main+0xd8>
mov    -0x18(%rbp),%rdi
lea    0xdfa(%rip),%rsi
call   1050 <strcmp@plt>
cmp    $0x0,%rax
jne    1238 <main+0xd8>
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
call   1060 <recover@plt>
mov    %eax,-0x4(%rbp)
jmp    124c <main+0xec>
jmp    123d <main+0xdd>
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
call   1070 <help@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r14
push   %rbx
mov    %rsi,%rbx
mov    %edi,%ebp
lea    0xe90(%rip),%rdi
mov    %ebp,%esi
mov    %rbx,%rdx
call   1030 <get_boolean_option@plt>
test   %rax,%rax
je     118d <main+0x2d>
mov    %ebp,%edi
mov    %rbx,%rsi
pop    %rbx
pop    %r14
pop    %rbp
jmp    1070 <help@plt>
lea    0xe71(%rip),%rdi
mov    %ebp,%esi
mov    %rbx,%rdx
call   1080 <get_option@plt>
test   %rax,%rax
je     117f <main+0x1f>
mov    %rax,%r14
lea    0xe5d(%rip),%rsi
mov    %rax,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
je     11dc <main+0x7c>
lea    0xe4e(%rip),%rsi
mov    %r14,%rdi
call   1050 <strcmp@plt>
test   %rax,%rax
jne    117f <main+0x1f>
mov    %ebp,%edi
mov    %rbx,%rsi
pop    %rbx
pop    %r14
pop    %rbp
jmp    1060 <recover@plt>
mov    %ebp,%edi
mov    %rbx,%rsi
pop    %rbx
pop    %r14
pop    %rbp
jmp    1040 <hide@plt>

LLVM IR (-O0):
@.str = [5 x i8] c"help\00"
@.str.1 = [5 x i8] c"task\00"
@.str.2 = [5 x i8] c"hide\00"
@.str.3 = [8 x i8] c"recover\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i8*
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i8* null, i8** %6
%7 = load i32, i32* %4
%8 = load i8**, i8*** %5
%9 = call i32* @get_boolean_option(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 %7, i8** %8)
%10 = icmp ne i32* %9, null
br i1 %10, label %11, label %15
11: ; preds = %2
%12 = load i32, i32* %4
%13 = load i8**, i8*** %5
%14 = call i32 @help(i32 %12, i8** %13)
store i32 %14, i32* %3
br label %45
15: ; preds = %2
%16 = load i32, i32* %4
%17 = load i8**, i8*** %5
%18 = call i8* @get_option(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32 %16, i8** %17)
store i8* %18, i8** %6
%19 = load i8*, i8** %6
%20 = icmp ne i8* %19, null
br i1 %20, label %21, label %29
21: ; preds = %15
%22 = load i8*, i8** %6
%23 = call i64 @strcmp(i8* %22, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%24 = icmp eq i64 %23, 0
br i1 %24, label %25, label %29
25: ; preds = %21
%26 = load i32, i32* %4
%27 = load i8**, i8*** %5
%28 = call i32 @hide(i32 %26, i8** %27)
store i32 %28, i32* %3
br label %45
29: ; preds = %21, %15
%30 = load i8*, i8** %6
%31 = icmp ne i8* %30, null
br i1 %31, label %32, label %40
32: ; preds = %29
%33 = load i8*, i8** %6
%34 = call i64 @strcmp(i8* %33, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i64 0, i64 0))
%35 = icmp eq i64 %34, 0
br i1 %35, label %36, label %40
36: ; preds = %32
%37 = load i32, i32* %4
%38 = load i8**, i8*** %5
%39 = call i32 @recover(i32 %37, i8** %38)
store i32 %39, i32* %3
br label %45
40: ; preds = %32, %29
br label %41
41: ; preds = %40
%42 = load i32, i32* %4
%43 = load i8**, i8*** %5
%44 = call i32 @help(i32 %42, i8** %43)
store i32 %44, i32* %3
br label %45
45: ; preds = %41, %36, %25, %11
%46 = load i32, i32* %3
ret i32 %46
}

LLVM IR (-O2):
@.str = [5 x i8] c"help\00"
@.str.1 = [5 x i8] c"task\00"
@.str.2 = [5 x i8] c"hide\00"
@.str.3 = [8 x i8] c"recover\00"
define i32 @main(i32 %0, i8** %1) {
%3 = tail call i32* @get_boolean_option(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i32 %0, i8** %1)
%4 = icmp eq i32* %3, null
br i1 %4, label %7, label %5
5: ; preds = %2
%6 = tail call i32 @help(i32 %0, i8** %1)
br label %22
7: ; preds = %2
%8 = tail call i8* @get_option(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.1, i64 0, i64 0), i32 %0, i8** %1)
%9 = icmp eq i8* %8, null
br i1 %9, label %20, label %10
10: ; preds = %7
%11 = tail call i64 @strcmp(i8* %8, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.2, i64 0, i64 0))
%12 = icmp eq i64 %11, 0
br i1 %12, label %13, label %15
13: ; preds = %10
%14 = tail call i32 @hide(i32 %0, i8** %1)
br label %22
15: ; preds = %10
%16 = tail call i64 @strcmp(i8* %8, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i64 0, i64 0))
%17 = icmp eq i64 %16, 0
br i1 %17, label %18, label %20
18: ; preds = %15
%19 = tail call i32 @recover(i32 %0, i8** %1)
br label %22
20: ; preds = %7, %15
%21 = tail call i32 @help(i32 %0, i8** %1)
br label %22
22: ; preds = %20, %18, %13, %5
%23 = phi i32 [ %6, %5 ], [ %14, %13 ], [ %19, %18 ], [ %21, %20 ]
ret i32 %23
}