#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*/ f1(float *, int);
int /*<<< orphan*/ printf(char *, float);
int main() {
  float niz[10] = {1734.4371, 172.432, 172.213};
  f1(niz, 10);
  int i;
  for (i = 0; i < 10; i++)
    printf("%.3f ", niz[i]);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x30(%rbp),%rdi
xor    %esi,%esi
mov    $0x28,%edx
call   1040 <memset@plt>
movss  0xeb1(%rip),%xmm0
movss  %xmm0,-0x30(%rbp)
movss  0xea0(%rip),%xmm0
movss  %xmm0,-0x2c(%rbp)
movss  0xe8f(%rip),%xmm0
movss  %xmm0,-0x28(%rbp)
lea    -0x30(%rbp),%rdi
mov    $0xa,%esi
call   1050 <f1@plt>
movl   $0x0,-0x34(%rbp)
cmpl   $0xa,-0x34(%rbp)
jge    11b9 <main+0x89>
movslq -0x34(%rbp),%rax
movss  -0x30(%rbp,%rax,4),%xmm0
lea    0xe66(%rip),%rdi
call   1030 <printf@plt>
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    118b <main+0x5b>
xor    %eax,%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x30,%rsp
xorps  %xmm0,%xmm0
movaps %xmm0,(%rsp)
movaps %xmm0,0x10(%rsp)
movq   $0x0,0x20(%rsp)
movabs $0x432c6e9844d8cdfd,%rax
6e 2c 43
mov    %rax,(%rsp)
movl   $0x432c3687,0x8(%rsp)
43
mov    %rsp,%rdi
mov    $0xa,%esi
call   1040 <f1@plt>
movss  (%rsp),%xmm0
lea    0xe97(%rip),%rbx
mov    %rbx,%rdi
call   1030 <printf@plt>
movss  0x4(%rsp),%xmm0
mov    %rbx,%rdi
call   1030 <printf@plt>
movss  0x8(%rsp),%xmm0
mov    %rbx,%rdi
call   1030 <printf@plt>
movss  0xc(%rsp),%xmm0
mov    %rbx,%rdi
call   1030 <printf@plt>
movss  0x10(%rsp),%xmm0
mov    %rbx,%rdi
call   1030 <printf@plt>
movss  0x14(%rsp),%xmm0
mov    %rbx,%rdi
call   1030 <printf@plt>
movss  0x18(%rsp),%xmm0
mov    %rbx,%rdi
call   1030 <printf@plt>
movss  0x1c(%rsp),%xmm0
mov    %rbx,%rdi
call   1030 <printf@plt>
movss  0x20(%rsp),%xmm0
mov    %rbx,%rdi
call   1030 <printf@plt>
movss  0x24(%rsp),%xmm0
mov    %rbx,%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [6 x i8] c"%.3f \00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [10 x float]
%3 = alloca i32
store i32 0, i32* %1
%4 = bitcast [10 x float]* %2 to i8*
%5 = bitcast i8* %4 to [10 x float]*
%6 = getelementptr inbounds [10 x float], [10 x float]* %5, i32 0, i32 0
store float 0x409B19BFA0000000, float* %6
%7 = getelementptr inbounds [10 x float], [10 x float]* %5, i32 0, i32 1
store float 0x40658DD300000000, float* %7
%8 = getelementptr inbounds [10 x float], [10 x float]* %5, i32 0, i32 2
store float 0x406586D0E0000000, float* %8
%9 = getelementptr inbounds [10 x float], [10 x float]* %2, i64 0, i64 0
%10 = call i32 @f1(float* %9, i32 10)
store i32 0, i32* %3
br label %11
11: ; preds = %20, %0
%12 = load i32, i32* %3
%13 = icmp slt i32 %12, 10
br i1 %13, label %14, label %23
14: ; preds = %11
%15 = load i32, i32* %3
%16 = sext i32 %15 to i64
%17 = getelementptr inbounds [10 x float], [10 x float]* %2, i64 0, i64 %16
%18 = load float, float* %17
%19 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %18)
br label %20
20: ; preds = %14
%21 = load i32, i32* %3
%22 = add nsw i32 %21, 1
store i32 %22, i32* %3
br label %11
23: ; preds = %11
ret i32 0
}

LLVM IR (-O2):
@.str = [6 x i8] c"%.3f \00"
define i32 @main() {
%1 = alloca [10 x float]
%2 = bitcast [10 x float]* %1 to i8*
%3 = getelementptr inbounds [10 x float], [10 x float]* %1, i64 0, i64 0
store float 0x409B19BFA0000000, float* %3
%4 = getelementptr inbounds [10 x float], [10 x float]* %1, i64 0, i64 1
store float 0x40658DD300000000, float* %4
%5 = getelementptr inbounds [10 x float], [10 x float]* %1, i64 0, i64 2
store float 0x406586D0E0000000, float* %5
%6 = call i32 @f1(float* %3, i32 10)
%7 = load float, float* %3
%8 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %7)
%9 = load float, float* %4
%10 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %9)
%11 = load float, float* %5
%12 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %11)
%13 = getelementptr inbounds [10 x float], [10 x float]* %1, i64 0, i64 3
%14 = load float, float* %13
%15 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %14)
%16 = getelementptr inbounds [10 x float], [10 x float]* %1, i64 0, i64 4
%17 = load float, float* %16
%18 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %17)
%19 = getelementptr inbounds [10 x float], [10 x float]* %1, i64 0, i64 5
%20 = load float, float* %19
%21 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %20)
%22 = getelementptr inbounds [10 x float], [10 x float]* %1, i64 0, i64 6
%23 = load float, float* %22
%24 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %23)
%25 = getelementptr inbounds [10 x float], [10 x float]* %1, i64 0, i64 7
%26 = load float, float* %25
%27 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %26)
%28 = getelementptr inbounds [10 x float], [10 x float]* %1, i64 0, i64 8
%29 = load float, float* %28
%30 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %29)
%31 = getelementptr inbounds [10 x float], [10 x float]* %1, i64 0, i64 9
%32 = load float, float* %31
%33 = call i32 @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), float %32)
ret i32 0
}