#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*/ glmMultMatrix4d(double *, double const *, double const *);
double glmNormalizeVector3d(double *);
void glmExtractFrustumd(double frustum[6][4], const double view[16],
                        const double proj[16]) {
  double clip[16];
  double t;
  glmMultMatrix4d(clip, proj, view);
  frustum[0][0] = clip[3] - clip[0];
  frustum[0][1] = clip[7] - clip[4];
  frustum[0][2] = clip[11] - clip[8];
  frustum[0][3] = clip[15] - clip[12];
  t = glmNormalizeVector3d(frustum[0]);
  frustum[0][3] /= t;
  frustum[1][0] = clip[3] + clip[0];
  frustum[1][1] = clip[7] + clip[4];
  frustum[1][2] = clip[11] + clip[8];
  frustum[1][3] = clip[15] + clip[12];
  t = glmNormalizeVector3d(frustum[1]);
  frustum[1][3] /= t;
  frustum[2][0] = clip[3] + clip[1];
  frustum[2][1] = clip[7] + clip[5];
  frustum[2][2] = clip[11] + clip[9];
  frustum[2][3] = clip[15] + clip[13];
  t = glmNormalizeVector3d(frustum[2]);
  frustum[2][3] /= t;
  frustum[3][0] = clip[3] - clip[1];
  frustum[3][1] = clip[7] - clip[5];
  frustum[3][2] = clip[11] - clip[9];
  frustum[3][3] = clip[15] - clip[13];
  t = glmNormalizeVector3d(frustum[3]);
  frustum[3][3] /= t;
  frustum[4][0] = clip[3] - clip[2];
  frustum[4][1] = clip[7] - clip[6];
  frustum[4][2] = clip[11] - clip[10];
  frustum[4][3] = clip[15] - clip[14];
  t = glmNormalizeVector3d(frustum[4]);
  frustum[4][3] /= t;
  frustum[5][0] = clip[3] + clip[2];
  frustum[5][1] = clip[7] + clip[6];
  frustum[5][2] = clip[11] + clip[10];
  frustum[5][3] = clip[15] + clip[14];
  t = glmNormalizeVector3d(frustum[5]);
  frustum[5][3] /= t;
}


x86 assembly (clang, -O0):
<glmExtractFrustumd>:
push   %rbp
mov    %rsp,%rbp
sub    $0xb0,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
lea    -0xa0(%rbp),%rdi
mov    -0x18(%rbp),%rsi
mov    -0x10(%rbp),%rdx
call   1030 <glmMultMatrix4d@plt>
movsd  -0x88(%rbp),%xmm0
ff
subsd  -0xa0(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0x68(%rbp),%xmm0
subsd  -0x80(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x8(%rax)
movsd  -0x48(%rbp),%xmm0
subsd  -0x60(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x10(%rax)
movsd  -0x28(%rbp),%xmm0
subsd  -0x40(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x18(%rax)
mov    -0x8(%rbp),%rdi
call   1040 <glmNormalizeVector3d@plt>
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa8(%rbp),%xmm1
ff
mov    -0x8(%rbp),%rax
movsd  0x18(%rax),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,0x18(%rax)
movsd  -0x88(%rbp),%xmm0
ff
addsd  -0xa0(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x20(%rax)
movsd  -0x68(%rbp),%xmm0
addsd  -0x80(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x28(%rax)
movsd  -0x48(%rbp),%xmm0
addsd  -0x60(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x30(%rax)
movsd  -0x28(%rbp),%xmm0
addsd  -0x40(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x38(%rax)
mov    -0x8(%rbp),%rdi
add    $0x20,%rdi
call   1040 <glmNormalizeVector3d@plt>
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa8(%rbp),%xmm1
ff
mov    -0x8(%rbp),%rax
movsd  0x38(%rax),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,0x38(%rax)
movsd  -0x88(%rbp),%xmm0
ff
addsd  -0x98(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x40(%rax)
movsd  -0x68(%rbp),%xmm0
addsd  -0x78(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x48(%rax)
movsd  -0x48(%rbp),%xmm0
addsd  -0x58(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x50(%rax)
movsd  -0x28(%rbp),%xmm0
addsd  -0x38(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x58(%rax)
mov    -0x8(%rbp),%rdi
add    $0x40,%rdi
call   1040 <glmNormalizeVector3d@plt>
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa8(%rbp),%xmm1
ff
mov    -0x8(%rbp),%rax
movsd  0x58(%rax),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,0x58(%rax)
movsd  -0x88(%rbp),%xmm0
ff
subsd  -0x98(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x60(%rax)
movsd  -0x68(%rbp),%xmm0
subsd  -0x78(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x68(%rax)
movsd  -0x48(%rbp),%xmm0
subsd  -0x58(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x70(%rax)
movsd  -0x28(%rbp),%xmm0
subsd  -0x38(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x78(%rax)
mov    -0x8(%rbp),%rdi
add    $0x60,%rdi
call   1040 <glmNormalizeVector3d@plt>
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa8(%rbp),%xmm1
ff
mov    -0x8(%rbp),%rax
movsd  0x78(%rax),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,0x78(%rax)
movsd  -0x88(%rbp),%xmm0
ff
subsd  -0x90(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x80(%rax)
movsd  -0x68(%rbp),%xmm0
subsd  -0x70(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x88(%rax)
movsd  -0x48(%rbp),%xmm0
subsd  -0x50(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x90(%rax)
movsd  -0x28(%rbp),%xmm0
subsd  -0x30(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0x98(%rax)
mov    -0x8(%rbp),%rdi
add    $0x80,%rdi
call   1040 <glmNormalizeVector3d@plt>
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa8(%rbp),%xmm1
ff
mov    -0x8(%rbp),%rax
movsd  0x98(%rax),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,0x98(%rax)
movsd  -0x88(%rbp),%xmm0
ff
addsd  -0x90(%rbp),%xmm0
ff
mov    -0x8(%rbp),%rax
movsd  %xmm0,0xa0(%rax)
movsd  -0x68(%rbp),%xmm0
addsd  -0x70(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0xa8(%rax)
movsd  -0x48(%rbp),%xmm0
addsd  -0x50(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0xb0(%rax)
movsd  -0x28(%rbp),%xmm0
addsd  -0x30(%rbp),%xmm0
mov    -0x8(%rbp),%rax
movsd  %xmm0,0xb8(%rax)
mov    -0x8(%rbp),%rdi
add    $0xa0,%rdi
call   1040 <glmNormalizeVector3d@plt>
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa8(%rbp),%xmm1
ff
mov    -0x8(%rbp),%rax
movsd  0xb8(%rax),%xmm0
divsd  %xmm1,%xmm0
movsd  %xmm0,0xb8(%rax)
add    $0xb0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<glmExtractFrustumd>:
push   %rbx
sub    $0x80,%rsp
mov    %rsi,%rax
mov    %rdi,%rbx
mov    %rsp,%rdi
mov    %rdx,%rsi
mov    %rax,%rdx
call   1030 <glmMultMatrix4d@plt>
movupd 0x18(%rsp),%xmm0
movapd (%rsp),%xmm1
movhpd 0x38(%rsp),%xmm0
movhpd 0x20(%rsp),%xmm1
subpd  %xmm1,%xmm0
movupd %xmm0,(%rbx)
movsd  0x58(%rsp),%xmm0
subsd  0x40(%rsp),%xmm0
movsd  %xmm0,0x10(%rbx)
movsd  0x78(%rsp),%xmm0
subsd  0x60(%rsp),%xmm0
movsd  %xmm0,0x18(%rbx)
mov    %rbx,%rdi
call   1040 <glmNormalizeVector3d@plt>
movsd  0x18(%rbx),%xmm1
divsd  %xmm0,%xmm1
movsd  %xmm1,0x18(%rbx)
movupd 0x18(%rsp),%xmm0
movapd (%rsp),%xmm1
lea    0x20(%rbx),%rdi
movhpd 0x38(%rsp),%xmm0
movhpd 0x20(%rsp),%xmm1
addpd  %xmm0,%xmm1
movupd %xmm1,0x20(%rbx)
movsd  0x58(%rsp),%xmm0
addsd  0x40(%rsp),%xmm0
movsd  %xmm0,0x30(%rbx)
movsd  0x78(%rsp),%xmm0
addsd  0x60(%rsp),%xmm0
movsd  %xmm0,0x38(%rbx)
call   1040 <glmNormalizeVector3d@plt>
movsd  0x38(%rbx),%xmm1
divsd  %xmm0,%xmm1
movsd  %xmm1,0x38(%rbx)
movupd 0x8(%rsp),%xmm0
movupd 0x18(%rsp),%xmm1
lea    0x40(%rbx),%rdi
movhpd 0x38(%rsp),%xmm1
movhpd 0x28(%rsp),%xmm0
addpd  %xmm1,%xmm0
movupd %xmm0,0x40(%rbx)
movsd  0x58(%rsp),%xmm0
addsd  0x48(%rsp),%xmm0
movsd  %xmm0,0x50(%rbx)
movsd  0x78(%rsp),%xmm0
addsd  0x68(%rsp),%xmm0
movsd  %xmm0,0x58(%rbx)
call   1040 <glmNormalizeVector3d@plt>
movsd  0x58(%rbx),%xmm1
divsd  %xmm0,%xmm1
movsd  %xmm1,0x58(%rbx)
movupd 0x8(%rsp),%xmm0
movupd 0x18(%rsp),%xmm1
lea    0x60(%rbx),%rdi
movhpd 0x38(%rsp),%xmm1
movhpd 0x28(%rsp),%xmm0
subpd  %xmm0,%xmm1
movupd %xmm1,0x60(%rbx)
movsd  0x58(%rsp),%xmm0
subsd  0x48(%rsp),%xmm0
movsd  %xmm0,0x70(%rbx)
movsd  0x78(%rsp),%xmm0
subsd  0x68(%rsp),%xmm0
movsd  %xmm0,0x78(%rbx)
call   1040 <glmNormalizeVector3d@plt>
movsd  0x78(%rbx),%xmm1
divsd  %xmm0,%xmm1
movsd  %xmm1,0x78(%rbx)
movupd 0x18(%rsp),%xmm0
movapd 0x10(%rsp),%xmm1
lea    0x80(%rbx),%rdi
movhpd 0x38(%rsp),%xmm0
movhpd 0x30(%rsp),%xmm1
subpd  %xmm1,%xmm0
movupd %xmm0,0x80(%rbx)
movsd  0x58(%rsp),%xmm0
subsd  0x50(%rsp),%xmm0
movsd  %xmm0,0x90(%rbx)
movsd  0x78(%rsp),%xmm0
subsd  0x70(%rsp),%xmm0
movsd  %xmm0,0x98(%rbx)
call   1040 <glmNormalizeVector3d@plt>
movsd  0x98(%rbx),%xmm1
divsd  %xmm0,%xmm1
movsd  %xmm1,0x98(%rbx)
movupd 0x18(%rsp),%xmm0
movapd 0x10(%rsp),%xmm1
lea    0xa0(%rbx),%rdi
movhpd 0x38(%rsp),%xmm0
movhpd 0x30(%rsp),%xmm1
addpd  %xmm0,%xmm1
movupd %xmm1,0xa0(%rbx)
movsd  0x58(%rsp),%xmm0
addsd  0x50(%rsp),%xmm0
movsd  %xmm0,0xb0(%rbx)
movsd  0x78(%rsp),%xmm0
addsd  0x70(%rsp),%xmm0
movsd  %xmm0,0xb8(%rbx)
call   1040 <glmNormalizeVector3d@plt>
movsd  0xb8(%rbx),%xmm1
divsd  %xmm0,%xmm1
movsd  %xmm1,0xb8(%rbx)
add    $0x80,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define void @glmExtractFrustumd([4 x double]* %0, double* %1, double* %2) {
%4 = alloca [4 x double]*
%5 = alloca double*
%6 = alloca double*
%7 = alloca [16 x double]
%8 = alloca double
store [4 x double]* %0, [4 x double]** %4
store double* %1, double** %5
store double* %2, double** %6
%9 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 0
%10 = load double*, double** %6
%11 = load double*, double** %5
%12 = call i32 @glmMultMatrix4d(double* %9, double* %10, double* %11)
%13 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 3
%14 = load double, double* %13
%15 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 0
%16 = load double, double* %15
%17 = fsub double %14, %16
%18 = load [4 x double]*, [4 x double]** %4
%19 = getelementptr inbounds [4 x double], [4 x double]* %18, i64 0
%20 = getelementptr inbounds [4 x double], [4 x double]* %19, i64 0, i64 0
store double %17, double* %20
%21 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 7
%22 = load double, double* %21
%23 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 4
%24 = load double, double* %23
%25 = fsub double %22, %24
%26 = load [4 x double]*, [4 x double]** %4
%27 = getelementptr inbounds [4 x double], [4 x double]* %26, i64 0
%28 = getelementptr inbounds [4 x double], [4 x double]* %27, i64 0, i64 1
store double %25, double* %28
%29 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 11
%30 = load double, double* %29
%31 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 8
%32 = load double, double* %31
%33 = fsub double %30, %32
%34 = load [4 x double]*, [4 x double]** %4
%35 = getelementptr inbounds [4 x double], [4 x double]* %34, i64 0
%36 = getelementptr inbounds [4 x double], [4 x double]* %35, i64 0, i64 2
store double %33, double* %36
%37 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 15
%38 = load double, double* %37
%39 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 12
%40 = load double, double* %39
%41 = fsub double %38, %40
%42 = load [4 x double]*, [4 x double]** %4
%43 = getelementptr inbounds [4 x double], [4 x double]* %42, i64 0
%44 = getelementptr inbounds [4 x double], [4 x double]* %43, i64 0, i64 3
store double %41, double* %44
%45 = load [4 x double]*, [4 x double]** %4
%46 = getelementptr inbounds [4 x double], [4 x double]* %45, i64 0
%47 = getelementptr inbounds [4 x double], [4 x double]* %46, i64 0, i64 0
%48 = call double @glmNormalizeVector3d(double* %47)
store double %48, double* %8
%49 = load double, double* %8
%50 = load [4 x double]*, [4 x double]** %4
%51 = getelementptr inbounds [4 x double], [4 x double]* %50, i64 0
%52 = getelementptr inbounds [4 x double], [4 x double]* %51, i64 0, i64 3
%53 = load double, double* %52
%54 = fdiv double %53, %49
store double %54, double* %52
%55 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 3
%56 = load double, double* %55
%57 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 0
%58 = load double, double* %57
%59 = fadd double %56, %58
%60 = load [4 x double]*, [4 x double]** %4
%61 = getelementptr inbounds [4 x double], [4 x double]* %60, i64 1
%62 = getelementptr inbounds [4 x double], [4 x double]* %61, i64 0, i64 0
store double %59, double* %62
%63 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 7
%64 = load double, double* %63
%65 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 4
%66 = load double, double* %65
%67 = fadd double %64, %66
%68 = load [4 x double]*, [4 x double]** %4
%69 = getelementptr inbounds [4 x double], [4 x double]* %68, i64 1
%70 = getelementptr inbounds [4 x double], [4 x double]* %69, i64 0, i64 1
store double %67, double* %70
%71 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 11
%72 = load double, double* %71
%73 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 8
%74 = load double, double* %73
%75 = fadd double %72, %74
%76 = load [4 x double]*, [4 x double]** %4
%77 = getelementptr inbounds [4 x double], [4 x double]* %76, i64 1
%78 = getelementptr inbounds [4 x double], [4 x double]* %77, i64 0, i64 2
store double %75, double* %78
%79 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 15
%80 = load double, double* %79
%81 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 12
%82 = load double, double* %81
%83 = fadd double %80, %82
%84 = load [4 x double]*, [4 x double]** %4
%85 = getelementptr inbounds [4 x double], [4 x double]* %84, i64 1
%86 = getelementptr inbounds [4 x double], [4 x double]* %85, i64 0, i64 3
store double %83, double* %86
%87 = load [4 x double]*, [4 x double]** %4
%88 = getelementptr inbounds [4 x double], [4 x double]* %87, i64 1
%89 = getelementptr inbounds [4 x double], [4 x double]* %88, i64 0, i64 0
%90 = call double @glmNormalizeVector3d(double* %89)
store double %90, double* %8
%91 = load double, double* %8
%92 = load [4 x double]*, [4 x double]** %4
%93 = getelementptr inbounds [4 x double], [4 x double]* %92, i64 1
%94 = getelementptr inbounds [4 x double], [4 x double]* %93, i64 0, i64 3
%95 = load double, double* %94
%96 = fdiv double %95, %91
store double %96, double* %94
%97 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 3
%98 = load double, double* %97
%99 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 1
%100 = load double, double* %99
%101 = fadd double %98, %100
%102 = load [4 x double]*, [4 x double]** %4
%103 = getelementptr inbounds [4 x double], [4 x double]* %102, i64 2
%104 = getelementptr inbounds [4 x double], [4 x double]* %103, i64 0, i64 0
store double %101, double* %104
%105 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 7
%106 = load double, double* %105
%107 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 5
%108 = load double, double* %107
%109 = fadd double %106, %108
%110 = load [4 x double]*, [4 x double]** %4
%111 = getelementptr inbounds [4 x double], [4 x double]* %110, i64 2
%112 = getelementptr inbounds [4 x double], [4 x double]* %111, i64 0, i64 1
store double %109, double* %112
%113 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 11
%114 = load double, double* %113
%115 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 9
%116 = load double, double* %115
%117 = fadd double %114, %116
%118 = load [4 x double]*, [4 x double]** %4
%119 = getelementptr inbounds [4 x double], [4 x double]* %118, i64 2
%120 = getelementptr inbounds [4 x double], [4 x double]* %119, i64 0, i64 2
store double %117, double* %120
%121 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 15
%122 = load double, double* %121
%123 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 13
%124 = load double, double* %123
%125 = fadd double %122, %124
%126 = load [4 x double]*, [4 x double]** %4
%127 = getelementptr inbounds [4 x double], [4 x double]* %126, i64 2
%128 = getelementptr inbounds [4 x double], [4 x double]* %127, i64 0, i64 3
store double %125, double* %128
%129 = load [4 x double]*, [4 x double]** %4
%130 = getelementptr inbounds [4 x double], [4 x double]* %129, i64 2
%131 = getelementptr inbounds [4 x double], [4 x double]* %130, i64 0, i64 0
%132 = call double @glmNormalizeVector3d(double* %131)
store double %132, double* %8
%133 = load double, double* %8
%134 = load [4 x double]*, [4 x double]** %4
%135 = getelementptr inbounds [4 x double], [4 x double]* %134, i64 2
%136 = getelementptr inbounds [4 x double], [4 x double]* %135, i64 0, i64 3
%137 = load double, double* %136
%138 = fdiv double %137, %133
store double %138, double* %136
%139 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 3
%140 = load double, double* %139
%141 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 1
%142 = load double, double* %141
%143 = fsub double %140, %142
%144 = load [4 x double]*, [4 x double]** %4
%145 = getelementptr inbounds [4 x double], [4 x double]* %144, i64 3
%146 = getelementptr inbounds [4 x double], [4 x double]* %145, i64 0, i64 0
store double %143, double* %146
%147 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 7
%148 = load double, double* %147
%149 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 5
%150 = load double, double* %149
%151 = fsub double %148, %150
%152 = load [4 x double]*, [4 x double]** %4
%153 = getelementptr inbounds [4 x double], [4 x double]* %152, i64 3
%154 = getelementptr inbounds [4 x double], [4 x double]* %153, i64 0, i64 1
store double %151, double* %154
%155 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 11
%156 = load double, double* %155
%157 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 9
%158 = load double, double* %157
%159 = fsub double %156, %158
%160 = load [4 x double]*, [4 x double]** %4
%161 = getelementptr inbounds [4 x double], [4 x double]* %160, i64 3
%162 = getelementptr inbounds [4 x double], [4 x double]* %161, i64 0, i64 2
store double %159, double* %162
%163 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 15
%164 = load double, double* %163
%165 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 13
%166 = load double, double* %165
%167 = fsub double %164, %166
%168 = load [4 x double]*, [4 x double]** %4
%169 = getelementptr inbounds [4 x double], [4 x double]* %168, i64 3
%170 = getelementptr inbounds [4 x double], [4 x double]* %169, i64 0, i64 3
store double %167, double* %170
%171 = load [4 x double]*, [4 x double]** %4
%172 = getelementptr inbounds [4 x double], [4 x double]* %171, i64 3
%173 = getelementptr inbounds [4 x double], [4 x double]* %172, i64 0, i64 0
%174 = call double @glmNormalizeVector3d(double* %173)
store double %174, double* %8
%175 = load double, double* %8
%176 = load [4 x double]*, [4 x double]** %4
%177 = getelementptr inbounds [4 x double], [4 x double]* %176, i64 3
%178 = getelementptr inbounds [4 x double], [4 x double]* %177, i64 0, i64 3
%179 = load double, double* %178
%180 = fdiv double %179, %175
store double %180, double* %178
%181 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 3
%182 = load double, double* %181
%183 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 2
%184 = load double, double* %183
%185 = fsub double %182, %184
%186 = load [4 x double]*, [4 x double]** %4
%187 = getelementptr inbounds [4 x double], [4 x double]* %186, i64 4
%188 = getelementptr inbounds [4 x double], [4 x double]* %187, i64 0, i64 0
store double %185, double* %188
%189 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 7
%190 = load double, double* %189
%191 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 6
%192 = load double, double* %191
%193 = fsub double %190, %192
%194 = load [4 x double]*, [4 x double]** %4
%195 = getelementptr inbounds [4 x double], [4 x double]* %194, i64 4
%196 = getelementptr inbounds [4 x double], [4 x double]* %195, i64 0, i64 1
store double %193, double* %196
%197 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 11
%198 = load double, double* %197
%199 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 10
%200 = load double, double* %199
%201 = fsub double %198, %200
%202 = load [4 x double]*, [4 x double]** %4
%203 = getelementptr inbounds [4 x double], [4 x double]* %202, i64 4
%204 = getelementptr inbounds [4 x double], [4 x double]* %203, i64 0, i64 2
store double %201, double* %204
%205 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 15
%206 = load double, double* %205
%207 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 14
%208 = load double, double* %207
%209 = fsub double %206, %208
%210 = load [4 x double]*, [4 x double]** %4
%211 = getelementptr inbounds [4 x double], [4 x double]* %210, i64 4
%212 = getelementptr inbounds [4 x double], [4 x double]* %211, i64 0, i64 3
store double %209, double* %212
%213 = load [4 x double]*, [4 x double]** %4
%214 = getelementptr inbounds [4 x double], [4 x double]* %213, i64 4
%215 = getelementptr inbounds [4 x double], [4 x double]* %214, i64 0, i64 0
%216 = call double @glmNormalizeVector3d(double* %215)
store double %216, double* %8
%217 = load double, double* %8
%218 = load [4 x double]*, [4 x double]** %4
%219 = getelementptr inbounds [4 x double], [4 x double]* %218, i64 4
%220 = getelementptr inbounds [4 x double], [4 x double]* %219, i64 0, i64 3
%221 = load double, double* %220
%222 = fdiv double %221, %217
store double %222, double* %220
%223 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 3
%224 = load double, double* %223
%225 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 2
%226 = load double, double* %225
%227 = fadd double %224, %226
%228 = load [4 x double]*, [4 x double]** %4
%229 = getelementptr inbounds [4 x double], [4 x double]* %228, i64 5
%230 = getelementptr inbounds [4 x double], [4 x double]* %229, i64 0, i64 0
store double %227, double* %230
%231 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 7
%232 = load double, double* %231
%233 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 6
%234 = load double, double* %233
%235 = fadd double %232, %234
%236 = load [4 x double]*, [4 x double]** %4
%237 = getelementptr inbounds [4 x double], [4 x double]* %236, i64 5
%238 = getelementptr inbounds [4 x double], [4 x double]* %237, i64 0, i64 1
store double %235, double* %238
%239 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 11
%240 = load double, double* %239
%241 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 10
%242 = load double, double* %241
%243 = fadd double %240, %242
%244 = load [4 x double]*, [4 x double]** %4
%245 = getelementptr inbounds [4 x double], [4 x double]* %244, i64 5
%246 = getelementptr inbounds [4 x double], [4 x double]* %245, i64 0, i64 2
store double %243, double* %246
%247 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 15
%248 = load double, double* %247
%249 = getelementptr inbounds [16 x double], [16 x double]* %7, i64 0, i64 14
%250 = load double, double* %249
%251 = fadd double %248, %250
%252 = load [4 x double]*, [4 x double]** %4
%253 = getelementptr inbounds [4 x double], [4 x double]* %252, i64 5
%254 = getelementptr inbounds [4 x double], [4 x double]* %253, i64 0, i64 3
store double %251, double* %254
%255 = load [4 x double]*, [4 x double]** %4
%256 = getelementptr inbounds [4 x double], [4 x double]* %255, i64 5
%257 = getelementptr inbounds [4 x double], [4 x double]* %256, i64 0, i64 0
%258 = call double @glmNormalizeVector3d(double* %257)
store double %258, double* %8
%259 = load double, double* %8
%260 = load [4 x double]*, [4 x double]** %4
%261 = getelementptr inbounds [4 x double], [4 x double]* %260, i64 5
%262 = getelementptr inbounds [4 x double], [4 x double]* %261, i64 0, i64 3
%263 = load double, double* %262
%264 = fdiv double %263, %259
store double %264, double* %262
ret void
}

LLVM IR (-O2):
define void @glmExtractFrustumd([4 x double]* %0, double* %1, double* %2) {
%4 = alloca [16 x double]
%5 = bitcast [16 x double]* %4 to i8*
%6 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 0
%7 = call i32 @glmMultMatrix4d(double* %6, double* %2, double* %1)
%8 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 3
%9 = bitcast double* %8 to <2 x double>*
%10 = load <2 x double>, <2 x double>* %9
%11 = bitcast [16 x double]* %4 to <2 x double>*
%12 = load <2 x double>, <2 x double>* %11
%13 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 0, i64 0
%14 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 7
%15 = load double, double* %14
%16 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 4
%17 = load double, double* %16
%18 = insertelement <2 x double> %10, double %15, i64 1
%19 = insertelement <2 x double> %12, double %17, i64 1
%20 = fsub <2 x double> %18, %19
%21 = bitcast [4 x double]* %0 to <2 x double>*
store <2 x double> %20, <2 x double>* %21
%22 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 11
%23 = load double, double* %22
%24 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 8
%25 = load double, double* %24
%26 = fsub double %23, %25
%27 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 0, i64 2
store double %26, double* %27
%28 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 15
%29 = load double, double* %28
%30 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 12
%31 = load double, double* %30
%32 = fsub double %29, %31
%33 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 0, i64 3
store double %32, double* %33
%34 = call double @glmNormalizeVector3d(double* %13)
%35 = load double, double* %33
%36 = fdiv double %35, %34
store double %36, double* %33
%37 = bitcast double* %8 to <2 x double>*
%38 = load <2 x double>, <2 x double>* %37
%39 = bitcast [16 x double]* %4 to <2 x double>*
%40 = load <2 x double>, <2 x double>* %39
%41 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 1, i64 0
%42 = load double, double* %14
%43 = load double, double* %16
%44 = insertelement <2 x double> %38, double %42, i64 1
%45 = insertelement <2 x double> %40, double %43, i64 1
%46 = fadd <2 x double> %44, %45
%47 = bitcast double* %41 to <2 x double>*
store <2 x double> %46, <2 x double>* %47
%48 = load double, double* %22
%49 = load double, double* %24
%50 = fadd double %48, %49
%51 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 1, i64 2
store double %50, double* %51
%52 = load double, double* %28
%53 = load double, double* %30
%54 = fadd double %52, %53
%55 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 1, i64 3
store double %54, double* %55
%56 = call double @glmNormalizeVector3d(double* %41)
%57 = load double, double* %55
%58 = fdiv double %57, %56
store double %58, double* %55
%59 = bitcast double* %8 to <2 x double>*
%60 = load <2 x double>, <2 x double>* %59
%61 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 1
%62 = bitcast double* %61 to <2 x double>*
%63 = load <2 x double>, <2 x double>* %62
%64 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 2, i64 0
%65 = load double, double* %14
%66 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 5
%67 = load double, double* %66
%68 = insertelement <2 x double> %60, double %65, i64 1
%69 = insertelement <2 x double> %63, double %67, i64 1
%70 = fadd <2 x double> %68, %69
%71 = bitcast double* %64 to <2 x double>*
store <2 x double> %70, <2 x double>* %71
%72 = load double, double* %22
%73 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 9
%74 = load double, double* %73
%75 = fadd double %72, %74
%76 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 2, i64 2
store double %75, double* %76
%77 = load double, double* %28
%78 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 13
%79 = load double, double* %78
%80 = fadd double %77, %79
%81 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 2, i64 3
store double %80, double* %81
%82 = call double @glmNormalizeVector3d(double* %64)
%83 = load double, double* %81
%84 = fdiv double %83, %82
store double %84, double* %81
%85 = bitcast double* %8 to <2 x double>*
%86 = load <2 x double>, <2 x double>* %85
%87 = bitcast double* %61 to <2 x double>*
%88 = load <2 x double>, <2 x double>* %87
%89 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 3, i64 0
%90 = load double, double* %14
%91 = load double, double* %66
%92 = insertelement <2 x double> %86, double %90, i64 1
%93 = insertelement <2 x double> %88, double %91, i64 1
%94 = fsub <2 x double> %92, %93
%95 = bitcast double* %89 to <2 x double>*
store <2 x double> %94, <2 x double>* %95
%96 = load double, double* %22
%97 = load double, double* %73
%98 = fsub double %96, %97
%99 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 3, i64 2
store double %98, double* %99
%100 = load double, double* %28
%101 = load double, double* %78
%102 = fsub double %100, %101
%103 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 3, i64 3
store double %102, double* %103
%104 = call double @glmNormalizeVector3d(double* %89)
%105 = load double, double* %103
%106 = fdiv double %105, %104
store double %106, double* %103
%107 = bitcast double* %8 to <2 x double>*
%108 = load <2 x double>, <2 x double>* %107
%109 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 2
%110 = bitcast double* %109 to <2 x double>*
%111 = load <2 x double>, <2 x double>* %110
%112 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 4, i64 0
%113 = load double, double* %14
%114 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 6
%115 = load double, double* %114
%116 = insertelement <2 x double> %108, double %113, i64 1
%117 = insertelement <2 x double> %111, double %115, i64 1
%118 = fsub <2 x double> %116, %117
%119 = bitcast double* %112 to <2 x double>*
store <2 x double> %118, <2 x double>* %119
%120 = load double, double* %22
%121 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 10
%122 = load double, double* %121
%123 = fsub double %120, %122
%124 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 4, i64 2
store double %123, double* %124
%125 = load double, double* %28
%126 = getelementptr inbounds [16 x double], [16 x double]* %4, i64 0, i64 14
%127 = load double, double* %126
%128 = fsub double %125, %127
%129 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 4, i64 3
store double %128, double* %129
%130 = call double @glmNormalizeVector3d(double* %112)
%131 = load double, double* %129
%132 = fdiv double %131, %130
store double %132, double* %129
%133 = bitcast double* %8 to <2 x double>*
%134 = load <2 x double>, <2 x double>* %133
%135 = bitcast double* %109 to <2 x double>*
%136 = load <2 x double>, <2 x double>* %135
%137 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 5, i64 0
%138 = load double, double* %14
%139 = load double, double* %114
%140 = insertelement <2 x double> %134, double %138, i64 1
%141 = insertelement <2 x double> %136, double %139, i64 1
%142 = fadd <2 x double> %140, %141
%143 = bitcast double* %137 to <2 x double>*
store <2 x double> %142, <2 x double>* %143
%144 = load double, double* %22
%145 = load double, double* %121
%146 = fadd double %144, %145
%147 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 5, i64 2
store double %146, double* %147
%148 = load double, double* %28
%149 = load double, double* %126
%150 = fadd double %148, %149
%151 = getelementptr inbounds [4 x double], [4 x double]* %0, i64 5, i64 3
store double %150, double* %151
%152 = call double @glmNormalizeVector3d(double* %137)
%153 = load double, double* %151
%154 = fdiv double %153, %152
store double %154, double* %151
ret void
}