#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*/ time_t;

/* Variables and functions */
double difftime(int /*<<< orphan*/, int /*<<< orphan*/);
int /*<<< orphan*/ ft_add_test_case(char **, char *, char *);
int /*<<< orphan*/ ft_get_values(char **, char **, char **);
int /*<<< orphan*/ ft_strcat(char *, char *);
int printf(char *, ...);
int /*<<< orphan*/ stpcpy(char *, char *);
int /*<<< orphan*/ strcat(char *, char *);
scalar_t__ strcmp(char *, char *);
int /*<<< orphan*/ time(int /*<<< orphan*/ *);
int main(void) {
  time_t start_t, end_t;
  double diff_t;
  char *data[4][2];
  char *dest;
  char *src;
  char your_result[100];
  char actual_answer[100];
  int i;
  ft_add_test_case(&data[0][0], "asi;yabs;fj", "sdhdhsh");
  ft_add_test_case(&data[1][0], "", "AGU:HIAHOS:GSOI:gsio;");
  ft_add_test_case(&data[2][0], "", "");
  ft_add_test_case(&data[3][0], "ASFPHA w0l0l0 SHOF", "");
  i = 0;
  while (i < 4) {
    ft_get_values(&data[i][0], &dest, &src);
    stpcpy(your_result, dest);
    stpcpy(actual_answer, dest);
    time(&start_t);
    ft_strcat(your_result, src);
    time(&end_t);
    strcat(actual_answer, src);
    diff_t = difftime(end_t, start_t);
    printf("dest: %s, src: %s, your_result: %s, actual_result: %s, execution "
           "time = %f\n",
           dest, src, your_result, actual_answer, diff_t);
    if (strcmp(your_result, actual_answer))
      return printf("\e[0;31mFAKE AND GAY ✗\e[0m\n");
    if (diff_t >= 2.0)
      return printf("\e[0;33mYOU ARE TOO SLOW! ✗\e[0m\n");
    ++i;
  }
  return printf("\e[0;32mGOES ✓\e[0m\n");
  ;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x160,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x60(%rbp),%rdi
lea    0xe5b(%rip),%rsi
lea    0xe60(%rip),%rdx
call   1090 <ft_add_test_case@plt>
lea    -0x60(%rbp),%rdi
add    $0x10,%rdi
lea    0xec8(%rip),%rsi
lea    0xe4d(%rip),%rdx
call   1090 <ft_add_test_case@plt>
lea    -0x60(%rbp),%rdi
add    $0x20,%rdi
lea    0xead(%rip),%rdx
mov    %rdx,%rsi
call   1090 <ft_add_test_case@plt>
lea    -0x60(%rbp),%rdi
add    $0x30,%rdi
lea    0xe38(%rip),%rsi
lea    0xe8f(%rip),%rdx
call   1090 <ft_add_test_case@plt>
movl   $0x0,-0x154(%rbp)
cmpl   $0x4,-0x154(%rbp)
jge    133b <main+0x1ab>
movslq -0x154(%rbp),%rax
lea    -0x60(%rbp),%rdi
shl    $0x4,%rax
add    %rax,%rdi
lea    -0x68(%rbp),%rsi
lea    -0x70(%rbp),%rdx
call   10b0 <ft_get_values@plt>
lea    -0xe0(%rbp),%rdi
mov    -0x68(%rbp),%rsi
call   1030 <stpcpy@plt>
lea    -0x150(%rbp),%rdi
mov    -0x68(%rbp),%rsi
call   1030 <stpcpy@plt>
lea    -0x8(%rbp),%rdi
call   1080 <time@plt>
lea    -0xe0(%rbp),%rdi
mov    -0x70(%rbp),%rsi
call   1040 <ft_strcat@plt>
lea    -0xc(%rbp),%rdi
call   1080 <time@plt>
lea    -0x150(%rbp),%rdi
mov    -0x70(%rbp),%rsi
call   10a0 <strcat@plt>
mov    -0xc(%rbp),%edi
mov    -0x8(%rbp),%esi
call   1060 <difftime@plt>
movsd  %xmm0,-0x18(%rbp)
mov    -0x68(%rbp),%rsi
mov    -0x70(%rbp),%rdx
lea    -0xe0(%rbp),%rcx
lea    -0x150(%rbp),%r8
movsd  -0x18(%rbp),%xmm0
lea    0xd85(%rip),%rdi
mov    $0x1,%al
call   1050 <printf@plt>
lea    -0xe0(%rbp),%rdi
lea    -0x150(%rbp),%rsi
call   1070 <strcmp@plt>
cmp    $0x0,%rax
je     12fa <main+0x16a>
lea    0xda6(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    %eax,-0x4(%rbp)
jmp    134c <main+0x1bc>
movsd  -0x18(%rbp),%xmm0
movsd  0xcf9(%rip),%xmm1
ucomisd %xmm1,%xmm0
jb     1327 <main+0x197>
lea    0xd96(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    %eax,-0x4(%rbp)
jmp    134c <main+0x1bc>
mov    -0x154(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x154(%rbp)
jmp    1210 <main+0x80>
lea    0xd8e(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x160,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x138,%rsp
lea    0xe60(%rip),%rsi
lea    0xe65(%rip),%rdx
lea    0x20(%rsp),%rdi
call   1090 <ft_add_test_case@plt>
lea    0x30(%rsp),%rdi
lea    0xecb(%rip),%rbx
lea    0xe50(%rip),%rdx
mov    %rbx,%rsi
call   1090 <ft_add_test_case@plt>
lea    0x40(%rsp),%rdi
mov    %rbx,%rsi
mov    %rbx,%rdx
call   1090 <ft_add_test_case@plt>
lea    0x50(%rsp),%rdi
lea    0xe42(%rip),%rsi
mov    %rbx,%rdx
call   1090 <ft_add_test_case@plt>
xor    %r12d,%r12d
lea    0xd0(%rsp),%r13
lea    0x60(%rsp),%rbx
lea    0x14(%rsp),%rbp
lea    0x10(%rsp),%r14
lea    0xe2c(%rip),%r15
nopl   0x0(%rax)
lea    (%rsp,%r12,1),%rdi
add    $0x20,%rdi
lea    0x8(%rsp),%rsi
mov    %rsp,%rdx
call   10b0 <ft_get_values@plt>
mov    0x8(%rsp),%rsi
mov    %r13,%rdi
call   1030 <stpcpy@plt>
mov    0x8(%rsp),%rsi
mov    %rbx,%rdi
call   1030 <stpcpy@plt>
mov    %rbp,%rdi
call   1080 <time@plt>
mov    (%rsp),%rsi
mov    %r13,%rdi
call   1040 <ft_strcat@plt>
mov    %r14,%rdi
call   1080 <time@plt>
mov    (%rsp),%rsi
mov    %rbx,%rdi
call   10a0 <strcat@plt>
mov    0x10(%rsp),%edi
mov    0x14(%rsp),%esi
call   1060 <difftime@plt>
mov    0x8(%rsp),%rsi
mov    (%rsp),%rdx
mov    %r15,%rdi
mov    %r13,%rcx
mov    %rbx,%r8
movsd  %xmm0,0x18(%rsp)
mov    $0x1,%al
call   1050 <printf@plt>
mov    %r13,%rdi
mov    %rbx,%rsi
call   1070 <strcmp@plt>
test   %rax,%rax
jne    12da <main+0x14a>
movsd  0x18(%rsp),%xmm0
ucomisd 0xd3f(%rip),%xmm0
jae    12e3 <main+0x153>
add    $0x10,%r12
cmp    $0x40,%r12
jne    1220 <main+0x90>
lea    0xdf8(%rip),%rdi
jmp    12ea <main+0x15a>
lea    0xdb0(%rip),%rdi
jmp    12ea <main+0x15a>
lea    0xdc4(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x138,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [12 x i8] c"asi;yabs;fj\00"
@.str.1 = [8 x i8] c"sdhdhsh\00"
@.str.2 = [1 x i8] zeroinitializer
@.str.3 = [22 x i8] c"AGU:HIAHOS:GSOI:gsio;\00"
@.str.4 = [19 x i8] c"ASFPHA w0l0l0 SHOF\00"
@.str.5 = [76 x i8] c"dest: %s, src: %s, your_result: %s, actual_result: %s, execution time = %f\0A\00"
@.str.6 = [29 x i8] c"\1B[0;31mFAKE AND GAY \E2\9C\97\1B[0m\0A\00"
@.str.7 = [34 x i8] c"\1B[0;33mYOU ARE TOO SLOW! \E2\9C\97\1B[0m\0A\00"
@.str.8 = [21 x i8] c"\1B[0;32mGOES \E2\9C\93\1B[0m\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca double
%5 = alloca [4 x [2 x i8*]]
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca [100 x i8]
%9 = alloca [100 x i8]
%10 = alloca i32
store i32 0, i32* %1
%11 = getelementptr inbounds [4 x [2 x i8*]], [4 x [2 x i8*]]* %5, i64 0, i64 0
%12 = getelementptr inbounds [2 x i8*], [2 x i8*]* %11, i64 0, i64 0
%13 = call i32 @ft_add_test_case(i8** %12, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%14 = getelementptr inbounds [4 x [2 x i8*]], [4 x [2 x i8*]]* %5, i64 0, i64 1
%15 = getelementptr inbounds [2 x i8*], [2 x i8*]* %14, i64 0, i64 0
%16 = call i32 @ft_add_test_case(i8** %15, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.3, i64 0, i64 0))
%17 = getelementptr inbounds [4 x [2 x i8*]], [4 x [2 x i8*]]* %5, i64 0, i64 2
%18 = getelementptr inbounds [2 x i8*], [2 x i8*]* %17, i64 0, i64 0
%19 = call i32 @ft_add_test_case(i8** %18, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0))
%20 = getelementptr inbounds [4 x [2 x i8*]], [4 x [2 x i8*]]* %5, i64 0, i64 3
%21 = getelementptr inbounds [2 x i8*], [2 x i8*]* %20, i64 0, i64 0
%22 = call i32 @ft_add_test_case(i8** %21, i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0))
store i32 0, i32* %10
br label %23
23: ; preds = %66, %0
%24 = load i32, i32* %10
%25 = icmp slt i32 %24, 4
br i1 %25, label %26, label %69
26: ; preds = %23
%27 = load i32, i32* %10
%28 = sext i32 %27 to i64
%29 = getelementptr inbounds [4 x [2 x i8*]], [4 x [2 x i8*]]* %5, i64 0, i64 %28
%30 = getelementptr inbounds [2 x i8*], [2 x i8*]* %29, i64 0, i64 0
%31 = call i32 @ft_get_values(i8** %30, i8** %6, i8** %7)
%32 = getelementptr inbounds [100 x i8], [100 x i8]* %8, i64 0, i64 0
%33 = load i8*, i8** %6
%34 = call i32 @stpcpy(i8* %32, i8* %33)
%35 = getelementptr inbounds [100 x i8], [100 x i8]* %9, i64 0, i64 0
%36 = load i8*, i8** %6
%37 = call i32 @stpcpy(i8* %35, i8* %36)
%38 = call i32 @time(i32* %2)
%39 = getelementptr inbounds [100 x i8], [100 x i8]* %8, i64 0, i64 0
%40 = load i8*, i8** %7
%41 = call i32 @ft_strcat(i8* %39, i8* %40)
%42 = call i32 @time(i32* %3)
%43 = getelementptr inbounds [100 x i8], [100 x i8]* %9, i64 0, i64 0
%44 = load i8*, i8** %7
%45 = call i32 @strcat(i8* %43, i8* %44)
%46 = load i32, i32* %3
%47 = load i32, i32* %2
%48 = call double @difftime(i32 %46, i32 %47)
store double %48, double* %4
%49 = load i8*, i8** %6
%50 = load i8*, i8** %7
%51 = getelementptr inbounds [100 x i8], [100 x i8]* %8, i64 0, i64 0
%52 = getelementptr inbounds [100 x i8], [100 x i8]* %9, i64 0, i64 0
%53 = load double, double* %4
%54 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([76 x i8], [76 x i8]* @.str.5, i64 0, i64 0), i8* %49, i8* %50, i8* %51, i8* %52, double %53)
%55 = getelementptr inbounds [100 x i8], [100 x i8]* %8, i64 0, i64 0
%56 = getelementptr inbounds [100 x i8], [100 x i8]* %9, i64 0, i64 0
%57 = call i64 @strcmp(i8* %55, i8* %56)
%58 = icmp ne i64 %57, 0
br i1 %58, label %59, label %61
59: ; preds = %26
%60 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.6, i64 0, i64 0))
store i32 %60, i32* %1
br label %71
61: ; preds = %26
%62 = load double, double* %4
%63 = fcmp oge double %62, 2.000000e+00
br i1 %63, label %64, label %66
64: ; preds = %61
%65 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.7, i64 0, i64 0))
store i32 %65, i32* %1
br label %71
66: ; preds = %61
%67 = load i32, i32* %10
%68 = add nsw i32 %67, 1
store i32 %68, i32* %10
br label %23
69: ; preds = %23
%70 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.8, i64 0, i64 0))
store i32 %70, i32* %1
br label %71
71: ; preds = %69, %64, %59
%72 = load i32, i32* %1
ret i32 %72
}

LLVM IR (-O2):
@.str = [12 x i8] c"asi;yabs;fj\00"
@.str.1 = [8 x i8] c"sdhdhsh\00"
@.str.2 = [1 x i8] zeroinitializer
@.str.3 = [22 x i8] c"AGU:HIAHOS:GSOI:gsio;\00"
@.str.4 = [19 x i8] c"ASFPHA w0l0l0 SHOF\00"
@.str.5 = [76 x i8] c"dest: %s, src: %s, your_result: %s, actual_result: %s, execution time = %f\0A\00"
@.str.6 = [29 x i8] c"\1B[0;31mFAKE AND GAY \E2\9C\97\1B[0m\0A\00"
@.str.7 = [34 x i8] c"\1B[0;33mYOU ARE TOO SLOW! \E2\9C\97\1B[0m\0A\00"
@.str.8 = [21 x i8] c"\1B[0;32mGOES \E2\9C\93\1B[0m\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca [4 x [2 x i8*]]
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca [100 x i8]
%7 = alloca [100 x i8]
%8 = bitcast i32* %1 to i8*
%9 = bitcast i32* %2 to i8*
%10 = bitcast [4 x [2 x i8*]]* %3 to i8*
%11 = bitcast i8** %4 to i8*
%12 = bitcast i8** %5 to i8*
%13 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 0
%14 = getelementptr inbounds [100 x i8], [100 x i8]* %7, i64 0, i64 0
%15 = getelementptr inbounds [4 x [2 x i8*]], [4 x [2 x i8*]]* %3, i64 0, i64 0, i64 0
%16 = call i32 @ft_add_test_case(i8** %15, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%17 = getelementptr inbounds [4 x [2 x i8*]], [4 x [2 x i8*]]* %3, i64 0, i64 1, i64 0
%18 = call i32 @ft_add_test_case(i8** %17, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.3, i64 0, i64 0))
%19 = getelementptr inbounds [4 x [2 x i8*]], [4 x [2 x i8*]]* %3, i64 0, i64 2, i64 0
%20 = call i32 @ft_add_test_case(i8** %19, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0))
%21 = getelementptr inbounds [4 x [2 x i8*]], [4 x [2 x i8*]]* %3, i64 0, i64 3, i64 0
%22 = call i32 @ft_add_test_case(i8** %21, i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0))
br label %26
23: ; preds = %48
%24 = add nuw nsw i64 %27, 1
%25 = icmp eq i64 %24, 4
br i1 %25, label %50, label %26
26: ; preds = %0, %23
%27 = phi i64 [ 0, %0 ], [ %24, %23 ]
%28 = getelementptr inbounds [4 x [2 x i8*]], [4 x [2 x i8*]]* %3, i64 0, i64 %27, i64 0
%29 = call i32 @ft_get_values(i8** %28, i8** %4, i8** %5)
%30 = load i8*, i8** %4
%31 = call i32 @stpcpy(i8* %13, i8* %30)
%32 = load i8*, i8** %4
%33 = call i32 @stpcpy(i8* %14, i8* %32)
%34 = call i32 @time(i32* %1)
%35 = load i8*, i8** %5
%36 = call i32 @ft_strcat(i8* %13, i8* %35)
%37 = call i32 @time(i32* %2)
%38 = load i8*, i8** %5
%39 = call i32 @strcat(i8* %14, i8* %38)
%40 = load i32, i32* %2
%41 = load i32, i32* %1
%42 = call double @difftime(i32 %40, i32 %41)
%43 = load i8*, i8** %4
%44 = load i8*, i8** %5
%45 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([76 x i8], [76 x i8]* @.str.5, i64 0, i64 0), i8* %43, i8* %44, i8* %13, i8* %14, double %42)
%46 = call i64 @strcmp(i8* %13, i8* %14)
%47 = icmp eq i64 %46, 0
br i1 %47, label %48, label %50
48: ; preds = %26
%49 = fcmp ult double %42, 2.000000e+00
br i1 %49, label %23, label %50
50: ; preds = %23, %48, %26
%51 = phi i8* [ getelementptr inbounds ([29 x i8], [29 x i8]* @.str.6, i64 0, i64 0), %26 ], [ getelementptr inbounds ([34 x i8], [34 x i8]* @.str.7, i64 0, i64 0), %48 ], [ getelementptr inbounds ([21 x i8], [21 x i8]* @.str.8, i64 0, i64 0), %23 ]
%52 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) %51)
ret i32 %52
}