#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 atan2(double, double);
double sqrt(double);
double solang(double *r1, double *r2, double *r3, int *on_triangle) {
  double cp23_x, cp23_y, cp23_z, n1, n2, n3, ip12, ip23, ip13, nom, den;
  *on_triangle = 0;
  cp23_x = r2[1] * r3[2] - r2[2] * r3[1];
  cp23_y = r2[2] * r3[0] - r2[0] * r3[2];
  cp23_z = r2[0] * r3[1] - r2[1] * r3[0];
  nom = cp23_x * r1[0] + cp23_y * r1[1] + cp23_z * r1[2];
  n1 = sqrt(r1[0] * r1[0] + r1[1] * r1[1] + r1[2] * r1[2]);
  n2 = sqrt(r2[0] * r2[0] + r2[1] * r2[1] + r2[2] * r2[2]);
  n3 = sqrt(r3[0] * r3[0] + r3[1] * r3[1] + r3[2] * r3[2]);
  ip12 = r1[0] * r2[0] + r1[1] * r2[1] + r1[2] * r2[2];
  ip23 = r2[0] * r3[0] + r2[1] * r3[1] + r2[2] * r3[2];
  ip13 = r1[0] * r3[0] + r1[1] * r3[1] + r1[2] * r3[2];
  den = n1 * n2 * n3 + ip12 * n3 + ip23 * n1 + ip13 * n2;
  if (nom == 0 & den <= 0) {
    *on_triangle = 1;
    return 0;
  }
  return -2. * atan2(nom, den);
}


x86 assembly (clang, -O0):
<solang>:
push   %rbp
mov    %rsp,%rbp
sub    $0x80,%rsp
mov    %rdi,-0x10(%rbp)
mov    %rsi,-0x18(%rbp)
mov    %rdx,-0x20(%rbp)
mov    %rcx,-0x28(%rbp)
mov    -0x28(%rbp),%rax
movl   $0x0,(%rax)
mov    -0x18(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x20(%rbp),%rax
movsd  0x10(%rax),%xmm2
mov    -0x18(%rbp),%rax
movsd  0x10(%rax),%xmm1
mov    -0x20(%rbp),%rax
mulsd  0x8(%rax),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x30(%rbp)
mov    -0x18(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x20(%rbp),%rax
movsd  (%rax),%xmm2
mov    -0x18(%rbp),%rax
movsd  (%rax),%xmm1
mov    -0x20(%rbp),%rax
mulsd  0x10(%rax),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x38(%rbp)
mov    -0x18(%rbp),%rax
movsd  (%rax),%xmm0
mov    -0x20(%rbp),%rax
movsd  0x8(%rax),%xmm2
mov    -0x18(%rbp),%rax
movsd  0x8(%rax),%xmm1
mov    -0x20(%rbp),%rax
mulsd  (%rax),%xmm1
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x40(%rbp)
movsd  -0x30(%rbp),%xmm1
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm2
movsd  -0x38(%rbp),%xmm0
mov    -0x10(%rbp),%rax
mulsd  0x8(%rax),%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
movsd  -0x40(%rbp),%xmm0
mov    -0x10(%rbp),%rax
movsd  0x10(%rax),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x78(%rbp)
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm1
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm2
mov    -0x10(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x10(%rbp),%rax
mulsd  0x8(%rax),%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x10(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x10(%rbp),%rax
movsd  0x10(%rax),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
call   1040 <sqrt@plt>
movsd  %xmm0,-0x48(%rbp)
mov    -0x18(%rbp),%rax
movsd  (%rax),%xmm1
mov    -0x18(%rbp),%rax
movsd  (%rax),%xmm2
mov    -0x18(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x18(%rbp),%rax
mulsd  0x8(%rax),%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x18(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x18(%rbp),%rax
movsd  0x10(%rax),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
call   1040 <sqrt@plt>
movsd  %xmm0,-0x50(%rbp)
mov    -0x20(%rbp),%rax
movsd  (%rax),%xmm1
mov    -0x20(%rbp),%rax
movsd  (%rax),%xmm2
mov    -0x20(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x20(%rbp),%rax
mulsd  0x8(%rax),%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x20(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x20(%rbp),%rax
movsd  0x10(%rax),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
call   1040 <sqrt@plt>
movsd  %xmm0,-0x58(%rbp)
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm1
mov    -0x18(%rbp),%rax
movsd  (%rax),%xmm2
mov    -0x10(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x18(%rbp),%rax
mulsd  0x8(%rax),%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x10(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x18(%rbp),%rax
movsd  0x10(%rax),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x60(%rbp)
mov    -0x18(%rbp),%rax
movsd  (%rax),%xmm1
mov    -0x20(%rbp),%rax
movsd  (%rax),%xmm2
mov    -0x18(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x20(%rbp),%rax
mulsd  0x8(%rax),%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x18(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x20(%rbp),%rax
movsd  0x10(%rax),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x68(%rbp)
mov    -0x10(%rbp),%rax
movsd  (%rax),%xmm1
mov    -0x20(%rbp),%rax
movsd  (%rax),%xmm2
mov    -0x10(%rbp),%rax
movsd  0x8(%rax),%xmm0
mov    -0x20(%rbp),%rax
mulsd  0x8(%rax),%xmm0
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
mov    -0x10(%rbp),%rax
movsd  0x10(%rax),%xmm0
mov    -0x20(%rbp),%rax
movsd  0x10(%rax),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x70(%rbp)
movsd  -0x48(%rbp),%xmm0
mulsd  -0x50(%rbp),%xmm0
movsd  -0x58(%rbp),%xmm2
movsd  -0x60(%rbp),%xmm1
mulsd  -0x58(%rbp),%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  -0x68(%rbp),%xmm1
movsd  -0x48(%rbp),%xmm2
mulsd  %xmm2,%xmm1
addsd  %xmm0,%xmm1
movsd  -0x70(%rbp),%xmm0
movsd  -0x50(%rbp),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x80(%rbp)
movsd  -0x78(%rbp),%xmm0
xorps  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
sete   %al
setnp  %cl
and    %cl,%al
and    $0x1,%al
movzbl %al,%eax
xorps  %xmm0,%xmm0
ucomisd -0x80(%rbp),%xmm0
setae  %cl
and    $0x1,%cl
movzbl %cl,%ecx
and    %ecx,%eax
cmp    $0x0,%eax
je     14b2 <solang+0x392>
mov    -0x28(%rbp),%rax
movl   $0x1,(%rax)
xorps  %xmm0,%xmm0
movsd  %xmm0,-0x8(%rbp)
jmp    14d6 <solang+0x3b6>
movsd  -0x78(%rbp),%xmm0
movsd  -0x80(%rbp),%xmm1
call   1030 <atan2@plt>
cvtsi2sd %eax,%xmm1
movsd  0xb33(%rip),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x8(%rbp)
movsd  -0x8(%rbp),%xmm0
add    $0x80,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<solang>:
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x28,%rsp
mov    %rcx,%r14
mov    %rdx,%r15
mov    %rsi,%rbx
mov    %rdi,%r12
movl   $0x0,(%rcx)
movsd  (%rsi),%xmm10
movsd  0x8(%rsi),%xmm0
movsd  0x10(%rdx),%xmm1
movsd  0x10(%rsi),%xmm5
movsd  (%rdx),%xmm2
movsd  0x8(%rdx),%xmm3
movapd %xmm0,%xmm4
mulsd  %xmm1,%xmm4
mulsd  %xmm10,%xmm1
mulsd  %xmm3,%xmm10
mulsd  %xmm5,%xmm3
subsd  %xmm3,%xmm4
mulsd  %xmm2,%xmm5
subsd  %xmm1,%xmm5
mulsd  %xmm0,%xmm2
subsd  %xmm2,%xmm10
movsd  (%rdi),%xmm1
movsd  0x8(%rdi),%xmm0
mulsd  %xmm0,%xmm5
mulsd  %xmm1,%xmm4
movsd  0x10(%rdi),%xmm3
mulsd  %xmm0,%xmm0
mulsd  %xmm1,%xmm1
addsd  %xmm0,%xmm1
movapd %xmm3,%xmm0
mulsd  %xmm3,%xmm0
addsd  %xmm1,%xmm0
xorpd  %xmm2,%xmm2
ucomisd %xmm2,%xmm0
jb     11c3 <solang+0xa3>
sqrtsd %xmm0,%xmm0
jmp    11fc <solang+0xdc>
movsd  %xmm10,0x8(%rsp)
movsd  %xmm4,(%rsp)
movsd  %xmm5,0x20(%rsp)
movsd  %xmm3,0x18(%rsp)
call   1040 <sqrt@plt>
movsd  0x18(%rsp),%xmm3
xorpd  %xmm2,%xmm2
movsd  0x20(%rsp),%xmm5
movsd  (%rsp),%xmm4
movsd  0x8(%rsp),%xmm10
movsd  %xmm0,0x10(%rsp)
addsd  %xmm5,%xmm4
mulsd  %xmm3,%xmm10
movsd  (%rbx),%xmm1
movsd  0x8(%rbx),%xmm0
mulsd  %xmm0,%xmm0
mulsd  %xmm1,%xmm1
addsd  %xmm0,%xmm1
movsd  0x10(%rbx),%xmm0
mulsd  %xmm0,%xmm0
addsd  %xmm1,%xmm0
ucomisd %xmm2,%xmm0
jb     123a <solang+0x11a>
sqrtsd %xmm0,%xmm11
jmp    125c <solang+0x13c>
movsd  %xmm10,0x8(%rsp)
movsd  %xmm4,(%rsp)
call   1040 <sqrt@plt>
movsd  (%rsp),%xmm4
movsd  0x8(%rsp),%xmm10
movapd %xmm0,%xmm11
addsd  %xmm4,%xmm10
movsd  (%r15),%xmm1
movsd  0x8(%r15),%xmm0
mulsd  %xmm0,%xmm0
mulsd  %xmm1,%xmm1
addsd  %xmm0,%xmm1
movsd  0x10(%r15),%xmm0
mulsd  %xmm0,%xmm0
addsd  %xmm1,%xmm0
xorpd  %xmm12,%xmm12
ucomisd %xmm12,%xmm0
jb     1298 <solang+0x178>
sqrtsd %xmm0,%xmm0
jmp    12bc <solang+0x19c>
movsd  %xmm10,0x8(%rsp)
movsd  %xmm11,(%rsp)
call   1040 <sqrt@plt>
xorpd  %xmm12,%xmm12
movsd  (%rsp),%xmm11
movsd  0x8(%rsp),%xmm10
movsd  (%r12),%xmm5
movsd  0x8(%r12),%xmm8
movsd  (%rbx),%xmm6
movsd  0x8(%rbx),%xmm7
movapd %xmm8,%xmm1
mulsd  %xmm7,%xmm1
movapd %xmm5,%xmm3
mulsd  %xmm6,%xmm3
addsd  %xmm1,%xmm3
movsd  0x10(%r12),%xmm1
movsd  0x10(%rbx),%xmm2
movapd %xmm1,%xmm4
mulsd  %xmm2,%xmm4
addsd  %xmm3,%xmm4
movsd  (%r15),%xmm9
movsd  0x8(%r15),%xmm3
mulsd  %xmm3,%xmm7
mulsd  %xmm9,%xmm6
addsd  %xmm7,%xmm6
movsd  0x10(%r15),%xmm7
mulsd  %xmm7,%xmm2
addsd  %xmm6,%xmm2
mulsd  %xmm3,%xmm8
mulsd  %xmm9,%xmm5
addsd  %xmm8,%xmm5
mulsd  %xmm7,%xmm1
addsd  %xmm5,%xmm1
movsd  0x10(%rsp),%xmm3
mulsd  %xmm3,%xmm2
mulsd  %xmm11,%xmm3
mulsd  %xmm0,%xmm4
mulsd  %xmm0,%xmm3
addsd  %xmm4,%xmm3
addsd  %xmm2,%xmm3
mulsd  %xmm11,%xmm1
addsd  %xmm3,%xmm1
ucomisd %xmm12,%xmm10
jne    1380 <solang+0x260>
jp     1380 <solang+0x260>
xorpd  %xmm0,%xmm0
ucomisd %xmm1,%xmm0
jb     1380 <solang+0x260>
movl   $0x1,(%r14)
jmp    1399 <solang+0x279>
movapd %xmm10,%xmm0
call   1030 <atan2@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
mulsd  0xc67(%rip),%xmm0
add    $0x28,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

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

LLVM IR (-O2):
define double @solang(double* nocapture %0, double* nocapture %1, double* nocapture %2, i32* nocapture writeonly %3) {
store i32 0, i32* %3
%5 = getelementptr inbounds double, double* %1, i64 1
%6 = load double, double* %5
%7 = getelementptr inbounds double, double* %2, i64 2
%8 = load double, double* %7
%9 = getelementptr inbounds double, double* %1, i64 2
%10 = load double, double* %9
%11 = getelementptr inbounds double, double* %2, i64 1
%12 = load double, double* %11
%13 = fneg double %10
%14 = fmul double %12, %13
%15 = tail call double @llvm.fmuladd.f64(double %6, double %8, double %14)
%16 = load double, double* %2
%17 = load double, double* %1
%18 = fneg double %17
%19 = fmul double %8, %18
%20 = tail call double @llvm.fmuladd.f64(double %10, double %16, double %19)
%21 = fneg double %6
%22 = fmul double %16, %21
%23 = tail call double @llvm.fmuladd.f64(double %17, double %12, double %22)
%24 = load double, double* %0
%25 = getelementptr inbounds double, double* %0, i64 1
%26 = load double, double* %25
%27 = fmul double %20, %26
%28 = tail call double @llvm.fmuladd.f64(double %15, double %24, double %27)
%29 = getelementptr inbounds double, double* %0, i64 2
%30 = load double, double* %29
%31 = tail call double @llvm.fmuladd.f64(double %23, double %30, double %28)
%32 = fmul double %26, %26
%33 = tail call double @llvm.fmuladd.f64(double %24, double %24, double %32)
%34 = tail call double @llvm.fmuladd.f64(double %30, double %30, double %33)
%35 = tail call double @sqrt(double %34)
%36 = load double, double* %1
%37 = load double, double* %5
%38 = fmul double %37, %37
%39 = tail call double @llvm.fmuladd.f64(double %36, double %36, double %38)
%40 = load double, double* %9
%41 = tail call double @llvm.fmuladd.f64(double %40, double %40, double %39)
%42 = tail call double @sqrt(double %41)
%43 = load double, double* %2
%44 = load double, double* %11
%45 = fmul double %44, %44
%46 = tail call double @llvm.fmuladd.f64(double %43, double %43, double %45)
%47 = load double, double* %7
%48 = tail call double @llvm.fmuladd.f64(double %47, double %47, double %46)
%49 = tail call double @sqrt(double %48)
%50 = load double, double* %0
%51 = load double, double* %1
%52 = load double, double* %25
%53 = load double, double* %5
%54 = fmul double %52, %53
%55 = tail call double @llvm.fmuladd.f64(double %50, double %51, double %54)
%56 = load double, double* %29
%57 = load double, double* %9
%58 = tail call double @llvm.fmuladd.f64(double %56, double %57, double %55)
%59 = load double, double* %2
%60 = load double, double* %11
%61 = fmul double %53, %60
%62 = tail call double @llvm.fmuladd.f64(double %51, double %59, double %61)
%63 = load double, double* %7
%64 = tail call double @llvm.fmuladd.f64(double %57, double %63, double %62)
%65 = fmul double %52, %60
%66 = tail call double @llvm.fmuladd.f64(double %50, double %59, double %65)
%67 = tail call double @llvm.fmuladd.f64(double %56, double %63, double %66)
%68 = fmul double %35, %42
%69 = fmul double %49, %58
%70 = tail call double @llvm.fmuladd.f64(double %68, double %49, double %69)
%71 = tail call double @llvm.fmuladd.f64(double %64, double %35, double %70)
%72 = tail call double @llvm.fmuladd.f64(double %67, double %42, double %71)
%73 = fcmp oeq double %31, 0.000000e+00
%74 = fcmp ole double %72, 0.000000e+00
%75 = and i1 %73, %74
br i1 %75, label %76, label %77
76: ; preds = %4
store i32 1, i32* %3
br label %81
77: ; preds = %4
%78 = tail call i32 @atan2(double %31, double %72)
%79 = sitofp i32 %78 to double
%80 = fmul double %79, -2.000000e+00
br label %81
81: ; preds = %77, %76
%82 = phi double [ 0.000000e+00, %76 ], [ %80, %77 ]
ret double %82
}