#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 */
float cos(float const);
int /*<<< orphan*/ par_shapes__cross3(float *, float *, float *);
int /*<<< orphan*/ par_shapes__normalize3(float *);
float const sin(float const);
void par_shapes__trefoil(float const *uv, float *xyz, void *userdata) {
  float minor = *((float *)userdata);
  const float a = 0.5f;
  const float b = 0.3f;
  const float c = 0.5f;
  const float d = minor * 0.1f;
  const float u = (1 - uv[0]) * 4 * (3.14159265359);
  const float v = uv[1] * 2 * (3.14159265359);
  const float r = a + b * cos(1.5f * u);
  const float x = r * cos(u);
  const float y = r * sin(u);
  const float z = c * sin(1.5f * u);
  float q[3];
  q[0] = -1.5f * b * sin(1.5f * u) * cos(u) - (a + b * cos(1.5f * u)) * sin(u);
  q[1] = -1.5f * b * sin(1.5f * u) * sin(u) + (a + b * cos(1.5f * u)) * cos(u);
  q[2] = 1.5f * c * cos(1.5f * u);
  par_shapes__normalize3(q);
  float qvn[3] = {q[1], -q[0], 0};
  par_shapes__normalize3(qvn);
  float ww[3];
  par_shapes__cross3(ww, q, qvn);
  xyz[0] = x + d * (qvn[0] * cos(v) + ww[0] * sin(v));
  xyz[1] = y + d * (qvn[1] * cos(v) + ww[1] * sin(v));
  xyz[2] = z + d * ww[2] * sin(v);
}


x86 assembly (clang, -O0):
<par_shapes__trefoil>:
push   %rbp
mov    %rsp,%rbp
sub    $0xc0,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x18(%rbp),%rax
movss  (%rax),%xmm0
movss  %xmm0,-0x1c(%rbp)
movss  0xea0(%rip),%xmm0
movss  %xmm0,-0x20(%rbp)
movss  0xe8f(%rip),%xmm0
movss  %xmm0,-0x24(%rbp)
movss  0xe86(%rip),%xmm0
movss  %xmm0,-0x28(%rbp)
movss  0xe8d(%rip),%xmm0
mulss  -0x1c(%rbp),%xmm0
movss  %xmm0,-0x2c(%rbp)
mov    -0x8(%rbp),%rax
movss  0xe73(%rip),%xmm0
subss  (%rax),%xmm0
movss  0xe63(%rip),%xmm1
mulss  %xmm1,%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xe63(%rip),%xmm1
mulsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x30(%rbp)
mov    -0x8(%rbp),%rax
movss  0xe36(%rip),%xmm0
mulss  0x4(%rax),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xe39(%rip),%xmm1
mulsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,-0x34(%rbp)
movss  0xe00(%rip),%xmm0
mulss  -0x30(%rbp),%xmm0
call   1050 <cos@plt>
movss  0xdf2(%rip),%xmm1
mulss  %xmm1,%xmm0
movss  0xdea(%rip),%xmm1
addss  %xmm1,%xmm0
movss  %xmm0,-0x38(%rbp)
movss  -0x38(%rbp),%xmm0
movss  %xmm0,-0xb8(%rbp)
ff
movss  -0x30(%rbp),%xmm0
call   1050 <cos@plt>
movaps %xmm0,%xmm1
movss  -0xb8(%rbp),%xmm0
ff
mulss  %xmm1,%xmm0
movss  %xmm0,-0x3c(%rbp)
movss  -0x38(%rbp),%xmm0
movss  %xmm0,-0xb4(%rbp)
ff
movss  -0x30(%rbp),%xmm0
call   1030 <sin@plt>
movaps %xmm0,%xmm1
movss  -0xb4(%rbp),%xmm0
ff
mulss  %xmm1,%xmm0
movss  %xmm0,-0x40(%rbp)
movss  0xd7b(%rip),%xmm0
mulss  -0x30(%rbp),%xmm0
call   1030 <sin@plt>
movaps %xmm0,%xmm1
movss  0xd6e(%rip),%xmm0
mulss  %xmm1,%xmm0
movss  %xmm0,-0x44(%rbp)
movss  0xd55(%rip),%xmm0
mulss  -0x30(%rbp),%xmm0
call   1030 <sin@plt>
movaps %xmm0,%xmm1
movss  0xd4c(%rip),%xmm0
mulss  %xmm1,%xmm0
movss  %xmm0,-0xa8(%rbp)
ff
movss  -0x30(%rbp),%xmm0
call   1050 <cos@plt>
movss  %xmm0,-0xac(%rbp)
ff
movss  0xd1a(%rip),%xmm0
mulss  -0x30(%rbp),%xmm0
call   1050 <cos@plt>
movss  0xd0c(%rip),%xmm1
mulss  %xmm1,%xmm0
movss  0xd04(%rip),%xmm1
addss  %xmm1,%xmm0
movss  %xmm0,-0xb0(%rbp)
ff
movss  -0x30(%rbp),%xmm0
call   1030 <sin@plt>
movss  -0xb0(%rbp),%xmm1
ff
movss  -0xac(%rbp),%xmm2
ff
movaps %xmm0,%xmm3
movss  -0xa8(%rbp),%xmm0
ff
mulss  %xmm3,%xmm1
movd   %xmm1,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x50(%rbp)
movss  0xca5(%rip),%xmm0
mulss  -0x30(%rbp),%xmm0
call   1030 <sin@plt>
movaps %xmm0,%xmm1
movss  0xc9c(%rip),%xmm0
mulss  %xmm1,%xmm0
movss  %xmm0,-0x9c(%rbp)
ff
movss  -0x30(%rbp),%xmm0
call   1030 <sin@plt>
movss  %xmm0,-0xa0(%rbp)
ff
movss  0xc6a(%rip),%xmm0
mulss  -0x30(%rbp),%xmm0
call   1050 <cos@plt>
movss  0xc5c(%rip),%xmm1
mulss  %xmm1,%xmm0
movss  0xc54(%rip),%xmm1
addss  %xmm1,%xmm0
movss  %xmm0,-0xa4(%rbp)
ff
movss  -0x30(%rbp),%xmm0
call   1050 <cos@plt>
movss  -0xa4(%rbp),%xmm1
ff
movss  -0xa0(%rbp),%xmm2
ff
movaps %xmm0,%xmm3
movss  -0x9c(%rbp),%xmm0
ff
mulss  %xmm3,%xmm1
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
movss  %xmm0,-0x4c(%rbp)
movss  0xc02(%rip),%xmm0
mulss  -0x30(%rbp),%xmm0
call   1050 <cos@plt>
movaps %xmm0,%xmm1
movss  0xbe9(%rip),%xmm0
mulss  %xmm1,%xmm0
movss  %xmm0,-0x48(%rbp)
lea    -0x50(%rbp),%rdi
call   1040 <par_shapes__normalize3@plt>
movss  -0x4c(%rbp),%xmm0
movss  %xmm0,-0x5c(%rbp)
movss  -0x50(%rbp),%xmm0
movd   %xmm0,%eax
xor    $0x80000000,%eax
movd   %eax,%xmm0
movss  %xmm0,-0x58(%rbp)
xorps  %xmm0,%xmm0
movss  %xmm0,-0x54(%rbp)
lea    -0x5c(%rbp),%rdi
call   1040 <par_shapes__normalize3@plt>
lea    -0x68(%rbp),%rdi
lea    -0x50(%rbp),%rsi
lea    -0x5c(%rbp),%rdx
call   1060 <par_shapes__cross3@plt>
movss  -0x3c(%rbp),%xmm0
movss  %xmm0,-0x8c(%rbp)
ff
movss  -0x2c(%rbp),%xmm0
movss  %xmm0,-0x88(%rbp)
ff
movss  -0x5c(%rbp),%xmm0
movss  %xmm0,-0x94(%rbp)
ff
movss  -0x34(%rbp),%xmm0
call   1050 <cos@plt>
movss  %xmm0,-0x90(%rbp)
ff
movss  -0x68(%rbp),%xmm0
movss  %xmm0,-0x98(%rbp)
ff
movss  -0x34(%rbp),%xmm0
call   1030 <sin@plt>
movss  -0x98(%rbp),%xmm3
ff
movss  -0x94(%rbp),%xmm2
ff
movss  -0x90(%rbp),%xmm4
ff
movss  -0x8c(%rbp),%xmm1
ff
movaps %xmm0,%xmm5
movss  -0x88(%rbp),%xmm0
ff
mulss  %xmm5,%xmm3
mulss  %xmm4,%xmm2
addss  %xmm3,%xmm2
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
mov    -0x10(%rbp),%rax
movss  %xmm0,(%rax)
movss  -0x40(%rbp),%xmm0
movss  %xmm0,-0x78(%rbp)
movss  -0x2c(%rbp),%xmm0
movss  %xmm0,-0x74(%rbp)
movss  -0x58(%rbp),%xmm0
movss  %xmm0,-0x80(%rbp)
movss  -0x34(%rbp),%xmm0
call   1050 <cos@plt>
movss  %xmm0,-0x7c(%rbp)
movss  -0x64(%rbp),%xmm0
movss  %xmm0,-0x84(%rbp)
ff
movss  -0x34(%rbp),%xmm0
call   1030 <sin@plt>
movss  -0x84(%rbp),%xmm3
ff
movss  -0x80(%rbp),%xmm2
movss  -0x7c(%rbp),%xmm4
movss  -0x78(%rbp),%xmm1
movaps %xmm0,%xmm5
movss  -0x74(%rbp),%xmm0
mulss  %xmm5,%xmm3
mulss  %xmm4,%xmm2
addss  %xmm3,%xmm2
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
mov    -0x10(%rbp),%rax
movss  %xmm0,0x4(%rax)
movss  -0x44(%rbp),%xmm0
movss  %xmm0,-0x70(%rbp)
movss  -0x2c(%rbp),%xmm0
mulss  -0x60(%rbp),%xmm0
movss  %xmm0,-0x6c(%rbp)
movss  -0x34(%rbp),%xmm0
call   1030 <sin@plt>
movss  -0x70(%rbp),%xmm1
movaps %xmm0,%xmm2
movss  -0x6c(%rbp),%xmm0
mulss  %xmm2,%xmm0
addss  %xmm1,%xmm0
mov    -0x10(%rbp),%rax
movss  %xmm0,0x8(%rax)
add    $0xc0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<par_shapes__trefoil>:
push   %r15
push   %r14
push   %rbx
sub    $0x50,%rsp
movss  (%rdx),%xmm0
mulss  0xeab(%rip),%xmm0
movss  %xmm0,0x18(%rsp)
movss  0xea1(%rip),%xmm0
subss  (%rdi),%xmm0
mov    %rsi,%r14
mulss  0xe96(%rip),%xmm0
cvtss2sd %xmm0,%xmm0
movsd  0xea2(%rip),%xmm1
mulsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm2
movss  %xmm2,0x4(%rsp)
movss  0x4(%rdi),%xmm0
addss  %xmm0,%xmm0
cvtss2sd %xmm0,%xmm0
mulsd  %xmm1,%xmm0
cvtsd2ss %xmm0,%xmm0
movss  %xmm0,0x10(%rsp)
movss  0xe5d(%rip),%xmm0
mulss  %xmm2,%xmm0
movss  %xmm0,0x8(%rsp)
call   1050 <cos@plt>
mulss  0xe4a(%rip),%xmm0
addss  0xe46(%rip),%xmm0
movss  %xmm0,0x14(%rsp)
movss  0x4(%rsp),%xmm0
call   1050 <cos@plt>
mulss  0x14(%rsp),%xmm0
movss  %xmm0,0x24(%rsp)
movss  0x4(%rsp),%xmm0
call   1030 <sin@plt>
mulss  0x14(%rsp),%xmm0
movss  %xmm0,0x28(%rsp)
movss  0x8(%rsp),%xmm0
call   1030 <sin@plt>
mulss  0xdff(%rip),%xmm0
movss  %xmm0,0x14(%rsp)
movss  0x8(%rsp),%xmm0
call   1030 <sin@plt>
mulss  0xdea(%rip),%xmm0
movss  %xmm0,0xc(%rsp)
movss  0x4(%rsp),%xmm0
call   1050 <cos@plt>
movss  %xmm0,0x20(%rsp)
movss  0x8(%rsp),%xmm0
call   1050 <cos@plt>
mulss  0xdb8(%rip),%xmm0
addss  0xdb4(%rip),%xmm0
movss  %xmm0,0x1c(%rsp)
movss  0x4(%rsp),%xmm0
call   1030 <sin@plt>
mulss  0x1c(%rsp),%xmm0
movss  0x20(%rsp),%xmm1
mulss  0xc(%rsp),%xmm1
subss  %xmm0,%xmm1
movss  %xmm1,0x38(%rsp)
movss  0x8(%rsp),%xmm0
call   1030 <sin@plt>
mulss  0xd78(%rip),%xmm0
movss  %xmm0,0xc(%rsp)
movss  0x4(%rsp),%xmm0
call   1030 <sin@plt>
movss  %xmm0,0x20(%rsp)
movss  0x8(%rsp),%xmm0
call   1050 <cos@plt>
mulss  0xd46(%rip),%xmm0
addss  0xd42(%rip),%xmm0
movss  %xmm0,0x1c(%rsp)
movss  0x4(%rsp),%xmm0
call   1050 <cos@plt>
mulss  0x1c(%rsp),%xmm0
movss  0x20(%rsp),%xmm1
mulss  0xc(%rsp),%xmm1
addss  %xmm0,%xmm1
movss  %xmm1,0x3c(%rsp)
movss  0x8(%rsp),%xmm0
call   1050 <cos@plt>
mulss  0xd0a(%rip),%xmm0
movss  %xmm0,0x40(%rsp)
lea    0x38(%rsp),%r15
mov    %r15,%rdi
call   1040 <par_shapes__normalize3@plt>
movss  0x3c(%rsp),%xmm0
movss  %xmm0,0x2c(%rsp)
movss  0x38(%rsp),%xmm0
xorps  0xcf2(%rip),%xmm0
movss  %xmm0,0x30(%rsp)
movl   $0x0,0x34(%rsp)
lea    0x2c(%rsp),%rbx
mov    %rbx,%rdi
call   1040 <par_shapes__normalize3@plt>
lea    0x44(%rsp),%rdi
mov    %r15,%rsi
mov    %rbx,%rdx
call   1060 <par_shapes__cross3@plt>
movss  0x2c(%rsp),%xmm0
movss  %xmm0,0x8(%rsp)
movss  0x10(%rsp),%xmm0
call   1050 <cos@plt>
movss  %xmm0,0x4(%rsp)
movss  0x44(%rsp),%xmm0
movss  %xmm0,0xc(%rsp)
movss  0x10(%rsp),%xmm0
call   1030 <sin@plt>
mulss  0xc(%rsp),%xmm0
movss  0x4(%rsp),%xmm1
mulss  0x8(%rsp),%xmm1
addss  %xmm0,%xmm1
mulss  0x18(%rsp),%xmm1
addss  0x24(%rsp),%xmm1
movss  %xmm1,(%r14)
movss  0x30(%rsp),%xmm0
movss  %xmm0,0x8(%rsp)
movss  0x10(%rsp),%xmm0
call   1050 <cos@plt>
movss  %xmm0,0x4(%rsp)
movss  0x48(%rsp),%xmm0
movss  %xmm0,0x24(%rsp)
movss  0x10(%rsp),%xmm0
call   1030 <sin@plt>
mulss  0x24(%rsp),%xmm0
movss  0x4(%rsp),%xmm1
mulss  0x8(%rsp),%xmm1
addss  %xmm0,%xmm1
movss  0x18(%rsp),%xmm0
mulss  %xmm0,%xmm1
addss  0x28(%rsp),%xmm1
movss  %xmm1,0x4(%r14)
mulss  0x4c(%rsp),%xmm0
movss  %xmm0,0x18(%rsp)
movss  0x10(%rsp),%xmm0
call   1030 <sin@plt>
mulss  0x18(%rsp),%xmm0
addss  0x14(%rsp),%xmm0
movss  %xmm0,0x8(%r14)
add    $0x50,%rsp
pop    %rbx
pop    %r14
pop    %r15
ret

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

LLVM IR (-O2):
define void @par_shapes__trefoil(float* nocapture %0, float* nocapture writeonly %1, i8* nocapture %2) {
%4 = alloca [3 x float]
%5 = alloca [3 x float]
%6 = alloca [3 x float]
%7 = bitcast i8* %2 to float*
%8 = load float, float* %7
%9 = fmul float %8, 0x3FB99999A0000000
%10 = load float, float* %0
%11 = fsub float 1.000000e+00, %10
%12 = fmul float %11, 4.000000e+00
%13 = fpext float %12 to double
%14 = fmul double %13, 0x400921FB54442EEA
%15 = fptrunc double %14 to float
%16 = getelementptr inbounds float, float* %0, i64 1
%17 = load float, float* %16
%18 = fmul float %17, 2.000000e+00
%19 = fpext float %18 to double
%20 = fmul double %19, 0x400921FB54442EEA
%21 = fptrunc double %20 to float
%22 = fmul float %15, 1.500000e+00
%23 = tail call float @cos(float %22)
%24 = tail call float @llvm.fmuladd.f32(float %23, float 0x3FD3333340000000, float 5.000000e-01)
%25 = tail call float @cos(float %15)
%26 = fmul float %24, %25
%27 = tail call float @sin(float %15)
%28 = fmul float %24, %27
%29 = tail call float @sin(float %22)
%30 = fmul float %29, 5.000000e-01
%31 = bitcast [3 x float]* %4 to i8*
%32 = tail call float @sin(float %22)
%33 = fmul float %32, 0xBFDCCCCCE0000000
%34 = tail call float @cos(float %15)
%35 = tail call float @cos(float %22)
%36 = tail call float @llvm.fmuladd.f32(float %35, float 0x3FD3333340000000, float 5.000000e-01)
%37 = tail call float @sin(float %15)
%38 = fneg float %36
%39 = fmul float %37, %38
%40 = tail call float @llvm.fmuladd.f32(float %33, float %34, float %39)
%41 = getelementptr inbounds [3 x float], [3 x float]* %4, i64 0, i64 0
store float %40, float* %41
%42 = tail call float @sin(float %22)
%43 = fmul float %42, 0xBFDCCCCCE0000000
%44 = tail call float @sin(float %15)
%45 = tail call float @cos(float %22)
%46 = tail call float @llvm.fmuladd.f32(float %45, float 0x3FD3333340000000, float 5.000000e-01)
%47 = tail call float @cos(float %15)
%48 = fmul float %46, %47
%49 = tail call float @llvm.fmuladd.f32(float %43, float %44, float %48)
%50 = getelementptr inbounds [3 x float], [3 x float]* %4, i64 0, i64 1
store float %49, float* %50
%51 = tail call float @cos(float %22)
%52 = fmul float %51, 7.500000e-01
%53 = getelementptr inbounds [3 x float], [3 x float]* %4, i64 0, i64 2
store float %52, float* %53
%54 = call i32 @par_shapes__normalize3(float* %41)
%55 = bitcast [3 x float]* %5 to i8*
%56 = getelementptr inbounds [3 x float], [3 x float]* %5, i64 0, i64 0
%57 = load float, float* %50
store float %57, float* %56
%58 = getelementptr inbounds [3 x float], [3 x float]* %5, i64 0, i64 1
%59 = load float, float* %41
%60 = fneg float %59
store float %60, float* %58
%61 = getelementptr inbounds [3 x float], [3 x float]* %5, i64 0, i64 2
store float 0.000000e+00, float* %61
%62 = call i32 @par_shapes__normalize3(float* %56)
%63 = bitcast [3 x float]* %6 to i8*
%64 = getelementptr inbounds [3 x float], [3 x float]* %6, i64 0, i64 0
%65 = call i32 @par_shapes__cross3(float* %64, float* %41, float* %56)
%66 = load float, float* %56
%67 = call float @cos(float %21)
%68 = load float, float* %64
%69 = call float @sin(float %21)
%70 = fmul float %68, %69
%71 = call float @llvm.fmuladd.f32(float %66, float %67, float %70)
%72 = call float @llvm.fmuladd.f32(float %9, float %71, float %26)
store float %72, float* %1
%73 = load float, float* %58
%74 = call float @cos(float %21)
%75 = getelementptr inbounds [3 x float], [3 x float]* %6, i64 0, i64 1
%76 = load float, float* %75
%77 = call float @sin(float %21)
%78 = fmul float %76, %77
%79 = call float @llvm.fmuladd.f32(float %73, float %74, float %78)
%80 = call float @llvm.fmuladd.f32(float %9, float %79, float %28)
%81 = getelementptr inbounds float, float* %1, i64 1
store float %80, float* %81
%82 = getelementptr inbounds [3 x float], [3 x float]* %6, i64 0, i64 2
%83 = load float, float* %82
%84 = fmul float %9, %83
%85 = call float @sin(float %21)
%86 = call float @llvm.fmuladd.f32(float %84, float %85, float %30)
%87 = getelementptr inbounds float, float* %1, i64 2
store float %86, float* %87
ret void
}