#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*/ abort();
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ f(int *, float *, float *, int);
main() {
  int r[4];
  float a[] = {5, 1, 3, 5};
  float b[] = {2, 4, 3, 0};
  int i;
  f(r, a, b, 4);
  for (i = 0; i < 4; i++)
    if ((a[i] == b[i]) != r[i])
      abort();
  exit(0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
movl   $0x0,-0x4(%rbp)
mov    0xeba(%rip),%rax
mov    %rax,-0x30(%rbp)
mov    0xeb7(%rip),%rax
mov    %rax,-0x28(%rbp)
mov    0xeb4(%rip),%rax
mov    %rax,-0x40(%rbp)
mov    0xeb1(%rip),%rax
mov    %rax,-0x38(%rbp)
lea    -0x20(%rbp),%rdi
lea    -0x30(%rbp),%rsi
lea    -0x40(%rbp),%rdx
mov    $0x4,%ecx
call   1040 <f@plt>
movl   $0x0,-0x44(%rbp)
cmpl   $0x4,-0x44(%rbp)
jge    11da <main+0xaa>
movslq -0x44(%rbp),%rax
movss  -0x30(%rbp,%rax,4),%xmm0
movslq -0x44(%rbp),%rax
ucomiss -0x40(%rbp,%rax,4),%xmm0
sete   %al
setnp  %cl
and    %cl,%al
and    $0x1,%al
movzbl %al,%eax
movslq -0x44(%rbp),%rcx
cmp    -0x20(%rbp,%rcx,4),%eax
je     11c7 <main+0x97>
mov    $0x0,%al
call   1030 <abort@plt>
jmp    11cc <main+0x9c>
mov    -0x44(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x44(%rbp)
jmp    1188 <main+0x58>
xor    %edi,%edi
call   1050 <exit@plt>

x86 assembly (clang, -O2):
<main>:
sub    $0x38,%rsp
movaps 0xec5(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
movaps 0xec9(%rip),%xmm0
movaps %xmm0,(%rsp)
lea    0x20(%rsp),%rdi
lea    0x10(%rsp),%rsi
mov    %rsp,%rdx
mov    $0x4,%ecx
call   1040 <f@plt>
movss  (%rsp),%xmm0
cmpeqss 0x10(%rsp),%xmm0
movd   %xmm0,%eax
and    $0x1,%eax
cmp    %eax,0x20(%rsp)
jne    11d0 <main+0xa0>
movss  0x4(%rsp),%xmm0
cmpeqss 0x14(%rsp),%xmm0
movd   %xmm0,%eax
and    $0x1,%eax
cmp    %eax,0x24(%rsp)
jne    11d0 <main+0xa0>
movss  0x8(%rsp),%xmm0
cmpeqss 0x18(%rsp),%xmm0
movd   %xmm0,%eax
and    $0x1,%eax
cmp    %eax,0x28(%rsp)
jne    11d0 <main+0xa0>
movss  0xc(%rsp),%xmm0
cmpeqss 0x1c(%rsp),%xmm0
movd   %xmm0,%eax
and    $0x1,%eax
cmp    %eax,0x2c(%rsp)
jne    11d0 <main+0xa0>
xor    %edi,%edi
call   1050 <exit@plt>
xor    %eax,%eax
call   1030 <abort@plt>

LLVM IR (-O0):
@__const.main.a = [4 x float] [float 5.000000e+00, float 1.000000e+00, float 3.000000e+00, float 5.000000e+00]
@__const.main.b = [4 x float] [float 2.000000e+00, float 4.000000e+00, float 3.000000e+00, float 0.000000e+00]
define i32 @main() {
%1 = alloca i32
%2 = alloca [4 x i32]
%3 = alloca [4 x float]
%4 = alloca [4 x float]
%5 = alloca i32
store i32 0, i32* %1
%6 = bitcast [4 x float]* %3 to i8*
%7 = bitcast [4 x float]* %4 to i8*
%8 = getelementptr inbounds [4 x i32], [4 x i32]* %2, i64 0, i64 0
%9 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%10 = getelementptr inbounds [4 x float], [4 x float]* %4, i64 0, i64 0
%11 = call i32 @f(i32* %8, float* %9, float* %10, i32 4)
store i32 0, i32* %5
br label %12
12: ; preds = %34, %0
%13 = load i32, i32* %5
%14 = icmp slt i32 %13, 4
br i1 %14, label %15, label %37
15: ; preds = %12
%16 = load i32, i32* %5
%17 = sext i32 %16 to i64
%18 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 %17
%19 = load float, float* %18
%20 = load i32, i32* %5
%21 = sext i32 %20 to i64
%22 = getelementptr inbounds [4 x float], [4 x float]* %4, i64 0, i64 %21
%23 = load float, float* %22
%24 = fcmp oeq float %19, %23
%25 = zext i1 %24 to i32
%26 = load i32, i32* %5
%27 = sext i32 %26 to i64
%28 = getelementptr inbounds [4 x i32], [4 x i32]* %2, i64 0, i64 %27
%29 = load i32, i32* %28
%30 = icmp ne i32 %25, %29
br i1 %30, label %31, label %33
31: ; preds = %15
%32 = call i32 (...) @abort()
unreachable
33: ; preds = %15
br label %34
34: ; preds = %33
%35 = load i32, i32* %5
%36 = add nsw i32 %35, 1
store i32 %36, i32* %5
br label %12
37: ; preds = %12
%38 = call i32 @exit(i32 0)
unreachable
}

LLVM IR (-O2):
@__const.main.a = [4 x float] [float 5.000000e+00, float 1.000000e+00, float 3.000000e+00, float 5.000000e+00]
@__const.main.b = [4 x float] [float 2.000000e+00, float 4.000000e+00, float 3.000000e+00, float 0.000000e+00]
define i32 @main() {
%1 = alloca [4 x i32]
%2 = alloca [4 x float]
%3 = alloca [4 x float]
%4 = bitcast [4 x i32]* %1 to i8*
%5 = bitcast [4 x float]* %2 to i8*
%6 = bitcast [4 x float]* %3 to i8*
%7 = getelementptr inbounds [4 x i32], [4 x i32]* %1, i64 0, i64 0
%8 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 0
%9 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%10 = call i32 @f(i32* %7, float* %8, float* %9, i32 4)
%11 = load float, float* %8
%12 = load float, float* %9
%13 = fcmp oeq float %11, %12
%14 = zext i1 %13 to i32
%15 = load i32, i32* %7
%16 = icmp eq i32 %15, %14
br i1 %16, label %17, label %49
17: ; preds = %0
%18 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 1
%19 = load float, float* %18
%20 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 1
%21 = load float, float* %20
%22 = fcmp oeq float %19, %21
%23 = zext i1 %22 to i32
%24 = getelementptr inbounds [4 x i32], [4 x i32]* %1, i64 0, i64 1
%25 = load i32, i32* %24
%26 = icmp eq i32 %25, %23
br i1 %26, label %27, label %49
27: ; preds = %17
%28 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 2
%29 = load float, float* %28
%30 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 2
%31 = load float, float* %30
%32 = fcmp oeq float %29, %31
%33 = zext i1 %32 to i32
%34 = getelementptr inbounds [4 x i32], [4 x i32]* %1, i64 0, i64 2
%35 = load i32, i32* %34
%36 = icmp eq i32 %35, %33
br i1 %36, label %37, label %49
37: ; preds = %27
%38 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 3
%39 = load float, float* %38
%40 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 3
%41 = load float, float* %40
%42 = fcmp oeq float %39, %41
%43 = zext i1 %42 to i32
%44 = getelementptr inbounds [4 x i32], [4 x i32]* %1, i64 0, i64 3
%45 = load i32, i32* %44
%46 = icmp eq i32 %45, %43
br i1 %46, label %47, label %49
47: ; preds = %37
%48 = call i32 @exit(i32 0)
unreachable
49: ; preds = %37, %27, %17, %0
%50 = call i32 (...) @abort()
unreachable
}