#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 */
typedef int /*<<< orphan*/ test7;
typedef int /*<<< orphan*/ test6;
typedef int /*<<< orphan*/ test5;
typedef int /*<<< orphan*/ test4_text;
typedef int /*<<< orphan*/ test4;
typedef int /*<<< orphan*/ test3_text;
typedef int /*<<< orphan*/ test3;
typedef int /*<<< orphan*/ test;

/* Variables and functions */
int /*<<< orphan*/ check(char *, int, char *, int, char *);
int strlen(char *);
int main(void) {
  int i;
  char test[16];
  char test_text[] = "Hi There";
  char test_result[] = "9294727a3638bb1c13f48ef8158bfc9d";
  for (i = 0; i < sizeof(test); i++) {
    test[i] = 0x0b;
  }
  check(test, sizeof(test), test_text, strlen(test_text), test_result);
  char test2[] = "Jefe";
  char test2_text[] = "what do ya want for nothing?";
  char test2_result[] = "750c783e6ab0b503eaa86e310a5db738";
  check(test2, strlen(test2), test2_text, strlen(test2_text), test2_result);
  char test3[16];
  char test3_text[50];
  char test3_result[] = "56be34521d144c88dbb8c733f0e8b3f6";
  for (i = 0; i < sizeof(test3); i++)
    test3[i] = 0xaa;
  for (i = 0; i < sizeof(test3_text); i++)
    test3_text[i] = 0xdd;
  check(test3, sizeof(test3), test3_text, sizeof(test3_text), test3_result);
  char test4[25];
  char test4_text[50];
  char test4_result[] = "697eaf0aca3a3aea3a75164746ffaa79";
  for (i = 0; i < sizeof(test4); i++)
    test4[i] = i + 1;
  for (i = 0; i < sizeof(test4_text); i++)
    test4_text[i] = 0xcd;
  check(test4, sizeof(test4), test4_text, sizeof(test4_text), test4_result);
  char test5[16];
  char test5_text[] = "Test With Truncation";
  char test5_result[] = "56461ef2342edc00f9bab995690efd4c";
  for (i = 0; i < sizeof(test5); i++)
    test5[i] = 0x0c;
  check(test5, sizeof(test5), test5_text, strlen(test5_text), test5_result);
  char test6[80];
  char test6_text[] = "Test Using Larger Than Block-Size Key - Hash Key First";
  char test6_result[] = "6b1ab7fe4bd7bf8f0b62e6ce61b9d0cd";
  for (i = 0; i < sizeof(test6); i++)
    test6[i] = 0xaa;
  check(test6, sizeof(test6), test6_text, strlen(test6_text), test6_result);
  char test7[80];
  char test7_text[] = "Test Using Larger Than Block-Size Key and Larger Than "
                      "One Block-Size Data";
  char test7_result[] = "6f630fad67cda0ee1fb1f562db3aa53e";
  for (i = 0; i < sizeof(test7); i++)
    test7[i] = 0xaa;
  check(test7, sizeof(test7), test7_text, strlen(test7_text), test7_result);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x410,%rsp
movl   $0x0,-0x4(%rbp)
mov    0xeb7(%rip),%rax
mov    %rax,-0x29(%rbp)
mov    0xeb5(%rip),%al
mov    %al,-0x21(%rbp)
lea    -0x50(%rbp),%rdi
lea    0xeaf(%rip),%rsi
mov    $0x21,%edx
call   1040 <memcpy@plt>
movl   $0x0,-0x8(%rbp)
movslq -0x8(%rbp),%rax
cmp    $0x10,%rax
jae    1197 <main+0x67>
movslq -0x8(%rbp),%rax
movb   $0xb,-0x20(%rbp,%rax,1)
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1172 <main+0x42>
lea    -0x20(%rbp),%rax
mov    %rax,-0x3d8(%rbp)
lea    -0x29(%rbp),%rax
mov    %rax,-0x3d0(%rbp)
lea    -0x29(%rbp),%rdi
call   1030 <strlen@plt>
mov    -0x3d8(%rbp),%rdi
mov    -0x3d0(%rbp),%rdx
mov    %eax,%ecx
lea    -0x50(%rbp),%r8
mov    $0x10,%esi
call   1050 <check@plt>
mov    0xe2f(%rip),%eax
mov    %eax,-0x55(%rbp)
mov    0xe2a(%rip),%al
mov    %al,-0x51(%rbp)
mov    0xe53(%rip),%rax
mov    %rax,-0x80(%rbp)
mov    0xe50(%rip),%rax
mov    %rax,-0x78(%rbp)
mov    0xe4d(%rip),%rax
mov    %rax,-0x70(%rbp)
mov    0xe4b(%rip),%eax
mov    %eax,-0x68(%rbp)
mov    0xe46(%rip),%al
mov    %al,-0x64(%rbp)
lea    -0xb0(%rbp),%rdi
lea    0xe39(%rip),%rsi
mov    $0x21,%edx
call   1040 <memcpy@plt>
lea    -0x55(%rbp),%rax
mov    %rax,-0x3c8(%rbp)
lea    -0x55(%rbp),%rdi
call   1030 <strlen@plt>
mov    %eax,-0x3bc(%rbp)
lea    -0x80(%rbp),%rax
mov    %rax,-0x3b8(%rbp)
lea    -0x80(%rbp),%rdi
call   1030 <strlen@plt>
mov    -0x3c8(%rbp),%rdi
mov    -0x3bc(%rbp),%esi
mov    -0x3b8(%rbp),%rdx
mov    %eax,%ecx
lea    -0xb0(%rbp),%r8
call   1050 <check@plt>
lea    -0x130(%rbp),%rdi
lea    0xe01(%rip),%rsi
mov    $0x21,%edx
call   1040 <memcpy@plt>
movl   $0x0,-0x8(%rbp)
movslq -0x8(%rbp),%rax
cmp    $0x10,%rax
jae    12c8 <main+0x198>
movslq -0x8(%rbp),%rax
movb   $0xaa,-0xc0(%rbp,%rax,1)
aa
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    12a0 <main+0x170>
movl   $0x0,-0x8(%rbp)
movslq -0x8(%rbp),%rax
cmp    $0x32,%rax
jae    12f7 <main+0x1c7>
movslq -0x8(%rbp),%rax
movb   $0xdd,-0x100(%rbp,%rax,1)
dd
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    12cf <main+0x19f>
lea    -0xc0(%rbp),%rdi
lea    -0x100(%rbp),%rdx
lea    -0x130(%rbp),%r8
mov    $0x10,%esi
mov    $0x32,%ecx
call   1050 <check@plt>
lea    -0x1c0(%rbp),%rdi
lea    0xd97(%rip),%rsi
mov    $0x21,%edx
call   1040 <memcpy@plt>
movl   $0x0,-0x8(%rbp)
movslq -0x8(%rbp),%rax
cmp    $0x19,%rax
jae    1369 <main+0x239>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %al,%cl
movslq -0x8(%rbp),%rax
mov    %cl,-0x150(%rbp,%rax,1)
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    133a <main+0x20a>
movl   $0x0,-0x8(%rbp)
movslq -0x8(%rbp),%rax
cmp    $0x32,%rax
jae    1398 <main+0x268>
movslq -0x8(%rbp),%rax
movb   $0xcd,-0x190(%rbp,%rax,1)
cd
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1370 <main+0x240>
lea    -0x150(%rbp),%rdi
lea    -0x190(%rbp),%rdx
lea    -0x1c0(%rbp),%r8
mov    $0x19,%esi
mov    $0x32,%ecx
call   1050 <check@plt>
mov    0xd2d(%rip),%rax
mov    %rax,-0x1f0(%rbp)
mov    0xd27(%rip),%rax
mov    %rax,-0x1e8(%rbp)
mov    0xd22(%rip),%eax
mov    %eax,-0x1e0(%rbp)
mov    0xd1a(%rip),%al
mov    %al,-0x1dc(%rbp)
lea    -0x220(%rbp),%rdi
lea    0xd12(%rip),%rsi
mov    $0x21,%edx
call   1040 <memcpy@plt>
movl   $0x0,-0x8(%rbp)
movslq -0x8(%rbp),%rax
cmp    $0x10,%rax
jae    1437 <main+0x307>
movslq -0x8(%rbp),%rax
movb   $0xc,-0x1d0(%rbp,%rax,1)
0c
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    140f <main+0x2df>
lea    -0x1d0(%rbp),%rax
mov    %rax,-0x3e8(%rbp)
lea    -0x1f0(%rbp),%rax
mov    %rax,-0x3e0(%rbp)
lea    -0x1f0(%rbp),%rdi
call   1030 <strlen@plt>
mov    -0x3e8(%rbp),%rdi
mov    -0x3e0(%rbp),%rdx
mov    %eax,%ecx
lea    -0x220(%rbp),%r8
mov    $0x10,%esi
call   1050 <check@plt>
lea    -0x2b0(%rbp),%rdi
lea    0xcb2(%rip),%rsi
mov    $0x37,%edx
call   1040 <memcpy@plt>
lea    -0x2e0(%rbp),%rdi
lea    0xcda(%rip),%rsi
mov    $0x21,%edx
call   1040 <memcpy@plt>
movl   $0x0,-0x8(%rbp)
movslq -0x8(%rbp),%rax
cmp    $0x50,%rax
jae    14df <main+0x3af>
movslq -0x8(%rbp),%rax
movb   $0xaa,-0x270(%rbp,%rax,1)
aa
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    14b7 <main+0x387>
lea    -0x270(%rbp),%rax
mov    %rax,-0x3f8(%rbp)
lea    -0x2b0(%rbp),%rax
mov    %rax,-0x3f0(%rbp)
lea    -0x2b0(%rbp),%rdi
call   1030 <strlen@plt>
mov    -0x3f8(%rbp),%rdi
mov    -0x3f0(%rbp),%rdx
mov    %eax,%ecx
lea    -0x2e0(%rbp),%r8
mov    $0x50,%esi
call   1050 <check@plt>
lea    -0x380(%rbp),%rdi
lea    0xc7a(%rip),%rsi
mov    $0x4a,%edx
call   1040 <memcpy@plt>
lea    -0x3b0(%rbp),%rdi
lea    0xcb2(%rip),%rsi
mov    $0x21,%edx
call   1040 <memcpy@plt>
movl   $0x0,-0x8(%rbp)
movslq -0x8(%rbp),%rax
cmp    $0x50,%rax
jae    1587 <main+0x457>
movslq -0x8(%rbp),%rax
movb   $0xaa,-0x330(%rbp,%rax,1)
aa
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    155f <main+0x42f>
lea    -0x330(%rbp),%rax
mov    %rax,-0x408(%rbp)
lea    -0x380(%rbp),%rax
mov    %rax,-0x400(%rbp)
lea    -0x380(%rbp),%rdi
call   1030 <strlen@plt>
mov    -0x408(%rbp),%rdi
mov    -0x400(%rbp),%rdx
mov    %eax,%ecx
lea    -0x3b0(%rbp),%r8
mov    $0x50,%esi
call   1050 <check@plt>
xor    %eax,%eax
add    $0x410,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r14
push   %rbx
sub    $0x3b0,%rsp
movabs $0x6572656854206948,%rax
65 72 65
mov    %rax,0x10(%rsp)
movb   $0x0,0x18(%rsp)
movaps 0xf3a(%rip),%xmm0
movaps %xmm0,0x1c0(%rsp)
movaps 0xf1b(%rip),%xmm0
movaps %xmm0,0x1b0(%rsp)
movb   $0x0,0x1d0(%rsp)
movaps 0xe94(%rip),%xmm0
movaps %xmm0,0x80(%rsp)
lea    0x10(%rsp),%rbx
mov    %rbx,%rdi
call   1030 <strlen@plt>
lea    0x80(%rsp),%rdi
lea    0x1b0(%rsp),%r8
mov    $0x10,%esi
mov    %rbx,%rdx
mov    %eax,%ecx
call   1040 <check@plt>
movb   $0x0,0xc(%rsp)
movl   $0x6566654a,0x8(%rsp)
65
movups 0xef9(%rip),%xmm0
movups %xmm0,0x1ed(%rsp)
movaps 0xedd(%rip),%xmm0
movaps %xmm0,0x1e0(%rsp)
movaps 0xefe(%rip),%xmm0
movaps %xmm0,0x190(%rsp)
movaps 0xedf(%rip),%xmm0
movaps %xmm0,0x180(%rsp)
movb   $0x0,0x1a0(%rsp)
lea    0x8(%rsp),%r14
mov    %r14,%rdi
call   1030 <strlen@plt>
mov    %eax,%ebp
lea    0x1e0(%rsp),%rbx
mov    %rbx,%rdi
call   1030 <strlen@plt>
lea    0x180(%rsp),%r8
mov    %r14,%rdi
mov    %ebp,%esi
mov    %rbx,%rdx
mov    %eax,%ecx
call   1040 <check@plt>
movaps 0xed2(%rip),%xmm0
movaps %xmm0,0x160(%rsp)
movaps 0xeb3(%rip),%xmm0
movaps %xmm0,0x150(%rsp)
movb   $0x0,0x170(%rsp)
movaps 0xdbc(%rip),%xmm0
movaps %xmm0,0x70(%rsp)
movaps 0xdc0(%rip),%xmm0
movaps %xmm0,0x240(%rsp)
movaps %xmm0,0x250(%rsp)
movaps %xmm0,0x260(%rsp)
movw   $0xdddd,0x270(%rsp)
lea    0x70(%rsp),%rdi
lea    0x240(%rsp),%rdx
lea    0x150(%rsp),%r8
mov    $0x10,%esi
mov    $0x32,%ecx
call   1040 <check@plt>
movaps 0xe83(%rip),%xmm0
movaps %xmm0,0x130(%rsp)
movaps 0xe64(%rip),%xmm0
movaps %xmm0,0x120(%rsp)
movb   $0x0,0x140(%rsp)
movaps 0xd5d(%rip),%xmm0
movaps %xmm0,0x20(%rsp)
movabs $0x1817161514131211,%rax
16 17 18
mov    %rax,0x30(%rsp)
movb   $0x19,0x38(%rsp)
movaps 0xd4d(%rip),%xmm0
movaps %xmm0,0x200(%rsp)
movaps %xmm0,0x210(%rsp)
movaps %xmm0,0x220(%rsp)
movw   $0xcdcd,0x230(%rsp)
lea    0x20(%rsp),%rdi
lea    0x200(%rsp),%rdx
lea    0x120(%rsp),%r8
mov    $0x19,%esi
mov    $0x32,%ecx
call   1040 <check@plt>
movaps 0xe10(%rip),%xmm0
movaps %xmm0,0x40(%rsp)
movabs $0x6e6f697461636e,%rax
mov    %rax,0x4d(%rsp)
movaps 0xe25(%rip),%xmm0
movaps %xmm0,0x100(%rsp)
movaps 0xe06(%rip),%xmm0
movaps %xmm0,0xf0(%rsp)
movb   $0x0,0x110(%rsp)
movaps 0xccf(%rip),%xmm0
movaps %xmm0,0x60(%rsp)
lea    0x40(%rsp),%rbx
mov    %rbx,%rdi
call   1030 <strlen@plt>
lea    0x60(%rsp),%rdi
lea    0xf0(%rsp),%r8
mov    $0x10,%esi
mov    %rbx,%rdx
mov    %eax,%ecx
call   1040 <check@plt>
movaps 0xe0a(%rip),%xmm0
movaps %xmm0,0x2a0(%rsp)
movaps 0xdeb(%rip),%xmm0
movaps %xmm0,0x290(%rsp)
movaps 0xdcc(%rip),%xmm0
movaps %xmm0,0x280(%rsp)
movabs $0x74737269462079,%rax
mov    %rax,0x2af(%rsp)
movaps 0xdfb(%rip),%xmm0
movaps %xmm0,0xd0(%rsp)
movaps 0xddc(%rip),%xmm0
movaps %xmm0,0xc0(%rsp)
movb   $0x0,0xe0(%rsp)
movaps 0xbf5(%rip),%xmm0
movaps %xmm0,0x360(%rsp)
movaps %xmm0,0x370(%rsp)
movaps %xmm0,0x380(%rsp)
movaps %xmm0,0x390(%rsp)
movaps %xmm0,0x3a0(%rsp)
lea    0x280(%rsp),%rbx
mov    %rbx,%rdi
call   1030 <strlen@plt>
lea    0x360(%rsp),%rdi
lea    0xc0(%rsp),%r8
mov    $0x50,%esi
mov    %rbx,%rdx
mov    %eax,%ecx
call   1040 <check@plt>
movups 0xdd1(%rip),%xmm0
movups %xmm0,0x2fa(%rsp)
movaps 0xdb8(%rip),%xmm0
movaps %xmm0,0x2f0(%rsp)
movaps 0xd99(%rip),%xmm0
movaps %xmm0,0x2e0(%rsp)
movaps 0xd7a(%rip),%xmm0
movaps %xmm0,0x2d0(%rsp)
movaps 0xd5b(%rip),%xmm0
movaps %xmm0,0x2c0(%rsp)
movaps 0xdac(%rip),%xmm0
movaps %xmm0,0xa0(%rsp)
movaps 0xd8d(%rip),%xmm0
movaps %xmm0,0x90(%rsp)
movb   $0x0,0xb0(%rsp)
movaps 0xb26(%rip),%xmm0
movaps %xmm0,0x310(%rsp)
movaps %xmm0,0x320(%rsp)
movaps %xmm0,0x330(%rsp)
movaps %xmm0,0x340(%rsp)
movaps %xmm0,0x350(%rsp)
lea    0x2c0(%rsp),%rbx
mov    %rbx,%rdi
call   1030 <strlen@plt>
lea    0x310(%rsp),%rdi
lea    0x90(%rsp),%r8
mov    $0x50,%esi
mov    %rbx,%rdx
mov    %eax,%ecx
call   1040 <check@plt>
xor    %eax,%eax
add    $0x3b0,%rsp
pop    %rbx
pop    %r14
pop    %rbp
ret

LLVM IR (-O0):
@__const.main.test_text = [9 x i8] c"Hi There\00"
@__const.main.test_result = [33 x i8] c"9294727a3638bb1c13f48ef8158bfc9d\00"
@__const.main.test2 = [5 x i8] c"Jefe\00"
@__const.main.test2_text = [29 x i8] c"what do ya want for nothing?\00"
@__const.main.test2_result = [33 x i8] c"750c783e6ab0b503eaa86e310a5db738\00"
@__const.main.test3_result = [33 x i8] c"56be34521d144c88dbb8c733f0e8b3f6\00"
@__const.main.test4_result = [33 x i8] c"697eaf0aca3a3aea3a75164746ffaa79\00"
@__const.main.test5_text = [21 x i8] c"Test With Truncation\00"
@__const.main.test5_result = [33 x i8] c"56461ef2342edc00f9bab995690efd4c\00"
@__const.main.test6_text = [55 x i8] c"Test Using Larger Than Block-Size Key - Hash Key First\00"
@__const.main.test6_result = [33 x i8] c"6b1ab7fe4bd7bf8f0b62e6ce61b9d0cd\00"
@__const.main.test7_text = [74 x i8] c"Test Using Larger Than Block-Size Key and Larger Than One Block-Size Data\00"
@__const.main.test7_result = [33 x i8] c"6f630fad67cda0ee1fb1f562db3aa53e\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca [16 x i8]
%4 = alloca [9 x i8]
%5 = alloca [33 x i8]
%6 = alloca [5 x i8]
%7 = alloca [29 x i8]
%8 = alloca [33 x i8]
%9 = alloca [16 x i8]
%10 = alloca [50 x i8]
%11 = alloca [33 x i8]
%12 = alloca [25 x i8]
%13 = alloca [50 x i8]
%14 = alloca [33 x i8]
%15 = alloca [16 x i8]
%16 = alloca [21 x i8]
%17 = alloca [33 x i8]
%18 = alloca [80 x i8]
%19 = alloca [55 x i8]
%20 = alloca [33 x i8]
%21 = alloca [80 x i8]
%22 = alloca [74 x i8]
%23 = alloca [33 x i8]
store i32 0, i32* %1
%24 = bitcast [9 x i8]* %4 to i8*
%25 = bitcast [33 x i8]* %5 to i8*
store i32 0, i32* %2
br label %26
26: ; preds = %34, %0
%27 = load i32, i32* %2
%28 = sext i32 %27 to i64
%29 = icmp ult i64 %28, 16
br i1 %29, label %30, label %37
30: ; preds = %26
%31 = load i32, i32* %2
%32 = sext i32 %31 to i64
%33 = getelementptr inbounds [16 x i8], [16 x i8]* %3, i64 0, i64 %32
store i8 11, i8* %33
br label %34
34: ; preds = %30
%35 = load i32, i32* %2
%36 = add nsw i32 %35, 1
store i32 %36, i32* %2
br label %26
37: ; preds = %26
%38 = getelementptr inbounds [16 x i8], [16 x i8]* %3, i64 0, i64 0
%39 = getelementptr inbounds [9 x i8], [9 x i8]* %4, i64 0, i64 0
%40 = getelementptr inbounds [9 x i8], [9 x i8]* %4, i64 0, i64 0
%41 = call i32 @strlen(i8* %40)
%42 = getelementptr inbounds [33 x i8], [33 x i8]* %5, i64 0, i64 0
%43 = call i32 @check(i8* %38, i32 16, i8* %39, i32 %41, i8* %42)
%44 = bitcast [5 x i8]* %6 to i8*
%45 = bitcast [29 x i8]* %7 to i8*
%46 = bitcast [33 x i8]* %8 to i8*
%47 = getelementptr inbounds [5 x i8], [5 x i8]* %6, i64 0, i64 0
%48 = getelementptr inbounds [5 x i8], [5 x i8]* %6, i64 0, i64 0
%49 = call i32 @strlen(i8* %48)
%50 = getelementptr inbounds [29 x i8], [29 x i8]* %7, i64 0, i64 0
%51 = getelementptr inbounds [29 x i8], [29 x i8]* %7, i64 0, i64 0
%52 = call i32 @strlen(i8* %51)
%53 = getelementptr inbounds [33 x i8], [33 x i8]* %8, i64 0, i64 0
%54 = call i32 @check(i8* %47, i32 %49, i8* %50, i32 %52, i8* %53)
%55 = bitcast [33 x i8]* %11 to i8*
store i32 0, i32* %2
br label %56
56: ; preds = %64, %37
%57 = load i32, i32* %2
%58 = sext i32 %57 to i64
%59 = icmp ult i64 %58, 16
br i1 %59, label %60, label %67
60: ; preds = %56
%61 = load i32, i32* %2
%62 = sext i32 %61 to i64
%63 = getelementptr inbounds [16 x i8], [16 x i8]* %9, i64 0, i64 %62
store i8 -86, i8* %63
br label %64
64: ; preds = %60
%65 = load i32, i32* %2
%66 = add nsw i32 %65, 1
store i32 %66, i32* %2
br label %56
67: ; preds = %56
store i32 0, i32* %2
br label %68
68: ; preds = %76, %67
%69 = load i32, i32* %2
%70 = sext i32 %69 to i64
%71 = icmp ult i64 %70, 50
br i1 %71, label %72, label %79
72: ; preds = %68
%73 = load i32, i32* %2
%74 = sext i32 %73 to i64
%75 = getelementptr inbounds [50 x i8], [50 x i8]* %10, i64 0, i64 %74
store i8 -35, i8* %75
br label %76
76: ; preds = %72
%77 = load i32, i32* %2
%78 = add nsw i32 %77, 1
store i32 %78, i32* %2
br label %68
79: ; preds = %68
%80 = getelementptr inbounds [16 x i8], [16 x i8]* %9, i64 0, i64 0
%81 = getelementptr inbounds [50 x i8], [50 x i8]* %10, i64 0, i64 0
%82 = getelementptr inbounds [33 x i8], [33 x i8]* %11, i64 0, i64 0
%83 = call i32 @check(i8* %80, i32 16, i8* %81, i32 50, i8* %82)
%84 = bitcast [33 x i8]* %14 to i8*
store i32 0, i32* %2
br label %85
85: ; preds = %96, %79
%86 = load i32, i32* %2
%87 = sext i32 %86 to i64
%88 = icmp ult i64 %87, 25
br i1 %88, label %89, label %99
89: ; preds = %85
%90 = load i32, i32* %2
%91 = add nsw i32 %90, 1
%92 = trunc i32 %91 to i8
%93 = load i32, i32* %2
%94 = sext i32 %93 to i64
%95 = getelementptr inbounds [25 x i8], [25 x i8]* %12, i64 0, i64 %94
store i8 %92, i8* %95
br label %96
96: ; preds = %89
%97 = load i32, i32* %2
%98 = add nsw i32 %97, 1
store i32 %98, i32* %2
br label %85
99: ; preds = %85
store i32 0, i32* %2
br label %100
100: ; preds = %108, %99
%101 = load i32, i32* %2
%102 = sext i32 %101 to i64
%103 = icmp ult i64 %102, 50
br i1 %103, label %104, label %111
104: ; preds = %100
%105 = load i32, i32* %2
%106 = sext i32 %105 to i64
%107 = getelementptr inbounds [50 x i8], [50 x i8]* %13, i64 0, i64 %106
store i8 -51, i8* %107
br label %108
108: ; preds = %104
%109 = load i32, i32* %2
%110 = add nsw i32 %109, 1
store i32 %110, i32* %2
br label %100
111: ; preds = %100
%112 = getelementptr inbounds [25 x i8], [25 x i8]* %12, i64 0, i64 0
%113 = getelementptr inbounds [50 x i8], [50 x i8]* %13, i64 0, i64 0
%114 = getelementptr inbounds [33 x i8], [33 x i8]* %14, i64 0, i64 0
%115 = call i32 @check(i8* %112, i32 25, i8* %113, i32 50, i8* %114)
%116 = bitcast [21 x i8]* %16 to i8*
%117 = bitcast [33 x i8]* %17 to i8*
store i32 0, i32* %2
br label %118
118: ; preds = %126, %111
%119 = load i32, i32* %2
%120 = sext i32 %119 to i64
%121 = icmp ult i64 %120, 16
br i1 %121, label %122, label %129
122: ; preds = %118
%123 = load i32, i32* %2
%124 = sext i32 %123 to i64
%125 = getelementptr inbounds [16 x i8], [16 x i8]* %15, i64 0, i64 %124
store i8 12, i8* %125
br label %126
126: ; preds = %122
%127 = load i32, i32* %2
%128 = add nsw i32 %127, 1
store i32 %128, i32* %2
br label %118
129: ; preds = %118
%130 = getelementptr inbounds [16 x i8], [16 x i8]* %15, i64 0, i64 0
%131 = getelementptr inbounds [21 x i8], [21 x i8]* %16, i64 0, i64 0
%132 = getelementptr inbounds [21 x i8], [21 x i8]* %16, i64 0, i64 0
%133 = call i32 @strlen(i8* %132)
%134 = getelementptr inbounds [33 x i8], [33 x i8]* %17, i64 0, i64 0
%135 = call i32 @check(i8* %130, i32 16, i8* %131, i32 %133, i8* %134)
%136 = bitcast [55 x i8]* %19 to i8*
%137 = bitcast [33 x i8]* %20 to i8*
store i32 0, i32* %2
br label %138
138: ; preds = %146, %129
%139 = load i32, i32* %2
%140 = sext i32 %139 to i64
%141 = icmp ult i64 %140, 80
br i1 %141, label %142, label %149
142: ; preds = %138
%143 = load i32, i32* %2
%144 = sext i32 %143 to i64
%145 = getelementptr inbounds [80 x i8], [80 x i8]* %18, i64 0, i64 %144
store i8 -86, i8* %145
br label %146
146: ; preds = %142
%147 = load i32, i32* %2
%148 = add nsw i32 %147, 1
store i32 %148, i32* %2
br label %138
149: ; preds = %138
%150 = getelementptr inbounds [80 x i8], [80 x i8]* %18, i64 0, i64 0
%151 = getelementptr inbounds [55 x i8], [55 x i8]* %19, i64 0, i64 0
%152 = getelementptr inbounds [55 x i8], [55 x i8]* %19, i64 0, i64 0
%153 = call i32 @strlen(i8* %152)
%154 = getelementptr inbounds [33 x i8], [33 x i8]* %20, i64 0, i64 0
%155 = call i32 @check(i8* %150, i32 80, i8* %151, i32 %153, i8* %154)
%156 = bitcast [74 x i8]* %22 to i8*
%157 = bitcast [33 x i8]* %23 to i8*
store i32 0, i32* %2
br label %158
158: ; preds = %166, %149
%159 = load i32, i32* %2
%160 = sext i32 %159 to i64
%161 = icmp ult i64 %160, 80
br i1 %161, label %162, label %169
162: ; preds = %158
%163 = load i32, i32* %2
%164 = sext i32 %163 to i64
%165 = getelementptr inbounds [80 x i8], [80 x i8]* %21, i64 0, i64 %164
store i8 -86, i8* %165
br label %166
166: ; preds = %162
%167 = load i32, i32* %2
%168 = add nsw i32 %167, 1
store i32 %168, i32* %2
br label %158
169: ; preds = %158
%170 = getelementptr inbounds [80 x i8], [80 x i8]* %21, i64 0, i64 0
%171 = getelementptr inbounds [74 x i8], [74 x i8]* %22, i64 0, i64 0
%172 = getelementptr inbounds [74 x i8], [74 x i8]* %22, i64 0, i64 0
%173 = call i32 @strlen(i8* %172)
%174 = getelementptr inbounds [33 x i8], [33 x i8]* %23, i64 0, i64 0
%175 = call i32 @check(i8* %170, i32 80, i8* %171, i32 %173, i8* %174)
ret i32 0
}

LLVM IR (-O2):
@__const.main.test_text = [9 x i8] c"Hi There\00"
@__const.main.test_result = [33 x i8] c"9294727a3638bb1c13f48ef8158bfc9d\00"
@__const.main.test2 = [5 x i8] c"Jefe\00"
@__const.main.test2_text = [29 x i8] c"what do ya want for nothing?\00"
@__const.main.test2_result = [33 x i8] c"750c783e6ab0b503eaa86e310a5db738\00"
@__const.main.test3_result = [33 x i8] c"56be34521d144c88dbb8c733f0e8b3f6\00"
@__const.main.test4_result = [33 x i8] c"697eaf0aca3a3aea3a75164746ffaa79\00"
@__const.main.test5_text = [21 x i8] c"Test With Truncation\00"
@__const.main.test5_result = [33 x i8] c"56461ef2342edc00f9bab995690efd4c\00"
@__const.main.test6_text = [55 x i8] c"Test Using Larger Than Block-Size Key - Hash Key First\00"
@__const.main.test6_result = [33 x i8] c"6b1ab7fe4bd7bf8f0b62e6ce61b9d0cd\00"
@__const.main.test7_text = [74 x i8] c"Test Using Larger Than Block-Size Key and Larger Than One Block-Size Data\00"
@__const.main.test7_result = [33 x i8] c"6f630fad67cda0ee1fb1f562db3aa53e\00"
define i32 @main() {
%1 = alloca [16 x i8]
%2 = getelementptr inbounds [16 x i8], [16 x i8]* %1, i64 0, i64 0
%3 = alloca [9 x i8]
%4 = alloca [33 x i8]
%5 = alloca [5 x i8]
%6 = alloca [29 x i8]
%7 = alloca [33 x i8]
%8 = alloca [16 x i8]
%9 = getelementptr inbounds [16 x i8], [16 x i8]* %8, i64 0, i64 0
%10 = alloca [50 x i8]
%11 = getelementptr inbounds [50 x i8], [50 x i8]* %10, i64 0, i64 0
%12 = alloca [33 x i8]
%13 = alloca [25 x i8]
%14 = alloca [50 x i8]
%15 = getelementptr inbounds [50 x i8], [50 x i8]* %14, i64 0, i64 0
%16 = alloca [33 x i8]
%17 = alloca [16 x i8]
%18 = getelementptr inbounds [16 x i8], [16 x i8]* %17, i64 0, i64 0
%19 = alloca [21 x i8]
%20 = alloca [33 x i8]
%21 = alloca [80 x i8]
%22 = getelementptr inbounds [80 x i8], [80 x i8]* %21, i64 0, i64 0
%23 = alloca [55 x i8]
%24 = alloca [33 x i8]
%25 = alloca [80 x i8]
%26 = getelementptr inbounds [80 x i8], [80 x i8]* %25, i64 0, i64 0
%27 = alloca [74 x i8]
%28 = alloca [33 x i8]
%29 = getelementptr inbounds [16 x i8], [16 x i8]* %1, i64 0, i64 0
%30 = getelementptr inbounds [9 x i8], [9 x i8]* %3, i64 0, i64 0
%31 = getelementptr inbounds [33 x i8], [33 x i8]* %4, i64 0, i64 0
%32 = call i32 @strlen(i8* %30)
%33 = call i32 @check(i8* %29, i32 16, i8* %30, i32 %32, i8* %31)
%34 = getelementptr inbounds [5 x i8], [5 x i8]* %5, i64 0, i64 0
%35 = getelementptr inbounds [29 x i8], [29 x i8]* %6, i64 0, i64 0
%36 = getelementptr inbounds [33 x i8], [33 x i8]* %7, i64 0, i64 0
%37 = call i32 @strlen(i8* %34)
%38 = call i32 @strlen(i8* %35)
%39 = call i32 @check(i8* %34, i32 %37, i8* %35, i32 %38, i8* %36)
%40 = getelementptr inbounds [16 x i8], [16 x i8]* %8, i64 0, i64 0
%41 = getelementptr inbounds [50 x i8], [50 x i8]* %10, i64 0, i64 0
%42 = getelementptr inbounds [33 x i8], [33 x i8]* %12, i64 0, i64 0
%43 = call i32 @check(i8* %40, i32 16, i8* %41, i32 50, i8* %42)
%44 = getelementptr inbounds [25 x i8], [25 x i8]* %13, i64 0, i64 0
%45 = getelementptr inbounds [50 x i8], [50 x i8]* %14, i64 0, i64 0
%46 = getelementptr inbounds [33 x i8], [33 x i8]* %16, i64 0, i64 0
%47 = bitcast [25 x i8]* %13 to <16 x i8>*
store <16 x i8> <i8 1, i8 2, i8 3, i8 4, i8 5, i8 6, i8 7, i8 8, i8 9, i8 10, i8 11, i8 12, i8 13, i8 14, i8 15, i8 16>, <16 x i8>* %47
%48 = getelementptr inbounds [25 x i8], [25 x i8]* %13, i64 0, i64 16
store i8 17, i8* %48
%49 = getelementptr inbounds [25 x i8], [25 x i8]* %13, i64 0, i64 17
store i8 18, i8* %49
%50 = getelementptr inbounds [25 x i8], [25 x i8]* %13, i64 0, i64 18
store i8 19, i8* %50
%51 = getelementptr inbounds [25 x i8], [25 x i8]* %13, i64 0, i64 19
store i8 20, i8* %51
%52 = getelementptr inbounds [25 x i8], [25 x i8]* %13, i64 0, i64 20
store i8 21, i8* %52
%53 = getelementptr inbounds [25 x i8], [25 x i8]* %13, i64 0, i64 21
store i8 22, i8* %53
%54 = getelementptr inbounds [25 x i8], [25 x i8]* %13, i64 0, i64 22
store i8 23, i8* %54
%55 = getelementptr inbounds [25 x i8], [25 x i8]* %13, i64 0, i64 23
store i8 24, i8* %55
%56 = getelementptr inbounds [25 x i8], [25 x i8]* %13, i64 0, i64 24
store i8 25, i8* %56
%57 = call i32 @check(i8* %44, i32 25, i8* %45, i32 50, i8* %46)
%58 = getelementptr inbounds [16 x i8], [16 x i8]* %17, i64 0, i64 0
%59 = getelementptr inbounds [21 x i8], [21 x i8]* %19, i64 0, i64 0
%60 = getelementptr inbounds [33 x i8], [33 x i8]* %20, i64 0, i64 0
%61 = call i32 @strlen(i8* %59)
%62 = call i32 @check(i8* %58, i32 16, i8* %59, i32 %61, i8* %60)
%63 = getelementptr inbounds [80 x i8], [80 x i8]* %21, i64 0, i64 0
%64 = getelementptr inbounds [55 x i8], [55 x i8]* %23, i64 0, i64 0
%65 = getelementptr inbounds [33 x i8], [33 x i8]* %24, i64 0, i64 0
%66 = call i32 @strlen(i8* %64)
%67 = call i32 @check(i8* %63, i32 80, i8* %64, i32 %66, i8* %65)
%68 = getelementptr inbounds [80 x i8], [80 x i8]* %25, i64 0, i64 0
%69 = getelementptr inbounds [74 x i8], [74 x i8]* %27, i64 0, i64 0
%70 = getelementptr inbounds [33 x i8], [33 x i8]* %28, i64 0, i64 0
%71 = call i32 @strlen(i8* %69)
%72 = call i32 @check(i8* %68, i32 80, i8* %69, i32 %71, i8* %70)
ret i32 0
}