#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 atan(int);
double exp(int);
double pow(int, double);
int /*<<< orphan*/ printf(char *, ...);
int main(void) {
  double e2pi, pi2e;
  e2pi = exp(4 * atan(1));
  pi2e = pow(4 * atan(1), exp(1));
  printf("\ne^pi = %g\n", e2pi);
  printf("pi^e = %g\n\n", pi2e);
  if (e2pi > pi2e)
    printf("e^pi is greater\n\n");
  else
    printf("pi^e is greater\n\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x1,%edi
call   1040 <atan@plt>
mov    %eax,%edi
shl    $0x2,%edi
call   1050 <exp@plt>
movsd  %xmm0,-0x10(%rbp)
mov    $0x1,%edi
call   1040 <atan@plt>
shl    $0x2,%eax
mov    %eax,-0x1c(%rbp)
mov    $0x1,%edi
call   1050 <exp@plt>
mov    -0x1c(%rbp),%edi
call   1060 <pow@plt>
movsd  %xmm0,-0x18(%rbp)
movsd  -0x10(%rbp),%xmm0
lea    0xe65(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
movsd  -0x18(%rbp),%xmm0
lea    0xe5e(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
movsd  -0x10(%rbp),%xmm0
ucomisd -0x18(%rbp),%xmm0
jbe    11d8 <main+0x98>
lea    0xe4c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
jmp    11e6 <main+0xa6>
lea    0xe4b(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x10,%rsp
mov    $0x1,%edi
call   1050 <atan@plt>
lea    0x0(,%rax,4),%edi
call   1060 <exp@plt>
movsd  %xmm0,0x8(%rsp)
mov    $0x1,%edi
call   1050 <atan@plt>
lea    0x0(,%rax,4),%ebx
mov    $0x1,%edi
call   1060 <exp@plt>
mov    %ebx,%edi
call   1070 <pow@plt>
movsd  %xmm0,(%rsp)
lea    0xe61(%rip),%rdi
movsd  0x8(%rsp),%xmm0
mov    $0x1,%al
call   1040 <printf@plt>
lea    0xe59(%rip),%rdi
movsd  (%rsp),%xmm0
mov    $0x1,%al
call   1040 <printf@plt>
movsd  0x8(%rsp),%xmm0
ucomisd (%rsp),%xmm0
lea    0xe58(%rip),%rax
lea    0xe40(%rip),%rdi
cmova  %rax,%rdi
call   1030 <puts@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [12 x i8] c"\0Ae^pi = %g\0A\00"
@.str.1 = [12 x i8] c"pi^e = %g\0A\0A\00"
@.str.2 = [18 x i8] c"e^pi is greater\0A\0A\00"
@.str.3 = [18 x i8] c"pi^e is greater\0A\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca double
%3 = alloca double
store i32 0, i32* %1
%4 = call i32 @atan(i32 1)
%5 = mul nsw i32 4, %4
%6 = call double @exp(i32 %5)
store double %6, double* %2
%7 = call i32 @atan(i32 1)
%8 = mul nsw i32 4, %7
%9 = call double @exp(i32 1)
%10 = call double @pow(i32 %8, double %9)
store double %10, double* %3
%11 = load double, double* %2
%12 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), double %11)
%13 = load double, double* %3
%14 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), double %13)
%15 = load double, double* %2
%16 = load double, double* %3
%17 = fcmp ogt double %15, %16
br i1 %17, label %18, label %20
18: ; preds = %0
%19 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.2, i64 0, i64 0))
br label %22
20: ; preds = %0
%21 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @.str.3, i64 0, i64 0))
br label %22
22: ; preds = %20, %18
ret i32 0
}

LLVM IR (-O2):
@.str = [12 x i8] c"\0Ae^pi = %g\0A\00"
@.str.1 = [12 x i8] c"pi^e = %g\0A\0A\00"
@str = [17 x i8] c"pi^e is greater\0A\00"
@str.4 = [17 x i8] c"e^pi is greater\0A\00"
define i32 @main() {
%1 = tail call i32 @atan(i32 1)
%2 = shl nsw i32 %1, 2
%3 = tail call double @exp(i32 %2)
%4 = tail call i32 @atan(i32 1)
%5 = shl nsw i32 %4, 2
%6 = tail call double @exp(i32 1)
%7 = tail call double @pow(i32 %5, double %6)
%8 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), double %3)
%9 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), double %7)
%10 = fcmp ogt double %3, %7
%11 = select i1 %10, i8* getelementptr inbounds ([17 x i8], [17 x i8]* @str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @str, i64 0, i64 0)
%12 = tail call i32 @puts(i8* dereferenceable(1) %11)
ret i32 0
}