#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 */
char *strchr(char const *, char);
int tfd_quoteDetected(char const *aString) {
  char const *p;
  if (!aString)
    return 0;
  p = aString;
  while ((p = strchr(p, '\''))) {
    return 1;
  }
  p = aString;
  while ((p = strchr(p, '\"'))) {
    return 1;
  }
  return 0;
}


x86 assembly (clang, -O0):
<tfd_quoteDetected>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1133 <tfd_quoteDetected+0x23>
movl   $0x0,-0x4(%rbp)
jmp    119a <tfd_quoteDetected+0x8a>
mov    -0x10(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rdi
mov    $0x27,%esi
call   1030 <strchr@plt>
mov    %rax,-0x18(%rbp)
cmp    $0x0,%rax
je     1163 <tfd_quoteDetected+0x53>
movl   $0x1,-0x4(%rbp)
jmp    119a <tfd_quoteDetected+0x8a>
mov    -0x10(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rdi
mov    $0x22,%esi
call   1030 <strchr@plt>
mov    %rax,-0x18(%rbp)
cmp    $0x0,%rax
je     1193 <tfd_quoteDetected+0x83>
movl   $0x1,-0x4(%rbp)
jmp    119a <tfd_quoteDetected+0x8a>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<tfd_quoteDetected>:
push   %rbx
test   %rdi,%rdi
je     1132 <tfd_quoteDetected+0x22>
mov    %rdi,%rbx
mov    $0x27,%esi
call   1030 <strchr@plt>
mov    %rax,%rcx
mov    $0x1,%eax
test   %rcx,%rcx
je     1136 <tfd_quoteDetected+0x26>
pop    %rbx
ret
xor    %eax,%eax
pop    %rbx
ret
mov    %rbx,%rdi
mov    $0x22,%esi
call   1030 <strchr@plt>
mov    %rax,%rcx
xor    %eax,%eax
test   %rcx,%rcx
setne  %al
pop    %rbx
ret

LLVM IR (-O0):
define i32 @tfd_quoteDetected(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
%5 = load i8*, i8** %3
%6 = icmp ne i8* %5, null
br i1 %6, label %8, label %7
7: ; preds = %1
store i32 0, i32* %2
br label %23
8: ; preds = %1
%9 = load i8*, i8** %3
store i8* %9, i8** %4
br label %10
10: ; preds = %8
%11 = load i8*, i8** %4
%12 = call i8* @strchr(i8* %11, i8 signext 39)
store i8* %12, i8** %4
%13 = icmp ne i8* %12, null
br i1 %13, label %14, label %15
14: ; preds = %10
store i32 1, i32* %2
br label %23
15: ; preds = %10
%16 = load i8*, i8** %3
store i8* %16, i8** %4
br label %17
17: ; preds = %15
%18 = load i8*, i8** %4
%19 = call i8* @strchr(i8* %18, i8 signext 34)
store i8* %19, i8** %4
%20 = icmp ne i8* %19, null
br i1 %20, label %21, label %22
21: ; preds = %17
store i32 1, i32* %2
br label %23
22: ; preds = %17
store i32 0, i32* %2
br label %23
23: ; preds = %22, %21, %14, %7
%24 = load i32, i32* %2
ret i32 %24
}

LLVM IR (-O2):
define i32 @tfd_quoteDetected(i8* %0) {
%2 = icmp eq i8* %0, null
br i1 %2, label %10, label %3
3: ; preds = %1
%4 = tail call i8* @strchr(i8* %0, i8 signext 39)
%5 = icmp eq i8* %4, null
br i1 %5, label %6, label %10
6: ; preds = %3
%7 = tail call i8* @strchr(i8* %0, i8 signext 34)
%8 = icmp ne i8* %7, null
%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
}