#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 */
scalar_t__ strcmp(char *, char *);
scalar_t__ strlen(char *);
int is_label_anonymous(char *label) {
  int length, i;
  char c;
  if (strcmp(label, "_f") == 0 || strcmp(label, "_F") == 0 ||
      strcmp(label, "_b") == 0 || strcmp(label, "_B") == 0 ||
      strcmp(label, "__") == 0)
    return 1;
  c = *label;
  if (!(c == '-' || c == '+'))
    return 0;
  length = (int)strlen(label);
  for (i = 0; i < length; i++) {
    if (*(label + i) != c)
      return 0;
  }
  return 1;
}


x86 assembly (clang, -O0):
<is_label_anonymous>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
lea    0xec9(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
je     11ae <is_label_anonymous+0x8e>
mov    -0x10(%rbp),%rdi
lea    0xeb2(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
je     11ae <is_label_anonymous+0x8e>
mov    -0x10(%rbp),%rdi
lea    0xe9b(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
je     11ae <is_label_anonymous+0x8e>
mov    -0x10(%rbp),%rdi
lea    0xe84(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
je     11ae <is_label_anonymous+0x8e>
mov    -0x10(%rbp),%rdi
lea    0xe6d(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
jne    11ba <is_label_anonymous+0x9a>
movl   $0x1,-0x4(%rbp)
jmp    1246 <is_label_anonymous+0x126>
mov    -0x10(%rbp),%rax
mov    (%rax),%al
mov    %al,-0x19(%rbp)
movsbl -0x19(%rbp),%eax
cmp    $0x2d,%eax
je     11e9 <is_label_anonymous+0xc9>
movsbl -0x19(%rbp),%eax
cmp    $0x2b,%eax
je     11e9 <is_label_anonymous+0xc9>
movl   $0x0,-0x4(%rbp)
jmp    1246 <is_label_anonymous+0x126>
mov    -0x10(%rbp),%rdi
call   1030 <strlen@plt>
mov    %eax,-0x14(%rbp)
movl   $0x0,-0x18(%rbp)
mov    -0x18(%rbp),%eax
cmp    -0x14(%rbp),%eax
jge    123f <is_label_anonymous+0x11f>
mov    -0x10(%rbp),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
movsbl -0x19(%rbp),%ecx
cmp    %ecx,%eax
je     122c <is_label_anonymous+0x10c>
movl   $0x0,-0x4(%rbp)
jmp    1246 <is_label_anonymous+0x126>
jmp    1231 <is_label_anonymous+0x111>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    11fc <is_label_anonymous+0xdc>
movl   $0x1,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<is_label_anonymous>:
push   %rbp
push   %r14
push   %rbx
mov    %rdi,%rbx
lea    0xed2(%rip),%rsi
call   1040 <strcmp@plt>
mov    $0x1,%ebp
test   %rax,%rax
je     11d4 <is_label_anonymous+0xb4>
lea    0xebb(%rip),%rsi
mov    %rbx,%rdi
call   1040 <strcmp@plt>
test   %rax,%rax
je     11d4 <is_label_anonymous+0xb4>
lea    0xeaa(%rip),%rsi
mov    %rbx,%rdi
call   1040 <strcmp@plt>
test   %rax,%rax
je     11d4 <is_label_anonymous+0xb4>
lea    0xe99(%rip),%rsi
mov    %rbx,%rdi
call   1040 <strcmp@plt>
test   %rax,%rax
je     11d4 <is_label_anonymous+0xb4>
lea    0xe88(%rip),%rsi
mov    %rbx,%rdi
call   1040 <strcmp@plt>
test   %rax,%rax
je     11d4 <is_label_anonymous+0xb4>
mov    (%rbx),%r14b
cmp    $0x2d,%r14b
je     11a0 <is_label_anonymous+0x80>
cmp    $0x2b,%r14b
jne    11d2 <is_label_anonymous+0xb2>
mov    %rbx,%rdi
call   1030 <strlen@plt>
test   %eax,%eax
jle    11d4 <is_label_anonymous+0xb4>
mov    %eax,%eax
mov    $0x1,%ecx
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
cmp    %rcx,%rax
je     11d4 <is_label_anonymous+0xb4>
lea    0x1(%rcx),%rdx
cmp    %r14b,(%rbx,%rcx,1)
mov    %rdx,%rcx
je     11c0 <is_label_anonymous+0xa0>
xor    %ebp,%ebp
mov    %ebp,%eax
pop    %rbx
pop    %r14
pop    %rbp
ret

LLVM IR (-O0):
@.str = [3 x i8] c"_f\00"
@.str.1 = [3 x i8] c"_F\00"
@.str.2 = [3 x i8] c"_b\00"
@.str.3 = [3 x i8] c"_B\00"
@.str.4 = [3 x i8] c"__\00"
define i32 @is_label_anonymous(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
%4 = alloca i32
%5 = alloca i32
%6 = alloca i8
store i8* %0, i8** %3
%7 = load i8*, i8** %3
%8 = call i64 @strcmp(i8* %7, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%9 = icmp eq i64 %8, 0
br i1 %9, label %26, label %10
10: ; preds = %1
%11 = load i8*, i8** %3
%12 = call i64 @strcmp(i8* %11, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%13 = icmp eq i64 %12, 0
br i1 %13, label %26, label %14
14: ; preds = %10
%15 = load i8*, i8** %3
%16 = call i64 @strcmp(i8* %15, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%17 = icmp eq i64 %16, 0
br i1 %17, label %26, label %18
18: ; preds = %14
%19 = load i8*, i8** %3
%20 = call i64 @strcmp(i8* %19, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%21 = icmp eq i64 %20, 0
br i1 %21, label %26, label %22
22: ; preds = %18
%23 = load i8*, i8** %3
%24 = call i64 @strcmp(i8* %23, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0))
%25 = icmp eq i64 %24, 0
br i1 %25, label %26, label %27
26: ; preds = %22, %18, %14, %10, %1
store i32 1, i32* %2
br label %62
27: ; preds = %22
%28 = load i8*, i8** %3
%29 = load i8, i8* %28
store i8 %29, i8* %6
%30 = load i8, i8* %6
%31 = sext i8 %30 to i32
%32 = icmp eq i32 %31, 45
br i1 %32, label %38, label %33
33: ; preds = %27
%34 = load i8, i8* %6
%35 = sext i8 %34 to i32
%36 = icmp eq i32 %35, 43
br i1 %36, label %38, label %37
37: ; preds = %33
store i32 0, i32* %2
br label %62
38: ; preds = %33, %27
%39 = load i8*, i8** %3
%40 = call i64 @strlen(i8* %39)
%41 = trunc i64 %40 to i32
store i32 %41, i32* %4
store i32 0, i32* %5
br label %42
42: ; preds = %58, %38
%43 = load i32, i32* %5
%44 = load i32, i32* %4
%45 = icmp slt i32 %43, %44
br i1 %45, label %46, label %61
46: ; preds = %42
%47 = load i8*, i8** %3
%48 = load i32, i32* %5
%49 = sext i32 %48 to i64
%50 = getelementptr inbounds i8, i8* %47, i64 %49
%51 = load i8, i8* %50
%52 = sext i8 %51 to i32
%53 = load i8, i8* %6
%54 = sext i8 %53 to i32
%55 = icmp ne i32 %52, %54
br i1 %55, label %56, label %57
56: ; preds = %46
store i32 0, i32* %2
br label %62
57: ; preds = %46
br label %58
58: ; preds = %57
%59 = load i32, i32* %5
%60 = add nsw i32 %59, 1
store i32 %60, i32* %5
br label %42
61: ; preds = %42
store i32 1, i32* %2
br label %62
62: ; preds = %61, %56, %37, %26
%63 = load i32, i32* %2
ret i32 %63
}

LLVM IR (-O2):
@.str = [3 x i8] c"_f\00"
@.str.1 = [3 x i8] c"_F\00"
@.str.2 = [3 x i8] c"_b\00"
@.str.3 = [3 x i8] c"_B\00"
@.str.4 = [3 x i8] c"__\00"
define i32 @is_label_anonymous(i8* %0) {
%2 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%3 = icmp eq i64 %2, 0
br i1 %3, label %32, label %4
4: ; preds = %1
%5 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%6 = icmp eq i64 %5, 0
br i1 %6, label %32, label %7
7: ; preds = %4
%8 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%9 = icmp eq i64 %8, 0
br i1 %9, label %32, label %10
10: ; preds = %7
%11 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%12 = icmp eq i64 %11, 0
br i1 %12, label %32, label %13
13: ; preds = %10
%14 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0))
%15 = icmp eq i64 %14, 0
br i1 %15, label %32, label %16
16: ; preds = %13
%17 = load i8, i8* %0
switch i8 %17, label %32 [
i8 45, label %18
i8 43, label %18
]
18: ; preds = %16, %16
%19 = tail call i64 @strlen(i8* %0)
%20 = trunc i64 %19 to i32
%21 = icmp sgt i32 %20, 0
br i1 %21, label %22, label %32
22: ; preds = %18
%23 = and i64 %19, 4294967295
br label %24
24: ; preds = %22, %27
%25 = phi i64 [ 1, %22 ], [ %31, %27 ]
%26 = icmp eq i64 %25, %23
br i1 %26, label %32, label %27
27: ; preds = %24
%28 = getelementptr inbounds i8, i8* %0, i64 %25
%29 = load i8, i8* %28
%30 = icmp eq i8 %29, %17
%31 = add nuw nsw i64 %25, 1
br i1 %30, label %24, label %32
32: ; preds = %27, %24, %18, %16, %1, %4, %7, %10, %13
%33 = phi i32 [ 1, %13 ], [ 1, %10 ], [ 1, %7 ], [ 1, %4 ], [ 1, %1 ], [ 0, %16 ], [ 1, %18 ], [ 0, %27 ], [ 1, %24 ]
ret i32 %33
}