unsigned int onig_jis_property_hash(str, len)
register const char *str;
register unsigned int len;
{
  static const unsigned char asso_values[] = {
      13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
      13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
      13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
      13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
      13, 13, 13, 3,  13, 2,  13, 1,  1,  13, 13, 2,  1,  13, 1,  13,
      13, 13, 1,  13, 1,  13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13,
      13, 13, 13, 3,  13, 2,  13, 1,  1,  13, 13, 2,  1,  13, 1,  13,
      13, 13, 1,  13, 1,  13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13};
  return len + asso_values[(unsigned char)str[2]] +
         asso_values[(unsigned char)str[0]];
}


x86 assembly (clang, -O0):
<onig_jis_property_hash>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    -0x8(%rbp),%rcx
movzbl 0x2(%rcx),%ecx
mov    %ecx,%edx
lea    0xee1(%rip),%rcx
movzbl (%rcx,%rdx,1),%ecx
add    %ecx,%eax
mov    -0x8(%rbp),%rcx
movzbl (%rcx),%ecx
mov    %ecx,%edx
lea    0xecb(%rip),%rcx
movzbl (%rcx,%rdx,1),%ecx
add    %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<onig_jis_property_hash>:
movzbl 0x2(%rdi),%eax
lea    0xef5(%rip),%rcx
movzbl (%rax,%rcx,1),%edx
add    %esi,%edx
movzbl (%rdi),%eax
movzbl (%rax,%rcx,1),%eax
add    %edx,%eax
ret

LLVM IR (-O0):
@onig_jis_property_hash.asso_values = internal constant [128 x i8] c"\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\03\0D\02\0D\01\01\0D\0D\02\01\0D\01\0D\0D\0D\01\0D\01\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\03\0D\02\0D\01\01\0D\0D\02\01\0D\01\0D\0D\0D\01\0D\01\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D"
define i32 @onig_jis_property_hash(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = load i8*, i8** %3
%7 = getelementptr inbounds i8, i8* %6, i64 2
%8 = load i8, i8* %7
%9 = zext i8 %8 to i64
%10 = getelementptr inbounds [128 x i8], [128 x i8]* @onig_jis_property_hash.asso_values, i64 0, i64 %9
%11 = load i8, i8* %10
%12 = zext i8 %11 to i32
%13 = add i32 %5, %12
%14 = load i8*, i8** %3
%15 = getelementptr inbounds i8, i8* %14, i64 0
%16 = load i8, i8* %15
%17 = zext i8 %16 to i64
%18 = getelementptr inbounds [128 x i8], [128 x i8]* @onig_jis_property_hash.asso_values, i64 0, i64 %17
%19 = load i8, i8* %18
%20 = zext i8 %19 to i32
%21 = add i32 %13, %20
ret i32 %21
}

LLVM IR (-O2):
@onig_jis_property_hash.asso_values = internal unnamed_addr constant [128 x i8] c"\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\03\0D\02\0D\01\01\0D\0D\02\01\0D\01\0D\0D\0D\01\0D\01\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\03\0D\02\0D\01\01\0D\0D\02\01\0D\01\0D\0D\0D\01\0D\01\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D\0D"
define i32 @onig_jis_property_hash(i8* nocapture %0, i32 %1) {
%3 = getelementptr inbounds i8, i8* %0, i64 2
%4 = load i8, i8* %3
%5 = zext i8 %4 to i64
%6 = getelementptr inbounds [128 x i8], [128 x i8]* @onig_jis_property_hash.asso_values, i64 0, i64 %5
%7 = load i8, i8* %6
%8 = zext i8 %7 to i32
%9 = add i32 %8, %1
%10 = load i8, i8* %0
%11 = zext i8 %10 to i64
%12 = getelementptr inbounds [128 x i8], [128 x i8]* @onig_jis_property_hash.asso_values, i64 0, i64 %11
%13 = load i8, i8* %12
%14 = zext i8 %13 to i32
%15 = add i32 %9, %14
ret i32 %15
}