#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 main1(int);
int /*<<< orphan*/ printf(char *, int, int);
int main() {
  int c1 = 3;
  int c2 = 5;
  int i;
  int tdoub = 1;
  while (tdoub <= 10) {
    if ((main1(c1) == 1) && (main1(c2) == 1) && (c2 - c1 == 2)) {
      printf("(%d, %d)\n", c1, c2);
      tdoub++;
    }
    c1++;
    c2++;
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x3,-0x8(%rbp)
movl   $0x5,-0xc(%rbp)
movl   $0x1,-0x14(%rbp)
cmpl   $0xa,-0x14(%rbp)
jg     11b1 <main+0x91>
mov    -0x8(%rbp),%edi
call   1040 <main1@plt>
cmp    $0x1,%eax
jne    119a <main+0x7a>
mov    -0xc(%rbp),%edi
call   1040 <main1@plt>
cmp    $0x1,%eax
jne    119a <main+0x7a>
mov    -0xc(%rbp),%eax
sub    -0x8(%rbp),%eax
cmp    $0x2,%eax
jne    119a <main+0x7a>
mov    -0x8(%rbp),%esi
mov    -0xc(%rbp),%edx
lea    0xe74(%rip),%rdi
call   1030 <printf@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
mov    -0xc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0xc(%rbp)
jmp    1144 <main+0x24>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    $0x3,%ebx
mov    $0x1,%r15d
lea    0xec7(%rip),%r14
jmp    1149 <main+0x29>
nopl   0x0(%rax,%rax,1)
add    $0x1,%ebx
cmp    $0xb,%r15d
jge    1176 <main+0x56>
mov    %ebx,%edi
call   1040 <main1@plt>
cmp    $0x1,%eax
jne    1140 <main+0x20>
lea    0x2(%rbx),%ebp
mov    %ebp,%edi
call   1040 <main1@plt>
cmp    $0x1,%eax
jne    1140 <main+0x20>
mov    %r14,%rdi
mov    %ebx,%esi
mov    %ebp,%edx
call   1030 <printf@plt>
add    $0x1,%r15d
jmp    1140 <main+0x20>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [10 x i8] c"(%d, %d)\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 0, i32* %1
store i32 3, i32* %2
store i32 5, i32* %3
store i32 1, i32* %5
br label %6
6: ; preds = %28, %0
%7 = load i32, i32* %5
%8 = icmp sle i32 %7, 10
br i1 %8, label %9, label %33
9: ; preds = %6
%10 = load i32, i32* %2
%11 = call i32 @main1(i32 %10)
%12 = icmp eq i32 %11, 1
br i1 %12, label %13, label %28
13: ; preds = %9
%14 = load i32, i32* %3
%15 = call i32 @main1(i32 %14)
%16 = icmp eq i32 %15, 1
br i1 %16, label %17, label %28
17: ; preds = %13
%18 = load i32, i32* %3
%19 = load i32, i32* %2
%20 = sub nsw i32 %18, %19
%21 = icmp eq i32 %20, 2
br i1 %21, label %22, label %28
22: ; preds = %17
%23 = load i32, i32* %2
%24 = load i32, i32* %3
%25 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i32 %23, i32 %24)
%26 = load i32, i32* %5
%27 = add nsw i32 %26, 1
store i32 %27, i32* %5
br label %28
28: ; preds = %22, %17, %13, %9
%29 = load i32, i32* %2
%30 = add nsw i32 %29, 1
store i32 %30, i32* %2
%31 = load i32, i32* %3
%32 = add nsw i32 %31, 1
store i32 %32, i32* %3
br label %6
33: ; preds = %6
ret i32 0
}

LLVM IR (-O2):
@.str = [10 x i8] c"(%d, %d)\0A\00"
define i32 @main() {
br label %1
1: ; preds = %0, %13
%2 = phi i32 [ 1, %0 ], [ %14, %13 ]
%3 = phi i32 [ 3, %0 ], [ %15, %13 ]
%4 = phi i32 [ 5, %0 ], [ %16, %13 ]
%5 = tail call i32 @main1(i32 %3)
%6 = icmp eq i32 %5, 1
br i1 %6, label %7, label %13
7: ; preds = %1
%8 = tail call i32 @main1(i32 %4)
%9 = icmp eq i32 %8, 1
br i1 %9, label %10, label %13
10: ; preds = %7
%11 = tail call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), i32 %3, i32 %4)
%12 = add nsw i32 %2, 1
br label %13
13: ; preds = %10, %7, %1
%14 = phi i32 [ %12, %10 ], [ %2, %7 ], [ %2, %1 ]
%15 = add nuw nsw i32 %3, 1
%16 = add nuw nsw i32 %4, 1
%17 = icmp slt i32 %14, 11
br i1 %17, label %1, label %18
18: ; preds = %13
ret i32 0
}