#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 */
typedef struct TYPE_2__ TYPE_1__;

/* Type definitions */
struct TYPE_2__ {
  int tv_sec;
  int tv_usec;
};
struct rusage {
  TYPE_1__ ru_utime;
};

/* Variables and functions */
float RAND_MAX;
int /*<<< orphan*/ RUSAGE_SELF;
int /*<<< orphan*/ cross3_c(float *, float *, float *);
int /*<<< orphan*/ cross3_neon(float *, float *, float *);
int /*<<< orphan*/ getrusage(int /*<<< orphan*/, struct rusage *);
int /*<<< orphan*/ normalize2_c(float *, float *);
int /*<<< orphan*/ normalize2_neon(float *, float *);
int /*<<< orphan*/ normalize3_c(float *, float *);
int /*<<< orphan*/ normalize3_neon(float *, float *);
int /*<<< orphan*/ normalize4_c(float *, float *);
int /*<<< orphan*/ normalize4_neon(float *, float *);
int /*<<< orphan*/ printf(char *, ...);
float rand();
void test_vectorfunc() {
  float v0[4], v1[4], d[4];
  for (int i = 0; i < 4; i++) {
    v0[i] = 10 * (rand() / (RAND_MAX + 1.0f)) - 5;
    v1[i] = 10 * (rand() / (RAND_MAX + 1.0f)) - 5;
    d[i] = 10 * (rand() / (RAND_MAX + 1.0f)) - 5;
  }
  int testnum = 5000000;
  struct rusage ru;
  int v2t[3], v3t[3], v4t[3];
  float r;
  printf("\n");
  getrusage(RUSAGE_SELF, &ru);
  v2t[0] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  for (int i = 0; i < testnum; i++) {
    normalize2_c(v0, d);
  };
  getrusage(RUSAGE_SELF, &ru);
  v2t[1] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  for (int i = 0; i < testnum; i++) {
    normalize2_neon(v0, d);
  };
  getrusage(RUSAGE_SELF, &ru);
  v2t[2] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  normalize2_c(v0, d);
  printf("normalize2_c = [%.2f, %.2f]\n", d[0], d[1]);
  normalize2_neon(v0, d);
  printf("normalize2_neon = [%.2f, %.2f]\n", d[0], d[1]);
  printf("normalize2: c=%i \t neon=%i \t rate=%.2f \n", v2t[1] - v2t[0],
         v2t[2] - v2t[1], (float)(v2t[1] - v2t[0]) / (float)(v2t[2] - v2t[1]));
  printf("\n");
  getrusage(RUSAGE_SELF, &ru);
  v3t[0] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  for (int i = 0; i < testnum; i++) {
    normalize3_c(v0, d);
  };
  getrusage(RUSAGE_SELF, &ru);
  v3t[1] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  for (int i = 0; i < testnum; i++) {
    normalize3_neon(v0, d);
  };
  getrusage(RUSAGE_SELF, &ru);
  v3t[2] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  normalize3_c(v0, d);
  printf("normalize3_c = [%.2f, %.2f, %.2f]\n", d[0], d[1], d[2]);
  normalize3_neon(v0, d);
  printf("normalize3_neon = [%.2f, %.2f, %.2f]\n", d[0], d[1], d[2]);
  printf("normalize3: c=%i \t neon=%i \t rate=%.2f \n", v3t[1] - v3t[0],
         v3t[2] - v3t[1], (float)(v3t[1] - v3t[0]) / (float)(v3t[2] - v3t[1]));
  getrusage(RUSAGE_SELF, &ru);
  v3t[0] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  for (int i = 0; i < testnum; i++) {
    cross3_c(v0, v1, d);
  };
  getrusage(RUSAGE_SELF, &ru);
  v3t[1] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  for (int i = 0; i < testnum; i++) {
    cross3_neon(v0, v1, d);
  };
  getrusage(RUSAGE_SELF, &ru);
  v3t[2] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  cross3_c(v0, v1, d);
  printf("cross3_c = [%.2f, %.2f, %.2f]\n", d[0], d[1], d[2]);
  cross3_neon(v0, v1, d);
  printf("cross3_neon = [%.2f, %.2f, %.2f]\n", d[0], d[1], d[2]);
  printf("cross3: c=%i \t neon=%i \t rate=%.2f \n", v3t[1] - v3t[0],
         v3t[2] - v3t[1], (float)(v3t[1] - v3t[0]) / (float)(v3t[2] - v3t[1]));
  printf("\n");
  getrusage(RUSAGE_SELF, &ru);
  v4t[0] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  for (int i = 0; i < testnum; i++) {
    normalize4_c(v0, d);
  };
  getrusage(RUSAGE_SELF, &ru);
  v4t[1] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  for (int i = 0; i < testnum; i++) {
    normalize4_neon(v0, d);
  };
  getrusage(RUSAGE_SELF, &ru);
  v4t[2] = ru.ru_utime.tv_sec * 1000000 + ru.ru_utime.tv_usec;
  normalize4_c(v0, d);
  printf("normalize4_c = [%.2f, %.2f, %.2f, %.2f]\n", d[0], d[1], d[2], d[3]);
  normalize4_neon(v0, d);
  printf("normalize4_neon = [%.2f, %.2f, %.2f, %.2f]\n", d[0], d[1], d[2],
         d[3]);
  printf("normalize4: c=%i \t neon=%i \t rate=%.2f \n", v4t[1] - v4t[0],
         v4t[2] - v4t[1], (float)(v4t[1] - v4t[0]) / (float)(v4t[2] - v4t[1]));
  printf("\n");
}


x86 assembly (clang, -O0):
<test_vectorfunc>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
movl   $0x0,-0x34(%rbp)
cmpl   $0x4,-0x34(%rbp)
jge    129a <test_vectorfunc+0xea>
mov    $0x0,%al
call   10d0 <rand@plt>
movss  0xe2d(%rip),%xmm1
mov    0x2e06(%rip),%rax
addss  (%rax),%xmm1
divss  %xmm1,%xmm0
movss  0xe0e(%rip),%xmm1
mulss  %xmm1,%xmm0
movss  0xe06(%rip),%xmm1
addss  %xmm1,%xmm0
movslq -0x34(%rbp),%rax
movss  %xmm0,-0x10(%rbp,%rax,4)
mov    $0x0,%al
call   10d0 <rand@plt>
movss  0xded(%rip),%xmm1
mov    0x2dc6(%rip),%rax
addss  (%rax),%xmm1
divss  %xmm1,%xmm0
movss  0xdce(%rip),%xmm1
mulss  %xmm1,%xmm0
movss  0xdc6(%rip),%xmm1
addss  %xmm1,%xmm0
movslq -0x34(%rbp),%rax
movss  %xmm0,-0x20(%rbp,%rax,4)
mov    $0x0,%al
call   10d0 <rand@plt>
movss  0xdad(%rip),%xmm1
mov    0x2d86(%rip),%rax
addss  (%rax),%xmm1
divss  %xmm1,%xmm0
movss  0xd8e(%rip),%xmm1
mulss  %xmm1,%xmm0
movss  0xd86(%rip),%xmm1
addss  %xmm1,%xmm0
movslq -0x34(%rbp),%rax
movss  %xmm0,-0x30(%rbp,%rax,4)
mov    -0x34(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x34(%rbp)
jmp    11c2 <test_vectorfunc+0x12>
movl   $0x4c4b40,-0x38(%rbp)
lea    0xdc8(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    0x2d22(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x4c(%rbp)
movl   $0x0,-0x6c(%rbp)
mov    -0x6c(%rbp),%eax
cmp    -0x38(%rbp),%eax
jge    12fc <test_vectorfunc+0x14c>
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   1060 <normalize2_c@plt>
mov    -0x6c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x6c(%rbp)
jmp    12d5 <test_vectorfunc+0x125>
mov    0x2cd5(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x48(%rbp)
movl   $0x0,-0x70(%rbp)
mov    -0x70(%rbp),%eax
cmp    -0x38(%rbp),%eax
jge    1349 <test_vectorfunc+0x199>
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   10a0 <normalize2_neon@plt>
mov    -0x70(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x70(%rbp)
jmp    1322 <test_vectorfunc+0x172>
mov    0x2c88(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x44(%rbp)
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   1060 <normalize2_c@plt>
movss  -0x30(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x2c(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
lea    0xc7e(%rip),%rdi
mov    $0x2,%al
call   1040 <printf@plt>
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   10a0 <normalize2_neon@plt>
movss  -0x30(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x2c(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
lea    0xc6e(%rip),%rdi
mov    $0x2,%al
call   1040 <printf@plt>
mov    -0x48(%rbp),%esi
sub    -0x4c(%rbp),%esi
mov    -0x44(%rbp),%edx
sub    -0x48(%rbp),%edx
mov    -0x48(%rbp),%eax
sub    -0x4c(%rbp),%eax
cvtsi2ss %eax,%xmm0
mov    -0x44(%rbp),%eax
sub    -0x48(%rbp),%eax
cvtsi2ss %eax,%xmm1
divss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xc58(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
lea    0xc71(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    0x2bcb(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x58(%rbp)
movl   $0x0,-0x74(%rbp)
mov    -0x74(%rbp),%eax
cmp    -0x38(%rbp),%eax
jge    1453 <test_vectorfunc+0x2a3>
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   1030 <normalize3_c@plt>
mov    -0x74(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x74(%rbp)
jmp    142c <test_vectorfunc+0x27c>
mov    0x2b7e(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x54(%rbp)
movl   $0x0,-0x78(%rbp)
mov    -0x78(%rbp),%eax
cmp    -0x38(%rbp),%eax
jge    14a0 <test_vectorfunc+0x2f0>
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   1090 <normalize3_neon@plt>
mov    -0x78(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x78(%rbp)
jmp    1479 <test_vectorfunc+0x2c9>
mov    0x2b31(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x50(%rbp)
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   1030 <normalize3_c@plt>
movss  -0x30(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x2c(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
movss  -0x28(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
lea    0xb84(%rip),%rdi
mov    $0x3,%al
call   1040 <printf@plt>
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   1090 <normalize3_neon@plt>
movss  -0x30(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x2c(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
movss  -0x28(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
lea    0xb71(%rip),%rdi
mov    $0x3,%al
call   1040 <printf@plt>
mov    -0x54(%rbp),%esi
sub    -0x58(%rbp),%esi
mov    -0x50(%rbp),%edx
sub    -0x54(%rbp),%edx
mov    -0x54(%rbp),%eax
sub    -0x58(%rbp),%eax
cvtsi2ss %eax,%xmm0
mov    -0x50(%rbp),%eax
sub    -0x54(%rbp),%eax
cvtsi2ss %eax,%xmm1
divss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xb61(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
mov    0x2a70(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x58(%rbp)
movl   $0x0,-0x7c(%rbp)
mov    -0x7c(%rbp),%eax
cmp    -0x38(%rbp),%eax
jge    15b2 <test_vectorfunc+0x402>
lea    -0x10(%rbp),%rdi
lea    -0x20(%rbp),%rsi
lea    -0x30(%rbp),%rdx
call   1080 <cross3_c@plt>
mov    -0x7c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x7c(%rbp)
jmp    1587 <test_vectorfunc+0x3d7>
mov    0x2a1f(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x54(%rbp)
movl   $0x0,-0x80(%rbp)
mov    -0x80(%rbp),%eax
cmp    -0x38(%rbp),%eax
jge    1603 <test_vectorfunc+0x453>
lea    -0x10(%rbp),%rdi
lea    -0x20(%rbp),%rsi
lea    -0x30(%rbp),%rdx
call   1070 <cross3_neon@plt>
mov    -0x80(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x80(%rbp)
jmp    15d8 <test_vectorfunc+0x428>
mov    0x29ce(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x50(%rbp)
lea    -0x10(%rbp),%rdi
lea    -0x20(%rbp),%rsi
lea    -0x30(%rbp),%rdx
call   1080 <cross3_c@plt>
movss  -0x30(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x2c(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
movss  -0x28(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
lea    0xa8f(%rip),%rdi
mov    $0x3,%al
call   1040 <printf@plt>
lea    -0x10(%rbp),%rdi
lea    -0x20(%rbp),%rsi
lea    -0x30(%rbp),%rdx
call   1070 <cross3_neon@plt>
movss  -0x30(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x2c(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
movss  -0x28(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
lea    0xa74(%rip),%rdi
mov    $0x3,%al
call   1040 <printf@plt>
mov    -0x54(%rbp),%esi
sub    -0x58(%rbp),%esi
mov    -0x50(%rbp),%edx
sub    -0x54(%rbp),%edx
mov    -0x54(%rbp),%eax
sub    -0x58(%rbp),%eax
cvtsi2ss %eax,%xmm0
mov    -0x50(%rbp),%eax
sub    -0x54(%rbp),%eax
cvtsi2ss %eax,%xmm1
divss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xa60(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
lea    0x99d(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    0x28f7(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x64(%rbp)
movl   $0x0,-0x84(%rbp)
mov    -0x84(%rbp),%eax
cmp    -0x38(%rbp),%eax
jge    1733 <test_vectorfunc+0x583>
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   1050 <normalize4_c@plt>
mov    -0x84(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x84(%rbp)
jmp    1703 <test_vectorfunc+0x553>
mov    0x289e(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x60(%rbp)
movl   $0x0,-0x88(%rbp)
mov    -0x88(%rbp),%eax
cmp    -0x38(%rbp),%eax
jge    178c <test_vectorfunc+0x5dc>
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   10b0 <normalize4_neon@plt>
mov    -0x88(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x88(%rbp)
jmp    175c <test_vectorfunc+0x5ac>
mov    0x2845(%rip),%rax
mov    (%rax),%edi
lea    -0x40(%rbp),%rsi
call   10c0 <getrusage@plt>
imul   $0xf4240,-0x40(%rbp),%eax
add    -0x3c(%rbp),%eax
mov    %eax,-0x5c(%rbp)
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   1050 <normalize4_c@plt>
movss  -0x30(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x2c(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
movss  -0x28(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
movss  -0x24(%rbp),%xmm3
cvtss2sd %xmm3,%xmm3
lea    0x967(%rip),%rdi
mov    $0x4,%al
call   1040 <printf@plt>
lea    -0x10(%rbp),%rdi
lea    -0x30(%rbp),%rsi
call   10b0 <normalize4_neon@plt>
movss  -0x30(%rbp),%xmm0
cvtss2sd %xmm0,%xmm0
movss  -0x2c(%rbp),%xmm1
cvtss2sd %xmm1,%xmm1
movss  -0x28(%rbp),%xmm2
cvtss2sd %xmm2,%xmm2
movss  -0x24(%rbp),%xmm3
cvtss2sd %xmm3,%xmm3
lea    0x951(%rip),%rdi
mov    $0x4,%al
call   1040 <printf@plt>
mov    -0x60(%rbp),%esi
sub    -0x64(%rbp),%esi
mov    -0x5c(%rbp),%edx
sub    -0x60(%rbp),%edx
mov    -0x60(%rbp),%eax
sub    -0x64(%rbp),%eax
cvtsi2ss %eax,%xmm0
mov    -0x5c(%rbp),%eax
sub    -0x60(%rbp),%eax
cvtsi2ss %eax,%xmm1
divss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0x947(%rip),%rdi
mov    $0x1,%al
call   1040 <printf@plt>
lea    0x80a(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_vectorfunc>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x138,%rsp
xor    %eax,%eax
call   10e0 <rand@plt>
movaps %xmm0,0xe0(%rsp)
mov    0x2e01(%rip),%rbx
movss  (%rbx),%xmm0
movaps %xmm0,0x50(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movaps %xmm0,0x110(%rsp)
movss  (%rbx),%xmm0
movaps %xmm0,0x40(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movaps %xmm0,0x120(%rsp)
movss  (%rbx),%xmm0
movaps %xmm0,0x20(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movaps %xmm0,0xb0(%rsp)
movss  (%rbx),%xmm0
movaps 0x50(%rsp),%xmm1
unpcklps %xmm0,%xmm1
movaps %xmm1,0x50(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movaps %xmm0,0xf0(%rsp)
movss  (%rbx),%xmm0
movaps 0x40(%rsp),%xmm1
unpcklps %xmm0,%xmm1
movaps %xmm1,0x40(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movaps %xmm0,0x100(%rsp)
movss  (%rbx),%xmm0
movaps 0x20(%rsp),%xmm1
unpcklps %xmm0,%xmm1
movaps %xmm1,0x20(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movaps %xmm0,0x80(%rsp)
movss  (%rbx),%xmm0
movaps %xmm0,0x70(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movaps %xmm0,0xa0(%rsp)
movss  (%rbx),%xmm0
movaps %xmm0,0x90(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movaps %xmm0,0xd0(%rsp)
movss  (%rbx),%xmm0
movaps %xmm0,0xc0(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movss  (%rbx),%xmm1
movaps 0x70(%rsp),%xmm2
unpcklps %xmm1,%xmm2
movaps 0x50(%rsp),%xmm1
movlhps %xmm2,%xmm1
addps  0xd10(%rip),%xmm1
movaps %xmm1,%xmm2
movaps 0xe0(%rsp),%xmm1
unpcklps 0xb0(%rsp),%xmm1
movaps 0x80(%rsp),%xmm3
unpcklps %xmm0,%xmm3
movlhps %xmm3,%xmm1
divps  %xmm2,%xmm1
mulps  0xcf5(%rip),%xmm1
addps  0xcfe(%rip),%xmm1
movaps %xmm1,0x30(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movss  (%rbx),%xmm1
movaps 0x90(%rsp),%xmm2
unpcklps %xmm1,%xmm2
movaps 0x40(%rsp),%xmm1
movlhps %xmm2,%xmm1
addps  0xcb4(%rip),%xmm1
movaps %xmm1,%xmm2
movaps 0x110(%rsp),%xmm1
unpcklps 0xf0(%rsp),%xmm1
movaps 0xa0(%rsp),%xmm3
unpcklps %xmm0,%xmm3
movlhps %xmm3,%xmm1
divps  %xmm2,%xmm1
mulps  0xc99(%rip),%xmm1
addps  0xca2(%rip),%xmm1
movaps %xmm1,0x60(%rsp)
xor    %eax,%eax
call   10e0 <rand@plt>
movss  (%rbx),%xmm1
movaps 0xc0(%rsp),%xmm2
unpcklps %xmm1,%xmm2
movaps 0x20(%rsp),%xmm1
movlhps %xmm2,%xmm1
addps  0xc58(%rip),%xmm1
movaps %xmm1,%xmm2
movaps 0x120(%rsp),%xmm1
unpcklps 0x100(%rsp),%xmm1
movaps 0xd0(%rsp),%xmm3
unpcklps %xmm0,%xmm3
movlhps %xmm3,%xmm1
divps  %xmm2,%xmm1
mulps  0xc3d(%rip),%xmm1
addps  0xc46(%rip),%xmm1
movaps %xmm1,0x10(%rsp)
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    0x2be8(%rip),%rax
mov    (%rax),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
mov    0x8(%rsp),%r13d
mov    0xc(%rsp),%eax
mov    %eax,0x20(%rsp)
mov    $0x4c4b40,%ebx
lea    0x30(%rsp),%r14
lea    0x10(%rsp),%rbp
nopl   0x0(%rax,%rax,1)
mov    %r14,%rdi
mov    %rbp,%rsi
call   1070 <normalize2_c@plt>
add    $0xffffffff,%ebx
jne    1420 <test_vectorfunc+0x260>
mov    0x2ba1(%rip),%rax
mov    (%rax),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
mov    0x8(%rsp),%r15d
mov    0xc(%rsp),%r14d
mov    $0x4c4b40,%ebx
lea    0x30(%rsp),%r12
lea    0x10(%rsp),%rbp
nopl   0x0(%rax)
mov    %r12,%rdi
mov    %rbp,%rsi
call   10b0 <normalize2_neon@plt>
add    $0xffffffff,%ebx
jne    1460 <test_vectorfunc+0x2a0>
imul   $0xf4240,%r15d,%r15d
add    %r14d,%r15d
mov    0x2b57(%rip),%rax
mov    (%rax),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
imul   $0xf4240,0x8(%rsp),%r12d
mov    0xc(%rsp),%ebp
lea    0x30(%rsp),%r14
lea    0x10(%rsp),%rbx
mov    %r14,%rdi
mov    %rbx,%rsi
call   1070 <normalize2_c@plt>
movss  0x10(%rsp),%xmm0
movss  0x14(%rsp),%xmm1
cvtss2sd %xmm0,%xmm0
cvtss2sd %xmm1,%xmm1
lea    0xb66(%rip),%rdi
mov    $0x2,%al
call   1050 <printf@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
call   10b0 <normalize2_neon@plt>
movss  0x10(%rsp),%xmm0
movss  0x14(%rsp),%xmm1
cvtss2sd %xmm0,%xmm0
cvtss2sd %xmm1,%xmm1
lea    0xb56(%rip),%rdi
mov    $0x2,%al
call   1050 <printf@plt>
imul   $0xfff0bdc0,%r13d,%esi
sub    0x20(%rsp),%esi
add    %r15d,%esi
sub    %r15d,%ebp
xorps  %xmm0,%xmm0
cvtsi2ss %esi,%xmm0
add    %r12d,%ebp
xorps  %xmm1,%xmm1
cvtsi2ss %ebp,%xmm1
divss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xb3e(%rip),%rdi
mov    %ebp,%edx
mov    $0x1,%al
call   1050 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    0x2a8f(%rip),%rax
mov    (%rax),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
mov    0x8(%rsp),%eax
mov    %eax,0x40(%rsp)
mov    0xc(%rsp),%eax
mov    %eax,0x20(%rsp)
mov    $0x4c4b40,%ebp
nopw   0x0(%rax,%rax,1)
mov    %r14,%rdi
mov    %rbx,%rsi
call   1040 <normalize3_c@plt>
add    $0xffffffff,%ebp
jne    1570 <test_vectorfunc+0x3b0>
mov    0x2a51(%rip),%rax
mov    (%rax),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
mov    0x8(%rsp),%r15d
mov    0xc(%rsp),%r14d
mov    $0x4c4b40,%ebx
lea    0x30(%rsp),%r12
lea    0x10(%rsp),%rbp
nopl   0x0(%rax)
mov    %r12,%rdi
mov    %rbp,%rsi
call   10a0 <normalize3_neon@plt>
add    $0xffffffff,%ebx
jne    15b0 <test_vectorfunc+0x3f0>
imul   $0xf4240,%r15d,%r15d
add    %r14d,%r15d
mov    0x2a07(%rip),%rbx
mov    (%rbx),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
imul   $0xf4240,0x8(%rsp),%r12d
mov    0xc(%rsp),%ebp
lea    0x30(%rsp),%r14
lea    0x10(%rsp),%r13
mov    %r14,%rdi
mov    %r13,%rsi
call   1040 <normalize3_c@plt>
movss  0x10(%rsp),%xmm0
movss  0x14(%rsp),%xmm1
cvtss2sd %xmm0,%xmm0
cvtss2sd %xmm1,%xmm1
movss  0x18(%rsp),%xmm2
cvtss2sd %xmm2,%xmm2
lea    0xa72(%rip),%rdi
mov    $0x3,%al
call   1050 <printf@plt>
mov    %r14,%rdi
mov    %r13,%rsi
call   10a0 <normalize3_neon@plt>
movss  0x10(%rsp),%xmm0
movss  0x14(%rsp),%xmm1
cvtss2sd %xmm0,%xmm0
cvtss2sd %xmm1,%xmm1
movss  0x18(%rsp),%xmm2
cvtss2sd %xmm2,%xmm2
lea    0xa5e(%rip),%rdi
mov    $0x3,%al
call   1050 <printf@plt>
imul   $0xfff0bdc0,0x40(%rsp),%esi
ff
sub    0x20(%rsp),%esi
add    %r15d,%esi
sub    %r15d,%ebp
xorps  %xmm0,%xmm0
cvtsi2ss %esi,%xmm0
add    %r12d,%ebp
xorps  %xmm1,%xmm1
cvtsi2ss %ebp,%xmm1
divss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0xa4b(%rip),%rdi
mov    %ebp,%edx
mov    $0x1,%al
call   1050 <printf@plt>
mov    (%rbx),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
mov    0x8(%rsp),%eax
mov    %eax,0x40(%rsp)
mov    0xc(%rsp),%eax
mov    %eax,0x20(%rsp)
mov    $0x4c4b40,%ebx
lea    0x60(%rsp),%rbp
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    %r14,%rdi
mov    %rbp,%rsi
mov    %r13,%rdx
call   1090 <cross3_c@plt>
add    $0xffffffff,%ebx
jne    16d0 <test_vectorfunc+0x510>
mov    0x28ee(%rip),%rax
mov    (%rax),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
mov    0x8(%rsp),%r12d
mov    0xc(%rsp),%r15d
mov    $0x4c4b40,%ebp
lea    0x30(%rsp),%r14
lea    0x60(%rsp),%r13
lea    0x10(%rsp),%rbx
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    %r14,%rdi
mov    %r13,%rsi
mov    %rbx,%rdx
call   1080 <cross3_neon@plt>
add    $0xffffffff,%ebp
jne    1720 <test_vectorfunc+0x560>
imul   $0xf4240,%r12d,%r13d
add    %r15d,%r13d
mov    0x2894(%rip),%rax
mov    (%rax),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
imul   $0xf4240,0x8(%rsp),%r15d
mov    0xc(%rsp),%ebp
lea    0x30(%rsp),%r14
lea    0x60(%rsp),%r12
lea    0x10(%rsp),%rbx
mov    %r14,%rdi
mov    %r12,%rsi
mov    %rbx,%rdx
call   1090 <cross3_c@plt>
movss  0x10(%rsp),%xmm0
movss  0x14(%rsp),%xmm1
cvtss2sd %xmm0,%xmm0
cvtss2sd %xmm1,%xmm1
movss  0x18(%rsp),%xmm2
cvtss2sd %xmm2,%xmm2
lea    0x969(%rip),%rdi
mov    $0x3,%al
call   1050 <printf@plt>
mov    %r14,%rdi
mov    %r12,%rsi
mov    %rbx,%rdx
call   1080 <cross3_neon@plt>
movss  0x10(%rsp),%xmm0
movss  0x14(%rsp),%xmm1
cvtss2sd %xmm0,%xmm0
cvtss2sd %xmm1,%xmm1
movss  0x18(%rsp),%xmm2
cvtss2sd %xmm2,%xmm2
lea    0x94e(%rip),%rdi
mov    $0x3,%al
call   1050 <printf@plt>
imul   $0xfff0bdc0,0x40(%rsp),%esi
ff
sub    0x20(%rsp),%esi
add    %r13d,%esi
sub    %r13d,%ebp
xorps  %xmm0,%xmm0
cvtsi2ss %esi,%xmm0
add    %r15d,%ebp
xorps  %xmm1,%xmm1
cvtsi2ss %ebp,%xmm1
divss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0x937(%rip),%rdi
mov    %ebp,%edx
mov    $0x1,%al
call   1050 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
mov    0x27ac(%rip),%rax
mov    (%rax),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
mov    0x8(%rsp),%r12d
mov    0xc(%rsp),%eax
mov    %eax,0x20(%rsp)
mov    $0x4c4b40,%ebp
nopw   0x0(%rax,%rax,1)
mov    %r14,%rdi
mov    %rbx,%rsi
call   1060 <normalize4_c@plt>
add    $0xffffffff,%ebp
jne    1850 <test_vectorfunc+0x690>
mov    0x2771(%rip),%rax
mov    (%rax),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
mov    0x8(%rsp),%r15d
mov    0xc(%rsp),%r14d
mov    $0x4c4b40,%ebx
lea    0x30(%rsp),%r13
lea    0x10(%rsp),%rbp
nopl   0x0(%rax)
mov    %r13,%rdi
mov    %rbp,%rsi
call   10c0 <normalize4_neon@plt>
add    $0xffffffff,%ebx
jne    1890 <test_vectorfunc+0x6d0>
imul   $0xf4240,%r15d,%ebp
add    %r14d,%ebp
mov    0x2727(%rip),%rax
mov    (%rax),%edi
lea    0x8(%rsp),%rsi
call   10d0 <getrusage@plt>
imul   $0xf4240,0x8(%rsp),%r15d
mov    0xc(%rsp),%ebx
lea    0x30(%rsp),%r13
lea    0x10(%rsp),%r14
mov    %r13,%rdi
mov    %r14,%rsi
call   1060 <normalize4_c@plt>
movss  0x10(%rsp),%xmm0
movss  0x14(%rsp),%xmm1
cvtss2sd %xmm0,%xmm0
cvtss2sd %xmm1,%xmm1
movss  0x18(%rsp),%xmm2
cvtss2sd %xmm2,%xmm2
movss  0x1c(%rsp),%xmm3
cvtss2sd %xmm3,%xmm3
lea    0x860(%rip),%rdi
mov    $0x4,%al
call   1050 <printf@plt>
mov    %r13,%rdi
mov    %r14,%rsi
call   10c0 <normalize4_neon@plt>
movss  0x10(%rsp),%xmm0
movss  0x14(%rsp),%xmm1
cvtss2sd %xmm0,%xmm0
cvtss2sd %xmm1,%xmm1
movss  0x18(%rsp),%xmm2
cvtss2sd %xmm2,%xmm2
movss  0x1c(%rsp),%xmm3
cvtss2sd %xmm3,%xmm3
lea    0x848(%rip),%rdi
mov    $0x4,%al
call   1050 <printf@plt>
imul   $0xfff0bdc0,%r12d,%esi
sub    0x20(%rsp),%esi
add    %ebp,%esi
sub    %ebp,%ebx
xorps  %xmm0,%xmm0
cvtsi2ss %esi,%xmm0
add    %r15d,%ebx
xorps  %xmm1,%xmm1
cvtsi2ss %ebx,%xmm1
divss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
lea    0x83e(%rip),%rdi
mov    %ebx,%edx
mov    $0x1,%al
call   1050 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x138,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
%struct.rusage = type { %struct.TYPE_2__ }
%struct.TYPE_2__ = type { i32, i32 }
@RAND_MAX = global float 0.000000e+00
@.str = [2 x i8] c"\0A\00"
@RUSAGE_SELF = global i32 0
@.str.1 = [29 x i8] c"normalize2_c = [%.2f, %.2f]\0A\00"
@.str.2 = [32 x i8] c"normalize2_neon = [%.2f, %.2f]\0A\00"
@.str.3 = [41 x i8] c"normalize2: c=%i \09 neon=%i \09 rate=%.2f \0A\00"
@.str.4 = [35 x i8] c"normalize3_c = [%.2f, %.2f, %.2f]\0A\00"
@.str.5 = [38 x i8] c"normalize3_neon = [%.2f, %.2f, %.2f]\0A\00"
@.str.6 = [41 x i8] c"normalize3: c=%i \09 neon=%i \09 rate=%.2f \0A\00"
@.str.7 = [31 x i8] c"cross3_c = [%.2f, %.2f, %.2f]\0A\00"
@.str.8 = [34 x i8] c"cross3_neon = [%.2f, %.2f, %.2f]\0A\00"
@.str.9 = [37 x i8] c"cross3: c=%i \09 neon=%i \09 rate=%.2f \0A\00"
@.str.10 = [41 x i8] c"normalize4_c = [%.2f, %.2f, %.2f, %.2f]\0A\00"
@.str.11 = [44 x i8] c"normalize4_neon = [%.2f, %.2f, %.2f, %.2f]\0A\00"
@.str.12 = [41 x i8] c"normalize4: c=%i \09 neon=%i \09 rate=%.2f \0A\00"
define void @test_vectorfunc() {
%1 = alloca [4 x float]
%2 = alloca [4 x float]
%3 = alloca [4 x float]
%4 = alloca i32
%5 = alloca i32
%6 = alloca %struct.rusage
%7 = alloca [3 x i32]
%8 = alloca [3 x i32]
%9 = alloca [3 x i32]
%10 = alloca float
%11 = alloca i32
%12 = alloca i32
%13 = alloca i32
%14 = alloca i32
%15 = alloca i32
%16 = alloca i32
%17 = alloca i32
%18 = alloca i32
store i32 0, i32* %4
br label %19
19: ; preds = %47, %0
%20 = load i32, i32* %4
%21 = icmp slt i32 %20, 4
br i1 %21, label %22, label %50
22: ; preds = %19
%23 = call float (...) @rand()
%24 = load float, float* @RAND_MAX
%25 = fadd float %24, 1.000000e+00
%26 = fdiv float %23, %25
%27 = call float @llvm.fmuladd.f32(float 1.000000e+01, float %26, float -5.000000e+00)
%28 = load i32, i32* %4
%29 = sext i32 %28 to i64
%30 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 %29
store float %27, float* %30
%31 = call float (...) @rand()
%32 = load float, float* @RAND_MAX
%33 = fadd float %32, 1.000000e+00
%34 = fdiv float %31, %33
%35 = call float @llvm.fmuladd.f32(float 1.000000e+01, float %34, float -5.000000e+00)
%36 = load i32, i32* %4
%37 = sext i32 %36 to i64
%38 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 %37
store float %35, float* %38
%39 = call float (...) @rand()
%40 = load float, float* @RAND_MAX
%41 = fadd float %40, 1.000000e+00
%42 = fdiv float %39, %41
%43 = call float @llvm.fmuladd.f32(float 1.000000e+01, float %42, float -5.000000e+00)
%44 = load i32, i32* %4
%45 = sext i32 %44 to i64
%46 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 %45
store float %43, float* %46
br label %47
47: ; preds = %22
%48 = load i32, i32* %4
%49 = add nsw i32 %48, 1
store i32 %49, i32* %4
br label %19
50: ; preds = %19
store i32 5000000, i32* %5
%51 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%52 = load i32, i32* @RUSAGE_SELF
%53 = call i32 @getrusage(i32 %52, %struct.rusage* %6)
%54 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%55 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %54, i32 0, i32 0
%56 = load i32, i32* %55
%57 = mul nsw i32 %56, 1000000
%58 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%59 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %58, i32 0, i32 1
%60 = load i32, i32* %59
%61 = add nsw i32 %57, %60
%62 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 0
store i32 %61, i32* %62
store i32 0, i32* %11
br label %63
63: ; preds = %71, %50
%64 = load i32, i32* %11
%65 = load i32, i32* %5
%66 = icmp slt i32 %64, %65
br i1 %66, label %67, label %74
67: ; preds = %63
%68 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%69 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%70 = call i32 @normalize2_c(float* %68, float* %69)
br label %71
71: ; preds = %67
%72 = load i32, i32* %11
%73 = add nsw i32 %72, 1
store i32 %73, i32* %11
br label %63
74: ; preds = %63
%75 = load i32, i32* @RUSAGE_SELF
%76 = call i32 @getrusage(i32 %75, %struct.rusage* %6)
%77 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%78 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %77, i32 0, i32 0
%79 = load i32, i32* %78
%80 = mul nsw i32 %79, 1000000
%81 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%82 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %81, i32 0, i32 1
%83 = load i32, i32* %82
%84 = add nsw i32 %80, %83
%85 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 1
store i32 %84, i32* %85
store i32 0, i32* %12
br label %86
86: ; preds = %94, %74
%87 = load i32, i32* %12
%88 = load i32, i32* %5
%89 = icmp slt i32 %87, %88
br i1 %89, label %90, label %97
90: ; preds = %86
%91 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%92 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%93 = call i32 @normalize2_neon(float* %91, float* %92)
br label %94
94: ; preds = %90
%95 = load i32, i32* %12
%96 = add nsw i32 %95, 1
store i32 %96, i32* %12
br label %86
97: ; preds = %86
%98 = load i32, i32* @RUSAGE_SELF
%99 = call i32 @getrusage(i32 %98, %struct.rusage* %6)
%100 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%101 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %100, i32 0, i32 0
%102 = load i32, i32* %101
%103 = mul nsw i32 %102, 1000000
%104 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%105 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %104, i32 0, i32 1
%106 = load i32, i32* %105
%107 = add nsw i32 %103, %106
%108 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 2
store i32 %107, i32* %108
%109 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%110 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%111 = call i32 @normalize2_c(float* %109, float* %110)
%112 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%113 = load float, float* %112
%114 = fpext float %113 to double
%115 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 1
%116 = load float, float* %115
%117 = fpext float %116 to double
%118 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0), double %114, double %117)
%119 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%120 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%121 = call i32 @normalize2_neon(float* %119, float* %120)
%122 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%123 = load float, float* %122
%124 = fpext float %123 to double
%125 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 1
%126 = load float, float* %125
%127 = fpext float %126 to double
%128 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str.2, i64 0, i64 0), double %124, double %127)
%129 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 1
%130 = load i32, i32* %129
%131 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 0
%132 = load i32, i32* %131
%133 = sub nsw i32 %130, %132
%134 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 2
%135 = load i32, i32* %134
%136 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 1
%137 = load i32, i32* %136
%138 = sub nsw i32 %135, %137
%139 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 1
%140 = load i32, i32* %139
%141 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 0
%142 = load i32, i32* %141
%143 = sub nsw i32 %140, %142
%144 = sitofp i32 %143 to float
%145 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 2
%146 = load i32, i32* %145
%147 = getelementptr inbounds [3 x i32], [3 x i32]* %7, i64 0, i64 1
%148 = load i32, i32* %147
%149 = sub nsw i32 %146, %148
%150 = sitofp i32 %149 to float
%151 = fdiv float %144, %150
%152 = fpext float %151 to double
%153 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.3, i64 0, i64 0), i32 %133, i32 %138, double %152)
%154 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%155 = load i32, i32* @RUSAGE_SELF
%156 = call i32 @getrusage(i32 %155, %struct.rusage* %6)
%157 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%158 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %157, i32 0, i32 0
%159 = load i32, i32* %158
%160 = mul nsw i32 %159, 1000000
%161 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%162 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %161, i32 0, i32 1
%163 = load i32, i32* %162
%164 = add nsw i32 %160, %163
%165 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 0
store i32 %164, i32* %165
store i32 0, i32* %13
br label %166
166: ; preds = %174, %97
%167 = load i32, i32* %13
%168 = load i32, i32* %5
%169 = icmp slt i32 %167, %168
br i1 %169, label %170, label %177
170: ; preds = %166
%171 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%172 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%173 = call i32 @normalize3_c(float* %171, float* %172)
br label %174
174: ; preds = %170
%175 = load i32, i32* %13
%176 = add nsw i32 %175, 1
store i32 %176, i32* %13
br label %166
177: ; preds = %166
%178 = load i32, i32* @RUSAGE_SELF
%179 = call i32 @getrusage(i32 %178, %struct.rusage* %6)
%180 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%181 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %180, i32 0, i32 0
%182 = load i32, i32* %181
%183 = mul nsw i32 %182, 1000000
%184 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%185 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %184, i32 0, i32 1
%186 = load i32, i32* %185
%187 = add nsw i32 %183, %186
%188 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
store i32 %187, i32* %188
store i32 0, i32* %14
br label %189
189: ; preds = %197, %177
%190 = load i32, i32* %14
%191 = load i32, i32* %5
%192 = icmp slt i32 %190, %191
br i1 %192, label %193, label %200
193: ; preds = %189
%194 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%195 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%196 = call i32 @normalize3_neon(float* %194, float* %195)
br label %197
197: ; preds = %193
%198 = load i32, i32* %14
%199 = add nsw i32 %198, 1
store i32 %199, i32* %14
br label %189
200: ; preds = %189
%201 = load i32, i32* @RUSAGE_SELF
%202 = call i32 @getrusage(i32 %201, %struct.rusage* %6)
%203 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%204 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %203, i32 0, i32 0
%205 = load i32, i32* %204
%206 = mul nsw i32 %205, 1000000
%207 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%208 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %207, i32 0, i32 1
%209 = load i32, i32* %208
%210 = add nsw i32 %206, %209
%211 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 2
store i32 %210, i32* %211
%212 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%213 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%214 = call i32 @normalize3_c(float* %212, float* %213)
%215 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%216 = load float, float* %215
%217 = fpext float %216 to double
%218 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 1
%219 = load float, float* %218
%220 = fpext float %219 to double
%221 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 2
%222 = load float, float* %221
%223 = fpext float %222 to double
%224 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.4, i64 0, i64 0), double %217, double %220, double %223)
%225 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%226 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%227 = call i32 @normalize3_neon(float* %225, float* %226)
%228 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%229 = load float, float* %228
%230 = fpext float %229 to double
%231 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 1
%232 = load float, float* %231
%233 = fpext float %232 to double
%234 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 2
%235 = load float, float* %234
%236 = fpext float %235 to double
%237 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.5, i64 0, i64 0), double %230, double %233, double %236)
%238 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
%239 = load i32, i32* %238
%240 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 0
%241 = load i32, i32* %240
%242 = sub nsw i32 %239, %241
%243 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 2
%244 = load i32, i32* %243
%245 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
%246 = load i32, i32* %245
%247 = sub nsw i32 %244, %246
%248 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
%249 = load i32, i32* %248
%250 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 0
%251 = load i32, i32* %250
%252 = sub nsw i32 %249, %251
%253 = sitofp i32 %252 to float
%254 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 2
%255 = load i32, i32* %254
%256 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
%257 = load i32, i32* %256
%258 = sub nsw i32 %255, %257
%259 = sitofp i32 %258 to float
%260 = fdiv float %253, %259
%261 = fpext float %260 to double
%262 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.6, i64 0, i64 0), i32 %242, i32 %247, double %261)
%263 = load i32, i32* @RUSAGE_SELF
%264 = call i32 @getrusage(i32 %263, %struct.rusage* %6)
%265 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%266 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %265, i32 0, i32 0
%267 = load i32, i32* %266
%268 = mul nsw i32 %267, 1000000
%269 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%270 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %269, i32 0, i32 1
%271 = load i32, i32* %270
%272 = add nsw i32 %268, %271
%273 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 0
store i32 %272, i32* %273
store i32 0, i32* %15
br label %274
274: ; preds = %283, %200
%275 = load i32, i32* %15
%276 = load i32, i32* %5
%277 = icmp slt i32 %275, %276
br i1 %277, label %278, label %286
278: ; preds = %274
%279 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%280 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 0
%281 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%282 = call i32 @cross3_c(float* %279, float* %280, float* %281)
br label %283
283: ; preds = %278
%284 = load i32, i32* %15
%285 = add nsw i32 %284, 1
store i32 %285, i32* %15
br label %274
286: ; preds = %274
%287 = load i32, i32* @RUSAGE_SELF
%288 = call i32 @getrusage(i32 %287, %struct.rusage* %6)
%289 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%290 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %289, i32 0, i32 0
%291 = load i32, i32* %290
%292 = mul nsw i32 %291, 1000000
%293 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%294 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %293, i32 0, i32 1
%295 = load i32, i32* %294
%296 = add nsw i32 %292, %295
%297 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
store i32 %296, i32* %297
store i32 0, i32* %16
br label %298
298: ; preds = %307, %286
%299 = load i32, i32* %16
%300 = load i32, i32* %5
%301 = icmp slt i32 %299, %300
br i1 %301, label %302, label %310
302: ; preds = %298
%303 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%304 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 0
%305 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%306 = call i32 @cross3_neon(float* %303, float* %304, float* %305)
br label %307
307: ; preds = %302
%308 = load i32, i32* %16
%309 = add nsw i32 %308, 1
store i32 %309, i32* %16
br label %298
310: ; preds = %298
%311 = load i32, i32* @RUSAGE_SELF
%312 = call i32 @getrusage(i32 %311, %struct.rusage* %6)
%313 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%314 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %313, i32 0, i32 0
%315 = load i32, i32* %314
%316 = mul nsw i32 %315, 1000000
%317 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%318 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %317, i32 0, i32 1
%319 = load i32, i32* %318
%320 = add nsw i32 %316, %319
%321 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 2
store i32 %320, i32* %321
%322 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%323 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 0
%324 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%325 = call i32 @cross3_c(float* %322, float* %323, float* %324)
%326 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%327 = load float, float* %326
%328 = fpext float %327 to double
%329 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 1
%330 = load float, float* %329
%331 = fpext float %330 to double
%332 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 2
%333 = load float, float* %332
%334 = fpext float %333 to double
%335 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.7, i64 0, i64 0), double %328, double %331, double %334)
%336 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%337 = getelementptr inbounds [4 x float], [4 x float]* %2, i64 0, i64 0
%338 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%339 = call i32 @cross3_neon(float* %336, float* %337, float* %338)
%340 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%341 = load float, float* %340
%342 = fpext float %341 to double
%343 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 1
%344 = load float, float* %343
%345 = fpext float %344 to double
%346 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 2
%347 = load float, float* %346
%348 = fpext float %347 to double
%349 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.8, i64 0, i64 0), double %342, double %345, double %348)
%350 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
%351 = load i32, i32* %350
%352 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 0
%353 = load i32, i32* %352
%354 = sub nsw i32 %351, %353
%355 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 2
%356 = load i32, i32* %355
%357 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
%358 = load i32, i32* %357
%359 = sub nsw i32 %356, %358
%360 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
%361 = load i32, i32* %360
%362 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 0
%363 = load i32, i32* %362
%364 = sub nsw i32 %361, %363
%365 = sitofp i32 %364 to float
%366 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 2
%367 = load i32, i32* %366
%368 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
%369 = load i32, i32* %368
%370 = sub nsw i32 %367, %369
%371 = sitofp i32 %370 to float
%372 = fdiv float %365, %371
%373 = fpext float %372 to double
%374 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.9, i64 0, i64 0), i32 %354, i32 %359, double %373)
%375 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%376 = load i32, i32* @RUSAGE_SELF
%377 = call i32 @getrusage(i32 %376, %struct.rusage* %6)
%378 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%379 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %378, i32 0, i32 0
%380 = load i32, i32* %379
%381 = mul nsw i32 %380, 1000000
%382 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%383 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %382, i32 0, i32 1
%384 = load i32, i32* %383
%385 = add nsw i32 %381, %384
%386 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 0
store i32 %385, i32* %386
store i32 0, i32* %17
br label %387
387: ; preds = %395, %310
%388 = load i32, i32* %17
%389 = load i32, i32* %5
%390 = icmp slt i32 %388, %389
br i1 %390, label %391, label %398
391: ; preds = %387
%392 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%393 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%394 = call i32 @normalize4_c(float* %392, float* %393)
br label %395
395: ; preds = %391
%396 = load i32, i32* %17
%397 = add nsw i32 %396, 1
store i32 %397, i32* %17
br label %387
398: ; preds = %387
%399 = load i32, i32* @RUSAGE_SELF
%400 = call i32 @getrusage(i32 %399, %struct.rusage* %6)
%401 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%402 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %401, i32 0, i32 0
%403 = load i32, i32* %402
%404 = mul nsw i32 %403, 1000000
%405 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%406 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %405, i32 0, i32 1
%407 = load i32, i32* %406
%408 = add nsw i32 %404, %407
%409 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 1
store i32 %408, i32* %409
store i32 0, i32* %18
br label %410
410: ; preds = %418, %398
%411 = load i32, i32* %18
%412 = load i32, i32* %5
%413 = icmp slt i32 %411, %412
br i1 %413, label %414, label %421
414: ; preds = %410
%415 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%416 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%417 = call i32 @normalize4_neon(float* %415, float* %416)
br label %418
418: ; preds = %414
%419 = load i32, i32* %18
%420 = add nsw i32 %419, 1
store i32 %420, i32* %18
br label %410
421: ; preds = %410
%422 = load i32, i32* @RUSAGE_SELF
%423 = call i32 @getrusage(i32 %422, %struct.rusage* %6)
%424 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%425 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %424, i32 0, i32 0
%426 = load i32, i32* %425
%427 = mul nsw i32 %426, 1000000
%428 = getelementptr inbounds %struct.rusage, %struct.rusage* %6, i32 0, i32 0
%429 = getelementptr inbounds %struct.TYPE_2__, %struct.TYPE_2__* %428, i32 0, i32 1
%430 = load i32, i32* %429
%431 = add nsw i32 %427, %430
%432 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 2
store i32 %431, i32* %432
%433 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%434 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%435 = call i32 @normalize4_c(float* %433, float* %434)
%436 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%437 = load float, float* %436
%438 = fpext float %437 to double
%439 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 1
%440 = load float, float* %439
%441 = fpext float %440 to double
%442 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 2
%443 = load float, float* %442
%444 = fpext float %443 to double
%445 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 3
%446 = load float, float* %445
%447 = fpext float %446 to double
%448 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.10, i64 0, i64 0), double %438, double %441, double %444, double %447)
%449 = getelementptr inbounds [4 x float], [4 x float]* %1, i64 0, i64 0
%450 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%451 = call i32 @normalize4_neon(float* %449, float* %450)
%452 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 0
%453 = load float, float* %452
%454 = fpext float %453 to double
%455 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 1
%456 = load float, float* %455
%457 = fpext float %456 to double
%458 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 2
%459 = load float, float* %458
%460 = fpext float %459 to double
%461 = getelementptr inbounds [4 x float], [4 x float]* %3, i64 0, i64 3
%462 = load float, float* %461
%463 = fpext float %462 to double
%464 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.11, i64 0, i64 0), double %454, double %457, double %460, double %463)
%465 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 1
%466 = load i32, i32* %465
%467 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 0
%468 = load i32, i32* %467
%469 = sub nsw i32 %466, %468
%470 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 2
%471 = load i32, i32* %470
%472 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 1
%473 = load i32, i32* %472
%474 = sub nsw i32 %471, %473
%475 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 1
%476 = load i32, i32* %475
%477 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 0
%478 = load i32, i32* %477
%479 = sub nsw i32 %476, %478
%480 = sitofp i32 %479 to float
%481 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 2
%482 = load i32, i32* %481
%483 = getelementptr inbounds [3 x i32], [3 x i32]* %9, i64 0, i64 1
%484 = load i32, i32* %483
%485 = sub nsw i32 %482, %484
%486 = sitofp i32 %485 to float
%487 = fdiv float %480, %486
%488 = fpext float %487 to double
%489 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.12, i64 0, i64 0), i32 %469, i32 %474, double %488)
%490 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
%struct.rusage = type { %struct.TYPE_2__ }
%struct.TYPE_2__ = type { i32, i32 }
@RAND_MAX = global float 0.000000e+00
@RUSAGE_SELF = global i32 0
@.str.1 = [29 x i8] c"normalize2_c = [%.2f, %.2f]\0A\00"
@.str.2 = [32 x i8] c"normalize2_neon = [%.2f, %.2f]\0A\00"
@.str.3 = [41 x i8] c"normalize2: c=%i \09 neon=%i \09 rate=%.2f \0A\00"
@.str.4 = [35 x i8] c"normalize3_c = [%.2f, %.2f, %.2f]\0A\00"
@.str.5 = [38 x i8] c"normalize3_neon = [%.2f, %.2f, %.2f]\0A\00"
@.str.6 = [41 x i8] c"normalize3: c=%i \09 neon=%i \09 rate=%.2f \0A\00"
@.str.7 = [31 x i8] c"cross3_c = [%.2f, %.2f, %.2f]\0A\00"
@.str.8 = [34 x i8] c"cross3_neon = [%.2f, %.2f, %.2f]\0A\00"
@.str.9 = [37 x i8] c"cross3: c=%i \09 neon=%i \09 rate=%.2f \0A\00"
@.str.10 = [41 x i8] c"normalize4_c = [%.2f, %.2f, %.2f, %.2f]\0A\00"
@.str.11 = [44 x i8] c"normalize4_neon = [%.2f, %.2f, %.2f, %.2f]\0A\00"
@.str.12 = [41 x i8] c"normalize4: c=%i \09 neon=%i \09 rate=%.2f \0A\00"
define void @test_vectorfunc() {
%1 = alloca <4 x float>
%2 = alloca <4 x float>
%3 = alloca <4 x float>
%4 = alloca %struct.rusage
%5 = bitcast <4 x float>* %1 to i8*
%6 = bitcast <4 x float>* %2 to i8*
%7 = bitcast <4 x float>* %3 to i8*
%8 = tail call float (...) @rand()
%9 = load float, float* @RAND_MAX
%10 = getelementptr inbounds <4 x float>, <4 x float>* %1, i64 0, i64 0
%11 = tail call float (...) @rand()
%12 = load float, float* @RAND_MAX
%13 = getelementptr inbounds <4 x float>, <4 x float>* %2, i64 0, i64 0
%14 = tail call float (...) @rand()
%15 = load float, float* @RAND_MAX
%16 = getelementptr inbounds <4 x float>, <4 x float>* %3, i64 0, i64 0
%17 = tail call float (...) @rand()
%18 = load float, float* @RAND_MAX
%19 = tail call float (...) @rand()
%20 = load float, float* @RAND_MAX
%21 = tail call float (...) @rand()
%22 = load float, float* @RAND_MAX
%23 = getelementptr inbounds <4 x float>, <4 x float>* %3, i64 0, i64 1
%24 = tail call float (...) @rand()
%25 = load float, float* @RAND_MAX
%26 = tail call float (...) @rand()
%27 = load float, float* @RAND_MAX
%28 = tail call float (...) @rand()
%29 = load float, float* @RAND_MAX
%30 = getelementptr inbounds <4 x float>, <4 x float>* %3, i64 0, i64 2
%31 = tail call float (...) @rand()
%32 = load float, float* @RAND_MAX
%33 = insertelement <4 x float> poison, float %9, i64 0
%34 = insertelement <4 x float> %33, float %18, i64 1
%35 = insertelement <4 x float> %34, float %25, i64 2
%36 = insertelement <4 x float> %35, float %32, i64 3
%37 = fadd <4 x float> %36, <float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00>
%38 = insertelement <4 x float> poison, float %8, i64 0
%39 = insertelement <4 x float> %38, float %17, i64 1
%40 = insertelement <4 x float> %39, float %24, i64 2
%41 = insertelement <4 x float> %40, float %31, i64 3
%42 = fdiv <4 x float> %41, %37
%43 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %42, <4 x float> <float 1.000000e+01, float 1.000000e+01, float 1.000000e+01, float 1.000000e+01>, <4 x float> <float -5.000000e+00, float -5.000000e+00, float -5.000000e+00, float -5.000000e+00>)
store <4 x float> %43, <4 x float>* %1
%44 = tail call float (...) @rand()
%45 = load float, float* @RAND_MAX
%46 = insertelement <4 x float> poison, float %12, i64 0
%47 = insertelement <4 x float> %46, float %20, i64 1
%48 = insertelement <4 x float> %47, float %27, i64 2
%49 = insertelement <4 x float> %48, float %45, i64 3
%50 = fadd <4 x float> %49, <float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00>
%51 = insertelement <4 x float> poison, float %11, i64 0
%52 = insertelement <4 x float> %51, float %19, i64 1
%53 = insertelement <4 x float> %52, float %26, i64 2
%54 = insertelement <4 x float> %53, float %44, i64 3
%55 = fdiv <4 x float> %54, %50
%56 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %55, <4 x float> <float 1.000000e+01, float 1.000000e+01, float 1.000000e+01, float 1.000000e+01>, <4 x float> <float -5.000000e+00, float -5.000000e+00, float -5.000000e+00, float -5.000000e+00>)
store <4 x float> %56, <4 x float>* %2
%57 = tail call float (...) @rand()
%58 = load float, float* @RAND_MAX
%59 = insertelement <4 x float> poison, float %15, i64 0
%60 = insertelement <4 x float> %59, float %22, i64 1
%61 = insertelement <4 x float> %60, float %29, i64 2
%62 = insertelement <4 x float> %61, float %58, i64 3
%63 = fadd <4 x float> %62, <float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00>
%64 = insertelement <4 x float> poison, float %14, i64 0
%65 = insertelement <4 x float> %64, float %21, i64 1
%66 = insertelement <4 x float> %65, float %28, i64 2
%67 = insertelement <4 x float> %66, float %57, i64 3
%68 = fdiv <4 x float> %67, %63
%69 = call <4 x float> @llvm.fmuladd.v4f32(<4 x float> %68, <4 x float> <float 1.000000e+01, float 1.000000e+01, float 1.000000e+01, float 1.000000e+01>, <4 x float> <float -5.000000e+00, float -5.000000e+00, float -5.000000e+00, float -5.000000e+00>)
%70 = getelementptr inbounds <4 x float>, <4 x float>* %3, i64 0, i64 3
store <4 x float> %69, <4 x float>* %3
%71 = bitcast %struct.rusage* %4 to i8*
%72 = tail call i32 @putchar(i32 10)
%73 = load i32, i32* @RUSAGE_SELF
%74 = call i32 @getrusage(i32 %73, %struct.rusage* %4)
%75 = getelementptr inbounds %struct.rusage, %struct.rusage* %4, i64 0, i32 0, i32 0
%76 = load i32, i32* %75
%77 = getelementptr inbounds %struct.rusage, %struct.rusage* %4, i64 0, i32 0, i32 1
%78 = load i32, i32* %77
br label %84
79: ; preds = %84
%80 = load i32, i32* @RUSAGE_SELF
%81 = call i32 @getrusage(i32 %80, %struct.rusage* %4)
%82 = load i32, i32* %75
%83 = load i32, i32* %77
br label %124
84: ; preds = %0, %84
%85 = phi i32 [ 0, %0 ], [ %87, %84 ]
%86 = call i32 @normalize2_c(float* %10, float* %16)
%87 = add nuw nsw i32 %85, 1
%88 = icmp eq i32 %87, 5000000
br i1 %88, label %79, label %84
89: ; preds = %124
%90 = mul nsw i32 %82, 1000000
%91 = add nsw i32 %90, %83
%92 = load i32, i32* @RUSAGE_SELF
%93 = call i32 @getrusage(i32 %92, %struct.rusage* %4)
%94 = load i32, i32* %75
%95 = mul nsw i32 %94, 1000000
%96 = load i32, i32* %77
%97 = call i32 @normalize2_c(float* %10, float* %16)
%98 = load float, float* %16
%99 = fpext float %98 to double
%100 = load float, float* %23
%101 = fpext float %100 to double
%102 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0), double %99, double %101)
%103 = call i32 @normalize2_neon(float* %10, float* %16)
%104 = load float, float* %16
%105 = fpext float %104 to double
%106 = load float, float* %23
%107 = fpext float %106 to double
%108 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([32 x i8], [32 x i8]* @.str.2, i64 0, i64 0), double %105, double %107)
%109 = mul i32 %76, -1000000
%110 = sub i32 %109, %78
%111 = add i32 %110, %91
%112 = sub i32 %96, %91
%113 = add i32 %112, %95
%114 = sitofp i32 %111 to float
%115 = sitofp i32 %113 to float
%116 = fdiv float %114, %115
%117 = fpext float %116 to double
%118 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @.str.3, i64 0, i64 0), i32 %111, i32 %113, double %117)
%119 = call i32 @putchar(i32 10)
%120 = load i32, i32* @RUSAGE_SELF
%121 = call i32 @getrusage(i32 %120, %struct.rusage* %4)
%122 = load i32, i32* %75
%123 = load i32, i32* %77
br label %134
124: ; preds = %79, %124
%125 = phi i32 [ 0, %79 ], [ %127, %124 ]
%126 = call i32 @normalize2_neon(float* %10, float* %16)
%127 = add nuw nsw i32 %125, 1
%128 = icmp eq i32 %127, 5000000
br i1 %128, label %89, label %124
129: ; preds = %134
%130 = load i32, i32* @RUSAGE_SELF
%131 = call i32 @getrusage(i32 %130, %struct.rusage* %4)
%132 = load i32, i32* %75
%133 = load i32, i32* %77
br label %177
134: ; preds = %89, %134
%135 = phi i32 [ 0, %89 ], [ %137, %134 ]
%136 = call i32 @normalize3_c(float* %10, float* %16)
%137 = add nuw nsw i32 %135, 1
%138 = icmp eq i32 %137, 5000000
br i1 %138, label %129, label %134
139: ; preds = %177
%140 = mul nsw i32 %132, 1000000
%141 = add nsw i32 %140, %133
%142 = load i32, i32* @RUSAGE_SELF
%143 = call i32 @getrusage(i32 %142, %struct.rusage* %4)
%144 = load i32, i32* %75
%145 = mul nsw i32 %144, 1000000
%146 = load i32, i32* %77
%147 = call i32 @normalize3_c(float* %10, float* %16)
%148 = load float, float* %16
%149 = fpext float %148 to double
%150 = load float, float* %23
%151 = fpext float %150 to double
%152 = load float, float* %30
%153 = fpext float %152 to double
%154 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([35 x i8], [35 x i8]* @.str.4, i64 0, i64 0), double %149, double %151, double %153)
%155 = call i32 @normalize3_neon(float* %10, float* %16)
%156 = load float, float* %16
%157 = fpext float %156 to double
%158 = load float, float* %23
%159 = fpext float %158 to double
%160 = load float, float* %30
%161 = fpext float %160 to double
%162 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([38 x i8], [38 x i8]* @.str.5, i64 0, i64 0), double %157, double %159, double %161)
%163 = mul i32 %122, -1000000
%164 = sub i32 %163, %123
%165 = add i32 %164, %141
%166 = sub i32 %146, %141
%167 = add i32 %166, %145
%168 = sitofp i32 %165 to float
%169 = sitofp i32 %167 to float
%170 = fdiv float %168, %169
%171 = fpext float %170 to double
%172 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @.str.6, i64 0, i64 0), i32 %165, i32 %167, double %171)
%173 = load i32, i32* @RUSAGE_SELF
%174 = call i32 @getrusage(i32 %173, %struct.rusage* %4)
%175 = load i32, i32* %75
%176 = load i32, i32* %77
br label %187
177: ; preds = %129, %177
%178 = phi i32 [ 0, %129 ], [ %180, %177 ]
%179 = call i32 @normalize3_neon(float* %10, float* %16)
%180 = add nuw nsw i32 %178, 1
%181 = icmp eq i32 %180, 5000000
br i1 %181, label %139, label %177
182: ; preds = %187
%183 = load i32, i32* @RUSAGE_SELF
%184 = call i32 @getrusage(i32 %183, %struct.rusage* %4)
%185 = load i32, i32* %75
%186 = load i32, i32* %77
br label %231
187: ; preds = %139, %187
%188 = phi i32 [ 0, %139 ], [ %190, %187 ]
%189 = call i32 @cross3_c(float* %10, float* %13, float* %16)
%190 = add nuw nsw i32 %188, 1
%191 = icmp eq i32 %190, 5000000
br i1 %191, label %182, label %187
192: ; preds = %231
%193 = mul nsw i32 %185, 1000000
%194 = add nsw i32 %193, %186
%195 = load i32, i32* @RUSAGE_SELF
%196 = call i32 @getrusage(i32 %195, %struct.rusage* %4)
%197 = load i32, i32* %75
%198 = mul nsw i32 %197, 1000000
%199 = load i32, i32* %77
%200 = call i32 @cross3_c(float* %10, float* %13, float* %16)
%201 = load float, float* %16
%202 = fpext float %201 to double
%203 = load float, float* %23
%204 = fpext float %203 to double
%205 = load float, float* %30
%206 = fpext float %205 to double
%207 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @.str.7, i64 0, i64 0), double %202, double %204, double %206)
%208 = call i32 @cross3_neon(float* %10, float* %13, float* %16)
%209 = load float, float* %16
%210 = fpext float %209 to double
%211 = load float, float* %23
%212 = fpext float %211 to double
%213 = load float, float* %30
%214 = fpext float %213 to double
%215 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([34 x i8], [34 x i8]* @.str.8, i64 0, i64 0), double %210, double %212, double %214)
%216 = mul i32 %175, -1000000
%217 = sub i32 %216, %176
%218 = add i32 %217, %194
%219 = sub i32 %199, %194
%220 = add i32 %219, %198
%221 = sitofp i32 %218 to float
%222 = sitofp i32 %220 to float
%223 = fdiv float %221, %222
%224 = fpext float %223 to double
%225 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([37 x i8], [37 x i8]* @.str.9, i64 0, i64 0), i32 %218, i32 %220, double %224)
%226 = call i32 @putchar(i32 10)
%227 = load i32, i32* @RUSAGE_SELF
%228 = call i32 @getrusage(i32 %227, %struct.rusage* %4)
%229 = load i32, i32* %75
%230 = load i32, i32* %77
br label %241
231: ; preds = %182, %231
%232 = phi i32 [ 0, %182 ], [ %234, %231 ]
%233 = call i32 @cross3_neon(float* %10, float* %13, float* %16)
%234 = add nuw nsw i32 %232, 1
%235 = icmp eq i32 %234, 5000000
br i1 %235, label %192, label %231
236: ; preds = %241
%237 = load i32, i32* @RUSAGE_SELF
%238 = call i32 @getrusage(i32 %237, %struct.rusage* %4)
%239 = load i32, i32* %75
%240 = load i32, i32* %77
br label %285
241: ; preds = %192, %241
%242 = phi i32 [ 0, %192 ], [ %244, %241 ]
%243 = call i32 @normalize4_c(float* %10, float* %16)
%244 = add nuw nsw i32 %242, 1
%245 = icmp eq i32 %244, 5000000
br i1 %245, label %236, label %241
246: ; preds = %285
%247 = mul nsw i32 %239, 1000000
%248 = add nsw i32 %247, %240
%249 = load i32, i32* @RUSAGE_SELF
%250 = call i32 @getrusage(i32 %249, %struct.rusage* %4)
%251 = load i32, i32* %75
%252 = mul nsw i32 %251, 1000000
%253 = load i32, i32* %77
%254 = call i32 @normalize4_c(float* %10, float* %16)
%255 = load float, float* %16
%256 = fpext float %255 to double
%257 = load float, float* %23
%258 = fpext float %257 to double
%259 = load float, float* %30
%260 = fpext float %259 to double
%261 = load float, float* %70
%262 = fpext float %261 to double
%263 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @.str.10, i64 0, i64 0), double %256, double %258, double %260, double %262)
%264 = call i32 @normalize4_neon(float* %10, float* %16)
%265 = load float, float* %16
%266 = fpext float %265 to double
%267 = load float, float* %23
%268 = fpext float %267 to double
%269 = load float, float* %30
%270 = fpext float %269 to double
%271 = load float, float* %70
%272 = fpext float %271 to double
%273 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([44 x i8], [44 x i8]* @.str.11, i64 0, i64 0), double %266, double %268, double %270, double %272)
%274 = mul i32 %229, -1000000
%275 = sub i32 %274, %230
%276 = add i32 %275, %248
%277 = sub i32 %253, %248
%278 = add i32 %277, %252
%279 = sitofp i32 %276 to float
%280 = sitofp i32 %278 to float
%281 = fdiv float %279, %280
%282 = fpext float %281 to double
%283 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([41 x i8], [41 x i8]* @.str.12, i64 0, i64 0), i32 %276, i32 %278, double %282)
%284 = call i32 @putchar(i32 10)
ret void
285: ; preds = %236, %285
%286 = phi i32 [ 0, %236 ], [ %288, %285 ]
%287 = call i32 @normalize4_neon(float* %10, float* %16)
%288 = add nuw nsw i32 %286, 1
%289 = icmp eq i32 %288, 5000000
br i1 %289, label %246, label %285
}