#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*/ synctex_ignore_leading_dot_slash_in_path(char const **);
int _synctex_is_equivalent_file_name(const char *lhs, const char *rhs) {
  synctex_ignore_leading_dot_slash_in_path(&lhs);
  synctex_ignore_leading_dot_slash_in_path(&rhs);
next_character:
  if (('/' == *lhs)) {
    if (!('/' == *rhs)) {
      return 0;
    }
    ++lhs;
    ++rhs;
    synctex_ignore_leading_dot_slash_in_path(&lhs);
    synctex_ignore_leading_dot_slash_in_path(&rhs);
    goto next_character;
  } else if (('/' == *rhs)) {
    return 0;
  } else if ((*lhs != *rhs)) {
    return 0;
  } else if (!*lhs) {
    return *rhs ? 0 : -1;
  } else if (!*rhs) {
    return 0;
  }
  ++lhs;
  ++rhs;
  goto next_character;
}


x86 assembly (clang, -O0):
<_synctex_is_equivalent_file_name>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
lea    -0x10(%rbp),%rdi
call   1030 <synctex_ignore_leading_dot_slash_in_path@plt>
lea    -0x18(%rbp),%rdi
call   1030 <synctex_ignore_leading_dot_slash_in_path@plt>
mov    -0x10(%rbp),%rax
movsbl (%rax),%ecx
mov    $0x2f,%eax
cmp    %ecx,%eax
jne    1195 <_synctex_is_equivalent_file_name+0x85>
mov    -0x18(%rbp),%rax
movsbl (%rax),%ecx
mov    $0x2f,%eax
cmp    %ecx,%eax
je     1166 <_synctex_is_equivalent_file_name+0x56>
movl   $0x0,-0x4(%rbp)
jmp    124a <_synctex_is_equivalent_file_name+0x13a>
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
mov    -0x18(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x18(%rbp)
lea    -0x10(%rbp),%rdi
call   1030 <synctex_ignore_leading_dot_slash_in_path@plt>
lea    -0x18(%rbp),%rdi
call   1030 <synctex_ignore_leading_dot_slash_in_path@plt>
jmp    1132 <_synctex_is_equivalent_file_name+0x22>
mov    -0x18(%rbp),%rax
movsbl (%rax),%ecx
mov    $0x2f,%eax
cmp    %ecx,%eax
jne    11b5 <_synctex_is_equivalent_file_name+0xa5>
movl   $0x0,-0x4(%rbp)
jmp    124a <_synctex_is_equivalent_file_name+0x13a>
mov    -0x10(%rbp),%rax
movsbl (%rax),%eax
mov    -0x18(%rbp),%rcx
movsbl (%rcx),%ecx
cmp    %ecx,%eax
je     11d7 <_synctex_is_equivalent_file_name+0xc7>
movl   $0x0,-0x4(%rbp)
jmp    124a <_synctex_is_equivalent_file_name+0x13a>
mov    -0x10(%rbp),%rax
cmpb   $0x0,(%rax)
jne    1200 <_synctex_is_equivalent_file_name+0xf0>
mov    -0x18(%rbp),%rax
movsbl (%rax),%edx
mov    $0xffffffff,%eax
xor    %ecx,%ecx
cmp    $0x0,%edx
cmovne %ecx,%eax
mov    %eax,-0x4(%rbp)
jmp    124a <_synctex_is_equivalent_file_name+0x13a>
mov    -0x18(%rbp),%rax
cmpb   $0x0,(%rax)
jne    1219 <_synctex_is_equivalent_file_name+0x109>
movl   $0x0,-0x4(%rbp)
jmp    124a <_synctex_is_equivalent_file_name+0x13a>
jmp    121e <_synctex_is_equivalent_file_name+0x10e>
jmp    1223 <_synctex_is_equivalent_file_name+0x113>
jmp    1228 <_synctex_is_equivalent_file_name+0x118>
jmp    122d <_synctex_is_equivalent_file_name+0x11d>
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x10(%rbp)
mov    -0x18(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x18(%rbp)
jmp    1132 <_synctex_is_equivalent_file_name+0x22>
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<_synctex_is_equivalent_file_name>:
push   %r15
push   %r14
push   %rbx
sub    $0x10,%rsp
mov    %rdi,0x8(%rsp)
mov    %rsi,(%rsp)
lea    0x8(%rsp),%r14
mov    %r14,%rdi
call   1030 <synctex_ignore_leading_dot_slash_in_path@plt>
mov    %rsp,%r15
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    %r15,%rdi
call   1030 <synctex_ignore_leading_dot_slash_in_path@plt>
mov    0x8(%rsp),%rdx
movzbl (%rdx),%esi
mov    (%rsp),%rcx
movzbl (%rcx),%ebx
cmp    $0x2f,%sil
je     1190 <_synctex_is_equivalent_file_name+0x80>
xor    %eax,%eax
cmp    $0x2f,%bl
je     11b9 <_synctex_is_equivalent_file_name+0xa9>
cmp    %bl,%sil
jne    11b9 <_synctex_is_equivalent_file_name+0xa9>
test   %sil,%sil
je     11b0 <_synctex_is_equivalent_file_name+0xa0>
add    $0x1,%rdx
mov    %rdx,0x8(%rsp)
add    $0x1,%rcx
mov    %rcx,(%rsp)
jmp    1148 <_synctex_is_equivalent_file_name+0x38>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
cmp    $0x2f,%bl
jne    11b7 <_synctex_is_equivalent_file_name+0xa7>
add    $0x1,%rdx
mov    %rdx,0x8(%rsp)
add    $0x1,%rcx
mov    %rcx,(%rsp)
mov    %r14,%rdi
call   1030 <synctex_ignore_leading_dot_slash_in_path@plt>
jmp    1140 <_synctex_is_equivalent_file_name+0x30>
mov    $0xffffffff,%eax
jmp    11b9 <_synctex_is_equivalent_file_name+0xa9>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define i32 @_synctex_is_equivalent_file_name(i8* %0, i8* %1) {
%3 = alloca i32
%4 = alloca i8*
%5 = alloca i8*
store i8* %0, i8** %4
store i8* %1, i8** %5
%6 = call i32 @synctex_ignore_leading_dot_slash_in_path(i8** %4)
%7 = call i32 @synctex_ignore_leading_dot_slash_in_path(i8** %5)
br label %8
8: ; preds = %61, %19, %2
%9 = load i8*, i8** %4
%10 = load i8, i8* %9
%11 = sext i8 %10 to i32
%12 = icmp eq i32 47, %11
br i1 %12, label %13, label %26
13: ; preds = %8
%14 = load i8*, i8** %5
%15 = load i8, i8* %14
%16 = sext i8 %15 to i32
%17 = icmp eq i32 47, %16
br i1 %17, label %19, label %18
18: ; preds = %13
store i32 0, i32* %3
br label %66
19: ; preds = %13
%20 = load i8*, i8** %4
%21 = getelementptr inbounds i8, i8* %20, i32 1
store i8* %21, i8** %4
%22 = load i8*, i8** %5
%23 = getelementptr inbounds i8, i8* %22, i32 1
store i8* %23, i8** %5
%24 = call i32 @synctex_ignore_leading_dot_slash_in_path(i8** %4)
%25 = call i32 @synctex_ignore_leading_dot_slash_in_path(i8** %5)
br label %8
26: ; preds = %8
%27 = load i8*, i8** %5
%28 = load i8, i8* %27
%29 = sext i8 %28 to i32
%30 = icmp eq i32 47, %29
br i1 %30, label %31, label %32
31: ; preds = %26
store i32 0, i32* %3
br label %66
32: ; preds = %26
%33 = load i8*, i8** %4
%34 = load i8, i8* %33
%35 = sext i8 %34 to i32
%36 = load i8*, i8** %5
%37 = load i8, i8* %36
%38 = sext i8 %37 to i32
%39 = icmp ne i32 %35, %38
br i1 %39, label %40, label %41
40: ; preds = %32
store i32 0, i32* %3
br label %66
41: ; preds = %32
%42 = load i8*, i8** %4
%43 = load i8, i8* %42
%44 = icmp ne i8 %43, 0
br i1 %44, label %52, label %45
45: ; preds = %41
%46 = load i8*, i8** %5
%47 = load i8, i8* %46
%48 = sext i8 %47 to i32
%49 = icmp ne i32 %48, 0
%50 = zext i1 %49 to i64
%51 = select i1 %49, i32 0, i32 -1
store i32 %51, i32* %3
br label %66
52: ; preds = %41
%53 = load i8*, i8** %5
%54 = load i8, i8* %53
%55 = icmp ne i8 %54, 0
br i1 %55, label %57, label %56
56: ; preds = %52
store i32 0, i32* %3
br label %66
57: ; preds = %52
br label %58
58: ; preds = %57
br label %59
59: ; preds = %58
br label %60
60: ; preds = %59
br label %61
61: ; preds = %60
%62 = load i8*, i8** %4
%63 = getelementptr inbounds i8, i8* %62, i32 1
store i8* %63, i8** %4
%64 = load i8*, i8** %5
%65 = getelementptr inbounds i8, i8* %64, i32 1
store i8* %65, i8** %5
br label %8
66: ; preds = %56, %45, %40, %31, %18
%67 = load i32, i32* %3
ret i32 %67
}

LLVM IR (-O2):
define i32 @_synctex_is_equivalent_file_name(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%5 = call i32 @synctex_ignore_leading_dot_slash_in_path(i8** %3)
%6 = call i32 @synctex_ignore_leading_dot_slash_in_path(i8** %4)
br label %7
7: ; preds = %20, %2
%8 = load i8*, i8** %3
%9 = load i8, i8* %8
%10 = icmp eq i8 %9, 47
%11 = load i8*, i8** %4
%12 = load i8, i8* %11
br i1 %10, label %13, label %21
13: ; preds = %7
%14 = icmp eq i8 %12, 47
br i1 %14, label %15, label %30
15: ; preds = %13
%16 = getelementptr inbounds i8, i8* %8, i64 1
store i8* %16, i8** %3
%17 = getelementptr inbounds i8, i8* %11, i64 1
store i8* %17, i8** %4
%18 = call i32 @synctex_ignore_leading_dot_slash_in_path(i8** %3)
%19 = call i32 @synctex_ignore_leading_dot_slash_in_path(i8** %4)
br label %20
20: ; preds = %15, %27
br label %7
21: ; preds = %7
%22 = icmp ne i8 %12, 47
%23 = icmp eq i8 %9, %12
%24 = select i1 %22, i1 %23, i1 false
br i1 %24, label %25, label %30
25: ; preds = %21
%26 = icmp eq i8 %9, 0
br i1 %26, label %30, label %27
27: ; preds = %25
%28 = getelementptr inbounds i8, i8* %8, i64 1
store i8* %28, i8** %3
%29 = getelementptr inbounds i8, i8* %11, i64 1
store i8* %29, i8** %4
br label %20
30: ; preds = %21, %13, %25
%31 = phi i32 [ -1, %25 ], [ 0, %13 ], [ 0, %21 ]
ret i32 %31
}