#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);
int pow(float, double);
int sqrt(float);
float r1(float t, float Tr) {
  float p1;
  p1 = (3.14159265358979323846 * (4 * t - Tr) * Tr +
        8 * pow(t, 1.5) * sqrt(-t + Tr) + 4 * Tr * sqrt(t * (-t + Tr)) -
        2 * (4 * t - Tr) * Tr *
            atan((-2 * t + Tr) / (2. * sqrt(t * (-t + Tr))))) /
       16.;
  return p1;
}


x86 assembly (clang, -O0):
<r1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
movss  %xmm0,-0x4(%rbp)
movss  %xmm1,-0x8(%rbp)
movss  -0x4(%rbp),%xmm0
movss  -0x8(%rbp),%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
movss  0xec3(%rip),%xmm2
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xea3(%rip),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x48(%rbp)
movss  -0x8(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,-0x40(%rbp)
movss  -0x4(%rbp),%xmm0
movsd  0xe77(%rip),%xmm1
call   1040 <pow@plt>
shl    $0x3,%eax
mov    %eax,-0x38(%rbp)
movss  -0x4(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
addss  -0x8(%rbp),%xmm0
call   1050 <sqrt@plt>
movsd  -0x48(%rbp),%xmm0
movsd  -0x40(%rbp),%xmm2
mov    %eax,%ecx
mov    -0x38(%rbp),%eax
imul   %ecx,%eax
cvtsi2sd %eax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x30(%rbp)
movss  0xe39(%rip),%xmm0
mulss  -0x8(%rbp),%xmm0
movss  %xmm0,-0x34(%rbp)
movss  -0x4(%rbp),%xmm0
movss  -0x4(%rbp),%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
addss  -0x8(%rbp),%xmm1
mulss  %xmm1,%xmm0
call   1050 <sqrt@plt>
movss  -0x34(%rbp),%xmm1
movsd  -0x30(%rbp),%xmm0
cvtsi2ss %eax,%xmm2
mulss  %xmm2,%xmm1
cvtss2sd %xmm1,%xmm1
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x18(%rbp)
movss  -0x4(%rbp),%xmm1
movss  -0x8(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
movss  0xdcc(%rip),%xmm2
mulss  %xmm2,%xmm1
addss  %xmm0,%xmm1
movss  0xdb8(%rip),%xmm0
mulss  %xmm1,%xmm0
mulss  -0x8(%rbp),%xmm0
movss  %xmm0,-0x1c(%rbp)
movss  -0x4(%rbp),%xmm1
movss  -0x8(%rbp),%xmm0
addss  %xmm1,%xmm1
subss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
movsd  %xmm0,-0x28(%rbp)
movss  -0x4(%rbp),%xmm0
movss  -0x4(%rbp),%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
addss  -0x8(%rbp),%xmm1
mulss  %xmm1,%xmm0
call   1050 <sqrt@plt>
movsd  -0x28(%rbp),%xmm0
cvtsi2sd %eax,%xmm2
movsd  0xd41(%rip),%xmm1
mulsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
cvttsd2si %xmm0,%edi
call   1030 <atan@plt>
movss  -0x1c(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm0
cvtsi2ss %eax,%xmm2
mulss  %xmm2,%xmm1
cvtss2sd %xmm1,%xmm1
subsd  %xmm1,%xmm0
movsd  0xd06(%rip),%xmm1
divsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0xc(%rbp)
movss  -0xc(%rbp),%xmm0
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<r1>:
push   %rbx
sub    $0x30,%rsp
movss  %xmm1,0x20(%rsp)
movss  0xebd(%rip),%xmm3
movss  %xmm3,0x18(%rsp)
movaps %xmm0,%xmm2
movss  %xmm0,0x10(%rsp)
mulss  %xmm3,%xmm2
subss  %xmm1,%xmm2
movss  %xmm2,0x14(%rsp)
xorps  %xmm3,%xmm3
cvtss2sd %xmm2,%xmm3
mulsd  0xe99(%rip),%xmm3
cvtss2sd %xmm1,%xmm1
mulsd  %xmm3,%xmm1
movsd  %xmm1,0x28(%rsp)
movsd  0xe8b(%rip),%xmm1
call   1040 <pow@plt>
mov    %eax,%ebx
movss  0x20(%rsp),%xmm0
subss  0x10(%rsp),%xmm0
movss  %xmm0,0xc(%rsp)
call   1050 <sqrt@plt>
imul   %ebx,%eax
shl    $0x3,%eax
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
addsd  0x28(%rsp),%xmm0
movsd  %xmm0,0x28(%rsp)
movss  0x18(%rsp),%xmm0
mulss  0x20(%rsp),%xmm0
movss  %xmm0,0x18(%rsp)
movss  0xc(%rsp),%xmm0
mulss  0x10(%rsp),%xmm0
movss  %xmm0,0xc(%rsp)
call   1050 <sqrt@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
mulss  0x18(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
addsd  0x28(%rsp),%xmm0
movsd  %xmm0,0x18(%rsp)
movss  0x14(%rsp),%xmm0
addss  %xmm0,%xmm0
movss  0x20(%rsp),%xmm1
mulss  %xmm1,%xmm0
movss  %xmm0,0x14(%rsp)
movss  0x10(%rsp),%xmm0
addss  %xmm0,%xmm0
subss  %xmm0,%xmm1
xorps  %xmm0,%xmm0
cvtss2sd %xmm1,%xmm0
movsd  %xmm0,0x20(%rsp)
movss  0xc(%rsp),%xmm0
call   1050 <sqrt@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
addsd  %xmm0,%xmm0
movsd  0x20(%rsp),%xmm1
divsd  %xmm0,%xmm1
cvttsd2si %xmm1,%edi
call   1030 <atan@plt>
xorps  %xmm0,%xmm0
cvtsi2ss %eax,%xmm0
mulss  0x14(%rsp),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0x18(%rsp),%xmm1
subsd  %xmm0,%xmm1
mulsd  0xd95(%rip),%xmm1
xorps  %xmm0,%xmm0
cvtsd2ss %xmm1,%xmm0
add    $0x30,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define float @r1(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 = load float, float* %4
%8 = fneg float %7
%9 = call float @llvm.fmuladd.f32(float 4.000000e+00, float %6, float %8)
%10 = fpext float %9 to double
%11 = fmul double 0x400921FB54442D18, %10
%12 = load float, float* %4
%13 = fpext float %12 to double
%14 = load float, float* %3
%15 = call i32 @pow(float %14, double 1.500000e+00)
%16 = mul nsw i32 8, %15
%17 = load float, float* %3
%18 = fneg float %17
%19 = load float, float* %4
%20 = fadd float %18, %19
%21 = call i32 @sqrt(float %20)
%22 = mul nsw i32 %16, %21
%23 = sitofp i32 %22 to double
%24 = call double @llvm.fmuladd.f64(double %11, double %13, double %23)
%25 = load float, float* %4
%26 = fmul float 4.000000e+00, %25
%27 = load float, float* %3
%28 = load float, float* %3
%29 = fneg float %28
%30 = load float, float* %4
%31 = fadd float %29, %30
%32 = fmul float %27, %31
%33 = call i32 @sqrt(float %32)
%34 = sitofp i32 %33 to float
%35 = fmul float %26, %34
%36 = fpext float %35 to double
%37 = fadd double %24, %36
%38 = load float, float* %3
%39 = load float, float* %4
%40 = fneg float %39
%41 = call float @llvm.fmuladd.f32(float 4.000000e+00, float %38, float %40)
%42 = fmul float 2.000000e+00, %41
%43 = load float, float* %4
%44 = fmul float %42, %43
%45 = load float, float* %3
%46 = load float, float* %4
%47 = call float @llvm.fmuladd.f32(float -2.000000e+00, float %45, float %46)
%48 = fpext float %47 to double
%49 = load float, float* %3
%50 = load float, float* %3
%51 = fneg float %50
%52 = load float, float* %4
%53 = fadd float %51, %52
%54 = fmul float %49, %53
%55 = call i32 @sqrt(float %54)
%56 = sitofp i32 %55 to double
%57 = fmul double 2.000000e+00, %56
%58 = fdiv double %48, %57
%59 = fptosi double %58 to i32
%60 = call i32 @atan(i32 %59)
%61 = sitofp i32 %60 to float
%62 = fmul float %44, %61
%63 = fpext float %62 to double
%64 = fsub double %37, %63
%65 = fdiv double %64, 1.600000e+01
%66 = fptrunc double %65 to float
store float %66, float* %5
%67 = load float, float* %5
ret float %67
}

LLVM IR (-O2):
define float @r1(float %0, float %1) {
%3 = fneg float %1
%4 = tail call float @llvm.fmuladd.f32(float %0, float 4.000000e+00, float %3)
%5 = fpext float %4 to double
%6 = fmul double %5, 0x400921FB54442D18
%7 = fpext float %1 to double
%8 = tail call i32 @pow(float %0, double 1.500000e+00)
%9 = shl nsw i32 %8, 3
%10 = fsub float %1, %0
%11 = tail call i32 @sqrt(float %10)
%12 = mul nsw i32 %9, %11
%13 = sitofp i32 %12 to double
%14 = tail call double @llvm.fmuladd.f64(double %6, double %7, double %13)
%15 = fmul float %1, 4.000000e+00
%16 = fmul float %10, %0
%17 = tail call i32 @sqrt(float %16)
%18 = sitofp i32 %17 to float
%19 = fmul float %15, %18
%20 = fpext float %19 to double
%21 = fadd double %14, %20
%22 = fmul float %4, 2.000000e+00
%23 = fmul float %22, %1
%24 = tail call float @llvm.fmuladd.f32(float %0, float -2.000000e+00, float %1)
%25 = fpext float %24 to double
%26 = tail call i32 @sqrt(float %16)
%27 = sitofp i32 %26 to double
%28 = fmul double %27, 2.000000e+00
%29 = fdiv double %25, %28
%30 = fptosi double %29 to i32
%31 = tail call i32 @atan(i32 %30)
%32 = sitofp i32 %31 to float
%33 = fmul float %23, %32
%34 = fpext float %33 to double
%35 = fsub double %21, %34
%36 = fmul double %35, 6.250000e-02
%37 = fptrunc double %36 to float
ret float %37
}