#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 *, double, ...);
int main(int argc, char **argv) {
  double t_c1 = 55, t_c2 = 100, t_c3 = 222.4;
  double cfac, t_f1, t_f2, t_f3;
  cfac = 9.0 / 5.0;
  t_f1 = t_c1 * cfac + 32;
  t_f2 = t_c2 * cfac + 32;
  t_f3 = t_c3 * cfac + 32;
  printf("cfac: %f\n", cfac);
  printf("%f celcius is %f farenheit\n", t_c1, t_f1);
  printf("%f celcius is %f farenheit\n", t_c2, t_f2);
  printf("%f celcius is %f farenheit\n", t_c3, t_f3);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movsd  0xef2(%rip),%xmm0
movsd  %xmm0,-0x18(%rbp)
movsd  0xedd(%rip),%xmm0
movsd  %xmm0,-0x20(%rbp)
movsd  0xec8(%rip),%xmm0
movsd  %xmm0,-0x28(%rbp)
movsd  0xeb3(%rip),%xmm0
movsd  %xmm0,-0x30(%rbp)
movsd  -0x18(%rbp),%xmm0
movsd  -0x30(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xe90(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x38(%rbp)
movsd  -0x20(%rbp),%xmm0
movsd  -0x30(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xe71(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x28(%rbp),%xmm0
movsd  -0x30(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movsd  0xe52(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
movsd  -0x30(%rbp),%xmm0
lea    0xe65(%rip),%rdi
mov    $0x1,%al
call   1030 <printf@plt>
movsd  -0x18(%rbp),%xmm0
movsd  -0x38(%rbp),%xmm1
lea    0xe57(%rip),%rdi
mov    $0x2,%al
call   1030 <printf@plt>
movsd  -0x20(%rbp),%xmm0
movsd  -0x40(%rbp),%xmm1
lea    0xe3f(%rip),%rdi
mov    $0x2,%al
call   1030 <printf@plt>
movsd  -0x28(%rbp),%xmm0
movsd  -0x48(%rbp),%xmm1
lea    0xe27(%rip),%rdi
mov    $0x2,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
lea    0xf20(%rip),%rdi
movsd  0xee0(%rip),%xmm0
mov    $0x1,%al
call   1030 <printf@plt>
lea    0xf14(%rip),%rbx
movsd  0xed2(%rip),%xmm0
movsd  0xed2(%rip),%xmm1
mov    %rbx,%rdi
mov    $0x2,%al
call   1030 <printf@plt>
movsd  0xec8(%rip),%xmm0
movsd  0xec8(%rip),%xmm1
mov    %rbx,%rdi
mov    $0x2,%al
call   1030 <printf@plt>
movsd  0xebe(%rip),%xmm0
movsd  0xebe(%rip),%xmm1
mov    %rbx,%rdi
mov    $0x2,%al
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [10 x i8] c"cfac: %f\0A\00"
@.str.1 = [28 x i8] c"%f celcius is %f farenheit\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca double
%7 = alloca double
%8 = alloca double
%9 = alloca double
%10 = alloca double
%11 = alloca double
%12 = alloca double
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store double 5.500000e+01, double* %6
store double 1.000000e+02, double* %7
store double 2.224000e+02, double* %8
store double 1.800000e+00, double* %9
%13 = load double, double* %6
%14 = load double, double* %9
%15 = call double @llvm.fmuladd.f64(double %13, double %14, double 3.200000e+01)
store double %15, double* %10
%16 = load double, double* %7
%17 = load double, double* %9
%18 = call double @llvm.fmuladd.f64(double %16, double %17, double 3.200000e+01)
store double %18, double* %11
%19 = load double, double* %8
%20 = load double, double* %9
%21 = call double @llvm.fmuladd.f64(double %19, double %20, double 3.200000e+01)
store double %21, double* %12
%22 = load double, double* %9
%23 = call i32 (i8*, double, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), double %22)
%24 = load double, double* %6
%25 = load double, double* %10
%26 = call i32 (i8*, double, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.1, i64 0, i64 0), double %24, double %25)
%27 = load double, double* %7
%28 = load double, double* %11
%29 = call i32 (i8*, double, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.1, i64 0, i64 0), double %27, double %28)
%30 = load double, double* %8
%31 = load double, double* %12
%32 = call i32 (i8*, double, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.1, i64 0, i64 0), double %30, double %31)
ret i32 0
}

LLVM IR (-O2):
@.str = [10 x i8] c"cfac: %f\0A\00"
@.str.1 = [28 x i8] c"%f celcius is %f farenheit\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 (i8*, double, ...) @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str, i64 0, i64 0), double 1.800000e+00)
%4 = tail call i32 (i8*, double, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.1, i64 0, i64 0), double 5.500000e+01, double 1.310000e+02)
%5 = tail call i32 (i8*, double, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.1, i64 0, i64 0), double 1.000000e+02, double 2.120000e+02)
%6 = tail call i32 (i8*, double, ...) @printf(i8* getelementptr inbounds ([28 x i8], [28 x i8]* @.str.1, i64 0, i64 0), double 2.224000e+02, double 4.323200e+02)
ret i32 0
}