#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 scalar_t__ time_t;

/* Variables and functions */
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ sleep(int);
scalar_t__ time(int /*<<< orphan*/ *);
int main() {
  time_t before = time(NULL);
  sleep(1);
  time_t after = time(NULL);
  if (before < after) {
    printf("Before did come before after");
  } else
    printf("What the fuck");
  if (after > before) {
    printf("Yarp Yarp\n");
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
xor    %eax,%eax
mov    %eax,%edi
call   1040 <time@plt>
mov    %rax,-0x10(%rbp)
mov    $0x1,%edi
call   1050 <sleep@plt>
xor    %eax,%eax
mov    %eax,%edi
call   1040 <time@plt>
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rax
cmp    -0x18(%rbp),%rax
jge    1182 <main+0x52>
lea    0xe88(%rip),%rdi
call   1030 <printf@plt>
jmp    118e <main+0x5e>
lea    0xe94(%rip),%rdi
call   1030 <printf@plt>
mov    -0x18(%rbp),%rax
cmp    -0x10(%rbp),%rax
jle    11a8 <main+0x78>
lea    0xe88(%rip),%rdi
call   1030 <printf@plt>
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
xor    %edi,%edi
call   1050 <time@plt>
mov    %rax,%rbx
mov    $0x1,%edi
call   1060 <sleep@plt>
xor    %edi,%edi
call   1050 <time@plt>
cmp    %rax,%rbx
jge    117b <main+0x3b>
lea    0xe98(%rip),%rdi
call   1040 <printf@plt>
lea    0xeb7(%rip),%rdi
call   1030 <puts@plt>
jmp    1187 <main+0x47>
lea    0xe9b(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [29 x i8] c"Before did come before after\00"
@.str.1 = [14 x i8] c"What the fuck\00"
@.str.2 = [11 x i8] c"Yarp Yarp\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i64
%3 = alloca i64
store i32 0, i32* %1
%4 = call i64 @time(i32* null)
store i64 %4, i64* %2
%5 = call i32 @sleep(i32 1)
%6 = call i64 @time(i32* null)
store i64 %6, i64* %3
%7 = load i64, i64* %2
%8 = load i64, i64* %3
%9 = icmp slt i64 %7, %8
br i1 %9, label %10, label %12
10: ; preds = %0
%11 = call i32 @printf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0))
br label %14
12: ; preds = %0
%13 = call i32 @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0))
br label %14
14: ; preds = %12, %10
%15 = load i64, i64* %3
%16 = load i64, i64* %2
%17 = icmp sgt i64 %15, %16
br i1 %17, label %18, label %20
18: ; preds = %14
%19 = call i32 @printf(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.2, i64 0, i64 0))
br label %20
20: ; preds = %18, %14
%21 = load i32, i32* %1
ret i32 %21
}

LLVM IR (-O2):
@.str = [29 x i8] c"Before did come before after\00"
@.str.1 = [14 x i8] c"What the fuck\00"
@str = [10 x i8] c"Yarp Yarp\00"
define i32 @main() {
%1 = tail call i64 @time(i32* null)
%2 = tail call i32 @sleep(i32 1)
%3 = tail call i64 @time(i32* null)
%4 = icmp slt i64 %1, %3
br i1 %4, label %7, label %5
5: ; preds = %0
%6 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0))
br label %10
7: ; preds = %0
%8 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @.str, i64 0, i64 0))
%9 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([10 x i8], [10 x i8]* @str, i64 0, i64 0))
br label %10
10: ; preds = %5, %7
ret i32 0
}