#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 */
float fahrenheit_to_celsius(float);
int /*<<< orphan*/ printf(char *, float, float);
int main(int argc, char const *argv[]) {
  float fahr, celsius;
  int lower, upper, step;
  lower = 0;
  upper = 300;
  step = 20;
  fahr = lower;
  while (fahr <= upper) {
    celsius = fahrenheit_to_celsius(fahr);
    printf("%3.0f %6.1f\n", fahr, celsius);
    fahr = fahr + step;
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x0,-0x1c(%rbp)
movl   $0x12c,-0x20(%rbp)
movl   $0x14,-0x24(%rbp)
cvtsi2ssl -0x1c(%rbp),%xmm0
movss  %xmm0,-0x14(%rbp)
movss  -0x14(%rbp),%xmm1
cvtsi2ssl -0x20(%rbp),%xmm0
ucomiss %xmm1,%xmm0
jb     11a5 <main+0x85>
movss  -0x14(%rbp),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movss  %xmm0,-0x18(%rbp)
movss  -0x14(%rbp),%xmm0
movss  -0x18(%rbp),%xmm1
lea    0xe78(%rip),%rdi
call   1030 <printf@plt>
movss  -0x14(%rbp),%xmm0
cvtsi2ssl -0x24(%rbp),%xmm1
addss  %xmm1,%xmm0
movss  %xmm0,-0x14(%rbp)
jmp    1155 <main+0x35>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
xorps  %xmm0,%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
lea    0xf09(%rip),%rbx
xorps  %xmm0,%xmm0
mov    %rbx,%rdi
call   1030 <printf@plt>
movss  0xeba(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xea7(%rip),%xmm0
call   1030 <printf@plt>
movss  0xe9e(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xe8b(%rip),%xmm0
call   1030 <printf@plt>
movss  0xe82(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xe6f(%rip),%xmm0
call   1030 <printf@plt>
movss  0xe66(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xe53(%rip),%xmm0
call   1030 <printf@plt>
movss  0xe4a(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xe37(%rip),%xmm0
call   1030 <printf@plt>
movss  0xe2e(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xe1b(%rip),%xmm0
call   1030 <printf@plt>
movss  0xe12(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xdff(%rip),%xmm0
call   1030 <printf@plt>
movss  0xdf6(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xde3(%rip),%xmm0
call   1030 <printf@plt>
movss  0xdda(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xdc7(%rip),%xmm0
call   1030 <printf@plt>
movss  0xdbe(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xdab(%rip),%xmm0
call   1030 <printf@plt>
movss  0xda2(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xd8f(%rip),%xmm0
call   1030 <printf@plt>
movss  0xd86(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xd73(%rip),%xmm0
call   1030 <printf@plt>
movss  0xd6a(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xd57(%rip),%xmm0
call   1030 <printf@plt>
movss  0xd4e(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xd3b(%rip),%xmm0
call   1030 <printf@plt>
movss  0xd32(%rip),%xmm0
call   1040 <fahrenheit_to_celsius@plt>
movaps %xmm0,%xmm1
mov    %rbx,%rdi
movss  0xd1f(%rip),%xmm0
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [13 x i8] c"%3.0f %6.1f\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca float
%7 = alloca float
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 0, i32* %8
store i32 300, i32* %9
store i32 20, i32* %10
%11 = load i32, i32* %8
%12 = sitofp i32 %11 to float
store float %12, float* %6
br label %13
13: ; preds = %18, %2
%14 = load float, float* %6
%15 = load i32, i32* %9
%16 = sitofp i32 %15 to float
%17 = fcmp ole float %14, %16
br i1 %17, label %18, label %28
18: ; preds = %13
%19 = load float, float* %6
%20 = call float @fahrenheit_to_celsius(float %19)
store float %20, float* %7
%21 = load float, float* %6
%22 = load float, float* %7
%23 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float %21, float %22)
%24 = load float, float* %6
%25 = load i32, i32* %10
%26 = sitofp i32 %25 to float
%27 = fadd float %24, %26
store float %27, float* %6
br label %13
28: ; preds = %13
ret i32 0
}

LLVM IR (-O2):
@.str = [13 x i8] c"%3.0f %6.1f\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call float @fahrenheit_to_celsius(float 0.000000e+00)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 0.000000e+00, float %3)
%5 = tail call float @fahrenheit_to_celsius(float 2.000000e+01)
%6 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 2.000000e+01, float %5)
%7 = tail call float @fahrenheit_to_celsius(float 4.000000e+01)
%8 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 4.000000e+01, float %7)
%9 = tail call float @fahrenheit_to_celsius(float 6.000000e+01)
%10 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 6.000000e+01, float %9)
%11 = tail call float @fahrenheit_to_celsius(float 8.000000e+01)
%12 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 8.000000e+01, float %11)
%13 = tail call float @fahrenheit_to_celsius(float 1.000000e+02)
%14 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 1.000000e+02, float %13)
%15 = tail call float @fahrenheit_to_celsius(float 1.200000e+02)
%16 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 1.200000e+02, float %15)
%17 = tail call float @fahrenheit_to_celsius(float 1.400000e+02)
%18 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 1.400000e+02, float %17)
%19 = tail call float @fahrenheit_to_celsius(float 1.600000e+02)
%20 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 1.600000e+02, float %19)
%21 = tail call float @fahrenheit_to_celsius(float 1.800000e+02)
%22 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 1.800000e+02, float %21)
%23 = tail call float @fahrenheit_to_celsius(float 2.000000e+02)
%24 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 2.000000e+02, float %23)
%25 = tail call float @fahrenheit_to_celsius(float 2.200000e+02)
%26 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 2.200000e+02, float %25)
%27 = tail call float @fahrenheit_to_celsius(float 2.400000e+02)
%28 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 2.400000e+02, float %27)
%29 = tail call float @fahrenheit_to_celsius(float 2.600000e+02)
%30 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 2.600000e+02, float %29)
%31 = tail call float @fahrenheit_to_celsius(float 2.800000e+02)
%32 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 2.800000e+02, float %31)
%33 = tail call float @fahrenheit_to_celsius(float 3.000000e+02)
%34 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), float 3.000000e+02, float %33)
ret i32 0
}