LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: time_since_perihelion(double)
double time_since_perihelion(double jd)
{
#define JD_DELTA_EOT 3.5884  // 3.52719  // typical offset time of perihelion from 1 Jan in days

   // return days (fractional) since perihelion (based upon local time)
   // returns estimated value if year not between 2016 and 2100
   gregorian(0, jd);
   if(g_year < 2016) return jd - jdate(g_year, 1, 1) - JD_DELTA_EOT;
   else if(g_year > 2100) return jd - jdate(g_year, 1, 1) - JD_DELTA_EOT;

   jd = jd - perihelion_jd[g_year-2016];
// jd -= 1.363;  // fudge factor to get alignment with NREL SPA code
jd -= 1.60;
   return jd;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
xorl %edi, %edi
movsd %xmm0, -0x8(%rbp)
callq 0xd12da
leaq 0x22be1f(%rip), %rax    # 0x30d6a4
movslq (%rax), %rax
cmpq $0x7df, %rax            # imm = 0x7DF
jg 0xe18d7
leaq -0x1(%rax), %rcx
movslq %ecx, %rcx
imulq $0x51eb851f, %rcx, %rcx # imm = 0x51EB851F
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x25, %rcx
addl %edx, %ecx
movslq %ecx, %rcx
imulq $-0x64, %rcx, %rdx
addq %rdx, %rax
decq %rax
imulq $0x23ab1, %rcx, %rcx    # imm = 0x23AB1
leaq 0x3(%rcx), %rsi
testq %rcx, %rcx
cmovnsq %rcx, %rsi
sarq $0x2, %rsi
imulq $0x8ead, %rax, %rcx     # imm = 0x8EAD
jmp 0xe1904
cmpl $0x835, %eax            # imm = 0x835
jb 0xe1955
decl %eax
imulq $0x51eb851f, %rax, %rcx # imm = 0x51EB851F
shrq $0x25, %rcx
imulq $-0x64, %rcx, %rdx
addq %rax, %rdx
imulq $0x23ab1, %rcx, %rsi    # imm = 0x23AB1
shrq $0x2, %rsi
imulq $0x8ead, %rdx, %rcx     # imm = 0x8EAD
movabsq $-0x5c28f5c28f5c28f5, %rdx # imm = 0xA3D70A3D70A3D70B
movq %rcx, %rax
imulq %rdx
addq %rcx, %rdx
movq %rdx, %rax
shrq $0x3f, %rax
sarq $0x6, %rdx
addq %rax, %rdx
cvtsi2sd %rsi, %xmm1
addsd 0x49eb6(%rip), %xmm1    # 0x12b7e8
cvtsi2sd %rdx, %xmm2
addsd %xmm1, %xmm2
addsd 0x4a0b5(%rip), %xmm2    # 0x12b9f8
addsd 0x27725(%rip), %xmm2    # 0x109070
movsd 0x4a0ad(%rip), %xmm1    # 0x12ba00
jmp 0xe196e
addl $0xfffff820, %eax       # imm = 0xFFFFF820
leaq 0x88eff(%rip), %rcx     # 0x16a860
movsd (%rcx,%rax,8), %xmm2
movsd 0x4a082(%rip), %xmm1    # 0x12b9f0
movsd -0x8(%rbp), %xmm0
subsd %xmm2, %xmm0
addsd %xmm1, %xmm0
addq $0x10, %rsp
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: orbit_eccentricity(double)
double orbit_eccentricity(double jd)
{
double t;
double ecc;

   t = (jd - JD2000)/365250.0;
   ecc = 0.0167086342 - 0.0004203654*t - 0.0000126734*t*t + 0.0000001444*t*t*t
         -0.0000000002*t*t*t*t + 0.0000000003*t*t*t*t*t;
   return ecc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
addsd 0x49ea3(%rip), %xmm0    # 0x12b830
divsd 0x4a073(%rip), %xmm0    # 0x12ba08
movsd 0x4a073(%rip), %xmm1    # 0x12ba10
mulsd %xmm0, %xmm1
addsd 0x4a06f(%rip), %xmm1    # 0x12ba18
movsd 0x4a06f(%rip), %xmm2    # 0x12ba20
mulsd %xmm0, %xmm2
mulsd %xmm0, %xmm2
addsd %xmm1, %xmm2
movsd 0x4a063(%rip), %xmm1    # 0x12ba28
mulsd %xmm0, %xmm1
mulsd %xmm0, %xmm1
mulsd %xmm0, %xmm1
addsd %xmm2, %xmm1
movsd 0x4a053(%rip), %xmm2    # 0x12ba30
mulsd %xmm0, %xmm2
mulsd %xmm0, %xmm2
mulsd %xmm0, %xmm2
mulsd %xmm0, %xmm2
addsd %xmm1, %xmm2
movsd 0x4a03f(%rip), %xmm1    # 0x12ba38
mulsd %xmm0, %xmm1
mulsd %xmm0, %xmm1
mulsd %xmm0, %xmm1
mulsd %xmm0, %xmm1
mulsd %xmm1, %xmm0
addsd %xmm2, %xmm0
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: calcObliquityCorrection(double)
double calcObliquityCorrection(double t)
{
  double seconds = 21.448 - t*(46.8150 + t*(0.00059 - t*(0.001813)));
  double e0 = 23.0 + (26.0 + (seconds/60.0))/60.0;

  double omega = 125.04 - 1934.136 * t;
  return e0 + 0.00256 * cos(omega*PI/180.0);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movsd 0x49fd2(%rip), %xmm1    # 0x12ba68
mulsd %xmm0, %xmm1
addsd 0x49fce(%rip), %xmm1    # 0x12ba70
mulsd %xmm0, %xmm1
addsd 0x49fca(%rip), %xmm1    # 0x12ba78
mulsd %xmm0, %xmm1
movsd 0x49fc6(%rip), %xmm2    # 0x12ba80
subsd %xmm1, %xmm2
movsd 0x27542(%rip), %xmm1    # 0x109008
divsd %xmm1, %xmm2
addsd 0x49e8e(%rip), %xmm2    # 0x12b960
divsd %xmm1, %xmm2
addsd 0x49faa(%rip), %xmm2    # 0x12ba88
movsd %xmm2, -0x8(%rbp)
mulsd 0x49fa5(%rip), %xmm0    # 0x12ba90
addsd 0x49fa5(%rip), %xmm0    # 0x12ba98
mulsd 0x29d2d(%rip), %xmm0    # 0x10b828
divsd 0x29d2d(%rip), %xmm0    # 0x10b830
callq 0x9710
mulsd 0x49f90(%rip), %xmm0    # 0x12baa0
addsd -0x8(%rbp), %xmm0
addq $0x10, %rsp
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: gmst(double, int)
double gmst(double jd, int apparent)
{
double st;
double d;    // oh, my
double omega;
double epsilon;
double l;
double delta;
double eqeq;
double jc;

   // calculate Greenwich mean or apparent sidereal time

   d = jd - JD2000; 

   // from NREL SPA code
   jc = d / 36525.0;  // julian century
   st = (280.46061837 + 360.98564736629 * (jd - JD2000) +
         jc*jc*(0.000387933 - jc/38710000.0));
   st = fmod(st, 360.0);
   st /= 15.0;

   if(apparent) { // calculate nutation for apparent sidereal time
      omega = 125.04 - (0.052954 * d);
      l = 280.47 + (0.98565 * d); 
      epsilon = 23.4393 - (0.0000004 * d); 
      delta = (-0.000319*sin(omega)) - (0.000024*sin(l+l));
      eqeq = delta * cos(epsilon);
      st += eqeq;
      st = fmod(st, 24.0);
   }

   while(st < 0.0)   st += 24.0;
   while(st >= 24.0) st -= 24.0;
   return st;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x28, %rsp
movapd %xmm0, %xmm2
addsd 0x4954d(%rip), %xmm2    # 0x12b830
movl %edi, %ebx
movapd %xmm2, %xmm0
divsd 0x49547(%rip), %xmm0    # 0x12b838
movsd 0x4984f(%rip), %xmm1    # 0x12bb48
movsd %xmm2, -0x18(%rbp)
mulsd %xmm2, %xmm1
addsd 0x49846(%rip), %xmm1    # 0x12bb50
movapd %xmm0, %xmm2
mulsd %xmm0, %xmm2
divsd 0x4983e(%rip), %xmm0    # 0x12bb58
addsd 0x4983e(%rip), %xmm0    # 0x12bb60
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd 0x3be06(%rip), %xmm1    # 0x11e138
callq 0x94d0
movapd %xmm0, %xmm2
divsd 0x3c1f5(%rip), %xmm2    # 0x11e538
testl %ebx, %ebx
je 0xe23f2
movsd 0x49815(%rip), %xmm0    # 0x12bb68
movsd -0x18(%rbp), %xmm1
mulsd %xmm1, %xmm0
addsd 0x49734(%rip), %xmm0    # 0x12ba98
movsd 0x49804(%rip), %xmm3    # 0x12bb70
mulsd %xmm1, %xmm3
addsd 0x49800(%rip), %xmm3    # 0x12bb78
movsd %xmm3, -0x20(%rbp)
mulsd 0x497fb(%rip), %xmm1    # 0x12bb80
addsd 0x497fb(%rip), %xmm1    # 0x12bb88
movsd %xmm1, -0x18(%rbp)
movsd %xmm2, -0x28(%rbp)
callq 0x9080
movsd %xmm0, -0x10(%rbp)
movsd -0x20(%rbp), %xmm0
addsd %xmm0, %xmm0
callq 0x9080
mulsd 0x497d9(%rip), %xmm0    # 0x12bb90
movsd -0x10(%rbp), %xmm1
mulsd 0x497d4(%rip), %xmm1    # 0x12bb98
addsd %xmm1, %xmm0
movsd %xmm0, -0x10(%rbp)
movsd -0x18(%rbp), %xmm0
callq 0x9710
mulsd -0x10(%rbp), %xmm0
addsd -0x28(%rbp), %xmm0
movsd 0x26c57(%rip), %xmm1    # 0x109040
callq 0x94d0
movapd %xmm0, %xmm2
xorpd %xmm0, %xmm0
ucomisd %xmm2, %xmm0
jbe 0xe240e
movsd 0x26c3c(%rip), %xmm1    # 0x109040
addsd %xmm1, %xmm2
ucomisd %xmm2, %xmm0
ja 0xe2404
ucomisd 0x26c2a(%rip), %xmm2    # 0x109040
jb 0xe2432
movsd 0x3c4e0(%rip), %xmm0    # 0x11e900
movsd 0x26c18(%rip), %xmm1    # 0x109040
addsd %xmm0, %xmm2
ucomisd %xmm1, %xmm2
jae 0xe2428
movapd %xmm2, %xmm0
addq $0x28, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: lmst(double, int)
double lmst(double jd, int apparent)
{
double st;

   // calculate Greenwich mean or apparent local time

   if(lon > 0.0) st = 360.0 - lon*RAD_TO_DEG;  // st = lon west of Greenwich
   else          st = 0.0 - lon*RAD_TO_DEG;
   st = st * 24.0 / 360.0;   // st is the hour offset based upon longitude

   st = gmst(jd, apparent) - st;

   while(st < 0.0)   st += 24.0;
   while(st >= 24.0) st -= 24.0;
   return st;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
leaq 0x22ab8c(%rip), %rax    # 0x30cfd8
movsd (%rax), %xmm1
movsd 0x49748(%rip), %xmm2    # 0x12bba0
mulsd %xmm1, %xmm2
xorpd %xmm3, %xmm3
cmpltsd %xmm1, %xmm3
movsd 0x3bccb(%rip), %xmm1    # 0x11e138
andpd %xmm1, %xmm3
addsd %xmm2, %xmm3
mulsd 0x3c483(%rip), %xmm3    # 0x11e900
divsd %xmm1, %xmm3
movapd %xmm3, -0x10(%rbp)
callq 0xe22ce
xorpd %xmm2, %xmm2
addsd -0x10(%rbp), %xmm0
ucomisd %xmm0, %xmm2
jbe 0xe24ac
movsd 0x26b9e(%rip), %xmm1    # 0x109040
addsd %xmm1, %xmm0
ucomisd %xmm0, %xmm2
ja 0xe24a2
ucomisd 0x26b8c(%rip), %xmm0    # 0x109040
jb 0xe24d0
movsd 0x3c442(%rip), %xmm1    # 0x11e900
movsd 0x26b7a(%rip), %xmm2    # 0x109040
addsd %xmm1, %xmm0
ucomisd %xmm2, %xmm0
jae 0xe24c6
addq $0x10, %rsp
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: tcb_time(double)
double tcb_time(double jd_tt)
{
double g;
double jd;

   g = (357.53 + (0.9856003 * (jd_tt - JD2000))) * PI/180.0; // radians
   jd = jd_tt + (((0.001658 * sin(g)) + (0.000014 * sin(2.0*g))) / (24.0*60.0*60.0)); // jd is TDB

   jd -= 2443144.5003725;         // convert TDB to TCB
   jd /= (1.0 - 1.550519768e-8);
   jd += 2443144.5003725;
   return jd;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movsd %xmm0, -0x18(%rbp)
movsd 0x49264(%rip), %xmm1    # 0x12b830
addsd %xmm0, %xmm1
mulsd 0x495e8(%rip), %xmm1    # 0x12bbc0
addsd 0x495e8(%rip), %xmm1    # 0x12bbc8
mulsd 0x29240(%rip), %xmm1    # 0x10b828
divsd 0x29240(%rip), %xmm1    # 0x10b830
movsd %xmm1, -0x8(%rbp)
movapd %xmm1, %xmm0
callq 0x9080
movsd %xmm0, -0x10(%rbp)
movsd -0x8(%rbp), %xmm0
addsd %xmm0, %xmm0
callq 0x9080
mulsd 0x495b7(%rip), %xmm0    # 0x12bbd0
movsd -0x10(%rbp), %xmm1
mulsd 0x495b2(%rip), %xmm1    # 0x12bbd8
addsd %xmm1, %xmm0
divsd 0x269e6(%rip), %xmm0    # 0x109018
addsd -0x18(%rbp), %xmm0
addsd 0x49571(%rip), %xmm0    # 0x12bbb0
divsd 0x49599(%rip), %xmm0    # 0x12bbe0
addsd 0x49599(%rip), %xmm0    # 0x12bbe8
addq $0x20, %rsp
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: get_alarm_time()
double get_alarm_time()
{

   // Get the time to trigger an alarm into the g_ variables and also return
   // it as a jdate double.
   //
   // This time can either be the local time or the displayed time (if it is
   // one of the astronomical time scales) depending upon the setting of the
   // alarm_type option.

   if(alarm_type == 0) {  // alarm/dump/exit on local time
      gregorian(0, jd_local);
      return jd_local;
   }
   else {  // alarm/dump/exit on displayed (possibly astronomical time)
      g_year    = pri_year;   
      g_month   = pri_month;
      g_day     = pri_day;
      g_hours   = pri_hours;
      g_minutes = pri_minutes;
      g_seconds = pri_seconds;
      g_frac    = pri_frac;

      return jdate(g_year,g_month,g_day) + jtime(g_hours,g_minutes,g_seconds,0.0);
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
leaq 0x138487(%rip), %rax    # 0x21b418
cmpb $0x0, (%rax)
je 0xe3060
leaq 0x22a573(%rip), %rax    # 0x30d514
movl (%rax), %edi
leaq 0x22a6fa(%rip), %rax    # 0x30d6a4
movl %edi, (%rax)
leaq 0x22a55d(%rip), %rax    # 0x30d510
movl (%rax), %esi
leaq 0x22a6e0(%rip), %rax    # 0x30d69c
movl %esi, (%rax)
leaq 0x22a547(%rip), %rax    # 0x30d50c
movl (%rax), %edx
leaq 0x22a6d2(%rip), %rax    # 0x30d6a0
movl %edx, (%rax)
leaq 0x22a531(%rip), %rax    # 0x30d508
movl (%rax), %ebx
leaq 0x22a6c8(%rip), %rax    # 0x30d6a8
movl %ebx, (%rax)
leaq 0x22a51b(%rip), %rax    # 0x30d504
movl (%rax), %r14d
leaq 0x22a6b9(%rip), %rax    # 0x30d6ac
movl %r14d, (%rax)
leaq 0x22a503(%rip), %rax    # 0x30d500
movl (%rax), %r15d
leaq 0x22a6a9(%rip), %rax    # 0x30d6b0
movl %r15d, (%rax)
leaq 0x22a507(%rip), %rax    # 0x30d518
movsd (%rax), %xmm0
leaq 0x22a69c(%rip), %rax    # 0x30d6b8
movsd %xmm0, (%rax)
callq 0xd485e
cvtsi2sd %ebx, %xmm2
cvtsi2sd %r14d, %xmm3
movapd %xmm0, %xmm1
divsd 0x25fce(%rip), %xmm3    # 0x109008
addsd %xmm2, %xmm3
xorps %xmm0, %xmm0
cvtsi2sd %r15d, %xmm0
divsd 0x25fc2(%rip), %xmm0    # 0x109010
addsd %xmm3, %xmm0
divsd 0x25fe6(%rip), %xmm0    # 0x109040
addsd %xmm1, %xmm0
jmp 0xe3076
leaq 0x22a4e1(%rip), %rbx    # 0x30d548
movsd (%rbx), %xmm0
xorl %edi, %edi
callq 0xd12da
movsd (%rbx), %xmm0
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: reset_alarm()
void reset_alarm()
{
   // reset the alarm, turn off modem control signals if enabled
   if(modem_alarms) {  // turn off modem control signal that indicates alarm
      Sleep(250);  // allow minimum modem control signal width
      // !!!!!! manipulate modem control signals here
      if(com[ALARM_PORT].com_port > 0) { // COM port in use
         SetDtrLine(ALARM_PORT, 1);  // drive +12V
         SetRtsLine(ALARM_PORT, 0);  // drive -12V
      }
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x22aec0(%rip), %rax    # 0x30df4c
cmpl $0x0, (%rax)
je 0xe30c7
movl $0xfa, %edi
callq 0xafe8
leaq 0x22b23e(%rip), %rax    # 0x30e2e0
cmpl $0x0, 0x157c0(%rax)
jle 0xe30c7
movl $0xa, %edi
movl $0x1, %esi
callq 0xaeab
movl $0xa, %edi
xorl %esi, %esi
popq %rbp
jmp 0xaef7
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: enable_alarm()
void enable_alarm()
{
   if(modem_alarms) {
      // !!!!!! manipulate modem control signals here
      if(com[ALARM_PORT].com_port > 0) { // COM port in use
         SetDtrLine(ALARM_PORT, 0);  // drive -12V
         SetRtsLine(ALARM_PORT, 1);  // drive +12V
      }
   }
}

// Assembly:
leaq 0x22ae7c(%rip), %rax    # 0x30df4c
cmpl $0x0, (%rax)
je 0xe3105
leaq 0x22b204(%rip), %rax    # 0x30e2e0
cmpl $0x0, 0x157c0(%rax)
jle 0xe3105
pushq %rbp
movq %rsp, %rbp
movl $0xa, %edi
xorl %esi, %esi
callq 0xaeab
movl $0xa, %edi
movl $0x1, %esi
popq %rbp
jmp 0xaef7
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: get_delta_t()
void get_delta_t()
{
FILE *file;

   // periodically try to get delta_t from a file
   gregorian(0, jd_utc);
   if((g_hours == DELTAT_HOUR) && (g_minutes == DELTAT_MINUTE) && (g_seconds == DELTAT_SECOND)) {
      need_delta_t = 1;
   }

   if(need_delta_t && (user_set_delta_t != 1)) { // time to get delta_t from a file
      if(0) {
         file = topen(lock_name, "r");     // check for lock file
         if(file) {        // deltat.dat is being updated
            fclose(file);
            return;
         }
      }

      file = topen(DELTAT_FILE, "r");
      if(file) {
         if(fgets(out, sizeof(out)-1, file) != NULL) {
            user_delta_t = atof(out);
            user_delta_t /= (24.0*60.0*60.0);  // convert seconds to days
            user_set_delta_t = 2;
         }
         fclose(file);
      }
      need_delta_t = 0;
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x229fb3(%rip), %rax    # 0x30d530
movsd (%rax), %xmm0
xorl %edi, %edi
callq 0xd12da
leaq 0x22a119(%rip), %rax    # 0x30d6a8
cmpl $0x0, (%rax)
jne 0xe35bd
leaq 0x22a111(%rip), %rax    # 0x30d6ac
cmpl $0x0, (%rax)
jne 0xe35bd
leaq 0x22a109(%rip), %rax    # 0x30d6b0
cmpl $0x10, (%rax)
jne 0xe35bd
leaq 0x229f39(%rip), %rax    # 0x30d4ec
movl $0x1, (%rax)
movb $0x1, %al
jmp 0xe35ca
leaq 0x229f28(%rip), %rax    # 0x30d4ec
cmpl $0x0, (%rax)
setne %al
testb %al, %al
je 0xe364a
leaq 0x229f13(%rip), %r14    # 0x30d4e8
cmpl $0x1, (%r14)
je 0xe364a
leaq 0x32593(%rip), %rdi     # 0x115b75
leaq 0x3d7a4(%rip), %rsi     # 0x120d8d
callq 0x9a47
testq %rax, %rax
je 0xe363d
movq %rax, %rbx
leaq 0x258c23(%rip), %rdi    # 0x33c220
movl $0x200, %esi            # imm = 0x200
movq %rax, %rdx
callq 0x9600
testq %rax, %rax
je 0xe3635
leaq 0x258c0a(%rip), %rdi    # 0x33c220
callq 0x9470
divsd 0x259f5(%rip), %xmm0    # 0x109018
leaq 0x229ec6(%rip), %rax    # 0x30d4f0
movsd %xmm0, (%rax)
movl $0x2, (%r14)
movq %rbx, %rdi
callq 0x9370
leaq 0x229ea8(%rip), %rax    # 0x30d4ec
movl $0x0, (%rax)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: get_std_zone(char*, int)
char *get_std_zone(char *s, int digit_stop)
{
int c;
int j;

   if(s == 0) return s;
   if(*s == 0) return 0;

   c = 0;
   std_string[0] = 0;
   j = 0;
   while(j < 20) {
      c = *s;
      if(c == '/') break;
      if(c == '-') break;
      if(c == '+') break;
      if(digit_stop && isdigit(c)) break;

      ++s;
      if(c == ' ') continue;
      if(c == '\t') continue;

      std_string[j++] = toupper(c);
      std_string[j] = 0;

      if(j >= TZ_NAME_LEN) break;
      else if(*s == 0)    { s=0; break; }
      else if(*s == 0x0D) { s=0; break; }
      else if(*s == 0x0A) { s=0; break; }
   }

   if(std_string[0] == 0) strcpy(std_string, tz_string);
   return s;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, -0x30(%rbp)
testq %rdi, %rdi
je 0xe38bc
movq %rdi, %r15
cmpb $0x0, (%rdi)
je 0xe38bc
leaq 0x22a108(%rip), %rdx    # 0x30d920
movb $0x0, (%rdx)
xorl %esi, %esi
movq %r15, %rbx
movb (%r15), %al
movslq %esi, %r12
cmpl $0x5, %r12d
movl $0x4, %ecx
movl %esi, -0x2c(%rbp)
cmovgel %esi, %ecx
leaq (%rdx,%r12), %r13
incq %r13
subq %rcx, %r12
incq %r15
xorl %r14d, %r14d
movzbl %al, %ecx
cmpb $0x2f, %al
ja 0xe385c
movabsq $0xa80000000000, %rdx   # imm = 0xA80000000000
btq %rcx, %rdx
jb 0xe38c0
movsbl %al, %edi
cmpl $0x0, -0x30(%rbp)
je 0xe386d
leal -0x30(%rdi), %edx
cmpl $0xa, %edx
jb 0xe38ca
cmpb $0x9, %al
je 0xe38aa
cmpl $0x20, %ecx
je 0xe38aa
callq 0x9700
movb %al, -0x1(%r13)
movb $0x0, (%r13)
cmpq %r14, %r12
je 0xe38c3
incq %rbx
movzbl (%r15), %eax
decq %r14
incq %r13
incq %r15
cmpl $0xd, %eax
ja 0xe3845
movl $0x2401, %ecx           # imm = 0x2401
btl %eax, %ecx
jae 0xe3845
jmp 0xe38c8
movl -0x2c(%rbp), %esi
subl %r14d, %esi
leaq 0x22a069(%rip), %rdx    # 0x30d920
jmp 0xe381d
xorl %ebx, %ebx
jmp 0xe38e9
decq %r15
movq %r15, %rbx
jmp 0xe38ca
xorl %ebx, %ebx
leaq 0x22a04f(%rip), %rax    # 0x30d920
cmpb $0x0, (%rax)
jne 0xe38e9
leaq 0x22a043(%rip), %rdi    # 0x30d920
leaq 0x22a04c(%rip), %rsi    # 0x30d930
callq 0x9340
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: get_dst_zone(char*)
char *get_dst_zone(char *s)
{
int c;
int j;

   if(dst_area == 0) dst_area = USA;
   dst_string[0] = 0;
   j = 0;
   while(j < 20) {
      c = *s;
      if(c == 0) { s=0; break; }
      ++s;

      if(c == '/') break;
      if(c == ' ') continue;
      if(c == '\t') continue;

      dst_string[j++] = toupper(c);
      dst_string[j] = 0;

      if     (j >= TZ_NAME_LEN) break;
      else if(*s == 0)    { s=0; break; }
      else if(*s == 0x0D) { s=0; break; }
      else if(*s == 0x0A) { s=0; break; }
   }

   if(1 && (user_set_dst == 0)) {  // user has not set the DST area
      strcpy(out, dst_string);
      strupr(out);
      if(strcmp(out, "BST") == 0) {  // UK/euro time
         dst_area = 2;  // set the DST area to Euro-land
      }
      else {  // assume USA
         dst_area = 1;
      }
      calc_dst_times(this_year, dst_list[dst_area]);
      dst_ofs = dst_offset();
   }

   return s;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
leaq 0x229f89(%rip), %rax    # 0x30d89c
cmpl $0x0, (%rax)
jne 0xe391e
movl $0x1, (%rax)
leaq 0x22a003(%rip), %rdx    # 0x30d928
movb $0x0, (%rdx)
xorl %ecx, %ecx
movb (%r14), %al
movl %ecx, -0x2c(%rbp)
movslq %ecx, %rcx
cmpl $0x5, %ecx
movl $0x4, %r12d
cmovgel %ecx, %r12d
subq %rcx, %r12
leaq (%rdx,%rcx), %r15
incq %r15
xorl %r13d, %r13d
movq %r14, %rbx
testb %al, %al
je 0xe39b1
cmpb $0x9, %al
je 0xe3999
movzbl %al, %ecx
cmpl $0x20, %ecx
je 0xe3999
cmpl $0x2f, %ecx
je 0xe39b5
movsbl %al, %edi
incq %rbx
callq 0x9700
movb %al, -0x1(%r15,%r13)
movb $0x0, (%r15,%r13)
cmpq %r13, %r12
je 0xe39bc
movzbl 0x1(%r14,%r13), %eax
incq %r13
cmpl $0xd, %eax
ja 0xe3950
movl $0x2401, %ecx           # imm = 0x2401
btl %eax, %ecx
jae 0xe3950
jmp 0xe39b1
movl -0x2c(%rbp), %ecx
addl %r13d, %ecx
addq %r13, %r14
incq %r14
leaq 0x229f7c(%rip), %rdx    # 0x30d928
jmp 0xe392a
xorl %ebx, %ebx
jmp 0xe39bc
leaq (%r14,%r13), %rbx
incq %rbx
leaq 0x229ee1(%rip), %rax    # 0x30d8a4
cmpb $0x0, (%rax)
jne 0xe3a24
leaq 0x258851(%rip), %r14    # 0x33c220
leaq 0x229f52(%rip), %rsi    # 0x30d928
movq %r14, %rdi
callq 0x9340
movq %r14, %rdi
callq 0x9899
xorl %eax, %eax
cmpl $0x545342, (%r14)       # imm = 0x545342
sete %al
incl %eax
leaq 0x229ea1(%rip), %rcx    # 0x30d89c
movl %eax, (%rcx)
leaq 0x229b1c(%rip), %rcx    # 0x30d520
movl (%rcx), %edi
leaq 0x86e23(%rip), %rcx     # 0x16a830
movq (%rcx,%rax,8), %rsi
callq 0xe1326
callq 0xe1630
leaq 0x229e7e(%rip), %rcx    # 0x30d8a0
movl %eax, (%rcx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: time_sync_median(double)
double time_sync_median(double delta)
{
int i;
int k, m;

   // This routine calculates the median of a string of system clock vs 
   // receiver time samples.  It returns 0 if median is not available,
   // otherwise it returns the value of the median.  This value is used
   // to determine when the system clock has diverged enough from
   // the reseiver time to cause a system clock reset.

   if(clk_sort_count < 0) clk_sort_count = 0;

   if(clk_sort_count >= CLK_SORT-1) {  // we have enough samples, get the median value
      delta = clk_sort[clk_sort_count/2];
      delta += clk_sort[clk_sort_count/2-1];
      delta += clk_sort[clk_sort_count/2+1];
      delta /= 3.0;
      clk_sort_count = 0;
      return fabs(delta);
   }

   if(clk_sort_count == 0) {   // first entry
      clk_sort[clk_sort_count] = delta;
      ++clk_sort_count;
      goto show_sort;
   }

   if(delta >= clk_sort[clk_sort_count-1]) {  // insert at end of list
      clk_sort[clk_sort_count] = delta;
      ++clk_sort_count;
      goto show_sort;
   }

   for(i=0; i<=clk_sort_count; i++) {  // insert new value into sorted list
      for(k=0; k<clk_sort_count; k++) {  // see where this value lies in the list so far
         if(delta > clk_sort[k]) continue;  // it's greater than the current value

         for(m=clk_sort_count; m>k; m--) {  // move lower value entries down one position
            clk_sort[m] = clk_sort[m-1];
         }

         clk_sort[k] = delta;   // insert new value in the list
         ++clk_sort_count;
         goto show_sort;
      }
   }
   return 0.0;

   show_sort:
// sprintf(plot_title, "sort %d: ", clk_sort_count);  // rrrrr
// for(i=0; i<clk_sort_count; i++) {
//    sprintf(out, "%.1f ", clk_sort[i]);
//    strcat(plot_title, out);
// }

   return 0.0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl 0x295c94(%rip), %eax    # 0x37aa80
testl %eax, %eax
js 0xe4e6f
cmpl $0xa, %eax
jb 0xe4e2e
shrl %eax
leaq 0x295c22(%rip), %rcx    # 0x37aa20
movsd (%rcx,%rax,8), %xmm0
movl %eax, %edx
decl %edx
addsd (%rcx,%rdx,8), %xmm0
addsd 0x8(%rcx,%rax,8), %xmm0
divsd 0x26bee(%rip), %xmm0    # 0x10ba08
movl $0x0, 0x295c5c(%rip)    # 0x37aa80
andpd 0x24364(%rip), %xmm0    # 0x109190
jmp 0xe4e85
testq %rax, %rax
je 0xe4e6f
leal -0x1(%rax), %ecx
leaq 0x295be3(%rip), %rdx    # 0x37aa20
ucomisd (%rdx,%rcx,8), %xmm0
jae 0xe4e87
leal 0x1(%rax), %ecx
xorl %r8d, %r8d
movq %rdx, %rsi
xorl %edi, %edi
ucomisd (%rsi), %xmm0
jbe 0xe4e96
incq %rdi
addq $0x8, %rsi
cmpq %rdi, %rax
jne 0xe4e4f
leal 0x1(%r8), %esi
cmpl %eax, %r8d
movl %esi, %r8d
jne 0xe4e4a
jmp 0xe4e81
movsd %xmm0, 0x295ba9(%rip)   # 0x37aa20
movl $0x1, 0x295bff(%rip)    # 0x37aa80
xorpd %xmm0, %xmm0
popq %rbp
retq
movsd %xmm0, (%rdx,%rax,8)
incl %eax
movl %eax, 0x295bec(%rip)    # 0x37aa80
jmp 0xe4e81
cmpl %edi, %eax
jle 0xe4eb8
leaq 0x295b7f(%rip), %rdx    # 0x37aa20
movsd -0x8(%rdx,%rax,8), %xmm1
movsd %xmm1, (%rdx,%rax,8)
leaq -0x1(%rax), %r8
movq %r8, %rax
cmpq %rdi, %r8
jg 0xe4ea1
movsd %xmm0, (%rsi)
movl %ecx, 0x295bbe(%rip)    # 0x37aa80
jmp 0xe4e81
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: moon_phase(double)
double moon_phase(double jd)
{
double ls;
double lm;
double p;

   //
   //  Calculates the phase of the moon at the given julian date.
   //  returns the moon phase as a real number (0-1)
   //
   ++sp_count;

   ls = sun_position(jd);       // geocentric (?) longitude of sun
   lm = moon_position(jd, ls);  // geocentric (?) longitude of moon

   p = (1.0 - cos((lm-ls)*DEG_TO_RAD))/2.0;
   return p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movsd %xmm0, -0x10(%rbp)
incl 0x29556e(%rip)          # 0x37a5b4
callq 0xe6360
movaps %xmm0, %xmm1
movsd %xmm0, -0x8(%rbp)
movsd -0x10(%rbp), %xmm0
callq 0xe652c
subsd -0x8(%rbp), %xmm0
mulsd 0x268a6(%rip), %xmm0    # 0x10b910
callq 0x9710
movsd 0x23ff9(%rip), %xmm1    # 0x109070
subsd %xmm0, %xmm1
mulsd 0x23fe5(%rip), %xmm1    # 0x109068
movapd %xmm1, %xmm0
addq $0x10, %rsp
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: set_holiday(int, int, int)
int set_holiday(int index, int m, int d)
{
int i;

   // search the holiday table for the specially calculated event
   // and set the month and day that it happens on in this year
//printf("set holiday: %d %d %d\n", index, m, d);
   for(i=0; i<MAX_HOLIDAYS; i++) {
      if(holiday[i].nth == index) {
         if(holiday[i].month) {  // do not enable a message that has been disabled
            holiday[i].month = m;
            holiday[i].day = d;
         }
         return i;
      }
   }
   return (-1);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x85dc0(%rip), %rcx     # 0x16ae58
xorl %eax, %eax
cmpl %edi, -0x8(%rcx)
je 0xe50b5
incq %rax
addq $0x18, %rcx
cmpq $0x16e, %rax            # imm = 0x16E
jne 0xe509a
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0xe50bf
cmpl $0x0, (%rcx)
je 0xe50bf
movl %esi, (%rcx)
movl %edx, -0x4(%rcx)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: calendar_count()
int calendar_count()
{
int start;

   // see how many dates are in the greetings list
   start = 0;
   while(start < MAX_HOLIDAYS) {
      if((holiday[start].month == 0) && (holiday[start].day == 0) && (holiday[start].nth == 0)) break;
      ++start;
   }
   return start;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x85d8c(%rip), %rcx     # 0x16ae58
xorl %eax, %eax
cmpl $0x0, (%rcx)
jne 0xe50df
cmpl $0x0, -0x4(%rcx)
jne 0xe50df
cmpl $0x0, -0x8(%rcx)
je 0xe50f3
incq %rax
addq $0x18, %rcx
cmpq $0x16e, %rax            # imm = 0x16E
jne 0xe50ce
movl $0x16e, %eax            # imm = 0x16E
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: clear_calendar()
void clear_calendar()
{
int start;

   // clear the greetings list
   start = 0;
   while(start < MAX_HOLIDAYS) {
      holiday[start].month = 0;
      holiday[start].day = 0;
      holiday[start].nth = 0;
      ++start;
   }
   calendar_entries = 0;
}

// Assembly:
movl $0x8, %eax
leaq 0x85d4f(%rip), %rcx     # 0x16ae50
movl $0x0, (%rax,%rcx)
movq $0x0, -0x8(%rax,%rcx)
addq $0x18, %rax
cmpq $0x2258, %rax           # imm = 0x2258
jne 0xe5101
pushq %rbp
movq %rsp, %rbp
leaq 0x1336c8(%rip), %rax    # 0x2187f0
movl $0x0, (%rax)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: get_mayan_date()
void get_mayan_date()
{
long mayan;

   gregorian(0, jd_local);
   mayan = (long) (jdate(g_year,g_month,g_day)-jdate(1618,9,18));
   mayan = adjust_mayan(mayan);

   kin = (int) (mayan % 20L);  mayan /= 20L;
   uinal = (int) (mayan % 18L);  mayan /= 18L;
   tun = (int) (mayan % 20L);  mayan /= 20L;
   katun = (int) (mayan % 20L);  mayan /= 20L;
   baktun = (int) ((mayan % 20L)+12L);  mayan /= 20L;  // Baktun 12 started in 1618, 13 started in 2012
   pictun = (int) (mayan % 20L);  mayan /= 20L;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x2275b2(%rip), %rax    # 0x30d548
movsd (%rax), %xmm0
xorl %ebx, %ebx
xorl %edi, %edi
callq 0xd12da
leaq 0x2276fa(%rip), %rax    # 0x30d6a4
movl (%rax), %edi
leaq 0x2276e9(%rip), %rax    # 0x30d69c
movl (%rax), %esi
leaq 0x2276e4(%rip), %rax    # 0x30d6a0
movl (%rax), %edx
callq 0xd485e
addsd 0x45c95(%rip), %xmm0    # 0x12bc60
cvttsd2si %xmm0, %rcx
leaq 0x135461(%rip), %rax    # 0x21b438
movq (%rax), %rax
movq %rcx, %rsi
subq %rax, %rsi
leaq 0x8ea5b(%rsi), %rdx
testq %rdx, %rdx
cmovgq %rdx, %rbx
addq %rbx, %rax
addq $-0x8ea5b, %rax         # imm = 0xFFF715A5
xorl %edi, %edi
subq %rcx, %rax
setne %dil
subq %rdi, %rax
movabsq $-0x45962422c53ec283, %r8 # imm = 0xBA69DBDD3AC13D7D
mulq %r8
shrq $0x15, %rdx
addq %rdi, %rdx
imulq $0x2bf200, %rdx, %rax   # imm = 0x2BF200
leaq (%rsi,%rax), %rcx
addq $0x8ea5b, %rcx          # imm = 0x8EA5B
movabsq $-0x3333333333333333, %rdx # imm = 0xCCCCCCCCCCCCCCCD
movq %rcx, %rax
mulq %rdx
movq %rdx, %rsi
shrq $0x4, %rsi
leal (,%rsi,4), %eax
leal (%rax,%rax,4), %eax
movq %rcx, %rdi
movl %ecx, %r9d
subl %eax, %r9d
movabsq $0xe38e38e38e38e39, %rdx # imm = 0xE38E38E38E38E39
movq %rsi, %rax
mulq %rdx
movl %r9d, 0x2953d2(%rip)    # 0x37b43c
addl %edx, %edx
leal (%rdx,%rdx,8), %eax
subl %eax, %esi
movl %esi, 0x2953c9(%rip)    # 0x37b440
movabsq $0x2d82d82d82d82d83, %rdx # imm = 0x2D82D82D82D82D83
movq %rcx, %rax
mulq %rdx
movq %rdx, %rsi
shrq $0x6, %rsi
movabsq $0xccccccccccccccd, %r9 # imm = 0xCCCCCCCCCCCCCCD
movq %rsi, %rax
mulq %r9
shll $0x2, %edx
leal (%rdx,%rdx,4), %eax
subl %eax, %esi
movl %esi, 0x295398(%rip)    # 0x37b444
shrq $0x5, %rdi
movabsq $0x91a2b3c4d5e6f81, %rdx # imm = 0x91A2B3C4D5E6F81
movq %rdi, %rax
mulq %rdx
movq %rdx, %rsi
shrq $0x3, %rsi
movq %rsi, %rax
mulq %r9
shll $0x2, %edx
leal (%rdx,%rdx,4), %eax
subl %eax, %esi
movabsq $0x3a4114b5225c6337, %rdx # imm = 0x3A4114B5225C6337
movq %rcx, %rax
mulq %rdx
movq %rdx, %rdi
shrq $0xf, %rdi
movq %rdi, %rax
mulq %r9
movl %esi, 0x295350(%rip)    # 0x37b448
shll $0x2, %edx
leal (%rdx,%rdx,4), %eax
subl %eax, %edi
addl $0xc, %edi
movl %edi, 0x295343(%rip)    # 0x37b44c
movq %rcx, %rax
mulq %r8
movq %rdx, %rcx
shrq $0x15, %rcx
movq %rcx, %rax
mulq %r9
shll $0x2, %edx
leal (%rdx,%rdx,4), %eax
subl %eax, %ecx
movl %ecx, 0x295326(%rip)    # 0x37b450
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: sun_position(double)
double sun_position(double jd)
{
double n,x,e,l,dl,v;
int i;
double ecc;

//  ecc = 0.016718;
    ecc = orbit_eccentricity(jd);
    jd -= 2444238.5;

    n = (360.0/SOLAR_YEAR) * jd;
    i = (int) (n / 360.0);
    n = n - 360.0 * (double) i;
    x = n - 3.762863;
    if(x < 0.0) x += 360.0;
    x *= DEG_TO_RAD;
    e = x;

    i = 0;
    do {  // solve Keppler's equation
        dl = e - (ecc*sin(e)) - x;
        e  = e - (dl / (1.0 - (ecc*cos(e))));
        if(++i > 10) break;
    } while (fabs(dl) >= SMALL_FLOAT);

    v = (360.0 / PI) * atan(1.01686011182*tan(e/2));
    l = v + 282.596403;
    i = (int) (l / 360.0);
    l = l - 360.0 * (double) i;
    return l;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x38, %rsp
movsd 0x454bf(%rip), %xmm2    # 0x12b830
addsd %xmm0, %xmm2
divsd 0x4568b(%rip), %xmm2    # 0x12ba08
movsd 0x4568b(%rip), %xmm1    # 0x12ba10
mulsd %xmm2, %xmm1
addsd 0x45687(%rip), %xmm1    # 0x12ba18
movsd 0x45687(%rip), %xmm3    # 0x12ba20
mulsd %xmm2, %xmm3
mulsd %xmm2, %xmm3
addsd %xmm1, %xmm3
movsd 0x4567b(%rip), %xmm4    # 0x12ba28
mulsd %xmm2, %xmm4
mulsd %xmm2, %xmm4
mulsd %xmm2, %xmm4
addsd %xmm3, %xmm4
movsd 0x4566b(%rip), %xmm1    # 0x12ba30
mulsd %xmm2, %xmm1
mulsd %xmm2, %xmm1
mulsd %xmm2, %xmm1
mulsd %xmm2, %xmm1
addsd %xmm4, %xmm1
movsd 0x45657(%rip), %xmm4    # 0x12ba38
mulsd %xmm2, %xmm4
mulsd %xmm2, %xmm4
mulsd %xmm2, %xmm4
mulsd %xmm2, %xmm4
addsd 0x4586f(%rip), %xmm0    # 0x12bc68
mulsd %xmm2, %xmm4
mulsd 0x456db(%rip), %xmm0    # 0x12bae0
movsd 0x37d2b(%rip), %xmm2    # 0x11e138
movapd %xmm0, %xmm3
divsd %xmm2, %xmm3
cvttpd2dq %xmm3, %xmm3
cvtdq2pd %xmm3, %xmm3
mulsd 0x456a3(%rip), %xmm3    # 0x12bac8
addsd %xmm0, %xmm3
addsd 0x4583f(%rip), %xmm3    # 0x12bc70
addsd %xmm3, %xmm2
xorpd %xmm0, %xmm0
movapd %xmm3, %xmm5
cmpltsd %xmm0, %xmm5
andpd %xmm5, %xmm2
andnpd %xmm3, %xmm5
orpd %xmm2, %xmm5
mulsd 0x254ba(%rip), %xmm5    # 0x10b910
addsd %xmm1, %xmm4
xorpd 0x22d4e(%rip), %xmm4    # 0x1091b0
movapd %xmm4, -0x20(%rbp)
movl $0xb, %ebx
movapd %xmm5, -0x30(%rbp)
movapd %xmm5, %xmm0
movsd %xmm0, -0x10(%rbp)
movsd -0x10(%rbp), %xmm0
callq 0x9080
mulsd -0x20(%rbp), %xmm0
addsd -0x10(%rbp), %xmm0
subsd -0x30(%rbp), %xmm0
movapd %xmm0, -0x40(%rbp)
movsd -0x10(%rbp), %xmm0
callq 0x9710
movapd -0x40(%rbp), %xmm2
mulsd -0x20(%rbp), %xmm0
addsd 0x22bbc(%rip), %xmm0    # 0x109070
movapd %xmm2, %xmm1
divsd %xmm0, %xmm1
movsd -0x10(%rbp), %xmm0
subsd %xmm1, %xmm0
decl %ebx
je 0xe64db
andpd 0x22cbf(%rip), %xmm2    # 0x109190
ucomisd 0x37d1f(%rip), %xmm2    # 0x11e1f8
jae 0xe6475
mulsd 0x22b85(%rip), %xmm0    # 0x109068
callq 0x91b0
mulsd 0x45788(%rip), %xmm0    # 0x12bc78
callq 0x92d0
mulsd 0x455fb(%rip), %xmm0    # 0x12baf8
addsd 0x4577b(%rip), %xmm0    # 0x12bc80
movapd %xmm0, %xmm1
divsd 0x37c27(%rip), %xmm1    # 0x11e138
cvttpd2dq %xmm1, %xmm1
cvtdq2pd %xmm1, %xmm1
mulsd 0x455a7(%rip), %xmm1    # 0x12bac8
addsd %xmm1, %xmm0
addq $0x38, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: moon_position(double, double)
double moon_position(double jd, double ls)
{
double ms,l,mm,n,ev,sms,ae,ec;
int i;

    jd -= 2444238.5;

    /* ls = sun_position(jd) */
    ms = 0.985647332099*jd - 3.762863;
    if(ms < 0) ms += 360.0;
    l = 13.176396*jd + 64.975464;
    i = (int) (l / 360.0);
    l = l - (360.0*(double) i);
    if(l < 0) l += 360.0;
    mm = l - 0.1114041*jd - 349.383063;
    i = (int) (mm / 360.0);
    mm -= 360.0 * (double) i;
    n = 151.950429 - 0.0529539*jd;
    i = (int) (n / 360.0);
    n -= 360.0 * (double) i;
    ev = 1.2739 * sin((2*(l-ls)-mm)*DEG_TO_RAD);
    sms = sin(ms*DEG_TO_RAD);
    ae = 0.1858 * sms;
    mm += ev - ae - 0.37*sms;
    ec = 6.2886 * sin(mm*DEG_TO_RAD);
    l += ev + ec - ae + 0.214*sin(2.0*mm*DEG_TO_RAD);
    l= 0.6583 * sin(2*(l-ls)*DEG_TO_RAD)+l;

    return l;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movsd %xmm1, -0x28(%rbp)
addsd 0x45727(%rip), %xmm0    # 0x12bc68
movsd 0x4573f(%rip), %xmm4    # 0x12bc88
mulsd %xmm0, %xmm4
addsd 0x4571b(%rip), %xmm4    # 0x12bc70
movsd 0x37bdb(%rip), %xmm6    # 0x11e138
movapd %xmm4, %xmm2
addsd %xmm6, %xmm2
xorpd %xmm3, %xmm3
movapd %xmm4, %xmm5
cmpltsd %xmm3, %xmm5
andpd %xmm5, %xmm2
andnpd %xmm4, %xmm5
movapd %xmm5, %xmm7
movsd 0x4570a(%rip), %xmm5    # 0x12bc90
mulsd %xmm0, %xmm5
addsd 0x45706(%rip), %xmm5    # 0x12bc98
movapd %xmm5, %xmm4
divsd %xmm6, %xmm4
cvttpd2dq %xmm4, %xmm4
orpd %xmm2, %xmm7
movapd %xmm7, -0x20(%rbp)
cvtdq2pd %xmm4, %xmm2
movsd 0x45515(%rip), %xmm4    # 0x12bac8
mulsd %xmm4, %xmm2
addsd %xmm5, %xmm2
movapd %xmm2, %xmm5
addsd %xmm6, %xmm5
movapd %xmm2, %xmm7
cmpltsd %xmm3, %xmm7
andpd %xmm7, %xmm5
andnpd %xmm2, %xmm7
orpd %xmm5, %xmm7
mulsd 0x456c0(%rip), %xmm0    # 0x12bca0
addsd %xmm7, %xmm0
movapd %xmm7, -0x40(%rbp)
addsd 0x456b7(%rip), %xmm0    # 0x12bca8
movapd %xmm0, %xmm2
movapd %xmm0, %xmm3
divsd %xmm6, %xmm2
cvttpd2dq %xmm2, %xmm0
cvtdq2pd %xmm0, %xmm0
mulsd %xmm4, %xmm0
addsd %xmm0, %xmm3
movsd %xmm3, -0x10(%rbp)
movapd %xmm7, %xmm0
subsd %xmm1, %xmm0
addsd %xmm0, %xmm0
subsd %xmm3, %xmm0
mulsd 0x252e6(%rip), %xmm0    # 0x10b910
callq 0x9080
mulsd 0x45679(%rip), %xmm0    # 0x12bcb0
movsd %xmm0, -0x8(%rbp)
movapd -0x20(%rbp), %xmm0
mulsd 0x252c7(%rip), %xmm0    # 0x10b910
callq 0x9080
movsd 0x45662(%rip), %xmm2    # 0x12bcb8
mulsd %xmm0, %xmm2
movsd %xmm2, -0x20(%rbp)
movsd -0x8(%rbp), %xmm1
subsd %xmm2, %xmm1
mulsd 0x45650(%rip), %xmm0    # 0x12bcc0
addsd %xmm1, %xmm0
addsd -0x10(%rbp), %xmm0
movsd %xmm0, -0x10(%rbp)
mulsd 0x2528a(%rip), %xmm0    # 0x10b910
callq 0x9080
mulsd 0x45635(%rip), %xmm0    # 0x12bcc8
addsd -0x8(%rbp), %xmm0
subsd -0x20(%rbp), %xmm0
movsd %xmm0, -0x8(%rbp)
movsd -0x10(%rbp), %xmm0
addsd %xmm0, %xmm0
mulsd 0x2525d(%rip), %xmm0    # 0x10b910
callq 0x9080
mulsd 0x45610(%rip), %xmm0    # 0x12bcd0
addsd -0x8(%rbp), %xmm0
addsd -0x40(%rbp), %xmm0
movsd %xmm0, -0x8(%rbp)
subsd -0x28(%rbp), %xmm0
addsd %xmm0, %xmm0
mulsd 0x25230(%rip), %xmm0    # 0x10b910
callq 0x9080
mulsd 0x455eb(%rip), %xmm0    # 0x12bcd8
addsd -0x8(%rbp), %xmm0
addq $0x40, %rsp
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: xmoon_info(double)
double xmoon_info(double jd)
{
double jd_new, jd_next;

   ++sp_count;

   jd_new = new_moon(jd);
   jd_next = new_moon(jd+31.0);
   MoonSynod = (jd_next-jd_new);
   if(MoonSynod == 0.0) MoonSynod = synmonth;

   MoonAge = ((jd - jd_new) / MoonSynod) * 360.0; // in degrees
   MoonAge = fmod(MoonAge, 360.0);
   MoonPhase = (1.0 - cos(MoonAge*PI/180.0)) / 2.0;

   MoonAge = MoonSynod * (MoonAge / 360.0);  // in days

   lunation = (long) floor(((jd_new + 7.0) - lunatbase) / MoonSynod) + 1;
//sprintf(debug_text, "jd:%f  jd_new:%f  next:%f  synod:%f  age:%f  lunat:%d  phase:%f", 
//jd,jd_new, jd_next, MoonSynod, MoonAge, lunation, MoonPhase);
   return MoonPhase;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movsd %xmm0, -0x18(%rbp)
incl 0x293ea6(%rip)          # 0x37a5b4
callq 0xe681a
movsd %xmm0, -0x20(%rbp)
movsd 0x455c0(%rip), %xmm0    # 0x12bce0
addsd -0x18(%rbp), %xmm0
callq 0xe681a
movsd -0x20(%rbp), %xmm3
subsd %xmm3, %xmm0
xorpd %xmm1, %xmm1
cmpeqsd %xmm0, %xmm1
movsd 0x455a4(%rip), %xmm2    # 0x12bce8
andpd %xmm1, %xmm2
andnpd %xmm0, %xmm1
orpd %xmm1, %xmm2
leaq 0x2270f1(%rip), %rbx    # 0x30d848
movlpd %xmm2, (%rbx)
movsd -0x18(%rbp), %xmm0
subsd %xmm3, %xmm0
divsd %xmm2, %xmm0
movsd 0x379c8(%rip), %xmm1    # 0x11e138
mulsd %xmm1, %xmm0
callq 0x94d0
leaq 0x2270b8(%rip), %r14    # 0x30d838
movsd %xmm0, (%r14)
mulsd 0x2509b(%rip), %xmm0    # 0x10b828
divsd 0x2509b(%rip), %xmm0    # 0x10b830
callq 0x9710
movsd 0x228ce(%rip), %xmm1    # 0x109070
subsd %xmm0, %xmm1
mulsd 0x228ba(%rip), %xmm1    # 0x109068
movsd %xmm1, -0x18(%rbp)
leaq 0x227086(%rip), %rax    # 0x30d840
movsd %xmm1, (%rax)
movsd (%rbx), %xmm0
movsd (%r14), %xmm1
divsd 0x37969(%rip), %xmm1    # 0x11e138
mulsd %xmm0, %xmm1
movsd -0x20(%rbp), %xmm2
addsd 0x25128(%rip), %xmm2    # 0x10b908
movsd %xmm1, (%r14)
addsd 0x45503(%rip), %xmm2    # 0x12bcf0
divsd %xmm0, %xmm2
movapd %xmm2, %xmm0
callq 0x9680
cvttsd2si %xmm0, %rax
incq %rax
leaq 0x22706f(%rip), %rcx    # 0x30d878
movq %rax, (%rcx)
movsd -0x18(%rbp), %xmm0
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: FNrange(double)
double FNrange(double x)
{
double a, b;

    b = x / (PI+PI);
    a = (PI+PI) * (b - FNipart(b));
    if(a < 0) a = (PI+PI) + a;
    return a;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movsd 0x36fe8(%rip), %xmm1    # 0x11e180
divsd %xmm1, %xmm0
xorpd %xmm2, %xmm2
xorl %eax, %eax
ucomisd %xmm2, %xmm0
setae %al
movapd 0x21fdf(%rip), %xmm3    # 0x109190
andpd %xmm0, %xmm3
cvttpd2dq %xmm3, %xmm3
cvtdq2pd %xmm3, %xmm3
leaq 0x25d2c(%rip), %rcx     # 0x10cef0
mulsd (%rcx,%rax,8), %xmm3
addsd %xmm0, %xmm3
mulsd %xmm1, %xmm3
addsd %xmm3, %xmm1
movapd %xmm3, %xmm0
cmpltsd %xmm2, %xmm0
andpd %xmm0, %xmm1
andnpd %xmm3, %xmm0
orpd %xmm1, %xmm0
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: earth_radius(double, double)
double earth_radius(double lat, double alt)
{
double r1,r2,r3,r4;
double r;

   // return earth radius in km at latitude, alt (in meters)

   r1 = (EQU_RADIUS*EQU_RADIUS) * cos(lat);
   r2 = (POLE_RADIUS*POLE_RADIUS) * sin(lat);
   r3 = EQU_RADIUS * cos(lat);
   r4 = POLE_RADIUS * sin(lat);

   r = (r3*r3) + (r4*r4);
   if(r == 0.0) r = dEarthMeanRadius;
   else {
      r = ((r1*r1) + (r2*r2)) / r;
      if(r > 0.0) r = sqrt(r);
      else r = dEarthMeanRadius;
   }

   return r + (alt / 1000.0);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movsd %xmm1, -0x28(%rbp)
movsd %xmm0, -0x8(%rbp)
callq 0x9710
movsd %xmm0, -0x18(%rbp)
movsd -0x8(%rbp), %xmm0
callq 0x9080
movsd %xmm0, -0x10(%rbp)
movsd -0x8(%rbp), %xmm0
callq 0x9710
mulsd 0x43d72(%rip), %xmm0    # 0x12bea8
movsd %xmm0, -0x20(%rbp)
movsd -0x8(%rbp), %xmm0
callq 0x9080
movsd -0x20(%rbp), %xmm4
mulsd 0x43d5e(%rip), %xmm0    # 0x12beb0
mulsd %xmm0, %xmm0
mulsd %xmm4, %xmm4
addsd %xmm0, %xmm4
movsd 0x43d52(%rip), %xmm2    # 0x12beb8
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm4
jne 0xe8172
jnp 0xe81a9
movsd -0x10(%rbp), %xmm3
mulsd 0x43d41(%rip), %xmm3    # 0x12bec0
movsd -0x18(%rbp), %xmm0
mulsd 0x43d3c(%rip), %xmm0    # 0x12bec8
mulsd %xmm3, %xmm3
mulsd %xmm0, %xmm0
addsd %xmm3, %xmm0
divsd %xmm4, %xmm0
ucomisd %xmm1, %xmm0
jbe 0xe81a9
xorps %xmm2, %xmm2
sqrtsd %xmm0, %xmm2
movsd -0x28(%rbp), %xmm0
divsd 0x20e82(%rip), %xmm0    # 0x109038
addsd %xmm2, %xmm0
addq $0x30, %rsp
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: sun_peak(double, int)
double sun_peak(double jd, int do_moon)
{
double peak;
#define PEAK_THRESH1 (5.0*PI/180.0)  // prevents search instability near the equator
#define PEAK_THRESH2 (80.0*PI/180.0) // longitude/azimuth gets ambiguous near the poles 

   // used to find the "peak" solar position.  Near the equator and poles this is
   // the actual solar elevation angle.  Otherwise it is where the sun crosses
   // crosses 180.0 degrees azimuth (northern hemisphere) or 0 degrees (southern)

   peak = sun_posn(jd, do_moon);

   // looking for peak in sun elevation
   if(0 && do_moon) return peak;
   else if((lat > (0.0-PEAK_THRESH1)) && (lat < PEAK_THRESH1)) return peak;
   else if(lat > PEAK_THRESH2) return peak;
   else if(lat < (0.0-PEAK_THRESH2)) return peak;
// else return peak;  // always use sun elevation

   // look for sun azimuth nearest 180.0 (or 0.0 below the equator)
   peak = sun_az;
   if(lat < 0.0) peak = fmod(peak+180.0, 360.0);
   if(peak > 180.0) return 360.0-peak;
   else return peak;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
callq 0xe823e
leaq 0x224e00(%rip), %rax    # 0x30cfd0
movsd (%rax), %xmm1
movapd 0x20fb4(%rip), %xmm2    # 0x109190
andpd %xmm1, %xmm2
movsd 0x43ce8(%rip), %xmm3    # 0x12bed0
ucomisd %xmm2, %xmm3
ja 0xe823c
ucomisd 0x43ce2(%rip), %xmm2    # 0x12bed8
ja 0xe823c
leaq 0x2255d1(%rip), %rax    # 0x30d7d0
movsd (%rax), %xmm0
xorpd %xmm2, %xmm2
ucomisd %xmm1, %xmm2
jbe 0xe8222
addsd 0x2361b(%rip), %xmm0    # 0x10b830
movsd 0x35f1b(%rip), %xmm1    # 0x11e138
callq 0x94d0
ucomisd 0x23606(%rip), %xmm0    # 0x10b830
jbe 0xe823c
movsd 0x35f04(%rip), %xmm1    # 0x11e138
subsd %xmm0, %xmm1
movapd %xmm1, %xmm0
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: interp_solar_noon(double, double, int)
double interp_solar_noon(double start, double end, int do_moon)
{
double start_el, mid_el, end_el;
double mid;
double pct, delta;

// return (start+end) / 2.0;

   if((lat > (0.0-PEAK_THRESH1)) && (lat < PEAK_THRESH1)) return (start+end)/2.0;
   else if(lat > PEAK_THRESH2) return (start+end)/2.0; 
   else if(lat < (0.0-PEAK_THRESH2)) return (start+end)/2.0; 

   start_el = sun_peak(start, do_moon);
   end_el = 360.0 - sun_peak(end, do_moon);
   delta = end_el - start_el;
   if(delta == 0.0) return (start+end) / 2.0;

   pct = (180.0 - start_el) / delta;
   mid = start + (end-start) * pct;


if(0 && debug_file) {
   mid_el = sun_peak(mid, do_moon);
   fprintf(debug_file, "\ninterp noon: start:%f mid:%f end:%f\n", start,mid,end);
   fprintf(debug_file, "start_el:%f mid_el:%f end_el:%f  pct:%f\n", start_el,mid_el,end_el, pct);
   gregorian(0, mid+time_zone());
   fprintf(debug_file, "noon (utc): %02d:%02d:%02d %f  %04d/%02d/%02d  tz:%f\n\n", g_hours,g_minutes,g_seconds,g_frac, g_year,g_month,g_day, time_zone());
}
   return mid;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x18, %rsp
leaq 0x224631(%rip), %rax    # 0x30cfd0
movsd (%rax), %xmm3
movapd 0x207e5(%rip), %xmm4    # 0x109190
andpd %xmm3, %xmm4
movsd 0x43519(%rip), %xmm2    # 0x12bed0
ucomisd %xmm4, %xmm2
ja 0xe89d5
ucomisd 0x43513(%rip), %xmm3    # 0x12bed8
ja 0xe89d5
movsd 0x35e89(%rip), %xmm2    # 0x11e858
ucomisd %xmm3, %xmm2
jbe 0xe89e8
addsd %xmm1, %xmm0
mulsd 0x20687(%rip), %xmm0    # 0x109068
addq $0x18, %rsp
popq %rbx
popq %rbp
retq
movl %edi, %ebx
movsd %xmm0, -0x18(%rbp)
movsd %xmm1, -0x10(%rbp)
callq 0xe81c0
movsd %xmm0, -0x20(%rbp)
movsd -0x10(%rbp), %xmm0
movl %ebx, %edi
callq 0xe81c0
movsd -0x20(%rbp), %xmm3
movsd 0x35721(%rip), %xmm1    # 0x11e138
subsd %xmm0, %xmm1
subsd %xmm3, %xmm1
xorpd %xmm0, %xmm0
ucomisd %xmm0, %xmm1
jne 0xe8a37
jp 0xe8a37
movsd -0x18(%rbp), %xmm0
addsd -0x10(%rbp), %xmm0
jmp 0xe89d9
movsd 0x22df1(%rip), %xmm2    # 0x10b830
subsd %xmm3, %xmm2
divsd %xmm1, %xmm2
movsd -0x18(%rbp), %xmm1
movsd -0x10(%rbp), %xmm0
subsd %xmm1, %xmm0
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
jmp 0xe89e1
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: interp_sun_posn(double, double, double, int)
double interp_sun_posn(double start, double end, double zenith, int do_moon)
{
double start_el, mid_el, end_el;
double mid;
double pct, delta;

//   return (start+end) / 2.0;

   start_el = sun_posn(start, do_moon);
   end_el = sun_posn(end, do_moon);
   delta = (end_el - start_el);
   if(delta == 0.0) return ((start+end) / 2.0);

   pct = (zenith - start_el) / delta;
   mid = start + (end-start) * pct;

if(0 && debug_file) {
   mid_el = sun_posn(mid, do_moon);
   fprintf(debug_file, "interp: start:%f mid:%f end:%f\n", start,mid,end);
   fprintf(debug_file, "start_el:%f mid_el:%f end_el:%f  pct:%f\n", start_el,mid_el,end_el, pct);
   gregorian(0, mid+time_zone());
   fprintf(debug_file, "time (utc): %02d:%02d:%02d %f  %04d/%02d/%02d  tz:%f\n\n", g_hours,g_minutes,g_seconds,g_frac, g_year,g_month,g_day, time_zone());
}
   return mid;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
subq $0x28, %rsp
movl %edi, %ebx
movsd %xmm2, -0x20(%rbp)
movsd %xmm1, -0x10(%rbp)
movsd %xmm0, -0x18(%rbp)
callq 0xe823e
movsd %xmm0, -0x28(%rbp)
movsd -0x10(%rbp), %xmm0
movl %ebx, %edi
callq 0xe823e
movsd -0x28(%rbp), %xmm3
subsd %xmm3, %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0xe8cf1
jp 0xe8cf1
movsd -0x18(%rbp), %xmm0
addsd -0x10(%rbp), %xmm0
mulsd 0x20379(%rip), %xmm0    # 0x109068
jmp 0xe8d14
movsd -0x20(%rbp), %xmm2
subsd %xmm3, %xmm2
divsd %xmm0, %xmm2
movsd -0x18(%rbp), %xmm1
movsd -0x10(%rbp), %xmm0
subsd %xmm1, %xmm0
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
addq $0x28, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathmsc.cpp
// Function: earth_sun_dist(double)
double earth_sun_dist(double jd)
{
double d;
double e;
double theta;

   // in km

   e = orbit_eccentricity(jd);
   theta = ((PI*2.0)/365.2563630) * time_since_perihelion(jd);

   d = (1.0-e*e) / (1.0 + (e*cos(theta)));

   d = d*dAstronomicalUnit;
   return d;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movsd 0x41eba(%rip), %xmm1    # 0x12b830
addsd %xmm0, %xmm1
divsd 0x42086(%rip), %xmm1    # 0x12ba08
movsd 0x42086(%rip), %xmm2    # 0x12ba10
mulsd %xmm1, %xmm2
addsd 0x42082(%rip), %xmm2    # 0x12ba18
movsd 0x42082(%rip), %xmm3    # 0x12ba20
mulsd %xmm1, %xmm3
mulsd %xmm1, %xmm3
addsd %xmm2, %xmm3
movsd 0x42076(%rip), %xmm2    # 0x12ba28
mulsd %xmm1, %xmm2
mulsd %xmm1, %xmm2
mulsd %xmm1, %xmm2
addsd %xmm3, %xmm2
movsd 0x42066(%rip), %xmm3    # 0x12ba30
mulsd %xmm1, %xmm3
mulsd %xmm1, %xmm3
mulsd %xmm1, %xmm3
mulsd %xmm1, %xmm3
addsd %xmm2, %xmm3
movsd 0x42052(%rip), %xmm2    # 0x12ba38
mulsd %xmm1, %xmm2
mulsd %xmm1, %xmm2
mulsd %xmm1, %xmm2
mulsd %xmm1, %xmm2
mulsd %xmm1, %xmm2
addsd %xmm3, %xmm2
movsd %xmm2, -0x8(%rbp)
callq 0xe186a
mulsd 0x42660(%rip), %xmm0    # 0x12c070
movsd -0x8(%rbp), %xmm1
mulsd %xmm1, %xmm1
movsd 0x1f64f(%rip), %xmm2    # 0x109070
subsd %xmm1, %xmm2
movsd %xmm2, -0x10(%rbp)
callq 0x9710
mulsd -0x8(%rbp), %xmm0
addsd 0x1f634(%rip), %xmm0    # 0x109070
movsd -0x10(%rbp), %xmm1
divsd %xmm0, %xmm1
mulsd 0x4262b(%rip), %xmm1    # 0x12c078
movapd %xmm1, %xmm0
addq $0x10, %rsp
popq %rbp
retq