#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 *, ...);
int GetTheAck(char *message) {
  static int fail_wait_count = 0;
  if (message[0] == 10 && message[1] == 10 && message[2] == 'O' &&
      message[3] == 'K' && message[4] == 10 && message[5] == 10) {
    fail_wait_count = 0;
    printf("FLTE:Acknowledgement OK Received from Telit\n");
    return 0;
  } else if (message[0] == 10 && message[1] == 10 && message[2] == 'N' &&
             message[3] == 'O' && message[4] == ' ' && message[5] == 'C' &&
             message[6] == 'A' && message[7] == 'R' && message[8] == 'R' &&
             message[9] == 'I' && message[10] == 'E' && message[11] == 'R' &&
             message[12] == 10 && message[13] == 10) {
    printf("FLTE:%s\n", message);
    printf("FLTE:No Carrier Information Received From Telit\n");
    fail_wait_count = 0;
    return 1;
  } else if (message[0] == 10 && message[1] == 10) {
    printf("FLTE:%s\n", message);
    printf("FLTE:Unexpected Response Received From Telit\n");
    return 1;
    fail_wait_count = 0;
  } else {
    printf("FLTE:Waiting for Telit Modem Response\n");
    fail_wait_count++;
    if (fail_wait_count >= 20) {
      fail_wait_count = 0;
      printf("FLTE:No Response  from Telit. \n");
      return 1;
    }
    return -1;
  }
}


x86 assembly (clang, -O0):
<GetTheAck>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0xa,%eax
jne    11a5 <GetTheAck+0x95>
mov    -0x10(%rbp),%rax
movsbl 0x1(%rax),%eax
cmp    $0xa,%eax
jne    11a5 <GetTheAck+0x95>
mov    -0x10(%rbp),%rax
movsbl 0x2(%rax),%eax
cmp    $0x4f,%eax
jne    11a5 <GetTheAck+0x95>
mov    -0x10(%rbp),%rax
movsbl 0x3(%rax),%eax
cmp    $0x4b,%eax
jne    11a5 <GetTheAck+0x95>
mov    -0x10(%rbp),%rax
movsbl 0x4(%rax),%eax
cmp    $0xa,%eax
jne    11a5 <GetTheAck+0x95>
mov    -0x10(%rbp),%rax
movsbl 0x5(%rax),%eax
cmp    $0xa,%eax
jne    11a5 <GetTheAck+0x95>
movl   $0x0,0x2ea1(%rip)
lea    0xe6e(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x4(%rbp)
jmp    136a <GetTheAck+0x25a>
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0xa,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0x1(%rax),%eax
cmp    $0xa,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0x2(%rax),%eax
cmp    $0x4e,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0x3(%rax),%eax
cmp    $0x4f,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0x4(%rax),%eax
cmp    $0x20,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0x5(%rax),%eax
cmp    $0x43,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0x6(%rax),%eax
cmp    $0x41,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0x7(%rax),%eax
cmp    $0x52,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0x8(%rax),%eax
cmp    $0x52,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0x9(%rax),%eax
cmp    $0x49,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0xa(%rax),%eax
cmp    $0x45,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0xb(%rax),%eax
cmp    $0x52,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0xc(%rax),%eax
cmp    $0xa,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rax
movsbl 0xd(%rax),%eax
cmp    $0xa,%eax
jne    12c8 <GetTheAck+0x1b8>
mov    -0x10(%rbp),%rsi
lea    0xd90(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xd8b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,0x2d70(%rip)
movl   $0x1,-0x4(%rbp)
jmp    136a <GetTheAck+0x25a>
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
cmp    $0xa,%eax
jne    1315 <GetTheAck+0x205>
mov    -0x10(%rbp),%rax
movsbl 0x1(%rax),%eax
cmp    $0xa,%eax
jne    1315 <GetTheAck+0x205>
mov    -0x10(%rbp),%rsi
lea    0xd39(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xd65(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x1,-0x4(%rbp)
jmp    136a <GetTheAck+0x25a>
lea    0xd79(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    0x2d03(%rip),%eax
add    $0x1,%eax
mov    %eax,0x2cfa(%rip)
cmpl   $0x14,0x2cf3(%rip)
jl     1363 <GetTheAck+0x253>
movl   $0x0,0x2ce3(%rip)
lea    0xd6c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x1,-0x4(%rbp)
jmp    136a <GetTheAck+0x25a>
movl   $0xffffffff,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<GetTheAck>:
push   %rax
cmpb   $0xa,(%rdi)
jne    1161 <GetTheAck+0x41>
mov    %rdi,%rsi
cmpb   $0xa,0x1(%rdi)
jne    1161 <GetTheAck+0x41>
cmpb   $0x4f,0x2(%rsi)
jne    11a0 <GetTheAck+0x80>
cmpb   $0x4b,0x3(%rsi)
jne    11a0 <GetTheAck+0x80>
cmpb   $0xa,0x4(%rsi)
jne    11a0 <GetTheAck+0x80>
cmpb   $0xa,0x5(%rsi)
jne    11a0 <GetTheAck+0x80>
movl   $0x0,0x2ee3(%rip)
lea    0xf53(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
pop    %rcx
ret
lea    0xea1(%rip),%rdi
call   1030 <puts@plt>
mov    0x2ec1(%rip),%ecx
lea    0x1(%rcx),%eax
mov    %eax,0x2eb8(%rip)
mov    $0xffffffff,%eax
cmp    $0x13,%ecx
jl     122d <GetTheAck+0x10d>
movl   $0x0,0x2ea0(%rip)
lea    0xe94(%rip),%rdi
jmp    1223 <GetTheAck+0x103>
cmpb   $0x4e,0x2(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0x4f,0x3(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0x20,0x4(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0x43,0x5(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0x41,0x6(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0x52,0x7(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0x52,0x8(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0x49,0x9(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0x45,0xa(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0x52,0xb(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0xa,0xc(%rsi)
jne    120e <GetTheAck+0xee>
cmpb   $0xa,0xd(%rsi)
jne    120e <GetTheAck+0xee>
lea    0xe11(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe7e(%rip),%rdi
call   1030 <puts@plt>
movl   $0x0,0x2e28(%rip)
jmp    1228 <GetTheAck+0x108>
lea    0xdeb(%rip),%rdi
xor    %eax,%eax
call   1040 <printf@plt>
lea    0xe2b(%rip),%rdi
call   1030 <puts@plt>
mov    $0x1,%eax
pop    %rcx
ret

LLVM IR (-O0):
@GetTheAck.fail_wait_count = internal global i32 0
@.str = [45 x i8] c"FLTE:Acknowledgement OK Received from Telit\0A\00"
@.str.1 = [9 x i8] c"FLTE:%s\0A\00"
@.str.2 = [49 x i8] c"FLTE:No Carrier Information Received From Telit\0A\00"
@.str.3 = [46 x i8] c"FLTE:Unexpected Response Received From Telit\0A\00"
@.str.4 = [39 x i8] c"FLTE:Waiting for Telit Modem Response\0A\00"
@.str.5 = [32 x i8] c"FLTE:No Response from Telit. \0A\00"
define i32 @GetTheAck(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
store i8* %0, i8** %3
%4 = load i8*, i8** %3
%5 = getelementptr inbounds i8, i8* %4, i64 0
%6 = load i8, i8* %5
%7 = sext i8 %6 to i32
%8 = icmp eq i32 %7, 10
br i1 %8, label %9, label %41
9: ; preds = %1
%10 = load i8*, i8** %3
%11 = getelementptr inbounds i8, i8* %10, i64 1
%12 = load i8, i8* %11
%13 = sext i8 %12 to i32
%14 = icmp eq i32 %13, 10
br i1 %14, label %15, label %41
15: ; preds = %9
%16 = load i8*, i8** %3
%17 = getelementptr inbounds i8, i8* %16, i64 2
%18 = load i8, i8* %17
%19 = sext i8 %18 to i32
%20 = icmp eq i32 %19, 79
br i1 %20, label %21, label %41
21: ; preds = %15
%22 = load i8*, i8** %3
%23 = getelementptr inbounds i8, i8* %22, i64 3
%24 = load i8, i8* %23
%25 = sext i8 %24 to i32
%26 = icmp eq i32 %25, 75
br i1 %26, label %27, label %41
27: ; preds = %21
%28 = load i8*, i8** %3
%29 = getelementptr inbounds i8, i8* %28, i64 4
%30 = load i8, i8* %29
%31 = sext i8 %30 to i32
%32 = icmp eq i32 %31, 10
br i1 %32, label %33, label %41
33: ; preds = %27
%34 = load i8*, i8** %3
%35 = getelementptr inbounds i8, i8* %34, i64 5
%36 = load i8, i8* %35
%37 = sext i8 %36 to i32
%38 = icmp eq i32 %37, 10
br i1 %38, label %39, label %41
39: ; preds = %33
store i32 0, i32* @GetTheAck.fail_wait_count
%40 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str, i64 0, i64 0))
store i32 0, i32* %2
br label %154
41: ; preds = %33, %27, %21, %15, %9, %1
%42 = load i8*, i8** %3
%43 = getelementptr inbounds i8, i8* %42, i64 0
%44 = load i8, i8* %43
%45 = sext i8 %44 to i32
%46 = icmp eq i32 %45, 10
br i1 %46, label %47, label %129
47: ; preds = %41
%48 = load i8*, i8** %3
%49 = getelementptr inbounds i8, i8* %48, i64 1
%50 = load i8, i8* %49
%51 = sext i8 %50 to i32
%52 = icmp eq i32 %51, 10
br i1 %52, label %53, label %129
53: ; preds = %47
%54 = load i8*, i8** %3
%55 = getelementptr inbounds i8, i8* %54, i64 2
%56 = load i8, i8* %55
%57 = sext i8 %56 to i32
%58 = icmp eq i32 %57, 78
br i1 %58, label %59, label %129
59: ; preds = %53
%60 = load i8*, i8** %3
%61 = getelementptr inbounds i8, i8* %60, i64 3
%62 = load i8, i8* %61
%63 = sext i8 %62 to i32
%64 = icmp eq i32 %63, 79
br i1 %64, label %65, label %129
65: ; preds = %59
%66 = load i8*, i8** %3
%67 = getelementptr inbounds i8, i8* %66, i64 4
%68 = load i8, i8* %67
%69 = sext i8 %68 to i32
%70 = icmp eq i32 %69, 32
br i1 %70, label %71, label %129
71: ; preds = %65
%72 = load i8*, i8** %3
%73 = getelementptr inbounds i8, i8* %72, i64 5
%74 = load i8, i8* %73
%75 = sext i8 %74 to i32
%76 = icmp eq i32 %75, 67
br i1 %76, label %77, label %129
77: ; preds = %71
%78 = load i8*, i8** %3
%79 = getelementptr inbounds i8, i8* %78, i64 6
%80 = load i8, i8* %79
%81 = sext i8 %80 to i32
%82 = icmp eq i32 %81, 65
br i1 %82, label %83, label %129
83: ; preds = %77
%84 = load i8*, i8** %3
%85 = getelementptr inbounds i8, i8* %84, i64 7
%86 = load i8, i8* %85
%87 = sext i8 %86 to i32
%88 = icmp eq i32 %87, 82
br i1 %88, label %89, label %129
89: ; preds = %83
%90 = load i8*, i8** %3
%91 = getelementptr inbounds i8, i8* %90, i64 8
%92 = load i8, i8* %91
%93 = sext i8 %92 to i32
%94 = icmp eq i32 %93, 82
br i1 %94, label %95, label %129
95: ; preds = %89
%96 = load i8*, i8** %3
%97 = getelementptr inbounds i8, i8* %96, i64 9
%98 = load i8, i8* %97
%99 = sext i8 %98 to i32
%100 = icmp eq i32 %99, 73
br i1 %100, label %101, label %129
101: ; preds = %95
%102 = load i8*, i8** %3
%103 = getelementptr inbounds i8, i8* %102, i64 10
%104 = load i8, i8* %103
%105 = sext i8 %104 to i32
%106 = icmp eq i32 %105, 69
br i1 %106, label %107, label %129
107: ; preds = %101
%108 = load i8*, i8** %3
%109 = getelementptr inbounds i8, i8* %108, i64 11
%110 = load i8, i8* %109
%111 = sext i8 %110 to i32
%112 = icmp eq i32 %111, 82
br i1 %112, label %113, label %129
113: ; preds = %107
%114 = load i8*, i8** %3
%115 = getelementptr inbounds i8, i8* %114, i64 12
%116 = load i8, i8* %115
%117 = sext i8 %116 to i32
%118 = icmp eq i32 %117, 10
br i1 %118, label %119, label %129
119: ; preds = %113
%120 = load i8*, i8** %3
%121 = getelementptr inbounds i8, i8* %120, i64 13
%122 = load i8, i8* %121
%123 = sext i8 %122 to i32
%124 = icmp eq i32 %123, 10
br i1 %124, label %125, label %129
125: ; preds = %119
%126 = load i8*, i8** %3
%127 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i8* %126)
%128 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str.2, i64 0, i64 0))
store i32 0, i32* @GetTheAck.fail_wait_count
store i32 1, i32* %2
br label %154
129: ; preds = %119, %113, %107, %101, %95, %89, %83, %77, %71, %65, %59, %53, %47, %41
%130 = load i8*, i8** %3
%131 = getelementptr inbounds i8, i8* %130, i64 0
%132 = load i8, i8* %131
%133 = sext i8 %132 to i32
%134 = icmp eq i32 %133, 10
br i1 %134, label %135, label %145
135: ; preds = %129
%136 = load i8*, i8** %3
%137 = getelementptr inbounds i8, i8* %136, i64 1
%138 = load i8, i8* %137
%139 = sext i8 %138 to i32
%140 = icmp eq i32 %139, 10
br i1 %140, label %141, label %145
141: ; preds = %135
%142 = load i8*, i8** %3
%143 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i8* %142)
%144 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([46 x i8], [46 x i8]* @.str.3, i64 0, i64 0))
store i32 1, i32* %2
br label %154
145: ; preds = %135, %129
%146 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str.4, i64 0, i64 0))
%147 = load i32, i32* @GetTheAck.fail_wait_count
%148 = add nsw i32 %147, 1
store i32 %148, i32* @GetTheAck.fail_wait_count
%149 = load i32, i32* @GetTheAck.fail_wait_count
%150 = icmp sge i32 %149, 20
br i1 %150, label %151, label %153
151: ; preds = %145
store i32 0, i32* @GetTheAck.fail_wait_count
%152 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.5, i64 0, i64 0))
store i32 1, i32* %2
br label %154
153: ; preds = %145
store i32 -1, i32* %2
br label %154
154: ; preds = %153, %151, %141, %125, %39
%155 = load i32, i32* %2
ret i32 %155
}

LLVM IR (-O2):
@GetTheAck.fail_wait_count = internal unnamed_addr global i32 0
@.str.1 = [9 x i8] c"FLTE:%s\0A\00"
@str = [38 x i8] c"FLTE:Waiting for Telit Modem Response\00"
@str.6 = [31 x i8] c"FLTE:No Response from Telit. \00"
@str.7 = [45 x i8] c"FLTE:Unexpected Response Received From Telit\00"
@str.8 = [48 x i8] c"FLTE:No Carrier Information Received From Telit\00"
@str.9 = [44 x i8] c"FLTE:Acknowledgement OK Received from Telit\00"
define i32 @GetTheAck(i8* %0) {
%2 = load i8, i8* %0
%3 = icmp eq i8 %2, 10
br i1 %3, label %4, label %80
4: ; preds = %1
%5 = getelementptr inbounds i8, i8* %0, i64 1
%6 = load i8, i8* %5
%7 = icmp eq i8 %6, 10
br i1 %7, label %8, label %80
8: ; preds = %4
%9 = getelementptr inbounds i8, i8* %0, i64 2
%10 = load i8, i8* %9
%11 = icmp eq i8 %10, 79
br i1 %11, label %12, label %26
12: ; preds = %8
%13 = getelementptr inbounds i8, i8* %0, i64 3
%14 = load i8, i8* %13
%15 = icmp eq i8 %14, 75
br i1 %15, label %16, label %26
16: ; preds = %12
%17 = getelementptr inbounds i8, i8* %0, i64 4
%18 = load i8, i8* %17
%19 = icmp eq i8 %18, 10
br i1 %19, label %20, label %26
20: ; preds = %16
%21 = getelementptr inbounds i8, i8* %0, i64 5
%22 = load i8, i8* %21
%23 = icmp eq i8 %22, 10
br i1 %23, label %24, label %26
24: ; preds = %20
store i32 0, i32* @GetTheAck.fail_wait_count
%25 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([44 x i8], [44 x i8]* @str.9, i64 0, i64 0))
br label %87
26: ; preds = %20, %16, %12, %8
%27 = getelementptr inbounds i8, i8* %0, i64 2
%28 = load i8, i8* %27
%29 = icmp eq i8 %28, 78
br i1 %29, label %30, label %77
30: ; preds = %26
%31 = getelementptr inbounds i8, i8* %0, i64 3
%32 = load i8, i8* %31
%33 = icmp eq i8 %32, 79
br i1 %33, label %34, label %77
34: ; preds = %30
%35 = getelementptr inbounds i8, i8* %0, i64 4
%36 = load i8, i8* %35
%37 = icmp eq i8 %36, 32
br i1 %37, label %38, label %77
38: ; preds = %34
%39 = getelementptr inbounds i8, i8* %0, i64 5
%40 = load i8, i8* %39
%41 = icmp eq i8 %40, 67
br i1 %41, label %42, label %77
42: ; preds = %38
%43 = getelementptr inbounds i8, i8* %0, i64 6
%44 = load i8, i8* %43
%45 = icmp eq i8 %44, 65
br i1 %45, label %46, label %77
46: ; preds = %42
%47 = getelementptr inbounds i8, i8* %0, i64 7
%48 = load i8, i8* %47
%49 = icmp eq i8 %48, 82
br i1 %49, label %50, label %77
50: ; preds = %46
%51 = getelementptr inbounds i8, i8* %0, i64 8
%52 = load i8, i8* %51
%53 = icmp eq i8 %52, 82
br i1 %53, label %54, label %77
54: ; preds = %50
%55 = getelementptr inbounds i8, i8* %0, i64 9
%56 = load i8, i8* %55
%57 = icmp eq i8 %56, 73
br i1 %57, label %58, label %77
58: ; preds = %54
%59 = getelementptr inbounds i8, i8* %0, i64 10
%60 = load i8, i8* %59
%61 = icmp eq i8 %60, 69
br i1 %61, label %62, label %77
62: ; preds = %58
%63 = getelementptr inbounds i8, i8* %0, i64 11
%64 = load i8, i8* %63
%65 = icmp eq i8 %64, 82
br i1 %65, label %66, label %77
66: ; preds = %62
%67 = getelementptr inbounds i8, i8* %0, i64 12
%68 = load i8, i8* %67
%69 = icmp eq i8 %68, 10
br i1 %69, label %70, label %77
70: ; preds = %66
%71 = getelementptr inbounds i8, i8* %0, i64 13
%72 = load i8, i8* %71
%73 = icmp eq i8 %72, 10
br i1 %73, label %74, label %77
74: ; preds = %70
%75 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i8* %0)
%76 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([48 x i8], [48 x i8]* @str.8, i64 0, i64 0))
store i32 0, i32* @GetTheAck.fail_wait_count
br label %87
77: ; preds = %70, %66, %62, %58, %54, %50, %46, %42, %38, %34, %30, %26
%78 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i8* %0)
%79 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([45 x i8], [45 x i8]* @str.7, i64 0, i64 0))
br label %87
80: ; preds = %4, %1
%81 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([38 x i8], [38 x i8]* @str, i64 0, i64 0))
%82 = load i32, i32* @GetTheAck.fail_wait_count
%83 = add nsw i32 %82, 1
store i32 %83, i32* @GetTheAck.fail_wait_count
%84 = icmp sgt i32 %82, 18
br i1 %84, label %85, label %87
85: ; preds = %80
store i32 0, i32* @GetTheAck.fail_wait_count
%86 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @str.6, i64 0, i64 0))
br label %87
87: ; preds = %80, %85, %77, %74, %24
%88 = phi i32 [ 0, %24 ], [ 1, %74 ], [ 1, %77 ], [ 1, %85 ], [ -1, %80 ]
ret i32 %88
}