void GetSatPosition(double EpochTime, double EpochRAAN, double EpochArgPerigee,
                    double SemiMajorAxis, double Inclination,
                    double Eccentricity, double RAANPrecession,
                    double PerigeePrecession, double T, double TrueAnomaly,
                    double *X, double *Y, double *Z, double *Radius, double *VX,
                    double *VY, double *VZ) {
  double RAAN, ArgPerigee;
  double Xw, Yw, VXw, VYw;
  double Tmp;
  double Px, Qx, Py, Qy, Pz, Qz;
  double CosArgPerigee, SinArgPerigee;
  double CosRAAN, SinRAAN, CoSinclination, SinInclination;
  *Radius = SemiMajorAxis * (1 - ((Eccentricity) * (Eccentricity))) /
            (1 + Eccentricity * cos(TrueAnomaly));
  if (*Radius <= 6378.16)
    *Radius = 6378.16;
  Xw = *Radius * cos(TrueAnomaly);
  Yw = *Radius * sin(TrueAnomaly);
  Tmp =
      sqrt(398600 / (SemiMajorAxis * (1 - ((Eccentricity) * (Eccentricity)))));
  VXw = -Tmp * sin(TrueAnomaly);
  VYw = Tmp * (cos(TrueAnomaly) + Eccentricity);
  ArgPerigee = EpochArgPerigee + (T - EpochTime) * PerigeePrecession;
  RAAN = EpochRAAN - (T - EpochTime) * RAANPrecession;
  CosRAAN = cos(RAAN);
  SinRAAN = sin(RAAN);
  CosArgPerigee = cos(ArgPerigee);
  SinArgPerigee = sin(ArgPerigee);
  CoSinclination = cos(Inclination);
  SinInclination = sin(Inclination);
  Px = CosArgPerigee * CosRAAN - SinArgPerigee * SinRAAN * CoSinclination;
  Py = CosArgPerigee * SinRAAN + SinArgPerigee * CosRAAN * CoSinclination;
  Pz = SinArgPerigee * SinInclination;
  Qx = -SinArgPerigee * CosRAAN - CosArgPerigee * SinRAAN * CoSinclination;
  Qy = -SinArgPerigee * SinRAAN + CosArgPerigee * CosRAAN * CoSinclination;
  Qz = CosArgPerigee * SinInclination;
  *X = Px * Xw + Qx * Yw;
  *Y = Py * Xw + Qy * Yw;
  *Z = Pz * Xw + Qz * Yw;
  *VX = Px * VXw + Qx * VYw;
  *VY = Py * VXw + Qy * VYw;
  *VZ = Pz * VXw + Qz * VYw;
}


x86 assembly (clang, -O0):
<GetSatPosition>:
push   %rbp
mov    %rsp,%rbp
sub    $0x140,%rsp
mov    0x20(%rbp),%rax
movsd  0x18(%rbp),%xmm8
movsd  0x10(%rbp),%xmm8
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  %xmm2,-0x18(%rbp)
movsd  %xmm3,-0x20(%rbp)
movsd  %xmm4,-0x28(%rbp)
movsd  %xmm5,-0x30(%rbp)
movsd  %xmm6,-0x38(%rbp)
movsd  %xmm7,-0x40(%rbp)
mov    %rdi,-0x48(%rbp)
mov    %rsi,-0x50(%rbp)
mov    %rdx,-0x58(%rbp)
mov    %rcx,-0x60(%rbp)
mov    %r8,-0x68(%rbp)
mov    %r9,-0x70(%rbp)
movsd  -0x20(%rbp),%xmm0
movsd  -0x30(%rbp),%xmm1
movsd  -0x30(%rbp),%xmm2
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm1
movsd  0xe4b(%rip),%xmm2
addsd  %xmm2,%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x110(%rbp)
ff
movsd  -0x30(%rbp),%xmm0
movsd  %xmm0,-0x118(%rbp)
ff
movsd  0x18(%rbp),%xmm0
call   1040 <cos@plt>
movsd  -0x118(%rbp),%xmm1
ff
movaps %xmm0,%xmm2
movsd  -0x110(%rbp),%xmm0
ff
mulsd  %xmm2,%xmm1
movsd  0xe05(%rip),%xmm2
addsd  %xmm2,%xmm1
divsd  %xmm1,%xmm0
mov    -0x60(%rbp),%rax
movsd  %xmm0,(%rax)
mov    -0x60(%rbp),%rax
movsd  0xde1(%rip),%xmm0
ucomisd (%rax),%xmm0
jb     1239 <GetSatPosition+0x109>
mov    -0x60(%rbp),%rax
movsd  0xdcb(%rip),%xmm0
movsd  %xmm0,(%rax)
mov    -0x60(%rbp),%rax
movsd  (%rax),%xmm0
movsd  %xmm0,-0x138(%rbp)
ff
movsd  0x18(%rbp),%xmm0
call   1040 <cos@plt>
movaps %xmm0,%xmm1
movsd  -0x138(%rbp),%xmm0
ff
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x88(%rbp)
ff
mov    -0x60(%rbp),%rax
movsd  (%rax),%xmm0
movsd  %xmm0,-0x130(%rbp)
ff
movsd  0x18(%rbp),%xmm0
call   1030 <sin@plt>
movaps %xmm0,%xmm1
movsd  -0x130(%rbp),%xmm0
ff
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x90(%rbp)
ff
movsd  -0x20(%rbp),%xmm1
movsd  -0x30(%rbp),%xmm0
movsd  -0x30(%rbp),%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
movsd  0xd3b(%rip),%xmm2
addsd  %xmm2,%xmm0
mulsd  %xmm0,%xmm1
movsd  0xd33(%rip),%xmm0
divsd  %xmm1,%xmm0
call   1050 <sqrt@plt>
movsd  %xmm0,-0xa8(%rbp)
ff
movsd  -0xa8(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  %xmm0,-0x128(%rbp)
ff
movsd  0x18(%rbp),%xmm0
call   1030 <sin@plt>
movaps %xmm0,%xmm1
movsd  -0x128(%rbp),%xmm0
ff
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x98(%rbp)
ff
movsd  -0xa8(%rbp),%xmm0
ff
movsd  %xmm0,-0x120(%rbp)
ff
movsd  0x18(%rbp),%xmm0
call   1040 <cos@plt>
movaps %xmm0,%xmm1
movsd  -0x120(%rbp),%xmm0
ff
addsd  -0x30(%rbp),%xmm1
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0xa0(%rbp)
ff
movsd  -0x18(%rbp),%xmm1
movsd  0x10(%rbp),%xmm0
subsd  -0x8(%rbp),%xmm0
movsd  -0x40(%rbp),%xmm2
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x80(%rbp)
movsd  -0x10(%rbp),%xmm1
movsd  0x10(%rbp),%xmm0
subsd  -0x8(%rbp),%xmm0
movsd  -0x38(%rbp),%xmm2
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0x78(%rbp)
movsd  -0x78(%rbp),%xmm0
call   1040 <cos@plt>
movsd  %xmm0,-0xf0(%rbp)
ff
movsd  -0x78(%rbp),%xmm0
call   1030 <sin@plt>
movsd  %xmm0,-0xf8(%rbp)
ff
movsd  -0x80(%rbp),%xmm0
call   1040 <cos@plt>
movsd  %xmm0,-0xe0(%rbp)
ff
movsd  -0x80(%rbp),%xmm0
call   1030 <sin@plt>
movsd  %xmm0,-0xe8(%rbp)
ff
movsd  -0x28(%rbp),%xmm0
call   1040 <cos@plt>
movsd  %xmm0,-0x100(%rbp)
ff
movsd  -0x28(%rbp),%xmm0
call   1030 <sin@plt>
movsd  %xmm0,-0x108(%rbp)
ff
movsd  -0xe0(%rbp),%xmm0
ff
movsd  -0xf0(%rbp),%xmm2
ff
movsd  -0xe8(%rbp),%xmm1
ff
mulsd  -0xf8(%rbp),%xmm1
ff
mulsd  -0x100(%rbp),%xmm1
ff
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xb0(%rbp)
ff
movsd  -0xe0(%rbp),%xmm0
ff
movsd  -0xf8(%rbp),%xmm2
ff
movsd  -0xe8(%rbp),%xmm1
ff
mulsd  -0xf0(%rbp),%xmm1
ff
mulsd  -0x100(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xc0(%rbp)
ff
movsd  -0xe8(%rbp),%xmm0
ff
mulsd  -0x108(%rbp),%xmm0
ff
movsd  %xmm0,-0xd0(%rbp)
ff
movsd  -0xe8(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  -0xf0(%rbp),%xmm2
ff
movsd  -0xe0(%rbp),%xmm1
ff
mulsd  -0xf8(%rbp),%xmm1
ff
mulsd  -0x100(%rbp),%xmm1
ff
movq   %xmm1,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm1
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xb8(%rbp)
ff
movsd  -0xe8(%rbp),%xmm0
ff
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  -0xf8(%rbp),%xmm2
ff
movsd  -0xe0(%rbp),%xmm1
ff
mulsd  -0xf0(%rbp),%xmm1
ff
mulsd  -0x100(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
movsd  %xmm0,-0xc8(%rbp)
ff
movsd  -0xe0(%rbp),%xmm0
ff
mulsd  -0x108(%rbp),%xmm0
ff
movsd  %xmm0,-0xd8(%rbp)
ff
movsd  -0xb0(%rbp),%xmm0
ff
movsd  -0x88(%rbp),%xmm2
ff
movsd  -0xb8(%rbp),%xmm1
ff
mulsd  -0x90(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x48(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0xc0(%rbp),%xmm0
ff
movsd  -0x88(%rbp),%xmm2
ff
movsd  -0xc8(%rbp),%xmm1
ff
mulsd  -0x90(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x50(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0xd0(%rbp),%xmm0
ff
movsd  -0x88(%rbp),%xmm2
ff
movsd  -0xd8(%rbp),%xmm1
ff
mulsd  -0x90(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x58(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0xb0(%rbp),%xmm0
ff
movsd  -0x98(%rbp),%xmm2
ff
movsd  -0xb8(%rbp),%xmm1
ff
mulsd  -0xa0(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x68(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0xc0(%rbp),%xmm0
ff
movsd  -0x98(%rbp),%xmm2
ff
movsd  -0xc8(%rbp),%xmm1
ff
mulsd  -0xa0(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    -0x70(%rbp),%rax
movsd  %xmm0,(%rax)
movsd  -0xd0(%rbp),%xmm0
ff
movsd  -0x98(%rbp),%xmm2
ff
movsd  -0xd8(%rbp),%xmm1
ff
mulsd  -0xa0(%rbp),%xmm1
ff
mulsd  %xmm2,%xmm0
addsd  %xmm1,%xmm0
mov    0x20(%rbp),%rax
movsd  %xmm0,(%rax)
add    $0x140,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<GetSatPosition>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x88,%rsp
mov    %r9,%r14
mov    %r8,%r15
mov    %rcx,%rbp
mov    %rdx,%r12
mov    %rsi,%r13
mov    %rdi,%rbx
movsd  %xmm7,0x8(%rsp)
movsd  %xmm6,0x28(%rsp)
movsd  %xmm5,0x18(%rsp)
movsd  %xmm4,0x58(%rsp)
movsd  %xmm2,0x20(%rsp)
movsd  %xmm1,0x10(%rsp)
movsd  %xmm0,0x60(%rsp)
movsd  0xc8(%rsp),%xmm0
movapd %xmm5,%xmm2
mulsd  %xmm5,%xmm2
movsd  0xe6a(%rip),%xmm1
subsd  %xmm2,%xmm1
mulsd  %xmm3,%xmm1
movsd  %xmm1,0x40(%rsp)
call   1040 <cos@plt>
mulsd  0x18(%rsp),%xmm0
addsd  0xe49(%rip),%xmm0
movsd  0x40(%rsp),%xmm1
divsd  %xmm0,%xmm1
movsd  0xe3f(%rip),%xmm0
maxsd  %xmm1,%xmm0
movsd  %xmm0,0x38(%rsp)
movsd  %xmm0,0x0(%rbp)
movsd  0xc8(%rsp),%xmm0
call   1040 <cos@plt>
mulsd  0x38(%rsp),%xmm0
movsd  %xmm0,0x38(%rsp)
movsd  0x0(%rbp),%xmm0
movsd  %xmm0,0x30(%rsp)
movsd  0xc8(%rsp),%xmm0
call   1030 <sin@plt>
mulsd  0x30(%rsp),%xmm0
movsd  %xmm0,0x30(%rsp)
movsd  0xdf1(%rip),%xmm0
divsd  0x40(%rsp),%xmm0
xorpd  %xmm1,%xmm1
ucomisd %xmm1,%xmm0
jb     1235 <GetSatPosition+0x105>
sqrtsd %xmm0,%xmm0
jmp    123a <GetSatPosition+0x10a>
call   1050 <sqrt@plt>
movapd %xmm0,0x70(%rsp)
xorpd  0xdd8(%rip),%xmm0
movapd %xmm0,0x40(%rsp)
movsd  0xc8(%rsp),%xmm0
call   1030 <sin@plt>
mulsd  0x40(%rsp),%xmm0
movsd  %xmm0,0x40(%rsp)
movsd  0xc8(%rsp),%xmm0
call   1040 <cos@plt>
addsd  0x18(%rsp),%xmm0
mulsd  0x70(%rsp),%xmm0
movsd  %xmm0,0x18(%rsp)
movsd  0xc0(%rsp),%xmm2
subsd  0x60(%rsp),%xmm2
movsd  0x8(%rsp),%xmm1
mulsd  %xmm2,%xmm1
addsd  0x20(%rsp),%xmm1
movsd  %xmm1,0x8(%rsp)
mulsd  0x28(%rsp),%xmm2
movsd  0x10(%rsp),%xmm0
subsd  %xmm2,%xmm0
movsd  %xmm0,0x10(%rsp)
call   1040 <cos@plt>
movsd  %xmm0,0x28(%rsp)
movsd  0x10(%rsp),%xmm0
call   1030 <sin@plt>
movsd  %xmm0,0x10(%rsp)
movsd  0x8(%rsp),%xmm0
call   1040 <cos@plt>
movsd  %xmm0,0x20(%rsp)
movsd  0x8(%rsp),%xmm0
call   1030 <sin@plt>
movaps %xmm0,0x60(%rsp)
movsd  0x58(%rsp),%xmm0
call   1040 <cos@plt>
movsd  %xmm0,0x8(%rsp)
movsd  0x58(%rsp),%xmm0
call   1030 <sin@plt>
movapd 0xcfc(%rip),%xmm4
movapd 0x60(%rsp),%xmm1
xorpd  %xmm1,%xmm4
movapd %xmm1,%xmm3
movapd %xmm1,%xmm6
movsd  0x10(%rsp),%xmm8
mulsd  %xmm8,%xmm3
movsd  0x20(%rsp),%xmm9
movapd %xmm9,%xmm1
movsd  0x28(%rsp),%xmm7
mulsd  %xmm7,%xmm1
movapd %xmm1,%xmm2
movsd  0x8(%rsp),%xmm5
mulsd  %xmm5,%xmm1
subsd  %xmm3,%xmm1
mulsd  %xmm5,%xmm3
subsd  %xmm3,%xmm2
movapd %xmm4,%xmm3
mulsd  %xmm7,%xmm3
mulsd  %xmm6,%xmm7
mulsd  %xmm5,%xmm7
movapd %xmm8,%xmm4
mulsd  %xmm9,%xmm4
addsd  %xmm4,%xmm7
mulsd  %xmm0,%xmm6
mulsd  %xmm5,%xmm4
subsd  %xmm4,%xmm3
mulsd  %xmm0,%xmm9
movsd  0x30(%rsp),%xmm5
movapd %xmm5,%xmm0
mulsd  %xmm3,%xmm0
movapd %xmm3,%xmm8
movapd %xmm2,%xmm3
movsd  0x38(%rsp),%xmm4
mulsd  %xmm4,%xmm3
addsd  %xmm0,%xmm3
movsd  %xmm3,(%rbx)
movapd %xmm5,%xmm0
mulsd  %xmm1,%xmm0
movapd %xmm7,%xmm3
mulsd  %xmm4,%xmm3
addsd  %xmm0,%xmm3
movsd  %xmm3,0x0(%r13)
mulsd  %xmm9,%xmm5
mulsd  %xmm6,%xmm4
addsd  %xmm5,%xmm4
movsd  %xmm4,(%r12)
movsd  0x18(%rsp),%xmm3
mulsd  %xmm3,%xmm8
movsd  0x40(%rsp),%xmm0
mulsd  %xmm0,%xmm2
addsd  %xmm8,%xmm2
movsd  %xmm2,(%r15)
mulsd  %xmm3,%xmm1
movapd %xmm7,%xmm2
mulsd  %xmm0,%xmm2
addsd  %xmm1,%xmm2
movsd  %xmm2,(%r14)
movapd %xmm9,%xmm1
mulsd  %xmm3,%xmm1
mulsd  %xmm0,%xmm6
addsd  %xmm1,%xmm6
mov    0xd0(%rsp),%rax
movsd  %xmm6,(%rax)
add    $0x88,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

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

LLVM IR (-O2):
define void @GetSatPosition(double %0, double %1, double %2, double %3, double %4, double %5, double %6, double %7, double %8, double %9, double* nocapture writeonly %10, double* nocapture writeonly %11, double* nocapture writeonly %12, double* nocapture %13, double* nocapture writeonly %14, double* nocapture writeonly %15, double* nocapture writeonly %16) {
%18 = fneg double %5
%19 = tail call double @llvm.fmuladd.f64(double %18, double %5, double 1.000000e+00)
%20 = fmul double %19, %3
%21 = tail call double @cos(double %9)
%22 = tail call double @llvm.fmuladd.f64(double %5, double %21, double 1.000000e+00)
%23 = fdiv double %20, %22
%24 = fcmp ole double %23, 6.378160e+03
%25 = select i1 %24, double 6.378160e+03, double %23
store double %25, double* %13
%26 = tail call double @cos(double %9)
%27 = fmul double %26, %25
%28 = load double, double* %13
%29 = tail call double @sin(double %9)
%30 = fmul double %28, %29
%31 = fdiv double 3.986000e+05, %20
%32 = tail call double @sqrt(double %31)
%33 = fneg double %32
%34 = tail call double @sin(double %9)
%35 = fmul double %34, %33
%36 = tail call double @cos(double %9)
%37 = fadd double %36, %5
%38 = fmul double %32, %37
%39 = fsub double %8, %0
%40 = tail call double @llvm.fmuladd.f64(double %39, double %7, double %2)
%41 = fneg double %39
%42 = tail call double @llvm.fmuladd.f64(double %41, double %6, double %1)
%43 = tail call double @cos(double %42)
%44 = tail call double @sin(double %42)
%45 = tail call double @cos(double %40)
%46 = tail call double @sin(double %40)
%47 = tail call double @cos(double %4)
%48 = tail call double @sin(double %4)
%49 = fneg double %46
%50 = fmul double %44, %49
%51 = fmul double %50, %47
%52 = tail call double @llvm.fmuladd.f64(double %45, double %43, double %51)
%53 = fmul double %43, %46
%54 = fmul double %53, %47
%55 = tail call double @llvm.fmuladd.f64(double %45, double %44, double %54)
%56 = fmul double %46, %48
%57 = fneg double %45
%58 = fmul double %44, %57
%59 = fmul double %58, %47
%60 = tail call double @llvm.fmuladd.f64(double %49, double %43, double %59)
%61 = fmul double %43, %45
%62 = fmul double %61, %47
%63 = tail call double @llvm.fmuladd.f64(double %49, double %44, double %62)
%64 = fmul double %45, %48
%65 = fmul double %30, %60
%66 = tail call double @llvm.fmuladd.f64(double %52, double %27, double %65)
store double %66, double* %10
%67 = fmul double %30, %63
%68 = tail call double @llvm.fmuladd.f64(double %55, double %27, double %67)
store double %68, double* %11
%69 = fmul double %30, %64
%70 = tail call double @llvm.fmuladd.f64(double %56, double %27, double %69)
store double %70, double* %12
%71 = fmul double %38, %60
%72 = tail call double @llvm.fmuladd.f64(double %52, double %35, double %71)
store double %72, double* %14
%73 = fmul double %38, %63
%74 = tail call double @llvm.fmuladd.f64(double %55, double %35, double %73)
store double %74, double* %15
%75 = fmul double %38, %64
%76 = tail call double @llvm.fmuladd.f64(double %56, double %35, double %75)
store double %76, double* %16
ret void
}