#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 cos(float);
double pow(float, double);
double sin(float);
float fint(float x) {
  return 4.0 * x * (x * x - 7.0) * sin(x) -
         (pow(x, 4.0) - 14.0 * x * x + 28.0) * cos(x);
}


x86 assembly (clang, -O0):
<fint>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movss  %xmm0,-0x4(%rbp)
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xec2(%rip),%xmm0
mulsd  %xmm1,%xmm0
movss  -0x4(%rbp),%xmm1
mulss  -0x4(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
movsd  0xeb0(%rip),%xmm2
subsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x10(%rbp)
movss  -0x4(%rbp),%xmm0
call   1030 <sin@plt>
movsd  %xmm0,-0x18(%rbp)
movss  -0x4(%rbp),%xmm0
movsd  0xe7f(%rip),%xmm1
call   1050 <pow@plt>
movaps %xmm0,%xmm1
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm2
movsd  0xe5e(%rip),%xmm0
mulsd  %xmm2,%xmm0
movss  -0x4(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  0xe22(%rip),%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x20(%rbp)
movss  -0x4(%rbp),%xmm0
call   1040 <cos@plt>
movsd  -0x20(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm2
movaps %xmm0,%xmm3
movsd  -0x10(%rbp),%xmm0
mulsd  %xmm3,%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fint>:
sub    $0x28,%rsp
movss  %xmm0,0xc(%rsp)
cvtss2sd %xmm0,%xmm2
movsd  %xmm2,0x10(%rsp)
mulsd  0xeb4(%rip),%xmm2
movaps %xmm0,%xmm1
mulss  %xmm0,%xmm1
cvtss2sd %xmm1,%xmm1
addsd  0xea9(%rip),%xmm1
mulsd  %xmm2,%xmm1
movsd  %xmm1,0x20(%rsp)
call   1030 <sin@plt>
movsd  %xmm0,0x18(%rsp)
movss  0xc(%rsp),%xmm0
movsd  0xe7e(%rip),%xmm1
call   1050 <pow@plt>
movsd  0xe81(%rip),%xmm2
movsd  0x10(%rsp),%xmm1
mulsd  %xmm1,%xmm2
mulsd  %xmm1,%xmm2
addsd  %xmm0,%xmm2
addsd  0xe6f(%rip),%xmm2
movsd  %xmm2,0x10(%rsp)
movss  0xc(%rsp),%xmm0
call   1040 <cos@plt>
mulsd  0x10(%rsp),%xmm0
movsd  0x18(%rsp),%xmm1
mulsd  0x20(%rsp),%xmm1
subsd  %xmm0,%xmm1
xorps  %xmm0,%xmm0
cvtsd2ss %xmm1,%xmm0
add    $0x28,%rsp
ret

LLVM IR (-O0):
define float @fint(float %0) {
%2 = alloca float
store float %0, float* %2
%3 = load float, float* %2
%4 = fpext float %3 to double
%5 = fmul double 4.000000e+00, %4
%6 = load float, float* %2
%7 = load float, float* %2
%8 = fmul float %6, %7
%9 = fpext float %8 to double
%10 = fsub double %9, 7.000000e+00
%11 = fmul double %5, %10
%12 = load float, float* %2
%13 = call double @sin(float %12)
%14 = load float, float* %2
%15 = call double @pow(float %14, double 4.000000e+00)
%16 = load float, float* %2
%17 = fpext float %16 to double
%18 = fmul double 1.400000e+01, %17
%19 = load float, float* %2
%20 = fpext float %19 to double
%21 = fneg double %18
%22 = call double @llvm.fmuladd.f64(double %21, double %20, double %15)
%23 = fadd double %22, 2.800000e+01
%24 = load float, float* %2
%25 = call double @cos(float %24)
%26 = fmul double %23, %25
%27 = fneg double %26
%28 = call double @llvm.fmuladd.f64(double %11, double %13, double %27)
%29 = fptrunc double %28 to float
ret float %29
}

LLVM IR (-O2):
define float @fint(float %0) {
%2 = fpext float %0 to double
%3 = fmul double %2, 4.000000e+00
%4 = fmul float %0, %0
%5 = fpext float %4 to double
%6 = fadd double %5, -7.000000e+00
%7 = fmul double %3, %6
%8 = tail call double @sin(float %0)
%9 = tail call double @pow(float %0, double 4.000000e+00)
%10 = fmul double %2, -1.400000e+01
%11 = tail call double @llvm.fmuladd.f64(double %10, double %2, double %9)
%12 = fadd double %11, 2.800000e+01
%13 = tail call double @cos(float %0)
%14 = fneg double %12
%15 = fmul double %13, %14
%16 = tail call double @llvm.fmuladd.f64(double %7, double %8, double %15)
%17 = fptrunc double %16 to float
ret float %17
}