#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*/ printf(char *);
int /*<<< orphan*/ test_enum();
int /*<<< orphan*/ test_ringbuf();
int /*<<< orphan*/ test_slice();
int /*<<< orphan*/ test_str();
int /*<<< orphan*/ test_vec();
int main(int argc, char *argv[]) {
  printf("Testing Vec!\n");
  test_vec();
  printf("\nTesting Slice!\n");
  test_slice();
  printf("\nTesting Str!\n");
  test_str();
  printf("\nTesting Enum!\n");
  test_enum();
  printf("\nTesting Ringbuf!\n");
  test_ringbuf();
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
lea    0xe8a(%rip),%rdi
call   1050 <printf@plt>
mov    $0x0,%al
call   1070 <test_vec@plt>
lea    0xe85(%rip),%rdi
call   1050 <printf@plt>
mov    $0x0,%al
call   1060 <test_slice@plt>
lea    0xe83(%rip),%rdi
call   1050 <printf@plt>
mov    $0x0,%al
call   1030 <test_str@plt>
lea    0xe7f(%rip),%rdi
call   1050 <printf@plt>
mov    $0x0,%al
call   1040 <test_enum@plt>
lea    0xe7c(%rip),%rdi
call   1050 <printf@plt>
mov    $0x0,%al
call   1080 <test_ringbuf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xe98(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   1070 <test_vec@plt>
lea    0xe92(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   1060 <test_slice@plt>
lea    0xe8f(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   1030 <test_str@plt>
lea    0xe8a(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   1050 <test_enum@plt>
lea    0xe86(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
call   1080 <test_ringbuf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [14 x i8] c"Testing Vec!\0A\00"
@.str.1 = [17 x i8] c"\0ATesting Slice!\0A\00"
@.str.2 = [15 x i8] c"\0ATesting Str!\0A\00"
@.str.3 = [16 x i8] c"\0ATesting Enum!\0A\00"
@.str.4 = [19 x i8] c"\0ATesting Ringbuf!\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i8**
store i32 %0, i32* %3
store i8** %1, i8*** %4
%5 = call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str, i64 0, i64 0))
%6 = call i32 (...) @test_vec()
%7 = call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.1, i64 0, i64 0))
%8 = call i32 (...) @test_slice()
%9 = call i32 @printf(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.2, i64 0, i64 0))
%10 = call i32 (...) @test_str()
%11 = call i32 @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.3, i64 0, i64 0))
%12 = call i32 (...) @test_enum()
%13 = call i32 @printf(i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0))
%14 = call i32 (...) @test_ringbuf()
ret i32 0
}

LLVM IR (-O2):
@str = [13 x i8] c"Testing Vec!\00"
@str.5 = [16 x i8] c"\0ATesting Slice!\00"
@str.6 = [14 x i8] c"\0ATesting Str!\00"
@str.7 = [15 x i8] c"\0ATesting Enum!\00"
@str.8 = [18 x i8] c"\0ATesting Ringbuf!\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([13 x i8], [13 x i8]* @str, i64 0, i64 0))
%4 = tail call i32 (...) @test_vec()
%5 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @str.5, i64 0, i64 0))
%6 = tail call i32 (...) @test_slice()
%7 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @str.6, i64 0, i64 0))
%8 = tail call i32 (...) @test_str()
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @str.7, i64 0, i64 0))
%10 = tail call i32 (...) @test_enum()
%11 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([18 x i8], [18 x i8]* @str.8, i64 0, i64 0))
%12 = tail call i32 (...) @test_ringbuf()
ret i32 0
}