#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 const *, char const *);
bool iskeyword(const char *lexeme) {
  static const char *KEYWORD[] = {
      "auto",    "double",   "int",      "struct",   "break",    "else",
      "long",    "switch",   "case",     "enum",     "register", "typedef",
      "char",    "extern",   "return",   "union",    "const",    "float",
      "short",   "unsigned", "continue", "for",      "signed",   "void",
      "default", "goto",     "sizeof",   "volatile", "do",       "if",
      "static",  "while"};
  for (int i = 0; i < 32; i++) {
    if (strcmp(KEYWORD[i], lexeme) == 0)
      return true;
  }
  return false;
}


x86 assembly (clang, -O0):
<iskeyword>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
cmpl   $0x20,-0x14(%rbp)
jge    116e <iskeyword+0x5e>
movslq -0x14(%rbp),%rcx
lea    0x2ef8(%rip),%rax
mov    (%rax,%rcx,8),%rdi
mov    -0x10(%rbp),%rsi
call   1030 <strcmp@plt>
cmp    $0x0,%rax
jne    115b <iskeyword+0x4b>
movl   $0x1,-0x4(%rbp)
jmp    1175 <iskeyword+0x65>
jmp    1160 <iskeyword+0x50>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    1123 <iskeyword+0x13>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<iskeyword>:
push   %r15
push   %r14
push   %rbx
mov    %rdi,%r14
lea    0xf61(%rip),%rdi
mov    %r14,%rsi
call   1030 <strcmp@plt>
test   %rax,%rax
je     116d <iskeyword+0x5d>
xor    %ecx,%ecx
lea    0xecb(%rip),%r15
cs nopw 0x0(%rax,%rax,1)
nop
mov    %rcx,%rbx
cmp    $0x1f,%rcx
je     1162 <iskeyword+0x52>
movslq 0x4(%r15,%rbx,4),%rdi
add    %r15,%rdi
mov    %r14,%rsi
call   1030 <strcmp@plt>
lea    0x1(%rbx),%rcx
test   %rax,%rax
jne    1140 <iskeyword+0x30>
xor    %eax,%eax
cmp    $0x1f,%rbx
setb   %al
jmp    1172 <iskeyword+0x62>
mov    $0x1,%eax
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@iskeyword.KEYWORD = internal global [32 x i8*] [i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.1, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.3, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.4, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.6, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.7, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.8, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.9, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.10, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.11, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.12, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.13, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.14, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.15, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.16, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.17, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.18, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.19, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.20, i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.21, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.22, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.23, i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.24, i32 0, i32 0), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.25, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.26, i32 0, i32 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.27, i32 0, i32 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.28, i32 0, i32 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.29, i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.30, i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.31, i32 0, i32 0)]
@.str = [5 x i8] c"auto\00"
@.str.1 = [7 x i8] c"double\00"
@.str.2 = [4 x i8] c"int\00"
@.str.3 = [7 x i8] c"struct\00"
@.str.4 = [6 x i8] c"break\00"
@.str.5 = [5 x i8] c"else\00"
@.str.6 = [5 x i8] c"long\00"
@.str.7 = [7 x i8] c"switch\00"
@.str.8 = [5 x i8] c"case\00"
@.str.9 = [5 x i8] c"enum\00"
@.str.10 = [9 x i8] c"register\00"
@.str.11 = [8 x i8] c"typedef\00"
@.str.12 = [5 x i8] c"char\00"
@.str.13 = [7 x i8] c"extern\00"
@.str.14 = [7 x i8] c"return\00"
@.str.15 = [6 x i8] c"union\00"
@.str.16 = [6 x i8] c"const\00"
@.str.17 = [6 x i8] c"float\00"
@.str.18 = [6 x i8] c"short\00"
@.str.19 = [9 x i8] c"unsigned\00"
@.str.20 = [9 x i8] c"continue\00"
@.str.21 = [4 x i8] c"for\00"
@.str.22 = [7 x i8] c"signed\00"
@.str.23 = [5 x i8] c"void\00"
@.str.24 = [8 x i8] c"default\00"
@.str.25 = [5 x i8] c"goto\00"
@.str.26 = [7 x i8] c"sizeof\00"
@.str.27 = [9 x i8] c"volatile\00"
@.str.28 = [3 x i8] c"do\00"
@.str.29 = [3 x i8] c"if\00"
@.str.30 = [7 x i8] c"static\00"
@.str.31 = [6 x i8] c"while\00"
define i32 @iskeyword(i8* %0) {
%2 = alloca i32
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 0, i32* %4
br label %5
5: ; preds = %18, %1
%6 = load i32, i32* %4
%7 = icmp slt i32 %6, 32
br i1 %7, label %8, label %21
8: ; preds = %5
%9 = load i32, i32* %4
%10 = sext i32 %9 to i64
%11 = getelementptr inbounds [32 x i8*], [32 x i8*]* @iskeyword.KEYWORD, i64 0, i64 %10
%12 = load i8*, i8** %11
%13 = load i8*, i8** %3
%14 = call i64 @strcmp(i8* %12, i8* %13)
%15 = icmp eq i64 %14, 0
br i1 %15, label %16, label %17
16: ; preds = %8
store i32 1, i32* %2
br label %22
17: ; preds = %8
br label %18
18: ; preds = %17
%19 = load i32, i32* %4
%20 = add nsw i32 %19, 1
store i32 %20, i32* %4
br label %5
21: ; preds = %5
store i32 0, i32* %2
br label %22
22: ; preds = %21, %16
%23 = load i32, i32* %2
ret i32 %23
}

LLVM IR (-O2):
@reltable.iskeyword = internal unnamed_addr constant [32 x i32] [i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.1 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str.2 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.3 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([6 x i8]* @.str.4 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.5 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.6 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.7 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.8 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.9 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([9 x i8]* @.str.10 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([8 x i8]* @.str.11 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.12 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.13 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.14 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([6 x i8]* @.str.15 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([6 x i8]* @.str.16 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([6 x i8]* @.str.17 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([6 x i8]* @.str.18 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([9 x i8]* @.str.19 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([9 x i8]* @.str.20 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([4 x i8]* @.str.21 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.22 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.23 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([8 x i8]* @.str.24 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.25 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.26 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([9 x i8]* @.str.27 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([3 x i8]* @.str.28 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([3 x i8]* @.str.29 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([7 x i8]* @.str.30 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([6 x i8]* @.str.31 to i64), i64 ptrtoint ([32 x i32]* @reltable.iskeyword to i64)) to i32)]
@.str = [5 x i8] c"auto\00"
@.str.1 = [7 x i8] c"double\00"
@.str.2 = [4 x i8] c"int\00"
@.str.3 = [7 x i8] c"struct\00"
@.str.4 = [6 x i8] c"break\00"
@.str.5 = [5 x i8] c"else\00"
@.str.6 = [5 x i8] c"long\00"
@.str.7 = [7 x i8] c"switch\00"
@.str.8 = [5 x i8] c"case\00"
@.str.9 = [5 x i8] c"enum\00"
@.str.10 = [9 x i8] c"register\00"
@.str.11 = [8 x i8] c"typedef\00"
@.str.12 = [5 x i8] c"char\00"
@.str.13 = [7 x i8] c"extern\00"
@.str.14 = [7 x i8] c"return\00"
@.str.15 = [6 x i8] c"union\00"
@.str.16 = [6 x i8] c"const\00"
@.str.17 = [6 x i8] c"float\00"
@.str.18 = [6 x i8] c"short\00"
@.str.19 = [9 x i8] c"unsigned\00"
@.str.20 = [9 x i8] c"continue\00"
@.str.21 = [4 x i8] c"for\00"
@.str.22 = [7 x i8] c"signed\00"
@.str.23 = [5 x i8] c"void\00"
@.str.24 = [8 x i8] c"default\00"
@.str.25 = [5 x i8] c"goto\00"
@.str.26 = [7 x i8] c"sizeof\00"
@.str.27 = [9 x i8] c"volatile\00"
@.str.28 = [3 x i8] c"do\00"
@.str.29 = [3 x i8] c"if\00"
@.str.30 = [7 x i8] c"static\00"
@.str.31 = [6 x i8] c"while\00"
define i32 @iskeyword(i8* %0) {
%2 = tail call i64 @strcmp(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0), i8* %0)
%3 = icmp eq i64 %2, 0
br i1 %3, label %16, label %4
4: ; preds = %1, %8
%5 = phi i64 [ %6, %8 ], [ 0, %1 ]
%6 = add nuw nsw i64 %5, 1
%7 = icmp eq i64 %6, 32
br i1 %7, label %13, label %8
8: ; preds = %4
%9 = shl i64 %6, 2
%10 = call i8* @llvm.load.relative.i64(i8* bitcast ([32 x i32]* @reltable.iskeyword to i8*), i64 %9)
%11 = tail call i64 @strcmp(i8* %10, i8* %0)
%12 = icmp eq i64 %11, 0
br i1 %12, label %13, label %4
13: ; preds = %8, %4
%14 = icmp ult i64 %5, 31
%15 = zext i1 %14 to i32
br label %16
16: ; preds = %13, %1
%17 = phi i32 [ 1, %1 ], [ %15, %13 ]
ret i32 %17
}