#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*/ Log(char *);
void handleFTPRetcode(char *rbuf) {
  if (rbuf[0] == '4') {
    if (rbuf[1] == '2')
      Log("There seems to be an error in the connections.");
    else if (rbuf[1] == '5')
      Log("Requested action not taken");
    Log("Retry the download after sometime.");
    Log("If the error persists, please report this with the command line used "
        "to murat@enderunix.org.");
  } else if (rbuf[0] == '5') {
    if (rbuf[1] == '0')
      Log("The server has reported a syntax error.");
    else if (rbuf[1] == '3')
      Log("Error relating to login; checkout the previous message, if "
          "available.");
    else if (rbuf[1] == '5')
      Log("Requested action not taken");
    Log("If you feel this is an error with aget, please report this with the "
        "command line used to murat@enderunix.org.");
  }
}


x86 assembly (clang, -O0):
<handleFTPRetcode>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x34,%eax
jne    118d <handleFTPRetcode+0x7d>
mov    -0x8(%rbp),%rax
movsbl 0x1(%rax),%eax
cmp    $0x32,%eax
jne    114e <handleFTPRetcode+0x3e>
lea    0xebc(%rip),%rdi
call   1030 <Log@plt>
jmp    1170 <handleFTPRetcode+0x60>
mov    -0x8(%rbp),%rax
movsbl 0x1(%rax),%eax
cmp    $0x35,%eax
jne    116b <handleFTPRetcode+0x5b>
lea    0xec9(%rip),%rdi
call   1030 <Log@plt>
jmp    1170 <handleFTPRetcode+0x60>
lea    0xed3(%rip),%rdi
call   1030 <Log@plt>
lea    0xeea(%rip),%rdi
call   1030 <Log@plt>
jmp    1219 <handleFTPRetcode+0x109>
mov    -0x8(%rbp),%rax
movsbl (%rax),%eax
cmp    $0x35,%eax
jne    1214 <handleFTPRetcode+0x104>
mov    -0x8(%rbp),%rax
movsbl 0x1(%rax),%eax
cmp    $0x30,%eax
jne    11bf <handleFTPRetcode+0xaf>
lea    0xf15(%rip),%rdi
call   1030 <Log@plt>
jmp    1208 <handleFTPRetcode+0xf8>
mov    -0x8(%rbp),%rax
movsbl 0x1(%rax),%eax
cmp    $0x33,%eax
jne    11e1 <handleFTPRetcode+0xd1>
lea    0xf1b(%rip),%rdi
call   1030 <Log@plt>
jmp    1203 <handleFTPRetcode+0xf3>
mov    -0x8(%rbp),%rax
movsbl 0x1(%rax),%eax
cmp    $0x35,%eax
jne    11fe <handleFTPRetcode+0xee>
lea    0xe36(%rip),%rdi
call   1030 <Log@plt>
jmp    1203 <handleFTPRetcode+0xf3>
jmp    1208 <handleFTPRetcode+0xf8>
lea    0xf29(%rip),%rdi
call   1030 <Log@plt>
jmp    1219 <handleFTPRetcode+0x109>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<handleFTPRetcode>:
push   %r14
push   %rbx
push   %rax
mov    (%rdi),%al
cmp    $0x35,%al
je     1145 <handleFTPRetcode+0x35>
cmp    $0x34,%al
jne    1164 <handleFTPRetcode+0x54>
mov    0x1(%rdi),%al
lea    0xf45(%rip),%r14
lea    0xf1b(%rip),%rbx
cmp    $0x32,%al
je     116c <handleFTPRetcode+0x5c>
cmp    $0x35,%al
jne    118a <handleFTPRetcode+0x7a>
lea    0xef1(%rip),%rdi
call   1030 <Log@plt>
jmp    118a <handleFTPRetcode+0x7a>
mov    0x1(%rdi),%al
lea    0xfe9(%rip),%r14
cmp    $0x30,%al
je     117a <handleFTPRetcode+0x6a>
cmp    $0x35,%al
je     1183 <handleFTPRetcode+0x73>
cmp    $0x33,%al
jne    1192 <handleFTPRetcode+0x82>
lea    0xf90(%rip),%rbx
jmp    118a <handleFTPRetcode+0x7a>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret
lea    0xe8d(%rip),%rdi
call   1030 <Log@plt>
jmp    118a <handleFTPRetcode+0x7a>
lea    0xf49(%rip),%rbx
jmp    118a <handleFTPRetcode+0x7a>
lea    0xea5(%rip),%rbx
mov    %rbx,%rdi
call   1030 <Log@plt>
mov    %r14,%rdi
add    $0x8,%rsp
pop    %rbx
pop    %r14
jmp    1030 <Log@plt>

LLVM IR (-O0):
@.str = [47 x i8] c"There seems to be an error in the connections.\00"
@.str.1 = [27 x i8] c"Requested action not taken\00"
@.str.2 = [35 x i8] c"Retry the download after sometime.\00"
@.str.3 = [93 x i8] c"If the error persists, please report this with the command line used to murat@enderunix.org.\00"
@.str.4 = [40 x i8] c"The server has reported a syntax error.\00"
@.str.5 = [70 x i8] c"Error relating to login; checkout the previous message, if available.\00"
@.str.6 = [110 x i8] c"If you feel this is an error with aget, please report this with the command line used to murat@enderunix.org.\00"
define void @handleFTPRetcode(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = getelementptr inbounds i8, i8* %3, i64 0
%5 = load i8, i8* %4
%6 = sext i8 %5 to i32
%7 = icmp eq i32 %6, 52
br i1 %7, label %8, label %28
8: ; preds = %1
%9 = load i8*, i8** %2
%10 = getelementptr inbounds i8, i8* %9, i64 1
%11 = load i8, i8* %10
%12 = sext i8 %11 to i32
%13 = icmp eq i32 %12, 50
br i1 %13, label %14, label %16
14: ; preds = %8
%15 = call i32 @Log(i8* getelementptr inbounds ([47 x i8], [47 x i8]* @.str, i64 0, i64 0))
br label %25
16: ; preds = %8
%17 = load i8*, i8** %2
%18 = getelementptr inbounds i8, i8* %17, i64 1
%19 = load i8, i8* %18
%20 = sext i8 %19 to i32
%21 = icmp eq i32 %20, 53
br i1 %21, label %22, label %24
22: ; preds = %16
%23 = call i32 @Log(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0))
br label %24
24: ; preds = %22, %16
br label %25
25: ; preds = %24, %14
%26 = call i32 @Log(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.2, i64 0, i64 0))
%27 = call i32 @Log(i8* getelementptr inbounds ([93 x i8], [93 x i8]* @.str.3, i64 0, i64 0))
br label %63
28: ; preds = %1
%29 = load i8*, i8** %2
%30 = getelementptr inbounds i8, i8* %29, i64 0
%31 = load i8, i8* %30
%32 = sext i8 %31 to i32
%33 = icmp eq i32 %32, 53
br i1 %33, label %34, label %62
34: ; preds = %28
%35 = load i8*, i8** %2
%36 = getelementptr inbounds i8, i8* %35, i64 1
%37 = load i8, i8* %36
%38 = sext i8 %37 to i32
%39 = icmp eq i32 %38, 48
br i1 %39, label %40, label %42
40: ; preds = %34
%41 = call i32 @Log(i8* getelementptr inbounds ([40 x i8], [40 x i8]* @.str.4, i64 0, i64 0))
br label %60
42: ; preds = %34
%43 = load i8*, i8** %2
%44 = getelementptr inbounds i8, i8* %43, i64 1
%45 = load i8, i8* %44
%46 = sext i8 %45 to i32
%47 = icmp eq i32 %46, 51
br i1 %47, label %48, label %50
48: ; preds = %42
%49 = call i32 @Log(i8* getelementptr inbounds ([70 x i8], [70 x i8]* @.str.5, i64 0, i64 0))
br label %59
50: ; preds = %42
%51 = load i8*, i8** %2
%52 = getelementptr inbounds i8, i8* %51, i64 1
%53 = load i8, i8* %52
%54 = sext i8 %53 to i32
%55 = icmp eq i32 %54, 53
br i1 %55, label %56, label %58
56: ; preds = %50
%57 = call i32 @Log(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0))
br label %58
58: ; preds = %56, %50
br label %59
59: ; preds = %58, %48
br label %60
60: ; preds = %59, %40
%61 = call i32 @Log(i8* getelementptr inbounds ([110 x i8], [110 x i8]* @.str.6, i64 0, i64 0))
br label %62
62: ; preds = %60, %28
br label %63
63: ; preds = %62, %25
ret void
}

LLVM IR (-O2):
@.str = [47 x i8] c"There seems to be an error in the connections.\00"
@.str.1 = [27 x i8] c"Requested action not taken\00"
@.str.2 = [35 x i8] c"Retry the download after sometime.\00"
@.str.3 = [93 x i8] c"If the error persists, please report this with the command line used to murat@enderunix.org.\00"
@.str.4 = [40 x i8] c"The server has reported a syntax error.\00"
@.str.5 = [70 x i8] c"Error relating to login; checkout the previous message, if available.\00"
@.str.6 = [110 x i8] c"If you feel this is an error with aget, please report this with the command line used to murat@enderunix.org.\00"
define void @handleFTPRetcode(i8* nocapture %0) {
%2 = load i8, i8* %0
switch i8 %2, label %22 [
i8 52, label %3
i8 53, label %10
]
3: ; preds = %1
%4 = getelementptr inbounds i8, i8* %0, i64 1
%5 = load i8, i8* %4
switch i8 %5, label %15 [
i8 50, label %7
i8 53, label %6
]
6: ; preds = %3
br label %7
7: ; preds = %3, %6
%8 = phi i8* [ getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0), %6 ], [ getelementptr inbounds ([47 x i8], [47 x i8]* @.str, i64 0, i64 0), %3 ]
%9 = tail call i32 @Log(i8* %8)
br label %15
10: ; preds = %1
%11 = getelementptr inbounds i8, i8* %0, i64 1
%12 = load i8, i8* %11
switch i8 %12, label %19 [
i8 48, label %15
i8 51, label %13
i8 53, label %14
]
13: ; preds = %10
br label %15
14: ; preds = %10
br label %15
15: ; preds = %13, %14, %10, %3, %7
%16 = phi i8* [ getelementptr inbounds ([35 x i8], [35 x i8]* @.str.2, i64 0, i64 0), %7 ], [ getelementptr inbounds ([35 x i8], [35 x i8]* @.str.2, i64 0, i64 0), %3 ], [ getelementptr inbounds ([70 x i8], [70 x i8]* @.str.5, i64 0, i64 0), %13 ], [ getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0), %14 ], [ getelementptr inbounds ([40 x i8], [40 x i8]* @.str.4, i64 0, i64 0), %10 ]
%17 = phi i8* [ getelementptr inbounds ([93 x i8], [93 x i8]* @.str.3, i64 0, i64 0), %7 ], [ getelementptr inbounds ([93 x i8], [93 x i8]* @.str.3, i64 0, i64 0), %3 ], [ getelementptr inbounds ([110 x i8], [110 x i8]* @.str.6, i64 0, i64 0), %13 ], [ getelementptr inbounds ([110 x i8], [110 x i8]* @.str.6, i64 0, i64 0), %14 ], [ getelementptr inbounds ([110 x i8], [110 x i8]* @.str.6, i64 0, i64 0), %10 ]
%18 = tail call i32 @Log(i8* %16)
br label %19
19: ; preds = %15, %10
%20 = phi i8* [ getelementptr inbounds ([110 x i8], [110 x i8]* @.str.6, i64 0, i64 0), %10 ], [ %17, %15 ]
%21 = tail call i32 @Log(i8* %20)
br label %22
22: ; preds = %19, %1
ret void
}