#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 *);
bool isValidConjecture(char *con) {
  int i;
  char *conjecture[2] = {"AND", "OR"};
  if (con == NULL)
    return false;
  for (i = 0; i < 2; i++) {
    if ((strcmp(conjecture[i], con) == 0))
      return true;
  }
  return false;
}


x86 assembly (clang, -O0):
<isValidConjecture>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x10(%rbp)
mov    0x2ced(%rip),%rax
mov    %rax,-0x30(%rbp)
mov    0x2cea(%rip),%rax
mov    %rax,-0x28(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1149 <isValidConjecture+0x39>
movl   $0x0,-0x4(%rbp)
jmp    119c <isValidConjecture+0x8c>
movl   $0x0,-0x14(%rbp)
cmpl   $0x2,-0x14(%rbp)
jge    1195 <isValidConjecture+0x85>
movslq -0x14(%rbp),%rax
mov    -0x30(%rbp,%rax,8),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <strcmp@plt>
cmp    $0x0,%rax
jne    1182 <isValidConjecture+0x72>
movl   $0x1,-0x4(%rbp)
jmp    119c <isValidConjecture+0x8c>
jmp    1187 <isValidConjecture+0x77>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1150 <isValidConjecture+0x40>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<isValidConjecture>:
push   %rbx
test   %rdi,%rdi
je     1149 <isValidConjecture+0x39>
mov    %rdi,%rbx
lea    0xee0(%rip),%rdi
mov    %rbx,%rsi
call   1030 <strcmp@plt>
test   %rax,%rax
je     114d <isValidConjecture+0x3d>
lea    0xed0(%rip),%rdi
mov    %rbx,%rsi
call   1030 <strcmp@plt>
mov    %rax,%rcx
xor    %eax,%eax
test   %rcx,%rcx
sete   %al
pop    %rbx
ret
xor    %eax,%eax
pop    %rbx
ret
mov    $0x1,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [4 x i8] c"AND\00"
@.str.1 = [3 x i8] c"OR\00"
@__const.isValidConjecture.conjecture = [2 x i8*] [i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i32 0, i32 0)]
define i32 @isValidConjecture(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
%4 = alloca i32
%5 = alloca [2 x i8*]
store i8* %0, i8** %3
%6 = bitcast [2 x i8*]* %5 to i8*
%7 = load i8*, i8** %3
%8 = icmp eq i8* %7, null
br i1 %8, label %9, label %10
9: ; preds = %1
store i32 0, i32* %2
br label %28
10: ; preds = %1
store i32 0, i32* %4
br label %11
11: ; preds = %24, %10
%12 = load i32, i32* %4
%13 = icmp slt i32 %12, 2
br i1 %13, label %14, label %27
14: ; preds = %11
%15 = load i32, i32* %4
%16 = sext i32 %15 to i64
%17 = getelementptr inbounds [2 x i8*], [2 x i8*]* %5, i64 0, i64 %16
%18 = load i8*, i8** %17
%19 = load i8*, i8** %3
%20 = call i64 @strcmp(i8* %18, i8* %19)
%21 = icmp eq i64 %20, 0
br i1 %21, label %22, label %23
22: ; preds = %14
store i32 1, i32* %2
br label %28
23: ; preds = %14
br label %24
24: ; preds = %23
%25 = load i32, i32* %4
%26 = add nsw i32 %25, 1
store i32 %26, i32* %4
br label %11
27: ; preds = %11
store i32 0, i32* %2
br label %28
28: ; preds = %27, %22, %9
%29 = load i32, i32* %2
ret i32 %29
}

LLVM IR (-O2):
@.str = [4 x i8] c"AND\00"
@.str.1 = [3 x i8] c"OR\00"
define i32 @isValidConjecture(i8* %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %10, label %3
3: ; preds = %1
%4 = tail call i64 @strcmp(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i8* %0)
%5 = icmp eq i64 %4, 0
br i1 %5, label %10, label %6
6: ; preds = %3
%7 = tail call i64 @strcmp(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* %0)
%8 = icmp eq i64 %7, 0
%9 = zext i1 %8 to i32
br label %10
10: ; preds = %6, %3, %1
%11 = phi i32 [ 0, %1 ], [ 1, %3 ], [ %9, %6 ]
ret i32 %11
}