#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 *, float, float, float, float);
int /*<<< orphan*/ scanf(char *, float *);
void main() {
  float r, l, s, v;
  scanf("%f", &r);
  ;
  l = 2 * 3.1415926 * r;
  s = 3.1415926 * r * r;
  v = 4.0 / 3.0 * 3.1415926 * r * r * r;
  printf("r = %6.2f,l=%6.2f,s=%6.2f,v=%6.2f\n", r, l, s, v);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
lea    0xee9(%rip),%rdi
lea    -0x4(%rbp),%rsi
call   1040 <scanf@plt>
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xec7(%rip),%xmm0
mulsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x8(%rbp)
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xea1(%rip),%xmm0
mulsd  %xmm1,%xmm0
movss  -0x4(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
mulsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0xc(%rbp)
movss  -0x4(%rbp),%xmm0
cvtss2sd %xmm0,%xmm1
movsd  0xe6e(%rip),%xmm0
mulsd  %xmm1,%xmm0
movss  -0x4(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
mulsd  %xmm1,%xmm0
movss  -0x4(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
mulsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x10(%rbp)
movss  -0x4(%rbp),%xmm0
movss  -0x8(%rbp),%xmm1
movss  -0xc(%rbp),%xmm2
movss  -0x10(%rbp),%xmm3
lea    0xe47(%rip),%rdi
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xef0(%rip),%rdi
lea    0x4(%rsp),%rsi
call   1040 <scanf@plt>
movss  0x4(%rsp),%xmm0
cvtss2sd %xmm0,%xmm3
movsd  0xebc(%rip),%xmm1
mulsd  %xmm3,%xmm1
cvtsd2ss %xmm1,%xmm1
movsd  0xeb4(%rip),%xmm2
mulsd  %xmm3,%xmm2
mulsd  %xmm3,%xmm2
cvtsd2ss %xmm2,%xmm2
movsd  0xea8(%rip),%xmm4
mulsd  %xmm3,%xmm4
mulsd  %xmm3,%xmm4
mulsd  %xmm3,%xmm4
xorps  %xmm3,%xmm3
cvtsd2ss %xmm4,%xmm3
lea    0xe99(%rip),%rdi
call   1030 <printf@plt>
pop    %rax
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%f\00"
@.str.1 = [35 x i8] c"r = %6.2f,l=%6.2f,s=%6.2f,v=%6.2f\0A\00"
define void @main() {
%1 = alloca float
%2 = alloca float
%3 = alloca float
%4 = alloca float
%5 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), float* %1)
%6 = load float, float* %1
%7 = fpext float %6 to double
%8 = fmul double 0x401921FB4D12D84A, %7
%9 = fptrunc double %8 to float
store float %9, float* %2
%10 = load float, float* %1
%11 = fpext float %10 to double
%12 = fmul double 0x400921FB4D12D84A, %11
%13 = load float, float* %1
%14 = fpext float %13 to double
%15 = fmul double %12, %14
%16 = fptrunc double %15 to float
store float %16, float* %3
%17 = load float, float* %1
%18 = fpext float %17 to double
%19 = fmul double 0x4010C1523361E586, %18
%20 = load float, float* %1
%21 = fpext float %20 to double
%22 = fmul double %19, %21
%23 = load float, float* %1
%24 = fpext float %23 to double
%25 = fmul double %22, %24
%26 = fptrunc double %25 to float
store float %26, float* %4
%27 = load float, float* %1
%28 = load float, float* %2
%29 = load float, float* %3
%30 = load float, float* %4
%31 = call i32 @printf(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.1, i64 0, i64 0), float %27, float %28, float %29, float %30)
ret void
}

LLVM IR (-O2):
@.str = [3 x i8] c"%f\00"
@.str.1 = [35 x i8] c"r = %6.2f,l=%6.2f,s=%6.2f,v=%6.2f\0A\00"
define void @main() {
%1 = alloca float
%2 = bitcast float* %1 to i8*
%3 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), float* %1)
%4 = load float, float* %1
%5 = fpext float %4 to double
%6 = fmul double %5, 0x401921FB4D12D84A
%7 = fptrunc double %6 to float
%8 = fmul double %5, 0x400921FB4D12D84A
%9 = fmul double %8, %5
%10 = fptrunc double %9 to float
%11 = fmul double %5, 0x4010C1523361E586
%12 = fmul double %11, %5
%13 = fmul double %12, %5
%14 = fptrunc double %13 to float
%15 = call i32 @printf(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.1, i64 0, i64 0), float %4, float %7, float %10, float %14)
ret void
}