#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*/ bar(float *, float *, float *);
int main1(float *__restrict__ pa, float *__restrict__ pb,
          float *__restrict__ pc) {
  int i;
  for (i = 0; i < 256; i++) {
    pa[i] = pb[i] * pc[i];
  }
  bar(pa, pb, pc);
  return 0;
}


x86 assembly (clang, -O0):
<main1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
movl   $0x0,-0x1c(%rbp)
cmpl   $0x100,-0x1c(%rbp)
jge    116d <main1+0x5d>
mov    -0x10(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movss  (%rax,%rcx,4),%xmm0
mov    -0x18(%rbp),%rax
movslq -0x1c(%rbp),%rcx
mulss  (%rax,%rcx,4),%xmm0
mov    -0x8(%rbp),%rax
movslq -0x1c(%rbp),%rcx
movss  %xmm0,(%rax,%rcx,4)
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    112b <main1+0x1b>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
mov    -0x18(%rbp),%rdx
call   1030 <bar@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main1>:
push   %rax
mov    $0xc,%eax
cs nopw 0x0(%rax,%rax,1)
movups -0x30(%rsi,%rax,4),%xmm0
movups -0x20(%rsi,%rax,4),%xmm1
movups -0x30(%rdx,%rax,4),%xmm2
mulps  %xmm0,%xmm2
movups -0x20(%rdx,%rax,4),%xmm0
mulps  %xmm1,%xmm0
movups %xmm2,-0x30(%rdi,%rax,4)
movups %xmm0,-0x20(%rdi,%rax,4)
movups -0x10(%rsi,%rax,4),%xmm0
movups (%rsi,%rax,4),%xmm1
movups -0x10(%rdx,%rax,4),%xmm2
mulps  %xmm0,%xmm2
movups (%rdx,%rax,4),%xmm0
mulps  %xmm1,%xmm0
movups %xmm2,-0x10(%rdi,%rax,4)
movups %xmm0,(%rdi,%rax,4)
add    $0x10,%rax
cmp    $0x10c,%rax
jne    1120 <main1+0x10>
call   1030 <bar@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main1(float* noalias %0, float* noalias %1, float* noalias %2) {
%4 = alloca float*
%5 = alloca float*
%6 = alloca float*
%7 = alloca i32
store float* %0, float** %4
store float* %1, float** %5
store float* %2, float** %6
store i32 0, i32* %7
br label %8
8: ; preds = %27, %3
%9 = load i32, i32* %7
%10 = icmp slt i32 %9, 256
br i1 %10, label %11, label %30
11: ; preds = %8
%12 = load float*, float** %5
%13 = load i32, i32* %7
%14 = sext i32 %13 to i64
%15 = getelementptr inbounds float, float* %12, i64 %14
%16 = load float, float* %15
%17 = load float*, float** %6
%18 = load i32, i32* %7
%19 = sext i32 %18 to i64
%20 = getelementptr inbounds float, float* %17, i64 %19
%21 = load float, float* %20
%22 = fmul float %16, %21
%23 = load float*, float** %4
%24 = load i32, i32* %7
%25 = sext i32 %24 to i64
%26 = getelementptr inbounds float, float* %23, i64 %25
store float %22, float* %26
br label %27
27: ; preds = %11
%28 = load i32, i32* %7
%29 = add nsw i32 %28, 1
store i32 %29, i32* %7
br label %8
30: ; preds = %8
%31 = load float*, float** %4
%32 = load float*, float** %5
%33 = load float*, float** %6
%34 = call i32 @bar(float* %31, float* %32, float* %33)
ret i32 0
}

LLVM IR (-O2):
define i32 @main1(float* noalias %0, float* noalias %1, float* noalias %2) {
br label %4
4: ; preds = %4, %3
%5 = phi i64 [ 0, %3 ], [ %43, %4 ]
%6 = getelementptr inbounds float, float* %1, i64 %5
%7 = bitcast float* %6 to <4 x float>*
%8 = load <4 x float>, <4 x float>* %7
%9 = getelementptr inbounds float, float* %6, i64 4
%10 = bitcast float* %9 to <4 x float>*
%11 = load <4 x float>, <4 x float>* %10
%12 = getelementptr inbounds float, float* %2, i64 %5
%13 = bitcast float* %12 to <4 x float>*
%14 = load <4 x float>, <4 x float>* %13
%15 = getelementptr inbounds float, float* %12, i64 4
%16 = bitcast float* %15 to <4 x float>*
%17 = load <4 x float>, <4 x float>* %16
%18 = fmul <4 x float> %8, %14
%19 = fmul <4 x float> %11, %17
%20 = getelementptr inbounds float, float* %0, i64 %5
%21 = bitcast float* %20 to <4 x float>*
store <4 x float> %18, <4 x float>* %21
%22 = getelementptr inbounds float, float* %20, i64 4
%23 = bitcast float* %22 to <4 x float>*
store <4 x float> %19, <4 x float>* %23
%24 = or i64 %5, 8
%25 = getelementptr inbounds float, float* %1, i64 %24
%26 = bitcast float* %25 to <4 x float>*
%27 = load <4 x float>, <4 x float>* %26
%28 = getelementptr inbounds float, float* %25, i64 4
%29 = bitcast float* %28 to <4 x float>*
%30 = load <4 x float>, <4 x float>* %29
%31 = getelementptr inbounds float, float* %2, i64 %24
%32 = bitcast float* %31 to <4 x float>*
%33 = load <4 x float>, <4 x float>* %32
%34 = getelementptr inbounds float, float* %31, i64 4
%35 = bitcast float* %34 to <4 x float>*
%36 = load <4 x float>, <4 x float>* %35
%37 = fmul <4 x float> %27, %33
%38 = fmul <4 x float> %30, %36
%39 = getelementptr inbounds float, float* %0, i64 %24
%40 = bitcast float* %39 to <4 x float>*
store <4 x float> %37, <4 x float>* %40
%41 = getelementptr inbounds float, float* %39, i64 4
%42 = bitcast float* %41 to <4 x float>*
store <4 x float> %38, <4 x float>* %42
%43 = add nuw nsw i64 %5, 16
%44 = icmp eq i64 %43, 256
br i1 %44, label %45, label %4
45: ; preds = %4
%46 = tail call i32 @bar(float* %0, float* %1, float* %2)
ret i32 0
}