LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Bonne::ProjectSimple(double, double, double&, double&) const
bool Bonne::ProjectSimple(double x, double y, 
			  double& phi, double& lambda) const
{
  bool result = false;
  double rho = sqrt(sqr(x) + sqr(cotp - y));
  if (p > 0) {
    phi = cotp + p - rho;
    lambda = rho * atan2(x, cotp - y)/cos(phi);
  } else if (p < 0) {
    phi = cotp + p + rho;
    lambda = rho * atan2(x, y - cotp)/cos(phi);
  } else {
    // Degenerate case - the sinusoidal projection
    phi = y;
    lambda = x/cos(phi);
  }
  if (phi >= -piovertwo && phi <= +piovertwo &&
      lambda >= -pi && lambda <= pi) {
    result = true;
  }
  return result;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdx, %r14
movq %rsi, %rbx
movapd %xmm1, %xmm3
movapd %xmm0, %xmm2
movq %rdi, %r15
movapd %xmm0, %xmm1
mulsd %xmm0, %xmm1
movsd 0xc8(%rdi), %xmm0
subsd %xmm3, %xmm0
mulsd %xmm0, %xmm0
addsd %xmm1, %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jb 0x7c4a
sqrtsd %xmm0, %xmm4
jmp 0x7c6d
movapd %xmm2, (%rsp)
movsd %xmm3, 0x18(%rsp)
callq 0x4190
xorpd %xmm1, %xmm1
movsd 0x18(%rsp), %xmm3
movapd (%rsp), %xmm2
movapd %xmm0, %xmm4
movsd 0xc0(%r15), %xmm0
ucomisd %xmm1, %xmm0
jbe 0x7ca0
addsd 0xc8(%r15), %xmm0
subsd %xmm4, %xmm0
movsd %xmm0, (%rbx)
movsd 0xc8(%r15), %xmm1
subsd %xmm3, %xmm1
movapd %xmm2, %xmm0
jmp 0x7cc8
ucomisd %xmm0, %xmm1
jbe 0x7ce2
addsd 0xc8(%r15), %xmm0
addsd %xmm4, %xmm0
movsd %xmm0, (%rbx)
subsd 0xc8(%r15), %xmm3
movapd %xmm2, %xmm0
movapd %xmm3, %xmm1
movsd %xmm4, (%rsp)
callq 0x4050
mulsd (%rsp), %xmm0
movapd %xmm0, (%rsp)
movsd (%rbx), %xmm3
jmp 0x7ceb
movsd %xmm3, (%rbx)
movapd %xmm2, (%rsp)
movapd %xmm3, %xmm0
callq 0x4380
movapd (%rsp), %xmm2
divsd %xmm0, %xmm2
movsd %xmm2, (%r14)
movsd (%rbx), %xmm0
movapd 0x56f2(%rip), %xmm1     # 0xd400
andpd %xmm1, %xmm0
andpd %xmm1, %xmm2
movsd 0x52ea(%rip), %xmm1     # 0xd008
cmplepd %xmm1, %xmm2
movsd 0x52f5(%rip), %xmm1     # 0xd020
cmplepd %xmm1, %xmm0
andpd %xmm2, %xmm0
movd %xmm0, %eax
andb $0x1, %al
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Bonne::ProjectInvSimple(double, double, double&, double&) const
bool Bonne::ProjectInvSimple(double phi, double lambda, double& x, double& y) const
{
  if (p == 0.0) {
    x = lambda * cos(phi);
    y = phi;
  } else {
    double rho = cotp + p - phi;
    double e = lambda * cos(phi)/rho;
    x = rho * sin(e);
    y = cotp - rho * cos(e);
  }
  return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdx, %rbx
movq %rsi, %r14
movsd %xmm1, 0x8(%rsp)
movsd 0xc0(%rdi), %xmm2
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm2
jne 0x7d8b
jp 0x7d8b
movsd %xmm0, 0x18(%rsp)
callq 0x4380
movsd 0x18(%rsp), %xmm1
mulsd 0x8(%rsp), %xmm0
movsd %xmm0, (%r14)
jmp 0x7df1
movq %rdi, %r15
addsd 0xc8(%rdi), %xmm2
subsd %xmm0, %xmm2
movsd %xmm2, 0x10(%rsp)
callq 0x4380
mulsd 0x8(%rsp), %xmm0
divsd 0x10(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
callq 0x4070
mulsd 0x10(%rsp), %xmm0
movsd %xmm0, (%r14)
movsd 0xc8(%r15), %xmm0
movsd %xmm0, 0x18(%rsp)
movsd 0x8(%rsp), %xmm0
callq 0x4380
movsd 0x18(%rsp), %xmm1
mulsd 0x10(%rsp), %xmm0
subsd %xmm0, %xmm1
movsd %xmm1, (%rbx)
movb $0x1, %al
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Perspective::Init(TransformParams const&)
void Perspective::Init(const TransformParams& params) 
{
  Transform::Init(params);
  vx = params.x; vy = params.y; vz = params.z;
  rx = vx; ry = vy; rz = vz;
  m.Apply(rx,ry,rz);
  scalefactor = (vx + 1) * tan(params.aw/2);
  iscalefactor = 1/scalefactor;

  a = params.ox;
  b = params.oy;
  c = params.oz;
  a2 = sqr(a);
  b2 = sqr(b);
  c2 = sqr(c);
  ia2 = 1/a2;
  ib2 = 1/b2;
  ic2 = 1/c2;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
callq 0x5c62
movsd 0x48(%r14), %xmm0
movsd %xmm0, 0xd0(%rbx)
movsd 0x50(%r14), %xmm1
movsd %xmm1, 0xd8(%rbx)
movsd 0x58(%r14), %xmm2
movsd %xmm2, 0xe0(%rbx)
leaq 0xe8(%rbx), %rsi
movsd %xmm0, 0xe8(%rbx)
leaq 0xf0(%rbx), %rdx
movsd %xmm1, 0xf0(%rbx)
leaq 0xf8(%rbx), %rcx
movsd %xmm2, 0xf8(%rbx)
leaq 0x8(%rbx), %rdi
callq 0x5894
movsd 0xd0(%rbx), %xmm0
addsd 0x51c7(%rip), %xmm0     # 0xd048
movsd %xmm0, (%rsp)
movsd 0x40(%r14), %xmm0
mulsd 0x55a4(%rip), %xmm0     # 0xd438
callq 0x4110
mulsd (%rsp), %xmm0
movsd %xmm0, 0xc0(%rbx)
movsd 0x519a(%rip), %xmm4     # 0xd048
movapd %xmm4, %xmm1
divsd %xmm0, %xmm1
movsd %xmm1, 0xc8(%rbx)
movsd 0x60(%r14), %xmm0
movsd %xmm0, 0x100(%rbx)
movsd 0x68(%r14), %xmm1
movsd %xmm1, 0x108(%rbx)
movsd 0x70(%r14), %xmm2
movsd %xmm2, 0x110(%rbx)
mulsd %xmm0, %xmm0
movsd %xmm0, 0x118(%rbx)
mulsd %xmm1, %xmm1
movsd %xmm1, 0x120(%rbx)
mulsd %xmm2, %xmm2
movsd %xmm2, 0x128(%rbx)
movapd %xmm4, %xmm3
divsd %xmm0, %xmm3
movsd %xmm3, 0x130(%rbx)
movapd %xmm4, %xmm3
movapd %xmm4, %xmm0
divsd %xmm1, %xmm0
movsd %xmm0, 0x138(%rbx)
divsd %xmm2, %xmm3
movsd %xmm3, 0x140(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: CylindricalTransform::AdjustSize(int&, int&, TransformParams&)
void CylindricalTransform::AdjustSize (int& w, int& h, 
				       TransformParams& params)
{
  if (params.scale < 1.0) {
    w = int(w * params.scale);
    params.scale = 1.0;     
  }
  // If a parallel has been given, check it's valid
  if (params.p < 0 || params.p >= piovertwo) {
    error ("Invalid parallel");
  }
  double h0 = GetMaxHeight(params);
  if (h0 > 0.0) { // Return <= 0 for don't adjust
    int newh = int(h0 * w * params.scale / pi);
    if (newh < h) { h = newh; };
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %r14
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r12
movsd 0x28(%rcx), %xmm0
movsd 0x4a04(%rip), %xmm1     # 0xd048
ucomisd %xmm0, %xmm1
jbe 0x866b
xorps %xmm1, %xmm1
cvtsi2sdl (%r15), %xmm1
mulsd %xmm1, %xmm0
cvttsd2si %xmm0, %eax
movl %eax, (%r15)
movabsq $0x3ff0000000000000, %rax # imm = 0x3FF0000000000000
movq %rax, 0x28(%r14)
movsd 0x80(%r14), %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm0, %xmm1
ja 0x8688
ucomisd 0x499a(%rip), %xmm0     # 0xd020
jb 0x8694
leaq 0x4ee0(%rip), %rdi      # 0xd56f
callq 0xa8ec
movq (%r12), %rax
movq %r12, %rdi
movq %r14, %rsi
callq *0x60(%rax)
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jbe 0x86f6
xorps %xmm1, %xmm1
cvtsi2sdl (%r15), %xmm1
mulsd %xmm1, %xmm0
mulsd 0x28(%r14), %xmm0
movsd %xmm0, 0x10(%rsp)
fldl 0x10(%rsp)
fdivl 0x493b(%rip)            # 0xd008
fnstcw 0x8(%rsp)
movzwl 0x8(%rsp), %eax
orl $0xc00, %eax            # imm = 0xC00
movw %ax, 0xa(%rsp)
fldcw 0xa(%rsp)
fistpl 0xc(%rsp)
fldcw 0x8(%rsp)
movl 0xc(%rsp), %eax
cmpl %eax, (%rbx)
jle 0x86f6
movl %eax, (%rbx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Sinusoidal2::CalcParams(double, double, double&, double&)
void Sinusoidal2::CalcParams(double a, double phi, double& k, double& b)
{
  // Find the t value for phi
  double t1 = 0;
  double t2 = pi/2.0;
  double epsilon = 1e-6;
  double k0 = 0.0, b0 = 0.0;
  while (fabs(t2 - t1) > epsilon) {
    double t0 = (t1 + t2)/2.0;
    k0 = sqr((cos(t0) + a) / ((a+1)*cos(phi)));
    b0 = (k0 * (a+1))/(1 + a * pi / 2.0);
    double p0 = b0 * sin(t0) + a * t0 - k0 * (a+1) * sin(phi);
    if (p0 <= 0.0) t1 = t0;
    else t2 = t0;
  }
  k = k0; b = b0;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x98, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movsd %xmm1, 0x18(%rsp)
movsd 0x48f0(%rip), %xmm1     # 0xd048
addsd %xmm0, %xmm1
movsd %xmm1, 0x30(%rsp)
movsd %xmm0, 0x10(%rsp)
movsd %xmm0, 0x58(%rsp)
fldl 0x58(%rsp)
fmull 0x4890(%rip)            # 0xd008
fmuls 0x4d52(%rip)            # 0xd4d0
fld1
faddp %st, %st(1)
fstpt 0x64(%rsp)
movsd 0x4892(%rip), %xmm0     # 0xd020
xorpd %xmm2, %xmm2
movsd %xmm2, 0x40(%rsp)
movapd %xmm0, 0x80(%rsp)
addsd %xmm2, %xmm0
mulsd 0x4c8b(%rip), %xmm0     # 0xd438
movapd %xmm0, 0x20(%rsp)
callq 0x4380
addsd 0x10(%rsp), %xmm0
movsd %xmm0, (%rsp)
movsd 0x18(%rsp), %xmm0
callq 0x4380
movsd 0x30(%rsp), %xmm1
mulsd %xmm1, %xmm0
movsd (%rsp), %xmm2
divsd %xmm0, %xmm2
mulsd %xmm2, %xmm2
movsd %xmm2, (%rsp)
mulsd %xmm2, %xmm1
movsd %xmm1, 0x38(%rsp)
movsd %xmm1, 0x50(%rsp)
fldt 0x64(%rsp)
fdivrl 0x50(%rsp)
fstpl 0x48(%rsp)
movsd 0x48(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
movapd 0x20(%rsp), %xmm0
callq 0x4070
movapd 0x20(%rsp), %xmm1
mulsd 0x10(%rsp), %xmm1
mulsd 0x8(%rsp), %xmm0
addsd %xmm1, %xmm0
movapd %xmm0, 0x70(%rsp)
movsd 0x18(%rsp), %xmm0
callq 0x4070
movapd 0x70(%rsp), %xmm3
movsd 0x40(%rsp), %xmm2
xorpd %xmm1, %xmm1
mulsd 0x38(%rsp), %xmm0
subsd %xmm0, %xmm3
movapd 0x20(%rsp), %xmm0
ucomisd %xmm3, %xmm1
jb 0x886e
movapd %xmm0, %xmm2
cmpnlesd %xmm1, %xmm3
andpd %xmm3, %xmm0
andnpd 0x80(%rsp), %xmm3
orpd %xmm0, %xmm3
movapd %xmm3, %xmm0
subsd %xmm2, %xmm0
andpd 0x4b6c(%rip), %xmm0     # 0xd400
ucomisd 0x4be4(%rip), %xmm0     # 0xd480
movapd %xmm3, %xmm0
ja 0x8792
movsd (%rsp), %xmm0
movsd %xmm0, (%r14)
movsd 0x8(%rsp), %xmm0
movsd %xmm0, (%rbx)
addq $0x98, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Sinusoidal2::GetLat(double)
double Sinusoidal2::GetLat(double y)
{
  double t = y/b;
  double phi = asin((b * (sin(t) + a * t)) / (k * (a+1)));
  m = (a+1) / (cos(t) + a);
  return phi;
}

// Assembly:
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
movsd 0xd0(%rdi), %xmm1
movsd %xmm1, 0x8(%rsp)
divsd %xmm1, %xmm0
movsd %xmm0, 0x10(%rsp)
callq 0x4070
movsd 0xc8(%rbx), %xmm1
movapd %xmm1, %xmm2
mulsd 0x10(%rsp), %xmm2
addsd %xmm2, %xmm0
mulsd 0x8(%rsp), %xmm0
movsd 0x46f7(%rip), %xmm2     # 0xd048
movsd %xmm2, 0x8(%rsp)
addsd %xmm2, %xmm1
mulsd 0xd8(%rbx), %xmm1
divsd %xmm1, %xmm0
callq 0x4300
movsd %xmm0, 0x18(%rsp)
movsd 0x8(%rsp), %xmm0
addsd 0xc8(%rbx), %xmm0
movsd %xmm0, 0x8(%rsp)
movsd 0x10(%rsp), %xmm0
callq 0x4380
addsd 0xc8(%rbx), %xmm0
movsd 0x8(%rsp), %xmm1
divsd %xmm0, %xmm1
movsd %xmm1, 0xe0(%rbx)
movsd 0x18(%rsp), %xmm0
addq $0x20, %rsp
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Sinusoidal2::GetXY(double, double, double&, double&) const
bool Sinusoidal2::GetXY(double phi, double lambda, double& x, double& y) const
{
  bool result = false;
  Sinusoidal2Equation equation;
  equation.b = b; equation.a = a; equation.k = k; equation.sinphi = sin(phi);
  double t = 0.0;
  if (equation.FindRoot(-pi/2, pi/2, 1e-5, t)) {
    y = b * t;
    x = lambda * (cos(t) + a) / (a+1);
    result = true;
  }
  return result;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rdx, %r15
movq %rsi, %rbx
movsd %xmm1, 0x8(%rsp)
movq %rdi, %r14
leaq 0xa00c(%rip), %rax      # 0x129f0
leaq 0x18(%rsp), %r12
movq %rax, (%r12)
movsd 0xd0(%rdi), %xmm1
movsd %xmm1, 0x8(%r12)
movsd 0xc8(%rdi), %xmm1
movsd %xmm1, 0x10(%r12)
movsd 0xd8(%rdi), %xmm1
movsd %xmm1, 0x18(%r12)
callq 0x4070
movsd %xmm0, 0x20(%r12)
leaq 0x10(%rsp), %rsi
movq $0x0, (%rsi)
movsd 0x45ee(%rip), %xmm0     # 0xd028
movsd 0x45de(%rip), %xmm1     # 0xd020
movsd 0x4a3e(%rip), %xmm2     # 0xd488
movq %r12, %rdi
callq 0x9fac
movl %eax, %ebp
testb %al, %al
je 0x8a98
movsd 0x10(%rsp), %xmm0
movsd 0xd0(%r14), %xmm1
mulsd %xmm0, %xmm1
movsd %xmm1, (%r15)
callq 0x4380
movsd 0xc8(%r14), %xmm1
addsd %xmm1, %xmm0
mulsd 0x8(%rsp), %xmm0
addsd 0x45b8(%rip), %xmm1     # 0xd048
divsd %xmm1, %xmm0
movsd %xmm0, (%rbx)
movl %ebp, %eax
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Mollweide::CalcParams(double, double&)
void Mollweide::CalcParams(double phi, double& a)
{
  // Now we need to find a suitable t
  // Good old binary search - note we cavalierly fail to check if there's
  // a solution in the interval. Hell, we're going to terminate with something.
  double t = 0;     // phi = 0;
  double t1 = pi/2;  // phi = pi/2;
  double b = 0.5 * pi * sin(phi);
  double epsilon = 1e-6;
  while (fabs(t1 - t) > epsilon) {
    double t2 = (t + t1)/2.0;
    double p = t2 + 0.5 * sin (2 * t2) - b;
    if (p <= 0.0) t = t2; 
    else t1 = t2;
  }
  // t is our selected value
  a = pi / (4 * sqr(cos (t)/cos(phi)));
}

// Assembly:
pushq %rbx
subq $0x50, %rsp
movq %rdi, %rbx
movsd %xmm0, 0x8(%rsp)
callq 0x4070
movsd %xmm0, 0x28(%rsp)
fldl 0x28(%rsp)
fmull 0x4529(%rip)            # 0xd020
fstpl 0x20(%rsp)
movsd 0x451d(%rip), %xmm1     # 0xd020
movsd 0x20(%rsp), %xmm0
movsd %xmm0, 0x10(%rsp)
xorpd %xmm2, %xmm2
movsd %xmm2, (%rsp)
movapd %xmm1, 0x40(%rsp)
addsd %xmm2, %xmm1
movsd 0x490e(%rip), %xmm0     # 0xd438
mulsd %xmm0, %xmm1
movapd %xmm1, 0x30(%rsp)
movapd %xmm1, %xmm0
addsd %xmm1, %xmm0
callq 0x4070
movapd 0x30(%rsp), %xmm3
movsd (%rsp), %xmm2
xorpd %xmm1, %xmm1
mulsd 0x48e0(%rip), %xmm0     # 0xd438
addsd %xmm3, %xmm0
subsd 0x10(%rsp), %xmm0
ucomisd %xmm0, %xmm1
jb 0x8b6c
movapd %xmm3, %xmm2
cmpnlesd %xmm1, %xmm0
andpd %xmm0, %xmm3
andnpd 0x40(%rsp), %xmm0
orpd %xmm3, %xmm0
movapd %xmm0, %xmm1
subsd %xmm2, %xmm1
andpd 0x4871(%rip), %xmm1     # 0xd400
ucomisd 0x48e9(%rip), %xmm1     # 0xd480
movapd %xmm0, %xmm1
ja 0x8b13
movapd %xmm2, %xmm0
callq 0x4380
movsd %xmm0, (%rsp)
movsd 0x8(%rsp), %xmm0
callq 0x4380
movsd (%rsp), %xmm1
divsd %xmm0, %xmm1
mulsd %xmm1, %xmm1
mulsd 0x48c1(%rip), %xmm1     # 0xd490
movsd %xmm1, 0x18(%rsp)
fldl 0x442d(%rip)            # 0xd008
fdivl 0x18(%rsp)
fstpl (%rbx)
addq $0x50, %rsp
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Mollweide::GetLat(double)
double Mollweide::GetLat(double y)
{
  // find t;
  double t = asin(y*a);
  m = 1/cos(t);
  return asin((t + 0.5 * sin(2 * t)) * twooverpi);
}

// Assembly:
pushq %rbx
subq $0x30, %rsp
movq %rdi, %rbx
mulsd 0xc8(%rdi), %xmm0
callq 0x4300
movsd %xmm0, 0x18(%rsp)
callq 0x4380
movsd 0x4416(%rip), %xmm1     # 0xd048
divsd %xmm0, %xmm1
movsd %xmm1, 0xd0(%rbx)
movsd 0x18(%rsp), %xmm0
addsd %xmm0, %xmm0
callq 0x4070
mulsd 0x47e3(%rip), %xmm0     # 0xd438
addsd 0x18(%rsp), %xmm0
movsd %xmm0, 0x28(%rsp)
fldt 0x47a9(%rip)            # 0xd410
fmull 0x28(%rsp)
fstpt (%rsp)
callq 0x42f0
fstpl 0x20(%rsp)
movsd 0x20(%rsp), %xmm0
addq $0x30, %rsp
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Mollweide::GetXY(double, double, double&, double&) const
bool Mollweide::GetXY(double phi, double lambda, double& x, double& y) const
{
  bool result = false;
  MollweideEquation equation;
  equation.sinphi = sin(phi);
  double t = 0.0;
  if (equation.FindRoot(-pi/2, pi/2, 1e-5, t)) {
    y = sin(t)/a;
    x = lambda * cos(t);
    result = true;
  }
  return result;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movq %rdx, %r14
movq %rsi, %rbx
movsd %xmm1, 0x8(%rsp)
movq %rdi, %r15
leaq 0x9d90(%rip), %rax      # 0x12a40
leaq 0x10(%rsp), %r12
movq %rax, (%r12)
callq 0x4070
movsd %xmm0, 0x8(%r12)
movq %rsp, %rsi
movq $0x0, (%rsi)
movsd 0x4351(%rip), %xmm0     # 0xd028
movsd 0x4341(%rip), %xmm1     # 0xd020
movsd 0x47a1(%rip), %xmm2     # 0xd488
movq %r12, %rdi
callq 0x9fac
movl %eax, %ebp
testb %al, %al
je 0x8d21
movsd (%rsp), %xmm0
callq 0x4070
divsd 0xc8(%r15), %xmm0
movsd %xmm0, (%r14)
movsd (%rsp), %xmm0
callq 0x4380
mulsd 0x8(%rsp), %xmm0
movsd %xmm0, (%rbx)
movl %ebp, %eax
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Transform::AddLines(Image&, TransformParams const&) const
void Transform::AddLines (Image& image, const TransformParams& params) const
{
  CmdParams cmdparams;
  cmdparams.color = params.gridcolor;
  cmdparams.gridx = params.gridx;
  cmdparams.gridy = params.gridy;
  DrawGrid(image,params,cmdparams);
  //DrawDial(image,params,cmdparams);
}

// Assembly:
subq $0x28, %rsp
movq %rsp, %rcx
movw $0x0, (%rcx)
movb $0x0, 0x2(%rcx)
movabsq $0xa0000000f, %rax      # imm = 0xA0000000F
movq %rax, 0x4(%rcx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rcx)
movq $0x0, 0x20(%rcx)
movzwl 0xcc(%rdx), %eax
movw %ax, (%rcx)
movb 0xce(%rdx), %al
movb %al, 0x2(%rcx)
movl 0xc4(%rdx), %eax
movl %eax, 0x4(%rcx)
movl 0xc8(%rdx), %eax
movl %eax, 0x8(%rcx)
callq 0x8d8c
addq $0x28, %rsp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Transform::DrawGrid(Image&, TransformParams const&, Transform::CmdParams const&) const
void Transform::DrawGrid (Image& image, 
			  const TransformParams& params,
			  const CmdParams &cmdparams) const
{
  int gridx = cmdparams.gridx;
  int gridy = cmdparams.gridy;
  int gridoff = cmdparams.gridoff;
  double loff = 2*pi*gridoff/360.0;
  int nx = 360/gridx;
  int ny = 180/gridy;
  for (int i = 0; i < nx; i++) {
    LatPlotter latplotter(image, params, *this);
    double lambda = (i - nx/2) * 2 * pi / nx + loff;
    latplotter.lambda = lambda;
    // Omit the last section of the lines of latitude.
    //image.PlotLine(-pi/2+radians(gridy), pi/2-radians(gridy), latplotter, cmdparams.color, 16);
    image.PlotLine(-pi/2, pi/2, latplotter, cmdparams.color, 16);
  }
  LongPlotter longplotter(image, params, *this);
  for (int i = 0; i <= ny; i++) {
    longplotter.phi = (i - ny/2) * pi / ny;
    image.PlotLine(-pi, pi, longplotter, cmdparams.color,16);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rdx, %r12
movq %rsi, %r14
movl $0x168, %eax            # imm = 0x168
xorl %edx, %edx
idivl 0x4(%rcx)
movl %eax, %r15d
movq %rdi, %rbx
movl $0xb4, %eax
xorl %edx, %edx
movq %rcx, 0x8(%rsp)
idivl 0x8(%rcx)
movl %eax, %ebp
testl %r15d, %r15d
jle 0x8e81
movq 0x8(%rsp), %rax
cvttsd2si 0x10(%rax), %eax
movl %eax, 0x20(%rsp)
fildl 0x20(%rsp)
fmull 0x4256(%rip)            # 0xd038
fdivs 0x46ec(%rip)            # 0xd4d4
fstpl 0x60(%rsp)
movsd 0x60(%rsp), %xmm0
movl %r15d, 0x1c(%rsp)
fildl 0x1c(%rsp)
fstpt 0x24(%rsp)
movsd %xmm0, 0x58(%rsp)
fldl 0x58(%rsp)
fstpt 0x6c(%rsp)
movl %r15d, %r13d
andl $-0x2, %r13d
negl %r13d
movq %r14, 0x38(%rsp)
movq %r12, 0x40(%rsp)
movq %rbx, 0x48(%rsp)
leaq 0x9c53(%rip), %rax      # 0x12a80
movq %rax, 0x30(%rsp)
movl %r13d, 0x18(%rsp)
fildl 0x18(%rsp)
fmull 0x41c7(%rip)            # 0xd008
fldt 0x24(%rsp)
fdivrp %st, %st(1)
fldt 0x6c(%rsp)
faddp %st, %st(1)
fstpl 0x50(%rsp)
movq %r14, %rdi
movsd 0x41cc(%rip), %xmm0     # 0xd028
movsd 0x41bc(%rip), %xmm1     # 0xd020
leaq 0x30(%rsp), %rsi
movq 0x8(%rsp), %rdx
movl $0x10, %ecx
callq 0xc31e
addl $0x2, %r13d
decl %r15d
jne 0x8e17
movq %r14, 0x38(%rsp)
movq %r12, 0x40(%rsp)
movq %rbx, 0x48(%rsp)
leaq 0x9c79(%rip), %rax      # 0x12b10
movq %rax, 0x30(%rsp)
movq $0x0, 0x50(%rsp)
testl %ebp, %ebp
movq 0x8(%rsp), %rbx
js 0x8f0d
movl %ebp, %r12d
shrl %r12d
movl %ebp, 0x14(%rsp)
fildl 0x14(%rsp)
fstpt 0x24(%rsp)
incl %ebp
negl %r12d
leaq 0x30(%rsp), %r15
movl %r12d, 0x10(%rsp)
fildl 0x10(%rsp)
fmull 0x412f(%rip)            # 0xd008
fldt 0x24(%rsp)
fdivrp %st, %st(1)
fstpl 0x50(%rsp)
movq %r14, %rdi
movsd 0x4142(%rip), %xmm0     # 0xd030
movsd 0x4112(%rip), %xmm1     # 0xd008
movq %r15, %rsi
movq %rbx, %rdx
movl $0x10, %ecx
callq 0xc31e
incl %r12d
decl %ebp
jne 0x8eca
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Transform::DrawTemporaryHours(Image&, TransformParams const&, Transform::CmdParams const&) const
void Transform::DrawTemporaryHours(Image& image, 
				   const TransformParams& params,
				   const CmdParams &cmdparams) const
{
  TempPlotter tempplotter(image, params, *this);
  tempplotter.phi = cmdparams.dlat;
  tempplotter.lambda = cmdparams.dlon;
  for (int i = 6; i <= 18; i++) {
    tempplotter.time  = i;
    image.PlotLine(-inclination,+inclination,tempplotter,cmdparams.color,4);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rcx, %rbx
movq %rsi, %r14
leaq 0x10(%rsp), %r15
movq %rsi, 0x8(%r15)
movq %rdx, 0x10(%r15)
movq %rdi, 0x18(%r15)
leaq 0x981c(%rip), %rax      # 0x12bd0
movq %rax, (%r15)
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%r15)
movq $0x0, 0x30(%r15)
movsd 0x18(%rcx), %xmm0
movsd %xmm0, 0x28(%r15)
movsd 0x20(%rcx), %xmm0
movsd %xmm0, 0x30(%r15)
movsd 0x40bb(%rip), %xmm0     # 0xd4a0
movl $0xd, %ebp
movsd %xmm0, 0x8(%rsp)
movsd %xmm0, 0x30(%rsp)
movq %r14, %rdi
movsd 0x40a7(%rip), %xmm0     # 0xd4a8
movsd 0x40a7(%rip), %xmm1     # 0xd4b0
movq %r15, %rsi
movq %rbx, %rdx
movl $0x4, %ecx
callq 0xc31e
movsd 0x8(%rsp), %xmm0
addsd 0x3c21(%rip), %xmm0     # 0xd048
decl %ebp
jne 0x93ea
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Transform::DrawLocalHours(Image&, TransformParams const&, Transform::CmdParams const&) const
void Transform::DrawLocalHours (Image& image, 
				const TransformParams& params,
				const CmdParams &cmdparams) const
{
  LatPlotter latplotter(image, params, *this);
  int nx = 24;
  for (int i = 0; i < nx; i++) {
    double lambda = (i - nx/2) * 2 * pi / nx + cmdparams.dlon;
    latplotter.lambda = lambda;
    // Omit the last section of the lines of latitude.
    image.PlotLine(-inclination, +inclination, latplotter, cmdparams.color, 4);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x38, %rsp
movq %rcx, %rbx
movq %rsi, %r14
leaq 0x10(%rsp), %r15
movq %rsi, 0x8(%r15)
movq %rdx, 0x10(%r15)
movq %rdi, 0x18(%r15)
leaq 0x9622(%rip), %rax      # 0x12a80
movq %rax, (%r15)
movq $0x0, 0x20(%r15)
movl $0xffffffe8, %ebp       # imm = 0xFFFFFFE8
movl %ebp, 0xc(%rsp)
fildl 0xc(%rsp)
fmull 0x3b8c(%rip)            # 0xd008
fdivs 0x4056(%rip)            # 0xd4d8
faddl 0x20(%rbx)
fstpl 0x30(%rsp)
movq %r14, %rdi
movsd 0x4014(%rip), %xmm0     # 0xd4a8
movsd 0x4014(%rip), %xmm1     # 0xd4b0
movq %r15, %rsi
movq %rbx, %rdx
movl $0x4, %ecx
callq 0xc31e
addl $0x2, %ebp
cmpl $0x18, %ebp
jne 0x946e
addq $0x38, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Transform::DrawAltitudes(Image&, TransformParams const&, Transform::CmdParams const&) const
void Transform::DrawAltitudes(Image& image, 
			 const TransformParams& params,
			 const CmdParams &cmdparams) const
{
  FooPlotter fooplotter(image,params,*this);
  fooplotter.lambda = cmdparams.dlon;
  fooplotter.phi = cmdparams.dlat;
  for (int i = 10; i <= 80; i += 10) {
    fooplotter.theta = radians(i);
    image.PlotLine(0,twopi,fooplotter,cmdparams.color,16);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rcx, %rbx
movq %rsi, %r14
leaq 0x10(%rsp), %r15
movq %rsi, 0x8(%r15)
movq %rdx, 0x10(%r15)
movq %rdi, 0x18(%r15)
leaq 0x96a8(%rip), %rax      # 0x12b90
movq %rax, (%r15)
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%r15)
movq $0x0, 0x30(%r15)
movsd 0x20(%rcx), %xmm0
movsd %xmm0, 0x28(%r15)
movsd 0x18(%rcx), %xmm0
movsd %xmm0, 0x30(%r15)
flds 0x3fc5(%rip)            # 0xd4dc
xorl %ebp, %ebp
fstpt 0x4(%rsp)
fldt 0x4(%rsp)
fmull 0x3ae1(%rip)            # 0xd008
fdivs 0x3b3f(%rip)            # 0xd06c
fstpl 0x30(%rsp)
xorps %xmm0, %xmm0
movq %r14, %rdi
movsd 0x3af9(%rip), %xmm1     # 0xd038
movq %r15, %rsi
movq %rbx, %rdx
movl $0x10, %ecx
callq 0xc31e
fldt 0x4(%rsp)
fadds 0x3f83(%rip)            # 0xd4dc
addl $0xa, %ebp
cmpl $0x47, %ebp
jb 0x9519
fstp %st(0)
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Transform::DrawAnalemma(Image&, TransformParams const&, Transform::CmdParams const&) const
void Transform::DrawAnalemma (Image& image, 
                              const TransformParams& params,
			      const CmdParams &cmdparams) const
{
  int gridx = cmdparams.gridx;
  AnalemmaPlotter analemmaplotter(image, params, *this);
  int nx = 360/gridx;
  for (int i = 0; i < nx; i++) {
    double time = 2 * pi * (i - nx/2) / nx;
    analemmaplotter.time = time;
    image.PlotLine(0, twopi, analemmaplotter, cmdparams.color,16);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rcx, %rbx
movq %rdx, %rcx
movl $0x168, %eax            # imm = 0x168
xorl %edx, %edx
idivl 0x4(%rbx)
movl %eax, %ebp
movq %rsi, 0x20(%rsp)
movq %rcx, 0x28(%rsp)
movq %rdi, 0x30(%rsp)
leaq 0x95ae(%rip), %rax      # 0x12b50
movq %rax, 0x18(%rsp)
movq $0x0, 0x38(%rsp)
testl %ebp, %ebp
jle 0x960f
movq %rsi, %r14
movl %ebp, %r12d
shrl %r12d
movl %ebp, 0x8(%rsp)
fildl 0x8(%rsp)
fstpt 0xc(%rsp)
negl %r12d
leaq 0x18(%rsp), %r15
movl %r12d, 0x4(%rsp)
fildl 0x4(%rsp)
fmull 0x3a58(%rip)            # 0xd038
fldt 0xc(%rsp)
fdivrp %st, %st(1)
fstpl 0x38(%rsp)
xorps %xmm0, %xmm0
movq %r14, %rdi
movsd 0x3a40(%rip), %xmm1     # 0xd038
movq %r15, %rsi
movq %rbx, %rdx
movl $0x10, %ecx
callq 0xc31e
incl %r12d
decl %ebp
jne 0x95d1
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Transform::DrawTropics(Image&, TransformParams const&, Transform::CmdParams const&) const
void Transform::DrawTropics(Image& image, 
			    const TransformParams& params,
			    const CmdParams &cmdparams) const
{
  LongPlotter longplotter(image, params, *this);
  longplotter.phi = inclination;
  image.PlotLine(-pi, pi, longplotter, cmdparams.color,16);
  longplotter.phi = -inclination;
  image.PlotLine(-pi, pi, longplotter, cmdparams.color,16);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rcx, %rbx
movq %rsi, %r14
leaq 0x8(%rsp), %r15
movq %rsi, 0x8(%r15)
movq %rdx, 0x10(%r15)
movq %rdi, 0x18(%r15)
leaq 0x94cd(%rip), %rax      # 0x12b10
movq %rax, (%r15)
movabsq $0x3fda31a385e77b3a, %rax # imm = 0x3FDA31A385E77B3A
movq %rax, 0x20(%r15)
movsd 0x39d4(%rip), %xmm0     # 0xd030
movsd 0x39a4(%rip), %xmm1     # 0xd008
movq %rsi, %rdi
movq %r15, %rsi
movq %rcx, %rdx
movl $0x10, %ecx
callq 0xc31e
movabsq $-0x4025ce5c7a1884c6, %rax # imm = 0xBFDA31A385E77B3A
movq %rax, 0x20(%r15)
movq %r14, %rdi
movsd 0x39a0(%rip), %xmm0     # 0xd030
movsd 0x3970(%rip), %xmm1     # 0xd008
movq %r15, %rsi
movq %rbx, %rdx
movl $0x10, %ecx
callq 0xc31e
addq $0x30, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Transform::DrawArctics(Image&, TransformParams const&, Transform::CmdParams const&) const
void Transform::DrawArctics(Image& image, 
			    const TransformParams& params,
			    const CmdParams &cmdparams) const
{
  LongPlotter longplotter(image, params, *this);
  longplotter.phi = 0.5*pi-inclination;
  image.PlotLine(-pi, pi, longplotter, cmdparams.color,16);
  longplotter.phi = inclination-0.5*pi;
  image.PlotLine(-pi, pi, longplotter, cmdparams.color,16);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rcx, %rbx
movq %rsi, %r14
leaq 0x8(%rsp), %r15
movq %rsi, 0x8(%r15)
movq %rdx, 0x10(%r15)
movq %rdi, 0x18(%r15)
leaq 0x9437(%rip), %rax      # 0x12b10
movq %rax, (%r15)
movabsq $0x3ff2959272ca4e4a, %rax # imm = 0x3FF2959272CA4E4A
movq %rax, 0x20(%r15)
movsd 0x393e(%rip), %xmm0     # 0xd030
movsd 0x390e(%rip), %xmm1     # 0xd008
movq %rsi, %rdi
movq %r15, %rsi
movq %rcx, %rdx
movl $0x10, %ecx
callq 0xc31e
movabsq $-0x400d6a6d8d35b1b6, %rax # imm = 0xBFF2959272CA4E4A
movq %rax, 0x20(%r15)
movq %r14, %rdi
movsd 0x390a(%rip), %xmm0     # 0xd030
movsd 0x38da(%rip), %xmm1     # 0xd008
movq %r15, %rsi
movq %rbx, %rdx
movl $0x10, %ecx
callq 0xc31e
addq $0x30, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Transform::DrawDateline(Image&, TransformParams const&, Transform::CmdParams const&, double) const
void Transform::DrawDateline (Image& image, 
			      const TransformParams& params,
			      const CmdParams &cmdparams,
			      double day) const
{
  LongPlotter longplotter(image, params, *this);
  // Spring equinox is date 0, and is day 80 of a normal year.
  day = day - 80;
  while (day < 0) day += 365;
  while (day >= 365) day -= 365;
  double date = 2 * pi * day / 365;
  longplotter.phi = sundec(date);
  image.PlotLine(-pi, pi, longplotter, cmdparams.color,16);
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x38, %rsp
movq %rcx, %rbx
movq %rsi, %r14
movq %rsi, 0x18(%rsp)
movq %rdx, 0x20(%rsp)
movq %rdi, 0x28(%rsp)
leaq 0x93a5(%rip), %rax      # 0x12b10
movq %rax, 0x10(%rsp)
addsd 0x3ca8(%rip), %xmm0     # 0xd420
movq $0x0, 0x30(%rsp)
xorpd %xmm1, %xmm1
ucomisd %xmm0, %xmm1
jbe 0x979d
movsd 0x3c95(%rip), %xmm2     # 0xd428
addsd %xmm2, %xmm0
ucomisd %xmm0, %xmm1
ja 0x9793
ucomisd 0x3c83(%rip), %xmm0     # 0xd428
jb 0x97c1
movsd 0x3c81(%rip), %xmm1     # 0xd430
movsd 0x3c71(%rip), %xmm2     # 0xd428
addsd %xmm1, %xmm0
ucomisd %xmm2, %xmm0
jae 0x97b7
movsd %xmm0, 0x8(%rsp)
fldl 0x8(%rsp)
fmull 0x3867(%rip)            # 0xd038
fdivs 0x3cf1(%rip)            # 0xd4c8
fstpl (%rsp)
movsd (%rsp), %xmm0
callq 0xa5e8
leaq 0x10(%rsp), %rsi
movsd %xmm0, 0x20(%rsi)
movsd 0x383a(%rip), %xmm0     # 0xd030
movsd 0x380a(%rip), %xmm1     # 0xd008
movq %r14, %rdi
movq %rbx, %rdx
movl $0x10, %ecx
callq 0xc31e
addq $0x38, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: Transform::DrawDatetime(Image&, TransformParams const&, Transform::CmdParams const&, double) const
void Transform::DrawDatetime (Image& image, 
			      const TransformParams& params,
			      const CmdParams &cmdparams,
			      double day) const
{
  LongPlotter longplotter(image, params, *this);
  // Spring equinox is day 0
  day = day - 80;
  while (day < 0) day += 365;
  while (day >= 365) day -= 365;
  double time = fmod(day, 1.0)-0.5; // Time relative to noon
  double date = 2 * pi * day / 365;
  double phi = sundec(date);
  double eot = equationoftime(date) / (24 * 60 * 60);
  double apparenttime = time + eot; // AT = MT + EOT
  double lambda = -(2 * pi * apparenttime);
  double x,y;
  MapXY(image, params, phi, lambda, x, y); 
  //fprintf(stderr,"%g %g %g %g %g %g\n", day, time,date,eot,phi,lambda);
  image.PlotPoint(x,y,1,cmdparams.color);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rcx, %rbx
movq %rdx, %r15
movq %rsi, %r14
addsd 0x3beb(%rip), %xmm0     # 0xd420
movq %rdi, %r12
xorpd %xmm2, %xmm2
ucomisd %xmm0, %xmm2
jbe 0x9854
movsd 0x3bde(%rip), %xmm1     # 0xd428
addsd %xmm1, %xmm0
ucomisd %xmm0, %xmm2
ja 0x984a
ucomisd 0x3bcc(%rip), %xmm0     # 0xd428
jb 0x9878
movsd 0x3bca(%rip), %xmm2     # 0xd430
movsd 0x3bba(%rip), %xmm1     # 0xd428
addsd %xmm2, %xmm0
ucomisd %xmm1, %xmm0
jae 0x986e
movsd %xmm0, (%rsp)
movsd 0x37c3(%rip), %xmm1     # 0xd048
callq 0x4260
addsd 0x3bc6(%rip), %xmm0     # 0xd458
movsd %xmm0, 0x10(%rsp)
movsd (%rsp), %xmm0
movsd %xmm0, 0x30(%rsp)
fldl 0x30(%rsp)
fmull 0x378b(%rip)            # 0xd038
fdivs 0x3c15(%rip)            # 0xd4c8
fstpl 0x28(%rsp)
movsd 0x28(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
callq 0xa5e8
movsd %xmm0, (%rsp)
movsd 0x8(%rsp), %xmm0
callq 0xa2c6
divsd 0x3bd8(%rip), %xmm0     # 0xd4b8
addsd 0x10(%rsp), %xmm0
movsd %xmm0, 0x20(%rsp)
fldl 0x20(%rsp)
fmull 0x371a(%rip)            # 0xd010
fstpl 0x18(%rsp)
movsd 0x18(%rsp), %xmm1
leaq 0x40(%rsp), %r13
leaq 0x38(%rsp), %rbp
movq %r12, %rdi
movq %r14, %rsi
movq %r15, %rdx
movsd (%rsp), %xmm0
movq %r13, %rcx
movq %rbp, %r8
callq 0x6ab0
movsd (%r13), %xmm0
movsd (%rbp), %xmm1
movq %r14, %rdi
movl $0x1, %esi
movq %rbx, %rdx
callq 0xc22a
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/transform.cpp
// Function: FooPlotter::GetXY(double, double&, double&) const
bool GetXY(double t, double&x, double&y) const
  {
    // Angle up from the pole
    double x0 = cos(t)*cos(theta);
    double y0 = sin(t)*cos(theta);
    double z0 = sin(theta);
    // Now rotate about y axis
    double x1 = sin(phi)*x0 + cos(phi)*z0;
    double y1 = y0;
    double z1 = -cos(phi)*x0 + sin(phi)*z0;
    double phi0 = asin(z1);
    if (phi0 < -inclination || phi0 > inclination) {
      return false;
    } else {
      double lambda0 = atan2(y1,x1);
      return transform.MapXY(image, params, phi0, lambda0+lambda, x, y);
    }
  }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x50, %rsp
movq %rdx, %rbx
movq %rsi, %r14
movsd %xmm0, 0x10(%rsp)
movq %rdi, %r15
callq 0x4380
movsd %xmm0, 0x8(%rsp)
movsd 0x20(%r15), %xmm0
callq 0x4380
mulsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
movsd 0x10(%rsp), %xmm0
callq 0x4070
movsd %xmm0, 0x40(%rsp)
movsd 0x20(%r15), %xmm0
callq 0x4380
movsd %xmm0, 0x38(%rsp)
movsd 0x20(%r15), %xmm0
callq 0x4070
movsd %xmm0, 0x10(%rsp)
movsd 0x30(%r15), %xmm0
callq 0x4070
movsd %xmm0, 0x30(%rsp)
movsd 0x30(%r15), %xmm0
callq 0x4380
movsd %xmm0, 0x28(%rsp)
movsd 0x30(%r15), %xmm0
callq 0x4380
movsd %xmm0, 0x48(%rsp)
movsd 0x30(%r15), %xmm0
callq 0x4070
mulsd 0x10(%rsp), %xmm0
movsd 0x48(%rsp), %xmm1
mulsd 0x8(%rsp), %xmm1
subsd %xmm1, %xmm0
callq 0x4300
movapd 0x35fe(%rip), %xmm1     # 0xd400
andpd %xmm0, %xmm1
ucomisd 0x36a2(%rip), %xmm1     # 0xd4b0
jbe 0x9e1c
xorl %eax, %eax
addq $0x50, %rsp
popq %rbx
popq %r14
popq %r15
retq
movsd 0x10(%rsp), %xmm2
mulsd 0x28(%rsp), %xmm2
movapd %xmm0, 0x10(%rsp)
movsd 0x30(%rsp), %xmm1
mulsd 0x8(%rsp), %xmm1
addsd %xmm2, %xmm1
movsd 0x40(%rsp), %xmm0
mulsd 0x38(%rsp), %xmm0
callq 0x4050
movapd %xmm0, %xmm1
movq 0x18(%r15), %rdi
movq 0x8(%r15), %rsi
addsd 0x28(%r15), %xmm1
movq 0x10(%r15), %rdx
movaps 0x10(%rsp), %xmm0
movq %r14, %rcx
movq %rbx, %r8
addq $0x50, %rsp
popq %rbx
popq %r14
popq %r15
jmp 0x6ab0
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/equations.cpp
// Function: Equation::FindRoot(double, double, double, double&) const
bool Equation::FindRoot (double t0, double t1, double epsilon, double& t) const
{
  bool result = false;
  double p0 = (*this)(t0);
  double p1 = (*this)(t1);
  if (p0 > p1) {
    double temp;
    temp = t0; t0 = t1; t1 = temp;
    temp = p0; p0 = p1; p1 = temp;
  };
  if (p0 > 0 || p1 < 0) {
    fprintf(stderr, "No root for %f %f %f %f\n", t0, t1, p0, p1);
  } else {
    while (t1 - t0 > epsilon) {
      double t2 = (t0 + t1) / 2.0;
      double p2 = (*this)(t2);
      if (p2 <= 0.0) {
	t0 = t2;
      } else {
	t1 = t2;
      }
    }
    t = t0;
    result = true;
  }
  return result;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %rbx
movsd %xmm2, 0x8(%rsp)
movsd %xmm1, (%rsp)
movq %rdi, %r14
movq (%rdi), %rax
movsd %xmm0, 0x10(%rsp)
callq *(%rax)
movaps %xmm0, 0x20(%rsp)
movq (%r14), %rax
movq %r14, %rdi
movsd (%rsp), %xmm0
callq *(%rax)
movapd 0x20(%rsp), %xmm3
ucomisd %xmm0, %xmm3
jbe 0x9fff
movapd %xmm0, %xmm2
movsd 0x10(%rsp), %xmm1
movsd (%rsp), %xmm5
jmp 0xa012
movapd %xmm3, %xmm2
movapd %xmm0, %xmm3
movsd (%rsp), %xmm1
movsd 0x10(%rsp), %xmm5
xorpd %xmm0, %xmm0
movapd %xmm3, %xmm4
cmpnltpd %xmm0, %xmm4
cmpnltpd %xmm2, %xmm0
andpd %xmm4, %xmm0
movd %xmm0, %ebp
testb $0x1, %bpl
je 0xa0c2
movapd %xmm1, %xmm0
subsd %xmm5, %xmm0
ucomisd 0x8(%rsp), %xmm0
jbe 0xa0af
movsd %xmm5, (%rsp)
movapd %xmm1, 0x10(%rsp)
movapd %xmm1, %xmm0
addsd %xmm5, %xmm0
mulsd 0x33d7(%rip), %xmm0     # 0xd438
movapd %xmm0, 0x20(%rsp)
movq (%r14), %rax
movq %r14, %rdi
callq *(%rax)
movapd 0x20(%rsp), %xmm2
xorpd %xmm1, %xmm1
movsd (%rsp), %xmm5
ucomisd %xmm0, %xmm1
jb 0xa088
movapd %xmm2, %xmm5
cmpnlesd %xmm1, %xmm0
andpd %xmm0, %xmm2
andnpd 0x10(%rsp), %xmm0
orpd %xmm2, %xmm0
movapd %xmm0, %xmm1
subsd %xmm5, %xmm1
ucomisd 0x8(%rsp), %xmm1
movapd %xmm0, %xmm1
ja 0xa046
movsd %xmm5, (%rbx)
andb $0x1, %bpl
movl %ebp, %eax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movq 0x8f17(%rip), %rax      # 0x12fe0
movq (%rax), %rdi
leaq 0x379d(%rip), %rsi      # 0xd870
movapd %xmm5, %xmm0
movb $0x4, %al
callq 0x4290
jmp 0xa0b3
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/equations.cpp
// Function: perihelionangle(double)
double perihelionangle (double m)
{
  double e = eccentricity;
  double r = m + 2*e*sin(m) + 5*sqr(e)*sin(2*m)/4 + 
             cube(e)*(-sin(m)/4 + 13*sin(3*m)/12);
  return r;
}

// Assembly:
subq $0x18, %rsp
movsd %xmm0, 0x8(%rsp)
callq 0x4070
movapd %xmm0, %xmm1
mulsd 0x36ad(%rip), %xmm1     # 0xd7a8
movsd 0x8(%rsp), %xmm0
addsd %xmm0, %xmm1
movsd %xmm1, (%rsp)
addsd %xmm0, %xmm0
callq 0x4070
mulsd 0x3695(%rip), %xmm0     # 0xd7b0
mulsd 0x3695(%rip), %xmm0     # 0xd7b8
addsd (%rsp), %xmm0
movsd %xmm0, (%rsp)
movsd 0x8(%rsp), %xmm0
callq 0x4070
mulsd 0x3678(%rip), %xmm0     # 0xd7b8
movsd %xmm0, 0x10(%rsp)
movsd 0x8(%rsp), %xmm0
mulsd 0x366c(%rip), %xmm0     # 0xd7c0
callq 0x4070
mulsd 0x3667(%rip), %xmm0     # 0xd7c8
divsd 0x3667(%rip), %xmm0     # 0xd7d0
subsd 0x10(%rsp), %xmm0
mulsd 0x3661(%rip), %xmm0     # 0xd7d8
addsd (%rsp), %xmm0
addq $0x18, %rsp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/equations.cpp
// Function: getperiheliontime()
double getperiheliontime ()
{
  double theta0 = 0;
  double theta1 = 2 * pi;
  double epsilon = 1e-8;
  while (theta1 - theta0 > epsilon) {
    double theta2 = (theta0 + theta1) / 2.0;
    double p = perihelionangle(theta2) - equinoxangle;
    if (p <= 0.0) {
      theta0 = theta2;
    } else {
      theta1 = theta2;
    }
  }
  printf ("Perihelion time: %f\n", -theta1);
  return -theta1;
}

// Assembly:
subq $0x48, %rsp
movsd 0x2eab(%rip), %xmm1     # 0xd038
xorpd %xmm2, %xmm2
movsd %xmm2, 0x28(%rsp)
movapd %xmm1, 0x30(%rsp)
movapd %xmm1, %xmm0
addsd %xmm2, %xmm0
mulsd 0x328b(%rip), %xmm0     # 0xd438
movapd %xmm0, 0x10(%rsp)
callq 0x4070
movapd %xmm0, %xmm1
mulsd 0x35e4(%rip), %xmm1     # 0xd7a8
movapd 0x10(%rsp), %xmm0
addsd %xmm0, %xmm1
movsd %xmm1, 0x8(%rsp)
addsd %xmm0, %xmm0
callq 0x4070
movapd %xmm0, %xmm1
mulsd 0x35c7(%rip), %xmm1     # 0xd7b0
movsd 0x35c7(%rip), %xmm0     # 0xd7b8
mulsd %xmm0, %xmm1
addsd 0x8(%rsp), %xmm1
movsd %xmm1, 0x8(%rsp)
movapd 0x10(%rsp), %xmm0
callq 0x4070
mulsd 0x35a4(%rip), %xmm0     # 0xd7b8
movsd %xmm0, 0x20(%rsp)
movapd 0x10(%rsp), %xmm0
mulsd 0x3598(%rip), %xmm0     # 0xd7c0
callq 0x4070
movapd 0x10(%rsp), %xmm3
movsd 0x28(%rsp), %xmm2
xorpd %xmm1, %xmm1
mulsd 0x3583(%rip), %xmm0     # 0xd7c8
divsd 0x3583(%rip), %xmm0     # 0xd7d0
subsd 0x20(%rsp), %xmm0
mulsd 0x357d(%rip), %xmm0     # 0xd7d8
addsd 0x8(%rsp), %xmm0
addsd 0x3577(%rip), %xmm0     # 0xd7e0
ucomisd %xmm0, %xmm1
jb 0xa273
movapd %xmm3, %xmm2
cmpnlesd %xmm1, %xmm0
andpd %xmm0, %xmm3
andnpd 0x30(%rsp), %xmm0
orpd %xmm3, %xmm0
movapd %xmm0, %xmm1
subsd %xmm2, %xmm0
ucomisd 0x3552(%rip), %xmm0     # 0xd7e8
ja 0xa191
movapd 0x2dcc(%rip), %xmm0     # 0xd070
xorpd %xmm1, %xmm0
movapd %xmm0, 0x10(%rsp)
leaq 0x35d4(%rip), %rdi      # 0xd889
movb $0x1, %al
callq 0x4040
movaps 0x10(%rsp), %xmm0
addq $0x48, %rsp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/equations.cpp
// Function: equationoftime(double)
double equationoftime(double date)
{
  double p = perihelion;
  double m = date - periheliontime;
  double s = 
    -591.7 * sin(2 * (m+p))
    -459.6 * sin(m) +
     +19.8 * sin(m + 2 * p)
     -19.8 * sin(3 * m + 2 * p)
     -12.8 * sin(4 * (m + p))
      -4.8 * sin(2 * m)
      +0.9 * sin(3 * m + 4 * p)
      -0.9 * sin(5 * m + 4 * p)
      -0.5 * sin(4 * m + 2 * p)
      -0.4 * sin(6 * (m + p));
    
  // fprintf(stderr, "EOT: %f\n", s / 60.0);
  return s; // seconds
}

// Assembly:
subq $0x28, %rsp
movapd %xmm0, %xmm1
addsd 0x351a(%rip), %xmm1     # 0xd7f0
movsd %xmm1, 0x10(%rsp)
movsd 0x3514(%rip), %xmm0     # 0xd7f8
addsd %xmm1, %xmm0
movsd %xmm0, 0x20(%rsp)
addsd %xmm0, %xmm0
callq 0x4070
movsd %xmm0, 0x8(%rsp)
movsd 0x10(%rsp), %xmm0
callq 0x4070
mulsd 0x34f0(%rip), %xmm0     # 0xd800
movsd 0x8(%rsp), %xmm1
mulsd 0x34ea(%rip), %xmm1     # 0xd808
addsd %xmm1, %xmm0
movsd %xmm0, 0x8(%rsp)
movsd 0x10(%rsp), %xmm0
addsd 0x34da(%rip), %xmm0     # 0xd810
callq 0x4070
mulsd 0x34d5(%rip), %xmm0     # 0xd818
addsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x18(%rsp)
movsd 0x3469(%rip), %xmm0     # 0xd7c0
mulsd 0x10(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
addsd 0x34a5(%rip), %xmm0     # 0xd810
callq 0x4070
mulsd 0x34a8(%rip), %xmm0     # 0xd820
addsd 0x18(%rsp), %xmm0
movsd %xmm0, 0x18(%rsp)
movsd 0x20(%rsp), %xmm0
mulsd 0x30fe(%rip), %xmm0     # 0xd490
callq 0x4070
mulsd 0x3489(%rip), %xmm0     # 0xd828
addsd 0x18(%rsp), %xmm0
movsd %xmm0, 0x18(%rsp)
movsd 0x10(%rsp), %xmm0
addsd %xmm0, %xmm0
callq 0x4070
mulsd 0x346e(%rip), %xmm0     # 0xd830
addsd 0x18(%rsp), %xmm0
movsd %xmm0, 0x18(%rsp)
movsd 0x8(%rsp), %xmm0
addsd 0x345c(%rip), %xmm0     # 0xd838
callq 0x4070
mulsd 0x3457(%rip), %xmm0     # 0xd840
addsd 0x18(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
movsd 0x344b(%rip), %xmm0     # 0xd848
mulsd 0x10(%rsp), %xmm0
addsd 0x342d(%rip), %xmm0     # 0xd838
callq 0x4070
mulsd 0x3438(%rip), %xmm0     # 0xd850
addsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
movsd 0x10(%rsp), %xmm0
mulsd 0x305e(%rip), %xmm0     # 0xd490
addsd 0x33d6(%rip), %xmm0     # 0xd810
callq 0x4070
mulsd 0x3011(%rip), %xmm0     # 0xd458
addsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x10(%rsp)
movsd 0x20(%rsp), %xmm0
mulsd 0x303f(%rip), %xmm0     # 0xd4a0
callq 0x4070
mulsd 0x33ea(%rip), %xmm0     # 0xd858
addsd 0x10(%rsp), %xmm0
addq $0x28, %rsp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/equations.cpp
// Function: sunangle(double)
double sunangle (double date)
{
  // Date is measured from vernal equinox
  // Need time from perihelion to equinox

  // Add the time from the perihelion and equinox
  double t = date - periheliontime;
  // r is the angle of the sun, from the perihelion
  double r = perihelionangle(t);
  // So subtract the angle between perihelion and equinox
  return r - equinoxangle;
}

// Assembly:
subq $0x18, %rsp
addsd 0x336b(%rip), %xmm0     # 0xd7f0
movsd %xmm0, 0x8(%rsp)
callq 0x4070
movapd %xmm0, %xmm1
mulsd 0x330c(%rip), %xmm1     # 0xd7a8
movsd 0x8(%rsp), %xmm0
addsd %xmm0, %xmm1
movsd %xmm1, (%rsp)
addsd %xmm0, %xmm0
callq 0x4070
mulsd 0x32f4(%rip), %xmm0     # 0xd7b0
mulsd 0x32f4(%rip), %xmm0     # 0xd7b8
addsd (%rsp), %xmm0
movsd %xmm0, (%rsp)
movsd 0x8(%rsp), %xmm0
callq 0x4070
mulsd 0x32d7(%rip), %xmm0     # 0xd7b8
movsd %xmm0, 0x10(%rsp)
movsd 0x8(%rsp), %xmm0
mulsd 0x32cb(%rip), %xmm0     # 0xd7c0
callq 0x4070
mulsd 0x32c6(%rip), %xmm0     # 0xd7c8
divsd 0x32c6(%rip), %xmm0     # 0xd7d0
subsd 0x10(%rsp), %xmm0
mulsd 0x32c0(%rip), %xmm0     # 0xd7d8
addsd (%rsp), %xmm0
addsd 0x32bb(%rip), %xmm0     # 0xd7e0
addq $0x18, %rsp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/equations.cpp
// Function: sunaltitude(double, double, double)
double sunaltitude (double date, double phi, double time)
{
  // Compute altitude of sun at the given date and time,
  // on the zero meridian at latitude phi
  double delta = asin(sunheight(date)); // Declination of the sun

  // Rotate lat = phi, long = 0 round by time
  // Find x,y,z coords on the sphere - no need to use an ellipsoid, as the
  // tangents at a location are the same.
  double x = cos(time) * cos(phi);
  double y = sin(time) * cos(phi);
  double z = sin(phi);

  // The sun vector - the sun is at -x
  double sunx = -cos(delta);
  double suny = 0;
  double sunz = sin(delta);

  // Dot product to get angle to normal
  double alt = pi/2.0 - acos(x * sunx + y * suny + z * sunz);
  return alt;
}

// Assembly:
subq $0x38, %rsp
movsd %xmm2, 0x8(%rsp)
movsd %xmm1, 0x18(%rsp)
addsd 0x312e(%rip), %xmm0     # 0xd7f0
movsd %xmm0, 0x10(%rsp)
callq 0x4070
movapd %xmm0, %xmm1
mulsd 0x30cf(%rip), %xmm1     # 0xd7a8
movsd 0x10(%rsp), %xmm0
addsd %xmm0, %xmm1
movsd %xmm1, (%rsp)
addsd %xmm0, %xmm0
callq 0x4070
mulsd 0x30b7(%rip), %xmm0     # 0xd7b0
mulsd 0x30b7(%rip), %xmm0     # 0xd7b8
addsd (%rsp), %xmm0
movsd %xmm0, (%rsp)
movsd 0x10(%rsp), %xmm0
callq 0x4070
mulsd 0x309a(%rip), %xmm0     # 0xd7b8
movsd %xmm0, 0x20(%rsp)
movsd 0x10(%rsp), %xmm0
mulsd 0x308e(%rip), %xmm0     # 0xd7c0
callq 0x4070
mulsd 0x3089(%rip), %xmm0     # 0xd7c8
divsd 0x3089(%rip), %xmm0     # 0xd7d0
subsd 0x20(%rsp), %xmm0
mulsd 0x3083(%rip), %xmm0     # 0xd7d8
addsd (%rsp), %xmm0
addsd 0x307e(%rip), %xmm0     # 0xd7e0
callq 0x4070
mulsd 0x30f1(%rip), %xmm0     # 0xd860
callq 0x4300
movsd %xmm0, 0x10(%rsp)
movsd 0x8(%rsp), %xmm0
callq 0x4380
movsd %xmm0, (%rsp)
movsd 0x18(%rsp), %xmm0
callq 0x4380
mulsd (%rsp), %xmm0
movsd %xmm0, (%rsp)
movsd 0x8(%rsp), %xmm0
callq 0x4070
movsd %xmm0, 0x8(%rsp)
movsd 0x18(%rsp), %xmm0
callq 0x4380
mulsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x8(%rsp)
movsd 0x18(%rsp), %xmm0
callq 0x4070
movsd %xmm0, 0x18(%rsp)
movsd 0x10(%rsp), %xmm0
callq 0x4380
movsd %xmm0, 0x20(%rsp)
movsd 0x10(%rsp), %xmm0
callq 0x4070
xorpd %xmm1, %xmm1
mulsd 0x8(%rsp), %xmm1
movsd 0x20(%rsp), %xmm2
mulsd (%rsp), %xmm2
subsd %xmm2, %xmm1
mulsd 0x18(%rsp), %xmm0
addsd %xmm1, %xmm0
callq 0x41f0
movsd %xmm0, 0x30(%rsp)
fldl 0x27f8(%rip)            # 0xd020
fsubl 0x30(%rsp)
fstpl 0x28(%rsp)
movsd 0x28(%rsp), %xmm0
addq $0x38, %rsp
retq
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/equations.cpp
// Function: sunrise(double, double)
double sunrise (double date, double phi)
{
  double t0 = 0;
  double t1 = pi;
  double epsilon = 1e-6;
  while (t1 - t0 > epsilon) {
    double t = (t1 + t0) / 2.0;
    double h = sunaltitude(date + t/daysinyear, phi, t);
    //printf ("%f %f %f %f\n", t0, t1, t, h);
    if (h < sunriseangle) {
      t0 = t;
    } else {
      t1 = t;
    }
  }
  return t0;
}

// Assembly:
subq $0x48, %rsp
movsd %xmm1, 0x10(%rsp)
movsd %xmm0, 0x8(%rsp)
movsd 0x27b5(%rip), %xmm2     # 0xd008
xorpd %xmm1, %xmm1
movapd %xmm2, 0x30(%rsp)
movsd %xmm1, 0x18(%rsp)
addsd %xmm1, %xmm2
mulsd 0x2bc9(%rip), %xmm2     # 0xd438
movapd %xmm2, %xmm0
movapd %xmm2, 0x20(%rsp)
divsd 0x2fe7(%rip), %xmm0     # 0xd868
addsd 0x8(%rsp), %xmm0
movsd 0x10(%rsp), %xmm1
callq 0xa6aa
movapd 0x20(%rsp), %xmm3
movsd 0x2ba0(%rip), %xmm2     # 0xd440
movapd %xmm0, %xmm1
ucomisd %xmm0, %xmm2
movapd %xmm3, %xmm0
ja 0xa8b4
movsd 0x18(%rsp), %xmm0
cmpltsd %xmm2, %xmm1
movapd 0x30(%rsp), %xmm2
andpd %xmm1, %xmm2
andnpd %xmm3, %xmm1
orpd %xmm1, %xmm2
movapd %xmm2, %xmm1
subsd %xmm0, %xmm1
ucomisd 0x2ba5(%rip), %xmm1     # 0xd480
movapd %xmm0, %xmm1
ja 0xa857
addq $0x48, %rsp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/utils.cpp
// Function: StringSpec::ReadOpt(int&, char**&)
int StringSpec::ReadOpt(int &argc, char** &argv) {
  if (strcmp(argv[0], optstring) != 0) {
    return 0;
  } else {
    argc--; argv++;
    if (argc == 0) {
      fprintf(stderr,"Need a parameter for %s\n", optstring);
      return -1;
    } else {
      value = argv[0];
      return 1;
    }
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq (%rdx), %r12
movq (%r12), %rdi
movq 0x8(%rbx), %rsi
callq 0x4270
movl %eax, %ecx
xorl %eax, %eax
testl %ecx, %ecx
jne 0xaa2b
addq $0x8, %r12
decl (%r15)
movq %r12, (%r14)
je 0xaa37
movq (%r12), %rax
movq 0x10(%rbx), %rcx
movq %rax, (%rcx)
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
addq $0x8, %rbx
movq %rbx, %rdi
callq 0x4418
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0xaa2b
// File: /workspace/github_cpp_makefile_star2_O1/matthewarcus[P]mmps/utils.cpp
// Function: IntSpec::ReadOpt(int&, char**&)
int IntSpec::ReadOpt(int &argc, char** &argv) {
  if (strcmp(argv[0], optstring) != 0) {
    return 0;
  } else {
    argc--; argv++;
    if (argc == 0) {
      fprintf(stderr,"Need a parameter for %s\n", optstring);
      return -1;
    } else {
      // Should do some error checking here
      value = strtol(argv[0],NULL,0);
      return 1;
    }
  }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq (%rdx), %r12
movq (%r12), %rdi
movq 0x8(%rbx), %rsi
callq 0x4270
movl %eax, %ecx
xorl %eax, %eax
testl %ecx, %ecx
jne 0xaaab
addq $0x8, %r12
decl (%r15)
movq %r12, (%r14)
je 0xaab7
movq (%r12), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x4280
movq 0x10(%rbx), %rcx
movl %eax, (%rcx)
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
addq $0x8, %rbx
movq %rbx, %rdi
callq 0x4436
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0xaaab