#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*/ ccf_demo(char *);
int /*<<< orphan*/ dlc_demo(char *);
int /*<<< orphan*/ fputs(char *, int /*<<< orphan*/);
int /*<<< orphan*/ rsdf_demo(char *);
int /*<<< orphan*/ stdout;
int main(void) {
  fputs("RSDF:\n=====\n", stdout);
  rsdf_demo("test.rsdf");
  fputs("\nCCF:\n====\n", stdout);
  ccf_demo("test.ccf");
  fputs("\nDLC:\n====\n", stdout);
  dlc_demo("test.dlc");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    0x2e8a(%rip),%rax
mov    (%rax),%esi
lea    0xea1(%rip),%rdi
call   1040 <fputs@plt>
lea    0xea2(%rip),%rdi
call   1060 <rsdf_demo@plt>
mov    0x2e69(%rip),%rax
mov    (%rax),%esi
lea    0xe97(%rip),%rdi
call   1040 <fputs@plt>
lea    0xe97(%rip),%rdi
call   1030 <ccf_demo@plt>
mov    0x2e48(%rip),%rax
mov    (%rax),%esi
lea    0xe8b(%rip),%rdi
call   1040 <fputs@plt>
lea    0xe8b(%rip),%rdi
call   1050 <dlc_demo@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
mov    0x2e98(%rip),%rbx
mov    (%rbx),%esi
lea    0xeaf(%rip),%rdi
call   1040 <fputs@plt>
lea    0xeb0(%rip),%rdi
call   1060 <rsdf_demo@plt>
mov    (%rbx),%esi
lea    0xeac(%rip),%rdi
call   1040 <fputs@plt>
lea    0xeac(%rip),%rdi
call   1030 <ccf_demo@plt>
mov    (%rbx),%esi
lea    0xea7(%rip),%rdi
call   1040 <fputs@plt>
lea    0xea7(%rip),%rdi
call   1050 <dlc_demo@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [13 x i8] c"RSDF:\0A=====\0A\00"
@stdout = global i32 0
@.str.1 = [10 x i8] c"test.rsdf\00"
@.str.2 = [12 x i8] c"\0ACCF:\0A====\0A\00"
@.str.3 = [9 x i8] c"test.ccf\00"
@.str.4 = [12 x i8] c"\0ADLC:\0A====\0A\00"
@.str.5 = [9 x i8] c"test.dlc\00"
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = load i32, i32* @stdout
%3 = call i32 @fputs(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %2)
%4 = call i32 @rsdf_demo(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
%5 = load i32, i32* @stdout
%6 = call i32 @fputs(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.2, i64 0, i64 0), i32 %5)
%7 = call i32 @ccf_demo(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.3, i64 0, i64 0))
%8 = load i32, i32* @stdout
%9 = call i32 @fputs(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.4, i64 0, i64 0), i32 %8)
%10 = call i32 @dlc_demo(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.5, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@.str = [13 x i8] c"RSDF:\0A=====\0A\00"
@stdout = global i32 0
@.str.1 = [10 x i8] c"test.rsdf\00"
@.str.2 = [12 x i8] c"\0ACCF:\0A====\0A\00"
@.str.3 = [9 x i8] c"test.ccf\00"
@.str.4 = [12 x i8] c"\0ADLC:\0A====\0A\00"
@.str.5 = [9 x i8] c"test.dlc\00"
define i32 @main() {
%1 = load i32, i32* @stdout
%2 = tail call i32 @fputs(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %1)
%3 = tail call i32 @rsdf_demo(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i64 0, i64 0))
%4 = load i32, i32* @stdout
%5 = tail call i32 @fputs(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.2, i64 0, i64 0), i32 %4)
%6 = tail call i32 @ccf_demo(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.3, i64 0, i64 0))
%7 = load i32, i32* @stdout
%8 = tail call i32 @fputs(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.4, i64 0, i64 0), i32 %7)
%9 = tail call i32 @dlc_demo(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.5, i64 0, i64 0))
ret i32 0
}