int main(int argc, char **argv) {
  int i, v[10];
  int *j, k[10];
  double y, x, s = 0;
  scanf("%lf", &x);
  y = f(x);
  printf("%lf \n", y);
  printf("%d %p \n", v[0], v);
  j = 10;
  j = k;
  k[0] = 150;
  k[1] = 100;
  printf("%d %p %d %p %p\n", *j, j, *(j + 1), j + 1, &k[1]);
  struct vect {
    double x, y, z;
  } * g, p;
  g = &p;
  p.x = x;
  printf("%lf %lf %lf \n", p.x, g[0], g->x);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0xc0,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
lea    0xea5(%rip),%rdi
lea    -0x80(%rbp),%rsi
mov    $0x0,%al
call   1050 <scanf@plt>
movsd  -0x80(%rbp),%xmm0
mov    $0x1,%al
call   1030 <f@plt>
cvtsi2sd %eax,%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x78(%rbp),%xmm0
lea    0xe9d(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
mov    -0x40(%rbp),%esi
lea    -0x40(%rbp),%rdx
lea    0xe68(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    $0xa,%eax
mov    %rax,-0x48(%rbp)
lea    -0x70(%rbp),%rax
mov    %rax,-0x48(%rbp)
movl   $0x96,-0x70(%rbp)
movl   $0x64,-0x6c(%rbp)
mov    -0x48(%rbp),%rax
mov    (%rax),%esi
mov    -0x48(%rbp),%rdx
mov    -0x48(%rbp),%rax
mov    0x4(%rax),%ecx
mov    -0x48(%rbp),%r8
add    $0x4,%r8
lea    -0x70(%rbp),%r9
add    $0x4,%r9
lea    0xe22(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
lea    -0xa8(%rbp),%rax
mov    %rax,-0x90(%rbp)
movsd  -0x80(%rbp),%xmm0
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa8(%rbp),%xmm0
ff
mov    -0x90(%rbp),%rax
mov    -0x90(%rbp),%rcx
movsd  (%rcx),%xmm1
lea    0xdef(%rip),%rdi
mov    (%rax),%rcx
mov    %rcx,(%rsp)
mov    0x8(%rax),%rcx
mov    %rcx,0x8(%rsp)
mov    0x10(%rax),%rax
mov    %rax,0x10(%rsp)
mov    $0x2,%al
call   1040 <printf@plt>
xor    %eax,%eax
add    $0xc0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x98,%rsp
lea    0xec2(%rip),%rdi
lea    0x20(%rsp),%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
movsd  0x20(%rsp),%xmm0
mov    $0x1,%al
call   1030 <f@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
lea    0xebf(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
lea    0xe91(%rip),%rdi
lea    0x70(%rsp),%rdx
xor    %eax,%eax
call   1040 <printf@plt>
movabs $0x6400000096,%rax
mov    %rax,0x40(%rsp)
lea    0x44(%rsp),%r8
lea    0xe72(%rip),%rdi
lea    0x40(%rsp),%rdx
mov    $0x96,%esi
mov    $0x64,%ecx
mov    %r8,%r9
xor    %eax,%eax
call   1040 <printf@plt>
movsd  0x20(%rsp),%xmm0
movsd  %xmm0,0x28(%rsp)
mov    0x38(%rsp),%rax
mov    %rax,0x10(%rsp)
movups 0x28(%rsp),%xmm1
movups %xmm1,(%rsp)
lea    0xe43(%rip),%rdi
movaps %xmm0,%xmm1
mov    $0x2,%al
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x98,%rsp
ret

LLVM IR (-O0):
%struct.vect = type { double, double, double }
@.str = [4 x i8] c"%lf\00"
@.str.1 = [6 x i8] c"%lf \0A\00"
@.str.2 = [8 x i8] c"%d %p \0A\00"
@.str.3 = [16 x i8] c"%d %p %d %p %p\0A\00"
@.str.4 = [14 x i8] c"%lf %lf %lf \0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca [10 x i32]
%8 = alloca i32*
%9 = alloca [10 x i32]
%10 = alloca double
%11 = alloca double
%12 = alloca double
%13 = alloca %struct.vect*
%14 = alloca %struct.vect
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store double 0.000000e+00, double* %12
%15 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), double* %11)
%16 = load double, double* %11
%17 = call i32 (double, ...) bitcast (i32 (...)* @f to i32 (double, ...)*)(double %16)
%18 = sitofp i32 %17 to double
store double %18, double* %10
%19 = load double, double* %10
%20 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), double %19)
%21 = getelementptr inbounds [10 x i32], [10 x i32]* %7, i64 0, i64 0
%22 = load i32, i32* %21
%23 = getelementptr inbounds [10 x i32], [10 x i32]* %7, i64 0, i64 0
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.2, i64 0, i64 0), i32 %22, i32* %23)
store i32* inttoptr (i64 10 to i32*), i32** %8
%25 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 0
store i32* %25, i32** %8
%26 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 0
store i32 150, i32* %26
%27 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 1
store i32 100, i32* %27
%28 = load i32*, i32** %8
%29 = load i32, i32* %28
%30 = load i32*, i32** %8
%31 = load i32*, i32** %8
%32 = getelementptr inbounds i32, i32* %31, i64 1
%33 = load i32, i32* %32
%34 = load i32*, i32** %8
%35 = getelementptr inbounds i32, i32* %34, i64 1
%36 = getelementptr inbounds [10 x i32], [10 x i32]* %9, i64 0, i64 1
%37 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.3, i64 0, i64 0), i32 %29, i32* %30, i32 %33, i32* %35, i32* %36)
store %struct.vect* %14, %struct.vect** %13
%38 = load double, double* %11
%39 = getelementptr inbounds %struct.vect, %struct.vect* %14, i32 0, i32 0
store double %38, double* %39
%40 = getelementptr inbounds %struct.vect, %struct.vect* %14, i32 0, i32 0
%41 = load double, double* %40
%42 = load %struct.vect*, %struct.vect** %13
%43 = getelementptr inbounds %struct.vect, %struct.vect* %42, i64 0
%44 = load %struct.vect*, %struct.vect** %13
%45 = getelementptr inbounds %struct.vect, %struct.vect* %44, i32 0, i32 0
%46 = load double, double* %45
%47 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.4, i64 0, i64 0), double %41, %struct.vect* byval(%struct.vect) align 8 %43, double %46)
ret i32 0
}

LLVM IR (-O2):
%struct.vect = type { double, double, double }
@.str = [4 x i8] c"%lf\00"
@.str.1 = [6 x i8] c"%lf \0A\00"
@.str.2 = [8 x i8] c"%d %p \0A\00"
@.str.3 = [16 x i8] c"%d %p %d %p %p\0A\00"
@.str.4 = [14 x i8] c"%lf %lf %lf \0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = alloca [10 x i32]
%4 = alloca [10 x i32]
%5 = alloca double
%6 = alloca %struct.vect
%7 = bitcast [10 x i32]* %3 to i8*
%8 = bitcast [10 x i32]* %4 to i8*
%9 = bitcast double* %5 to i8*
%10 = call i32 (i8*, ...) @scanf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), double* %5)
%11 = load double, double* %5
%12 = call i32 (double, ...) bitcast (i32 (...)* @f to i32 (double, ...)*)(double %11)
%13 = sitofp i32 %12 to double
%14 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.1, i64 0, i64 0), double %13)
%15 = getelementptr inbounds [10 x i32], [10 x i32]* %3, i64 0, i64 0
%16 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([8 x i8], [8 x i8]* @.str.2, i64 0, i64 0), i32 undef, i32* %15)
%17 = getelementptr inbounds [10 x i32], [10 x i32]* %4, i64 0, i64 0
store i32 150, i32* %17
%18 = getelementptr inbounds [10 x i32], [10 x i32]* %4, i64 0, i64 1
store i32 100, i32* %18
%19 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @.str.3, i64 0, i64 0), i32 150, i32* %17, i32 100, i32* %18, i32* %18)
%20 = bitcast %struct.vect* %6 to i8*
%21 = load double, double* %5
%22 = getelementptr inbounds %struct.vect, %struct.vect* %6, i64 0, i32 0
store double %21, double* %22
%23 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([14 x i8], [14 x i8]* @.str.4, i64 0, i64 0), double %21, %struct.vect* byval(%struct.vect) align 8 %6, double %21)
ret i32 0
}