#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 */
int /*<<< orphan*/ _test_allocation();
int /*<<< orphan*/ _test_strings();
int /*<<< orphan*/ _test_uneven();
int /*<<< orphan*/ printf(char *);
int main() {
  printf("simple allocation...");
  _test_allocation();
  printf(" OK!\n");
  printf("strings...");
  _test_strings();
  printf(" OK!\n");
  printf("uneven...");
  _test_uneven();
  printf(" OK!\n");
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
lea    0xeb5(%rip),%rdi
call   1040 <printf@plt>
mov    $0x0,%al
call   1060 <_test_allocation@plt>
lea    0xeb7(%rip),%rdi
call   1040 <printf@plt>
lea    0xeb1(%rip),%rdi
call   1040 <printf@plt>
mov    $0x0,%al
call   1030 <_test_strings@plt>
lea    0xe98(%rip),%rdi
call   1040 <printf@plt>
lea    0xe9d(%rip),%rdi
call   1040 <printf@plt>
mov    $0x0,%al
call   1050 <_test_uneven@plt>
lea    0xe79(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
lea    0xea8(%rip),%rdi
call   1050 <printf@plt>
xor    %eax,%eax
call   1070 <_test_allocation@plt>
lea    0xebf(%rip),%rbx
mov    %rbx,%rdi
call   1030 <puts@plt>
lea    0xe9b(%rip),%rdi
call   1050 <printf@plt>
xor    %eax,%eax
call   1040 <_test_strings@plt>
mov    %rbx,%rdi
call   1030 <puts@plt>
lea    0xe8b(%rip),%rdi
call   1050 <printf@plt>
xor    %eax,%eax
call   1060 <_test_uneven@plt>
mov    %rbx,%rdi
call   1030 <puts@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [21 x i8] c"simple allocation...\00"
@.str.1 = [6 x i8] c" OK!\0A\00"
@.str.2 = [11 x i8] c"strings...\00"
@.str.3 = [10 x i8] c"uneven...\00"
define i32 @main() {
%1 = call i32 @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0))
%2 = call i32 (...) @_test_allocation()
%3 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0))
%4 = call i32 @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.2, i64 0, i64 0))
%5 = call i32 (...) @_test_strings()
%6 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0))
%7 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.3, i64 0, i64 0))
%8 = call i32 (...) @_test_uneven()
%9 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@.str = [21 x i8] c"simple allocation...\00"
@.str.2 = [11 x i8] c"strings...\00"
@.str.3 = [10 x i8] c"uneven...\00"
@str.5 = [5 x i8] c" OK!\00"
define i32 @main() {
%1 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0))
%2 = tail call i32 (...) @_test_allocation()
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @str.5, i64 0, i64 0))
%4 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([11 x i8], [11 x i8]* @.str.2, i64 0, i64 0))
%5 = tail call i32 (...) @_test_strings()
%6 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @str.5, i64 0, i64 0))
%7 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @.str.3, i64 0, i64 0))
%8 = tail call i32 (...) @_test_uneven()
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @str.5, i64 0, i64 0))
ret i32 0
}