#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 */
double logf(float);
float dew_point(float relative_humidity, float temperature) {
  float dew_point;
  dew_point = 243.12 *
              (logf(relative_humidity / 100.0) +
               17.62 * temperature / (243.12 + temperature)) /
              (17.62 - logf(relative_humidity / 100.0) -
               17.62 * temperature / (243.12 + temperature));
  return dew_point;
}


x86 assembly (clang, -O0):
<dew_point>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movss  %xmm0,-0x4(%rbp)
movss  %xmm1,-0x8(%rbp)
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xedd(%rip),%xmm1
divsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
call   1030 <logf@plt>
movaps %xmm0,%xmm1
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm2
movsd  0xeb4(%rip),%xmm0
mulsd  %xmm2,%xmm0
movss  -0x8(%rbp),%xmm2
cvtss2sd %xmm2,%xmm3
movsd  0xe97(%rip),%xmm2
addsd  %xmm3,%xmm2
divsd  %xmm2,%xmm0
addsd  %xmm0,%xmm1
movsd  0xe83(%rip),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xe79(%rip),%xmm1
divsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
call   1030 <logf@plt>
movaps %xmm0,%xmm2
movsd  -0x18(%rbp),%xmm0
movsd  0xe54(%rip),%xmm1
subsd  %xmm2,%xmm1
movss  -0x8(%rbp),%xmm2
cvtss2sd %xmm2,%xmm3
movsd  0xe3f(%rip),%xmm2
mulsd  %xmm3,%xmm2
movss  -0x8(%rbp),%xmm3
cvtss2sd %xmm3,%xmm4
movsd  0xe22(%rip),%xmm3
addsd  %xmm4,%xmm3
divsd  %xmm3,%xmm2
subsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0xc(%rbp)
movss  -0xc(%rbp),%xmm0
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<dew_point>:
sub    $0x18,%rsp
movss  %xmm1,(%rsp)
divss  0xedf(%rip),%xmm0
movss  %xmm0,0xc(%rsp)
call   1030 <logf@plt>
movss  (%rsp),%xmm1
cvtss2sd %xmm1,%xmm2
movaps %xmm2,%xmm3
mulsd  0xec8(%rip),%xmm3
movsd  0xec8(%rip),%xmm1
addsd  %xmm1,%xmm2
divsd  %xmm2,%xmm3
movsd  %xmm3,(%rsp)
addsd  %xmm3,%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,0x10(%rsp)
movss  0xc(%rsp),%xmm0
call   1030 <logf@plt>
movsd  0xe92(%rip),%xmm1
subsd  %xmm0,%xmm1
subsd  (%rsp),%xmm1
movsd  0x10(%rsp),%xmm0
divsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
add    $0x18,%rsp
ret

LLVM IR (-O0):
define float @dew_point(float %0, float %1) {
%3 = alloca float
%4 = alloca float
%5 = alloca float
store float %0, float* %3
store float %1, float* %4
%6 = load float, float* %3
%7 = fpext float %6 to double
%8 = fdiv double %7, 1.000000e+02
%9 = fptrunc double %8 to float
%10 = call double @logf(float %9)
%11 = load float, float* %4
%12 = fpext float %11 to double
%13 = fmul double 1.762000e+01, %12
%14 = load float, float* %4
%15 = fpext float %14 to double
%16 = fadd double 2.431200e+02, %15
%17 = fdiv double %13, %16
%18 = fadd double %10, %17
%19 = fmul double 2.431200e+02, %18
%20 = load float, float* %3
%21 = fpext float %20 to double
%22 = fdiv double %21, 1.000000e+02
%23 = fptrunc double %22 to float
%24 = call double @logf(float %23)
%25 = fsub double 1.762000e+01, %24
%26 = load float, float* %4
%27 = fpext float %26 to double
%28 = fmul double 1.762000e+01, %27
%29 = load float, float* %4
%30 = fpext float %29 to double
%31 = fadd double 2.431200e+02, %30
%32 = fdiv double %28, %31
%33 = fsub double %25, %32
%34 = fdiv double %19, %33
%35 = fptrunc double %34 to float
store float %35, float* %5
%36 = load float, float* %5
ret float %36
}

LLVM IR (-O2):
define float @dew_point(float %0, float %1) {
%3 = fdiv float %0, 1.000000e+02
%4 = tail call double @logf(float %3)
%5 = fpext float %1 to double
%6 = fmul double %5, 1.762000e+01
%7 = fadd double %5, 2.431200e+02
%8 = fdiv double %6, %7
%9 = fadd double %8, %4
%10 = fmul double %9, 2.431200e+02
%11 = tail call double @logf(float %3)
%12 = fsub double 1.762000e+01, %11
%13 = fsub double %12, %8
%14 = fdiv double %10, %13
%15 = fptrunc double %14 to float
ret float %15
}