LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: get_ticc_char()
int get_ticc_char() 
{
u08 c;

   // Get the next byte from the TICC port (or simulation file)

   if(rcvr_type == TICC_RCVR) c = get_serial_char(RCVR_PORT);
   else                       c = get_serial_char(TICC_PORT);

   if((rcvr_type == TICC_RCVR) && (ticc_file == 0)) {  // aaattt
      echo_stream(c); // echo ticc char to a file or com device
   }
   else if(ticc_file) {  // echo ticc data to TICC capture file
      echo_ticc(c);
   }
   return c;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x1c0396(%rip), %rbx    # 0x2188d0
movl $0x10000, %r14d         # imm = 0x10000
xorl %eax, %eax
cmpq %r14, (%rbx)
setne %al
leal (%rax,%rax,2), %edi
addl $0xa, %edi
callq 0xbafb
xorq (%rbx), %r14
leaq 0x1e5e2b(%rip), %rcx    # 0x23e388
movq (%rcx), %rsi
movzbl %al, %ebx
orq %rsi, %r14
jne 0x58571
movl %ebx, %edi
callq 0x58115
jmp 0x5857d
testq %rsi, %rsi
je 0x5857d
movl %ebx, %edi
callq 0x9480
movl %ebx, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: get_enviro_char()
int get_enviro_char() 
{
u08 c;

   // Get the next byte from the environmental sensor port (or simulation file)

   if(rcvr_type == THERMO_RCVR) {
      c = get_serial_char(RCVR_PORT);
   }
   else {
      c = get_serial_char(THERMO_PORT);
   }

   if((rcvr_type == THERMO_RCVR) && (enviro_file == 0)) {  // aaattt
      echo_stream(c); // echo enviro char to a file or com device
   }
   else if(enviro_file) {  // echo enviro data to capture file
      echo_enviro(c);
   }
   return c;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x1c033e(%rip), %rbx    # 0x2188d0
movl $0x80000, %r14d         # imm = 0x80000
xorl %eax, %eax
cmpq %r14, (%rbx)
setne %al
leal (%rax,%rax,4), %edi
addl $0xa, %edi
callq 0xbafb
xorq (%rbx), %r14
leaq 0x1e5dcb(%rip), %rcx    # 0x23e380
movq (%rcx), %rsi
movzbl %al, %ebx
orq %rsi, %r14
jne 0x585c9
movl %ebx, %edi
callq 0x58115
jmp 0x585d5
testq %rsi, %rsi
je 0x585d5
movl %ebx, %edi
callq 0x9480
movl %ebx, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: drain_com_data()
void drain_com_data()
{
   // drain any data from the serial input buffer

   if(sim_file) return;
   if(rcvr_type == NO_RCVR) return;

   Sleep(250);
   while(SERIAL_DATA_AVAILABLE(RCVR_PORT)) {
      update_pwm();
      if((this_msec-com[RCVR_PORT].last_com_time) > 1000.0) { 
         break;
      }
      get_serial_char(RCVR_PORT);
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x1e5dc3(%rip), %rax    # 0x23e3c0
cmpq $0x0, (%rax)
jne 0x5866d
leaq 0x1c02c6(%rip), %rax    # 0x2188d0
cmpq $0x400, (%rax)          # imm = 0x400
je 0x5866d
movl $0xfa, %edi
callq 0xafe8
movl $0xa, %edi
callq 0xb9ad
testl %eax, %eax
je 0x5866d
leaq 0x2b5136(%rip), %rbx    # 0x30d768
leaq 0x2b5ca7(%rip), %r14    # 0x30e2e0
callq 0xd1efe
movsd (%rbx), %xmm0
subsd 0x17a08(%r14), %xmm0
ucomisd 0xb09e5(%rip), %xmm0    # 0x109038
ja 0x5866d
movl $0xa, %edi
callq 0xbafb
movl $0xa, %edi
callq 0xb9ad
testl %eax, %eax
jne 0x58639
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: get_sync_time()
void get_sync_time()
{
int bits;

   // get the approximate time the receiver sent the start bit of the message
   // (this assumes no delay through the operating system buffers)

   if(com[RCVR_PORT].baud_rate == 0) return;

   bits = 1 + com[RCVR_PORT].data_bits + com[RCVR_PORT].stop_bits;
   if(com[RCVR_PORT].parity) ++bits;
   msg_sync_msec = 0.0 - ((double) bits / (double) com[RCVR_PORT].baud_rate);

   msg_sync_msec += GetMsecs();
}

// Assembly:
leaq 0x2b5c67(%rip), %rcx    # 0x30e2e0
movl 0x159d0(%rcx), %eax
testl %eax, %eax
je 0x586d3
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl 0x159d4(%rcx), %edx
addl 0x159d8(%rcx), %edx
cmpl $0x1, 0x159dc(%rcx)
sbbl $-0x1, %edx
incl %edx
cvtsi2sd %edx, %xmm0
cvtsi2sd %eax, %xmm1
divsd %xmm1, %xmm0
xorpd %xmm1, %xmm1
subsd %xmm0, %xmm1
leaq 0x2b5064(%rip), %rbx    # 0x30d720
movsd %xmm1, (%rbx)
callq 0xae92
addsd (%rbx), %xmm0
movsd %xmm0, (%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: check_utc_ofs(int)
void check_utc_ofs(int redraw)
{
   if(have_utc_ofs) return;
   else if((pri_year > 2016) && (utc_offset < 18)) return;
   else if(utc_offset < MIN_UTC_OFFSET) return;

   if((redraw > 0) && (have_utc_ofs == 0)) need_redraw = 2000+redraw;
   if(redraw < 0) have_utc_ofs = (0 - redraw);
   else           have_utc_ofs = redraw;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x2b4c3d(%rip), %rax    # 0x30d31c
cmpl $0x0, (%rax)
jne 0x5872b
leaq 0x2b4e29(%rip), %rcx    # 0x30d514
cmpl $0x7e1, (%rcx)          # imm = 0x7E1
setge %cl
leaq 0x2b502d(%rip), %rdx    # 0x30d728
movl (%rdx), %edx
cmpl $0x12, %edx
setl %sil
andb %cl, %sil
cmpl $0x11, %edx
setl %cl
orb %sil, %cl
jne 0x5872b
testl %edi, %edi
jle 0x58727
leal 0x7d0(%rdi), %ecx
leaq 0x1c0121(%rip), %rdx    # 0x218844
movl %ecx, (%rdx)
jmp 0x58729
negl %edi
movl %edi, (%rax)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: get_unkn_message()
void get_unkn_message()
{
u08 c;

   // This routine reads and throws away messages from unknown receiver types.

   if(SERIAL_DATA_AVAILABLE(RCVR_PORT) == 0) {
      check_com_timer(RCVR_PORT);
      return;
   }
   else {
      reset_com_timer(RCVR_PORT);
   }

   c = get_com_char();
   if(com[RCVR_PORT].rcv_error) {      // parity/framing/overrun errors
      com[RCVR_PORT].rcv_error = 0;
   }

   tsip_wptr = 0;
   tsip_sync = 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl $0xa, %edi
callq 0xb9ad
movl $0xa, %edi
testl %eax, %eax
je 0x5877d
callq 0x1ea0b
callq 0x584bd
leaq 0x2b5b8b(%rip), %rax    # 0x30e2e0
cmpb $0x0, 0x17a12(%rax)
je 0x58765
movb $0x0, 0x17a12(%rax)
leaq 0x2dfae6(%rip), %rax    # 0x338252
xorl %ecx, %ecx
movw %cx, (%rax)
leaq 0x2dfade(%rip), %rax    # 0x338256
movw %cx, (%rax)
popq %rbp
retq
popq %rbp
jmp 0x1e66a
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: get_next_tsip_byte()
unsigned get_next_tsip_byte()
{
u16 c;

   if(1 && early_end) {  // we are skipping message data
      if(log_comments && (log_stream & LOG_HEX_STREAM) && log_file) {
         fprintf(log_file, "[%04X]", early_end);
         if(log_flush_mode) fflush(log_file);
      }
      return early_end;
   }

   c = get_next_tsip();  // get next data stream element
   if(c & 0xFF00) {      // we saw something that was not expected
      if(log_comments && (log_stream & LOG_HEX_STREAM) && log_file) {
         fprintf(log_file, "<%04X>", c);
         if(log_flush_mode) fflush(log_file);
      }
      early_end = c;
   }
   return c;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movzwl 0x3135f5(%rip), %edx    # 0x36bdc0
testl %edx, %edx
je 0x58827
leaq 0x1e5c3e(%rip), %rax    # 0x23e414
cmpb $0x0, (%rax)
je 0x5881b
leaq 0x1e5c2e(%rip), %rax    # 0x23e410
leaq 0x1e5b77(%rip), %rbx    # 0x23e360
movq (%rbx), %rdi
testq %rdi, %rdi
setne %cl
andb (%rax), %cl
cmpb $0x1, %cl
jne 0x5881b
leaq 0xc79b7(%rip), %rsi     # 0x1201b7
xorl %eax, %eax
callq 0x9560
leaq 0x1e5c12(%rip), %rax    # 0x23e420
cmpl $0x0, (%rax)
je 0x5881b
movq (%rbx), %rdi
callq 0x9420
movzwl 0x31359e(%rip), %eax    # 0x36bdc0
jmp 0x588af
leaq 0x2dfa26(%rip), %rcx    # 0x338254
movzwl (%rcx), %eax
leaq 0x2dfa1a(%rip), %rdx    # 0x338252
cmpw (%rdx), %ax
jae 0x58850
leal 0x1(%rax), %edx
movw %dx, (%rcx)
leaq 0x2dea06(%rip), %rcx    # 0x337250
movzbl (%rcx,%rax), %eax
jmp 0x588af
leaq 0x1e5bbd(%rip), %rax    # 0x23e414
cmpb $0x0, (%rax)
je 0x588a1
leaq 0x1e5bad(%rip), %rax    # 0x23e410
leaq 0x1e5af6(%rip), %rbx    # 0x23e360
movq (%rbx), %rdi
testq %rdi, %rdi
setne %cl
andb (%rax), %cl
cmpb $0x1, %cl
jne 0x588a1
leaq 0xc793d(%rip), %rsi     # 0x1201be
movl $0x2000, %edx           # imm = 0x2000
xorl %eax, %eax
callq 0x9560
leaq 0x1e5b8c(%rip), %rax    # 0x23e420
cmpl $0x0, (%rax)
je 0x588a1
movq (%rbx), %rdi
callq 0x9420
movw $0x2000, 0x313516(%rip) # imm = 0x2000
movl $0x2000, %eax           # imm = 0x2000
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: tsip_word()
u16 tsip_word()   /* get next two byte (word) field from binary message */
{
u08 i;
u08 word[2];
u16 c;

   for(i=0; i<2; i++) {
      c = get_next_tsip_byte();
      if(c & 0xFF00) tsip_error |= WORD_ERROR; 
      if(ENDIAN) word[i] = (u08) c;
      else       word[1-i] = (u08) c;
   }
   return * ((u16 *) (void *) &word[0]);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movb $0x1, %bl
xorl %r14d, %r14d
leaq 0x1bfee7(%rip), %r15    # 0x2187d4
leaq 0x1e667c(%rip), %r12    # 0x23ef70
callq 0x587be
cmpl $0x100, %eax            # imm = 0x100
jb 0x58905
orb $0x10, (%r12)
xorl %ecx, %ecx
cmpb $0x0, (%r15)
sete %cl
xorq %rcx, %r14
movb %al, -0x22(%rbp,%r14)
movl $0x1, %r14d
testb $0x1, %bl
movl $0x0, %ebx
jne 0x588f4
movzwl -0x22(%rbp), %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: tsip_tbyte()
u32 tsip_tbyte()   /* get next 3 byte field from binary message */
{
u08 i;
u08 word[3];
u16 c;

   for(i=0; i<3; i++) {
      c = get_next_tsip_byte();
      if(c & 0xFF00) tsip_error |= DWORD_ERROR;
      if(ENDIAN) word[i] = (u08) c;
      else       word[2-i] = (u08) c;
   }
   return * ((u32 *) (void *) &word[0]);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl $0x3, %ebx
leaq 0x1e6626(%rip), %r14    # 0x23ef70
callq 0x587be
cmpl $0x100, %eax            # imm = 0x100
jb 0x5895a
orb $0x20, (%r14)
decq %rbx
jne 0x5894a
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: tsip_dword()
u32 tsip_dword()   /* get next dword field from binary message */
{
u08 i;
u08 word[4];
u16 c;

   for(i=0; i<4; i++) {
      c = get_next_tsip_byte();
      if(c & 0xFF00) tsip_error |= DWORD_ERROR;
      if(ENDIAN) word[i] = (u08) c;
      else       word[3-i] = (u08) c;
   }
   return * ((u32 *) (void *) &word[0]);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movl $0x3, %ebx
xorl %r14d, %r14d
leaq 0x1bfe52(%rip), %r15    # 0x2187d4
leaq 0x1e65e7(%rip), %r12    # 0x23ef70
callq 0x587be
cmpl $0x100, %eax            # imm = 0x100
jb 0x5899a
orb $0x20, (%r12)
cmpb $0x0, (%r15)
movq %r14, %rcx
cmoveq %rbx, %rcx
movb %al, -0x24(%rbp,%rcx)
incq %r14
addq $-0x1, %rbx
jb 0x58989
movl -0x24(%rbp), %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: tsip_tword()
u48 tsip_tword()   /* get next tword field (48 bit) from binary message */
{
u08 i;
u08 word[3];
u16 c;

   for(i=0; i<3; i++) {
      c = get_next_tsip_byte();
      if(c & 0xFF00) tsip_error |= TWORD_ERROR;
      if(ENDIAN) word[i] = (u08) c;
      else       word[2-i] = (u08) c;
   }
   return * ((u48 *) (void *) &word[0]);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movl $0x3, %ebx
leaq 0x1e659b(%rip), %r14    # 0x23ef70
callq 0x587be
cmpl $0x100, %eax            # imm = 0x100
jb 0x589e6
orb $0x1, 0x1(%r14)
decq %rbx
jne 0x589d5
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: check_float(float)
float check_float(float val) 
{
   // validate a float as being resonable

   if(val != val) {
      tsip_error |= NAN_ERROR;
      return 0.0F;  // kludgy NAN check
   }
   if(val > 1.0E30F) {
      tsip_error |= RANGE_ERROR;
      return 1.0E30F;        // prevent run-away printf's
   }
   if(val < (-1.0E30F)) {
      tsip_error |= RANGE_ERROR;
      return (-1.0E30F);
   }
   return val;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
ucomiss %xmm0, %xmm0
jp 0x58a26
movss 0xc601f(%rip), %xmm1    # 0x11ea20
movl $0x800, %eax            # imm = 0x800
ucomiss %xmm1, %xmm0
ja 0x58a18
movss 0xc6011(%rip), %xmm1    # 0x11ea24
ucomiss %xmm0, %xmm1
jbe 0x58a24
leaq 0x1e6551(%rip), %rcx    # 0x23ef70
orl %eax, (%rcx)
movaps %xmm1, %xmm0
popq %rbp
retq
xorps %xmm1, %xmm1
movl $0x400, %eax            # imm = 0x400
jmp 0x58a18
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: tsip_single()
float tsip_single()   /* get next four byte floating number from binary message */
{
u08 i;
u08 word[4];
u16 c;
float val;

   for(i=0; i<4; i++) {
      c = get_next_tsip_byte();
      if(c & 0xFF00) tsip_error |= FLOAT_ERROR;
      if(ENDIAN) word[i] = (u08) c;
      else       word[3-i] = (u08) c;
   }

   val = (* ((float *) (void *) &word[0]));
   val = check_float(val);   // checks for NAN's
   return val;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movl $0x3, %r14d
xorl %r15d, %r15d
leaq 0x1bfd85(%rip), %r12    # 0x2187d4
leaq 0x1e651a(%rip), %rbx    # 0x23ef70
callq 0x587be
cmpl $0x100, %eax            # imm = 0x100
jb 0x58a65
orb $0x40, (%rbx)
cmpb $0x0, (%r12)
movq %r15, %rcx
cmoveq %r14, %rcx
movb %al, -0x24(%rbp,%rcx)
incq %r15
addq $-0x1, %r14
jb 0x58a56
movss -0x24(%rbp), %xmm0
ucomiss %xmm0, %xmm0
jp 0x58ab9
movss 0xc5f90(%rip), %xmm1    # 0x11ea20
movl $0x800, %eax            # imm = 0x800
ucomiss %xmm1, %xmm0
ja 0x58aa7
movss 0xc5f82(%rip), %xmm1    # 0x11ea24
ucomiss %xmm0, %xmm1
jbe 0x58aac
orl %eax, (%rbx)
movaps %xmm1, %xmm0
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
xorps %xmm1, %xmm1
movl $0x400, %eax            # imm = 0x400
jmp 0x58aa7
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: check_double(double)
double check_double(double val) 
{
   // validate a double as being resonable

   if(val != val) {
      tsip_error |= NAN_ERROR;
      return 0.0;  // kludgy NAN check
   }
   if(val > 1.0E30) {
      tsip_error |= RANGE_ERROR;
      return 1.0E30;        // prevent runaway printf's
   }
   if(val < (-1.0E30)) {
      tsip_error |= RANGE_ERROR;
      return (-1.0E30);
   }
   return val;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
ucomisd %xmm0, %xmm0
jp 0x58afd
movsd 0xc564b(%rip), %xmm1    # 0x11e120
movl $0x800, %eax            # imm = 0x800
ucomisd %xmm1, %xmm0
ja 0x58aee
movsd 0xc5640(%rip), %xmm1    # 0x11e128
ucomisd %xmm0, %xmm1
jbe 0x58afb
leaq 0x1e647b(%rip), %rcx    # 0x23ef70
orl %eax, (%rcx)
movapd %xmm1, %xmm0
popq %rbp
retq
xorpd %xmm1, %xmm1
movl $0x400, %eax            # imm = 0x400
jmp 0x58aee
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: tsip_double()
double tsip_double()   /* get next eight byte floating number from binary message */
{
u08 i;
u08 word[8];
u16 c;
double val;

   for(i=0; i<8; i++) {
      c = get_next_tsip_byte();
      if(c & 0xFF00) tsip_error |= DOUBLE_ERROR;
      if(ENDIAN) word[i] = (u08) c;
      else       word[7-i] = (u08) c;
   }

   val = (* ((double *) (void *) &word[0]));
   val = check_double(val);   // checks for NAN's, etc
   return val;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movl $0x7, %r14d
xorl %r15d, %r15d
leaq 0x1bfcad(%rip), %r12    # 0x2187d4
leaq 0x1e6442(%rip), %rbx    # 0x23ef70
callq 0x587be
cmpl $0x100, %eax            # imm = 0x100
jb 0x58b3d
orb $-0x80, (%rbx)
cmpb $0x0, (%r12)
movq %r15, %rcx
cmoveq %r14, %rcx
movb %al, -0x28(%rbp,%rcx)
incq %r15
addq $-0x1, %r14
jb 0x58b2e
movsd -0x28(%rbp), %xmm0
ucomisd %xmm0, %xmm0
jp 0x58b95
movsd 0xc55b7(%rip), %xmm1    # 0x11e120
movl $0x800, %eax            # imm = 0x800
ucomisd %xmm1, %xmm0
ja 0x58b82
movsd 0xc55ac(%rip), %xmm1    # 0x11e128
ucomisd %xmm0, %xmm1
jbe 0x58b88
orl %eax, (%rbx)
movapd %xmm1, %xmm0
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
xorpd %xmm1, %xmm1
movl $0x400, %eax            # imm = 0x400
jmp 0x58b82
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: tsip_string(char*, int)
void tsip_string(char *s, int len)
{
int i;

   // get a 'len" byte string into 's'.  Terminate string with a 0 byte

   if(s == 0) return;

   i = 0;
   s[i] = 0;
   if(len < 0) return;

   while(len--) {
      s[i++] = tsip_byte();
      s[i] = 0;
   }
}

// Assembly:
testq %rdi, %rdi
je 0x58dc1
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movb $0x0, (%rdi)
testl %esi, %esi
jle 0x58db9
movl %esi, %r14d
xorl %r12d, %r12d
leaq 0x1e61de(%rip), %r15    # 0x23ef70
callq 0x587be
cmpl $0x100, %eax            # imm = 0x100
jb 0x58da2
orb $0x8, (%r15)
movb %al, (%rbx,%r12)
movb $0x0, 0x1(%rbx,%r12)
leaq 0x1(%r12), %rax
movq %rax, %r12
cmpl %eax, %r14d
jne 0x58d92
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: log_packet_id(char*)
void log_packet_id(char *s)
{
   if((log_stream & LOG_PACKET_ID) || (zoom_screen == 'H')) {
      if(HEX_PACKET_IDS) {
         if(s) strcpy(packet_id, s);
         else  strcpy(packet_id, "{null packet id string}\n");
      }
      else if(s) {
         if(log_file) fprintf(log_file, "   {%s}\n", s);
      }
      else {
         if(log_file) fprintf(log_file, "   {null packet id string}\n");
      }
      if(log_flush_mode && log_file) fflush(log_file);
   }
}

// Assembly:
movq %rdi, %rdx
leaq 0x1e5644(%rip), %rax    # 0x23e410
testb $0x2, (%rax)
jne 0x58de1
leaq 0x2b39d0(%rip), %rax    # 0x30c7a8
cmpb $0x48, (%rax)
jne 0x58e9a
pushq %rbp
movq %rsp, %rbp
leaq 0x1bfae4(%rip), %rax    # 0x2188d0
movabsq $0x1b197411ff, %rcx     # imm = 0x1B197411FF
testq %rcx, (%rax)
je 0x58e11
testq %rdx, %rdx
je 0x58e38
leaq 0x312e99(%rip), %rdi    # 0x36bca0
movq %rdx, %rsi
callq 0x9340
jmp 0x58e71
leaq 0x1e5548(%rip), %rax    # 0x23e360
movq (%rax), %rcx
testq %rdx, %rdx
je 0x58e56
testq %rcx, %rcx
je 0x58e71
leaq 0xc737c(%rip), %rsi     # 0x1201a8
movq %rcx, %rdi
xorl %eax, %eax
callq 0x9560
jmp 0x58e71
movups 0xc7392(%rip), %xmm0    # 0x1201d1
movups %xmm0, 0x312e63(%rip)   # 0x36bca9
movups 0xc737b(%rip), %xmm0    # 0x1201c8
movaps %xmm0, 0x312e4c(%rip)   # 0x36bca0
jmp 0x58e71
testq %rcx, %rcx
je 0x58e71
leaq 0xc7363(%rip), %rdi     # 0x1201c5
movl $0x1b, %esi
movl $0x1, %edx
callq 0x9750
leaq 0x1e55a8(%rip), %rax    # 0x23e420
cmpl $0x0, (%rax)
setne %al
leaq 0x1e54db(%rip), %rcx    # 0x23e360
movq (%rcx), %rdi
testq %rdi, %rdi
setne %cl
andb %al, %cl
cmpb $0x1, %cl
popq %rbp
je 0x9420
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: average_dop()
DATA_SIZE average_dop()
{
DATA_SIZE dop, div;

   // returns the average of all dop values
   // (this should probably be a geometric average or maybe an AGM average !!!!!)

   dop = 0.0;
   div = 0.0;

   if((have_dops & TDOP) && tdop) { dop += tdop; ++div; }
   if((have_dops & HDOP) && hdop) { dop += hdop; ++div; }
   if((have_dops & VDOP) && vdop) { dop += vdop; ++div; }
   if((have_dops & PDOP) && pdop) { dop += pdop; ++div; }
   if((have_dops & GDOP) && gdop) { dop += gdop; ++div; }
   if((have_dops & EDOP) && edop) { dop += edop; ++div; }
   if((have_dops & NDOP) && ndop) { dop += ndop; ++div; }
   if((have_dops & XDOP) && xdop) { dop += xdop; ++div; }
   if((have_dops & YDOP) && ydop) { dop += ydop; ++div; }
   if(div) dop /= div;

   avg_dop = dop;
   return dop;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x1ca08a(%rip), %rax    # 0x2234e4
movl (%rax), %eax
movl %eax, %ecx
shrb $0x4, %cl
leaq 0x1ca0a0(%rip), %rdx    # 0x223508
movsd (%rdx), %xmm1
xorpd %xmm0, %xmm0
ucomisd %xmm0, %xmm1
setp %dl
setne %sil
orb %dl, %sil
testb %sil, %cl
jne 0x59489
xorpd %xmm1, %xmm1
jmp 0x5948d
addsd %xmm0, %xmm1
movsd 0xafbdb(%rip), %xmm3    # 0x109070
movapd %xmm3, %xmm2
jne 0x5949f
xorpd %xmm2, %xmm2
movl %eax, %ecx
shrb %cl
leaq 0x1ca046(%rip), %rdx    # 0x2234f0
movsd (%rdx), %xmm4
ucomisd %xmm0, %xmm4
setp %dl
setne %sil
orb %dl, %sil
testb %sil, %cl
je 0x594c9
addsd %xmm4, %xmm1
addsd %xmm3, %xmm2
movl %eax, %ecx
shrb $0x2, %cl
leaq 0x1ca023(%rip), %rdx    # 0x2234f8
movsd (%rdx), %xmm4
ucomisd %xmm0, %xmm4
setp %dl
setne %sil
orb %dl, %sil
testb %sil, %cl
je 0x594f4
addsd %xmm4, %xmm1
addsd %xmm3, %xmm2
leaq 0x1c9fed(%rip), %rcx    # 0x2234e8
movsd (%rcx), %xmm4
ucomisd %xmm0, %xmm4
setp %cl
setne %dl
orb %cl, %dl
testb %dl, %al
je 0x59517
addsd %xmm4, %xmm1
addsd %xmm3, %xmm2
movl %eax, %ecx
shrb $0x3, %cl
leaq 0x1c9fdd(%rip), %rdx    # 0x223500
movsd (%rdx), %xmm4
ucomisd %xmm0, %xmm4
setp %dl
setne %sil
orb %dl, %sil
testb %sil, %cl
je 0x59542
addsd %xmm4, %xmm1
addsd %xmm3, %xmm2
movl %eax, %ecx
shrb $0x6, %cl
leaq 0x1c9fca(%rip), %rdx    # 0x223518
movsd (%rdx), %xmm4
ucomisd %xmm0, %xmm4
setp %dl
setne %sil
orb %dl, %sil
testb %sil, %cl
je 0x5956d
addsd %xmm4, %xmm1
addsd %xmm3, %xmm2
movl %eax, %ecx
shrb $0x5, %cl
leaq 0x1c9f97(%rip), %rdx    # 0x223510
movsd (%rdx), %xmm4
ucomisd %xmm0, %xmm4
setp %dl
setne %sil
orb %dl, %sil
testb %sil, %cl
je 0x59598
addsd %xmm4, %xmm1
addsd %xmm3, %xmm2
testb %al, %al
sets %cl
leaq 0x1c9f7c(%rip), %rdx    # 0x223520
movsd (%rdx), %xmm4
ucomisd %xmm0, %xmm4
setp %dl
setne %sil
orb %dl, %sil
testb %sil, %cl
je 0x595c3
addsd %xmm4, %xmm1
addsd %xmm3, %xmm2
shrl $0x8, %eax
leaq 0x1c9f5b(%rip), %rcx    # 0x223528
movsd (%rcx), %xmm4
ucomisd %xmm0, %xmm4
setp %cl
setne %dl
orb %cl, %dl
testb %dl, %al
je 0x595e9
addsd %xmm4, %xmm1
addsd %xmm3, %xmm2
movapd %xmm1, %xmm3
divsd %xmm2, %xmm3
cmpneqsd %xmm2, %xmm0
andpd %xmm0, %xmm3
andnpd %xmm1, %xmm0
orpd %xmm3, %xmm0
leaq 0x1c9f27(%rip), %rax    # 0x223530
movlpd %xmm0, (%rax)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: echo_nmea_string(char*)
void echo_nmea_string(char *ss)
{
u08 cksum;
char buf[2048+1];
unsigned i;

   // send a NMEA command out the NMEA_PORT.  Leading '$' and checksum are added.

   if(ss == 0) return;
   strcpy(buf,ss);

   sendout(NMEA_PORT, '$', ADD_CHAR);
   cksum = 0;

   for(i=0; i<strlen(buf); i++) {
      sendout(NMEA_PORT, buf[i], ADD_CHAR);
      cksum ^= buf[i];
   }

   sendout(NMEA_PORT, '*', ADD_CHAR);  
   i = (cksum >> 4) & 0x0F;
   if(i > 9) i += ('A'-10);
   else      i += '0';
   sendout(NMEA_PORT, (u08) i, ADD_CHAR);  
   i = cksum & 0x0F;
   if(i > 9) i += ('A'-10);
   else      i += '0';
   sendout(NMEA_PORT, (u08) i, ADD_CHAR);  

   sendout(NMEA_PORT, 0x0D, ADD_CHAR);
   sendout(NMEA_PORT, 0x0A, EOM);

   drain_port(NMEA_PORT);   // we ignore any data comming in the NMEA echo port

// if(debug_file) fprintf(debug_file, "echo nmea:%s\n", s);
}

// Assembly:
testq %rdi, %rdi
je 0x59752
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x810, %rsp            # imm = 0x810
movq %rdi, %rsi
leaq -0x830(%rbp), %rbx
movq %rbx, %rdi
callq 0x9340
xorl %r14d, %r14d
movl $0xc, %edi
movl $0x24, %esi
xorl %edx, %edx
callq 0xbcaa
cmpb $0x0, (%rbx)
je 0x596b1
movl $0x1, %r15d
xorl %r12d, %r12d
xorl %r14d, %r14d
movzbl -0x830(%rbp,%r12), %esi
movl $0xc, %edi
xorl %edx, %edx
callq 0xbcaa
xorb -0x830(%rbp,%r12), %r14b
movl %r15d, %r12d
movq %rbx, %rdi
callq 0x9120
incl %r15d
cmpq %r12, %rax
ja 0x59681
movl $0xc, %edi
movl $0x2a, %esi
xorl %edx, %edx
callq 0xbcaa
movl %r14d, %eax
shrb $0x4, %al
leal 0x37(%rax), %ecx
orb $0x30, %al
cmpb $-0x60, %r14b
movzbl %cl, %ecx
movzbl %al, %esi
cmovael %ecx, %esi
movl $0xff, %ebx
andl %ebx, %esi
movl $0xc, %edi
xorl %edx, %edx
callq 0xbcaa
andb $0xf, %r14b
leal 0x37(%r14), %eax
leal 0x30(%r14), %ecx
cmpb $0xa, %r14b
movzbl %al, %eax
movzbl %cl, %esi
cmovael %eax, %esi
andl %ebx, %esi
movl $0xc, %edi
xorl %edx, %edx
callq 0xbcaa
movl $0xc, %edi
movl $0xd, %esi
xorl %edx, %edx
callq 0xbcaa
movl $0xc, %edi
movl $0xa, %esi
movl $0x1, %edx
callq 0xbcaa
movl $0xc, %edi
callq 0x5802f
addq $0x810, %rsp            # imm = 0x810
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: nmea_time()
double nmea_time()
{
double time;

   // return UTC time as a floating point number

//   gregorian(0, jd_utc);
   time = ((double) g_hours) * 100 * 100.0;
   time += ((double) g_minutes) * 100.0;
   time += ((double) g_seconds);
   time += g_frac;

   return time;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x2b3f4a(%rip), %rax    # 0x30d6a8
cvtsi2sdl (%rax), %xmm0
movsd 0xaf8f6(%rip), %xmm1    # 0x109060
mulsd %xmm1, %xmm0
mulsd %xmm1, %xmm0
leaq 0x2b3f33(%rip), %rax    # 0x30d6ac
cvtsi2sdl (%rax), %xmm2
mulsd %xmm1, %xmm2
addsd %xmm0, %xmm2
leaq 0x2b3f24(%rip), %rax    # 0x30d6b0
xorps %xmm0, %xmm0
cvtsi2sdl (%rax), %xmm0
addsd %xmm2, %xmm0
leaq 0x2b3f1a(%rip), %rax    # 0x30d6b8
addsd (%rax), %xmm0
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: nmea_date()
int nmea_date()
{
int date;

   // return date as an integer (year modulo 100)

   date = g_day * 100 * 100;
   date += g_month * 100;
   date += (g_year % 100);

   return date;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x2b3ef1(%rip), %rax    # 0x30d6a0
imull $0x2710, (%rax), %eax   # imm = 0x2710
leaq 0x2b3ee0(%rip), %rcx    # 0x30d69c
imull $0x64, (%rcx), %ecx
addl %eax, %ecx
leaq 0x2b3edc(%rip), %rax    # 0x30d6a4
movslq (%rax), %rax
imulq $0x51eb851f, %rax, %rdx # imm = 0x51EB851F
movq %rdx, %rsi
shrq $0x3f, %rsi
sarq $0x25, %rdx
addl %esi, %edx
imull $0x64, %edx, %edx
subl %edx, %eax
addl %ecx, %eax
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: nmea_lat()
char *nmea_lat()
{
static char s[256];
double val;
int deg;
char c;

   // return latitude as a NMEA format string

   if(lat < 0.0) c = 'S';
   else          c = 'N';

   val = fabs(lat) * 180.0 / PI;
   deg = (int) val;
   val -= (double) deg;        // fractional degrees
   val *= 60.0;                // fractional minutes
   val += (double) (deg*100);  // NMEA location

   s[0] = 0;
   if(echo_fmt & ECHO_LLA) sprintf(s, "%.4f,%c", val,c);
   else                    sprintf(s, "%.3f,%c", val,c);
   return &s[0];
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x2b37db(%rip), %rax    # 0x30cfd0
movsd (%rax), %xmm1
xorpd %xmm0, %xmm0
xorl %eax, %eax
ucomisd %xmm1, %xmm0
seta %al
andpd 0xaf982(%rip), %xmm1    # 0x109190
mulsd 0xb201a(%rip), %xmm1    # 0x10b830
divsd 0xb200a(%rip), %xmm1    # 0x10b828
cvttsd2si %xmm1, %ecx
cvttpd2dq %xmm1, %xmm0
cvtdq2pd %xmm0, %xmm0
leal (%rax,%rax,4), %edx
addl $0x4e, %edx
subsd %xmm0, %xmm1
mulsd 0xaf7cc(%rip), %xmm1    # 0x109008
imull $0x64, %ecx, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
addsd %xmm1, %xmm0
movb $0x0, 0x3167cf(%rip)    # 0x370020
leaq 0x3167c8(%rip), %rbx    # 0x370020
cmpb $0x0, 0x110d21(%rip)    # 0x16a580
leaq 0xc6a04(%rip), %rax     # 0x12026a
leaq 0xc69f5(%rip), %rsi     # 0x120262
cmovnsq %rax, %rsi
movq %rbx, %rdi
movb $0x1, %al
callq 0x9060
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: nmea_lon()
char *nmea_lon()
{
static char s[256];
double val;
int deg;
char c;

   // return longitude as a NMEA format string

   s[0] = 0;
   if(lon < 0.0) c = 'W';
   else          c = 'E';

   val = fabs(lon) * 180.0 / PI;
   deg = (int) val;
   val -= (double) deg;        // fractional degrees
   val *= 60.0;                // fractional minutes
   val += (double) (deg*100);  // NMEA location
   

   if(echo_fmt & ECHO_LLA) sprintf(s, "%.4f,%c", val,c);
   else                    sprintf(s, "%.3f,%c", val,c);
   return &s[0];
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x2b3746(%rip), %rax    # 0x30cfd8
movsd (%rax), %xmm1
xorpd %xmm0, %xmm0
ucomisd %xmm1, %xmm0
movl $0x57, %eax
movl $0x45, %edx
cmoval %eax, %edx
andpd 0xaf8dd(%rip), %xmm1    # 0x109190
mulsd 0xb1f75(%rip), %xmm1    # 0x10b830
divsd 0xb1f65(%rip), %xmm1    # 0x10b828
cvttsd2si %xmm1, %eax
cvttpd2dq %xmm1, %xmm0
cvtdq2pd %xmm0, %xmm0
subsd %xmm0, %xmm1
mulsd 0xaf72d(%rip), %xmm1    # 0x109008
movb $0x0, 0x31683e(%rip)    # 0x370120
imull $0x64, %eax, %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
leaq 0x31682d(%rip), %rbx    # 0x370120
addsd %xmm1, %xmm0
cmpb $0x0, 0x110c82(%rip)    # 0x16a580
leaq 0xc6965(%rip), %rax     # 0x12026a
leaq 0xc6956(%rip), %rsi     # 0x120262
cmovnsq %rax, %rsi
movq %rbx, %rdi
movb $0x1, %al
callq 0x9060
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: nmea_speed()
char *nmea_speed()
{
static char s[256];

   // return speed as a NMEA format string

   s[0] = 0;
   if(have_speed) {
      sprintf(s, "%.2f", speed / 0.514444);
   }
   return &s[0];
}

// Assembly:
movb $0x0, 0x3169b6(%rip)    # 0x370320
leaq 0x2b39c7(%rip), %rax    # 0x30d338
cmpl $0x0, (%rax)
je 0x599a3
pushq %rbp
movq %rsp, %rbp
leaq 0x2b369f(%rip), %rax    # 0x30d020
movsd (%rax), %xmm0
divsd 0xc47a3(%rip), %xmm0    # 0x11e130
leaq 0x31698c(%rip), %rdi    # 0x370320
leaq 0xca5b1(%rip), %rsi     # 0x123f4c
movb $0x1, %al
callq 0x9060
popq %rbp
leaq 0x316976(%rip), %rax    # 0x370320
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: nmea_heading()
char *nmea_heading()
{
static char s[256];

   // return heading as a NMEA format string

   s[0] = 0;
   if(have_heading) {
      sprintf(s, "%.2f", heading);
   }
   return &s[0];
}

// Assembly:
movb $0x0, 0x316a6e(%rip)    # 0x370420
leaq 0x2b397b(%rip), %rax    # 0x30d334
cmpl $0x0, (%rax)
je 0x599e3
pushq %rbp
movq %rsp, %rbp
leaq 0x2b365f(%rip), %rax    # 0x30d028
movsd (%rax), %xmm0
leaq 0x316a4c(%rip), %rdi    # 0x370420
leaq 0xca571(%rip), %rsi     # 0x123f4c
movb $0x1, %al
callq 0x9060
popq %rbp
leaq 0x316a36(%rip), %rax    # 0x370420
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: send_zda()
void send_zda()
{
   // send time/date as a NMEA GPZDA sentence
   
//   gregorian(0, jd_utc);

   if     (echo_fmt & ECHO_MSECS) sprintf(out, "GPZDA,%010.3f,%02d,%02d,%04d,00,00", nmea_time(), g_day,g_month,g_year);
   else if(echo_fmt & ECHO_HSECS) sprintf(out, "GPZDA,%09.2f,%02d,%02d,%04d,00,00", nmea_time(), g_day,g_month,g_year);
   else                           sprintf(out, "GPZDA,%06d,%02d,%02d,%04d,00,00", (int)nmea_time(), g_day,g_month,g_year);
   echo_nmea_string(out);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl 0x110b8b(%rip), %eax    # 0x16a580
testb $0x4, %al
jne 0x59a8b
leaq 0x2b3ca4(%rip), %rcx    # 0x30d6a8
cvtsi2sdl (%rcx), %xmm0
movsd 0xaf650(%rip), %xmm1    # 0x109060
mulsd %xmm1, %xmm0
mulsd %xmm1, %xmm0
leaq 0x2b3c8d(%rip), %rcx    # 0x30d6ac
cvtsi2sdl (%rcx), %xmm2
mulsd %xmm1, %xmm2
addsd %xmm0, %xmm2
leaq 0x2b3c7e(%rip), %rcx    # 0x30d6b0
xorps %xmm0, %xmm0
cvtsi2sdl (%rcx), %xmm0
addsd %xmm2, %xmm0
leaq 0x2b3c74(%rip), %rcx    # 0x30d6b8
addsd (%rcx), %xmm0
testb $0x2, %al
jne 0x59b02
cvttsd2si %xmm0, %edx
leaq 0x2b3c45(%rip), %rax    # 0x30d6a0
movl (%rax), %ecx
leaq 0x2b3c38(%rip), %rax    # 0x30d69c
movl (%rax), %r8d
leaq 0x2b3c36(%rip), %rax    # 0x30d6a4
movl (%rax), %r9d
leaq 0x2e27a8(%rip), %rdi    # 0x33c220
leaq 0xc6840(%rip), %rsi     # 0x1202bf
xorl %eax, %eax
callq 0x9060
jmp 0x59b33
leaq 0x2b3c16(%rip), %rax    # 0x30d6a8
cvtsi2sdl (%rax), %xmm0
movsd 0xaf5c2(%rip), %xmm1    # 0x109060
mulsd %xmm1, %xmm0
leaq 0x2b3c03(%rip), %rax    # 0x30d6ac
cvtsi2sdl (%rax), %xmm2
mulsd %xmm1, %xmm0
mulsd %xmm1, %xmm2
addsd %xmm0, %xmm2
leaq 0x2b3bf0(%rip), %rax    # 0x30d6b0
xorps %xmm0, %xmm0
cvtsi2sdl (%rax), %xmm0
addsd %xmm2, %xmm0
leaq 0x2b3be6(%rip), %rax    # 0x30d6b8
addsd (%rax), %xmm0
leaq 0x2b3bc3(%rip), %rax    # 0x30d6a0
movl (%rax), %edx
leaq 0x2b3bb6(%rip), %rax    # 0x30d69c
movl (%rax), %ecx
leaq 0x2b3bb5(%rip), %rax    # 0x30d6a4
movl (%rax), %r8d
leaq 0x2e2727(%rip), %rdi    # 0x33c220
leaq 0xc677a(%rip), %rsi     # 0x12027a
jmp 0x59b2c
leaq 0x2b3b97(%rip), %rax    # 0x30d6a0
movl (%rax), %edx
leaq 0x2b3b8a(%rip), %rax    # 0x30d69c
movl (%rax), %ecx
leaq 0x2b3b89(%rip), %rax    # 0x30d6a4
movl (%rax), %r8d
leaq 0x2e26fb(%rip), %rdi    # 0x33c220
leaq 0xc6771(%rip), %rsi     # 0x12029d
movb $0x1, %al
callq 0x9060
leaq 0x2e26e6(%rip), %rdi    # 0x33c220
popq %rbp
jmp 0x5962f
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: echo_nmea()
void echo_nmea()
{
int last_sec = 99;

   // send receiver data formmated as NMEA to the NMEA_PORT

   if(com[NMEA_PORT].process_com == 0) return;  // NMEA_PORT not open
   if(com[NMEA_PORT].com_running <= 0) return;
//ffff if(fake_time_stamp) return;   // don't echo faked time stamps so NTP works better?

   gregorian(0, jd_utc + jtime(0,0,0,TSX_TWEAK));

   if(echo_fmt & ECHO_ZDA) send_zda();
   if(echo_fmt & ECHO_VTG) send_vtg();  // we don't do this one for now
   if(echo_fmt & ECHO_RMC) send_rmc();
   if(echo_fmt & ECHO_GGA) send_gga();


   if(POLLED_RCVR) {
      if(g_seconds == (SCPI_STATUS_SECOND+10)) {
         if(echo_fmt & ECHO_GSA) send_gsa();
         if(echo_fmt & ECHO_GSV) send_gsv();
      }
   }
   else if((g_seconds % 10) == (SCPI_STATUS_SECOND%10)) {
      if(echo_fmt & ECHO_GSA) send_gsa();
      if(echo_fmt & ECHO_GSV) send_gsv();
   }

   last_sec = g_seconds;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
leaq 0x2b3cdc(%rip), %rax    # 0x30e2e0
cmpl $0x0, 0x1beb4(%rax)
je 0x5a6f1
cmpl $0x0, 0x1beb0(%rax)
jle 0x5a6f1
leaq 0x2b2f0b(%rip), %rax    # 0x30d530
movsd (%rax), %xmm0
movsd %xmm0, -0x8(%rbp)
leaq 0x2b3893(%rip), %rax    # 0x30dec8
movsd (%rax), %xmm0
divsd 0xae9f7(%rip), %xmm0    # 0x109038
xorl %edi, %edi
xorl %esi, %esi
xorl %edx, %edx
callq 0xd492e
addsd -0x8(%rbp), %xmm0
xorl %edi, %edi
callq 0xd12da
movl 0x10ff22(%rip), %eax    # 0x16a580
btl $0x8, %eax
jae 0x5a66f
callq 0x599eb
movl 0x10ff11(%rip), %eax    # 0x16a580
btl $0xa, %eax
jae 0x5a680
callq 0x59b40
movl 0x10ff00(%rip), %eax    # 0x16a580
btl $0xb, %eax
jae 0x5a68b
callq 0x59f4d
leaq 0x1be23e(%rip), %rcx    # 0x2188d0
movabsq $0x101b0e5018, %rdx     # imm = 0x101B0E5018
leaq 0x2b300d(%rip), %rax    # 0x30d6b0
movl (%rax), %eax
testq %rdx, (%rcx)
je 0x5a6b1
cmpl $0x2a, %eax
je 0x5a6d4
jmp 0x5a6f1
movslq %eax, %rcx
imulq $0x66666667, %rcx, %rcx # imm = 0x66666667
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x22, %rcx
addl %edx, %ecx
addl %ecx, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
cmpl $0x2, %eax
jne 0x5a6f1
movl 0x10fea6(%rip), %eax    # 0x16a580
btl $0xc, %eax
jae 0x5a6eb
callq 0x5a224
movl 0x10fe95(%rip), %eax    # 0x16a580
btl $0xd, %eax
jb 0x5a6f7
addq $0x10, %rsp
popq %rbp
retq
addq $0x10, %rsp
popq %rbp
jmp 0x5a41f
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: dump_prn_info()
void dump_prn_info()
{
int i;

   if(prn_file == 0) return;
   if(new_sat_azel == 0) return;
   new_sat_azel = 0;

   for(i=0; i<=SUN_MOON_PRN; i++) {
      if((sat[i].tracking > 0) || (i == SUN_PRN) || (i == MOON_PRN)) {
         fprintf(prn_file, "%.6f %4d %6.2f %6.2f %6.2f\n", jd_utc, i, sat[i].azimuth, sat[i].elevation, sat[i].sig_level);
      }
   }

   ++prn_count;
   fprintf(prn_file, "# %d\n", prn_count);
   if(prn_flush_mode) fflush(prn_file);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
leaq 0x1e2af6(%rip), %r15    # 0x23e378
cmpq $0x0, (%r15)
je 0x5b95e
cmpl $0x0, 0x310529(%rip)    # 0x36bdbc
je 0x5b95e
movl $0x218, %r12d           # imm = 0x218
addq 0xf469a(%rip), %r12     # 0x14ff40
movl $0x0, 0x31050c(%rip)    # 0x36bdbc
xorl %ebx, %ebx
leaq 0x2b1c77(%rip), %r13    # 0x30d530
leaq 0xcb991(%rip), %r14     # 0x127251
movl %ebx, %eax
andl $0x3fe, %eax            # imm = 0x3FE
cmpl $0x3e8, %eax            # imm = 0x3E8
je 0x5b8d5
cmpl $0x0, (%r12)
jle 0x5b90b
movq (%r15), %rdi
movsd (%r13), %xmm0
xorps %xmm1, %xmm1
cvtss2sd -0x10(%r12), %xmm1
xorps %xmm2, %xmm2
cvtss2sd -0xc(%r12), %xmm2
xorps %xmm3, %xmm3
cvtss2sd -0x1f8(%r12), %xmm3
movq %r14, %rsi
movl %ebx, %edx
movb $0x4, %al
callq 0x9560
incq %rbx
addq $0x348, %r12            # imm = 0x348
cmpq $0x3ea, %rbx            # imm = 0x3EA
jne 0x5b8c0
leaq 0x1e2af3(%rip), %rax    # 0x23e418
movl (%rax), %edx
incl %edx
movl %edx, (%rax)
movq (%r15), %rdi
leaq 0xcb938(%rip), %rsi     # 0x12726d
xorl %eax, %eax
callq 0x9560
leaq 0x1e2ae9(%rip), %rax    # 0x23e42c
cmpl $0x0, (%rax)
je 0x5b95e
movq (%r15), %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x9420
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/heathgps.cpp
// Function: set_gregorian_time(double)
void set_gregorian_time(double jd)
{
   // set the receiver time/date variables to jd decoded to gregorian

   gregorian(0, jd);  // convert julian date to gregorian

   pri_year = year = g_year;  // update date/time variables to the gregorian values
   pri_month = month = g_month;
   pri_day = day = g_day;

   pri_hours = hours = g_hours;
   pri_minutes = minutes = g_minutes;
   pri_seconds = seconds = g_seconds;
   pri_frac = raw_frac = g_frac;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
xorl %edi, %edi
callq 0xd12da
leaq 0x2b0f75(%rip), %rax    # 0x30d6a4
movl (%rax), %eax
leaq 0x2b0da4(%rip), %rcx    # 0x30d4dc
movl %eax, (%rcx)
leaq 0x2b0dd3(%rip), %rcx    # 0x30d514
movl %eax, (%rcx)
leaq 0x2b0f52(%rip), %rax    # 0x30d69c
movl (%rax), %eax
leaq 0x2b0d85(%rip), %rcx    # 0x30d4d8
movl %eax, (%rcx)
leaq 0x2b0db4(%rip), %rcx    # 0x30d510
movl %eax, (%rcx)
leaq 0x2b0f3b(%rip), %rax    # 0x30d6a0
movl (%rax), %eax
leaq 0x2b0d66(%rip), %rcx    # 0x30d4d4
movl %eax, (%rcx)
leaq 0x2b0d95(%rip), %rcx    # 0x30d50c
movl %eax, (%rcx)
leaq 0x2b0f28(%rip), %rax    # 0x30d6a8
movl (%rax), %eax
leaq 0x2b0d47(%rip), %rcx    # 0x30d4d0
movl %eax, (%rcx)
leaq 0x2b0d76(%rip), %rcx    # 0x30d508
movl %eax, (%rcx)
leaq 0x2b0f11(%rip), %rax    # 0x30d6ac
movl (%rax), %eax
leaq 0x2b0d28(%rip), %rcx    # 0x30d4cc
movl %eax, (%rcx)
leaq 0x2b0d57(%rip), %rcx    # 0x30d504
movl %eax, (%rcx)
leaq 0x2b0efa(%rip), %rax    # 0x30d6b0
movl (%rax), %eax
leaq 0x2b0d09(%rip), %rcx    # 0x30d4c8
movl %eax, (%rcx)
leaq 0x2b0d38(%rip), %rcx    # 0x30d500
movl %eax, (%rcx)
leaq 0x2b0ee7(%rip), %rax    # 0x30d6b8
movsd (%rax), %xmm0
leaq 0x2b0d04(%rip), %rax    # 0x30d4e0
movsd %xmm0, (%rax)
leaq 0x2b0d31(%rip), %rax    # 0x30d518
movsd %xmm0, (%rax)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: lla_to_ecef(double, double, double)
void lla_to_ecef(double lat, double lon, double alt)
{   
double clat;
double slat;
double clon;
double slon;
double N;

   // convert lat/lon/alt values (in radians/meters) to ECEF coordinates

   clat = cos(lat);
   slat = sin(lat);
   clon = cos(lon);
   slon = sin(lon);

   N = WGS84_A / sqrt(1.0 - WGS84_E * WGS84_E * slat * slat);

   ecef_x = (N + alt) * clat * clon;
   ecef_y = (N + alt) * clat * slon;
   ecef_z = (N * (1.0 - WGS84_E * WGS84_E) + alt) * slat;
// sprintf(plot_title, "ecef: %f %f %f", ecef_x,ecef_y,ecef_z);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movsd %xmm2, -0x28(%rbp)
movsd %xmm1, -0x8(%rbp)
movsd %xmm0, -0x10(%rbp)
callq 0x9710
movsd %xmm0, -0x20(%rbp)
movsd -0x10(%rbp), %xmm0
callq 0x9080
movsd %xmm0, -0x10(%rbp)
movsd -0x8(%rbp), %xmm0
callq 0x9710
movsd %xmm0, -0x18(%rbp)
movsd -0x8(%rbp), %xmm0
callq 0x9080
movsd 0xc1837(%rip), %xmm1    # 0x11e148
movsd -0x10(%rbp), %xmm2
mulsd %xmm2, %xmm1
mulsd %xmm2, %xmm1
addsd 0xac74a(%rip), %xmm1    # 0x109070
movapd %xmm0, %xmm4
xorpd %xmm0, %xmm0
ucomisd %xmm0, %xmm1
jb 0x5c93d
xorps %xmm0, %xmm0
sqrtsd %xmm1, %xmm0
jmp 0x5c950
movapd %xmm1, %xmm0
movsd %xmm4, -0x8(%rbp)
callq 0x9270
movsd -0x8(%rbp), %xmm4
movsd 0xc17f8(%rip), %xmm1    # 0x11e150
divsd %xmm0, %xmm1
movapd %xmm1, %xmm0
movsd -0x28(%rbp), %xmm2
addsd %xmm2, %xmm0
movsd -0x20(%rbp), %xmm3
mulsd %xmm0, %xmm3
movsd -0x18(%rbp), %xmm0
mulsd %xmm3, %xmm0
leaq 0x2b0666(%rip), %rax    # 0x30cfe8
movsd %xmm0, (%rax)
mulsd %xmm3, %xmm4
leaq 0x2b065f(%rip), %rax    # 0x30cff0
movsd %xmm4, (%rax)
mulsd 0xc17bb(%rip), %xmm1    # 0x11e158
addsd %xmm2, %xmm1
movsd -0x10(%rbp), %xmm0
mulsd %xmm1, %xmm0
leaq 0x2b0647(%rip), %rax    # 0x30cff8
movsd %xmm0, (%rax)
addq $0x30, %rsp
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: ecef_to_lla(double, double, double)
void ecef_to_lla(double x, double y, double z)
{
  // convert ECEF coordinate to geocentric lat/lon/alt in radians/meters

  double b = sqrt( (WGS84_A*WGS84_A) * (1.0-(WGS84_E*WGS84_E)) );
  double bsq = (b * b);
  double ep = sqrt( (WGS84_A*WGS84_A - bsq) / bsq);
  double p = sqrt( (x*x) + (y*y) );
  double th = atan2(WGS84_A*z, b*p);

  elon = atan2(y,x);
  elat = atan2( (z + (ep*ep)*b*(sin(th)*sin(th)*sin(th)) ), (p - (WGS84_E*WGS84_E)*WGS84_A*(cos(th)*cos(th)*cos(th))) );

  double N = WGS84_A / ( sqrt(1.0-(WGS84_E*WGS84_E)*(sin(elat)*sin(elat))) );
  ealt = (p / cos(elat)) - N;

  // mod lon to 0-2pi
  elon = fmod(elon,(2.0*PI));
  // correction for altitude near poles left out.  // zork
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movsd %xmm2, -0x18(%rbp)
movsd %xmm1, -0x10(%rbp)
movsd %xmm0, -0x28(%rbp)
movapd %xmm1, %xmm3
mulsd %xmm1, %xmm3
movapd %xmm0, %xmm1
mulsd %xmm0, %xmm1
addsd %xmm3, %xmm1
xorps %xmm3, %xmm3
sqrtsd %xmm1, %xmm3
movsd %xmm3, -0x20(%rbp)
movsd 0xc1756(%rip), %xmm0    # 0x11e150
mulsd %xmm2, %xmm0
movsd 0xc175a(%rip), %xmm1    # 0x11e160
mulsd %xmm3, %xmm1
callq 0x9050
movsd %xmm0, -0x8(%rbp)
movsd -0x10(%rbp), %xmm0
movsd -0x28(%rbp), %xmm1
callq 0x9050
movsd %xmm0, 0x310075(%rip)   # 0x36caa0
movsd -0x8(%rbp), %xmm0
callq 0x9080
movsd %xmm0, -0x10(%rbp)
movsd -0x8(%rbp), %xmm0
callq 0x9080
mulsd -0x10(%rbp), %xmm0
movsd %xmm0, -0x10(%rbp)
movsd -0x8(%rbp), %xmm0
callq 0x9080
mulsd -0x10(%rbp), %xmm0
mulsd 0xc1703(%rip), %xmm0    # 0x11e168
addsd -0x18(%rbp), %xmm0
movsd %xmm0, -0x10(%rbp)
movsd -0x8(%rbp), %xmm0
callq 0x9710
movsd %xmm0, -0x18(%rbp)
movsd -0x8(%rbp), %xmm0
callq 0x9710
movsd -0x18(%rbp), %xmm1
mulsd %xmm0, %xmm1
movsd %xmm1, -0x18(%rbp)
movsd -0x8(%rbp), %xmm0
callq 0x9710
movsd -0x18(%rbp), %xmm1
mulsd %xmm0, %xmm1
mulsd 0xc16bf(%rip), %xmm1    # 0x11e170
addsd -0x20(%rbp), %xmm1
movsd -0x10(%rbp), %xmm0
callq 0x9050
movsd %xmm0, 0x30ffd0(%rip)   # 0x36ca98
callq 0x9080
movsd %xmm0, -0x8(%rbp)
movsd 0x30ffbe(%rip), %xmm0   # 0x36ca98
callq 0x9080
mulsd -0x8(%rbp), %xmm0
mulsd 0xc165c(%rip), %xmm0    # 0x11e148
addsd 0xac57c(%rip), %xmm0    # 0x109070
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jb 0x5cb04
sqrtsd %xmm0, %xmm0
jmp 0x5cb09
callq 0x9270
movsd 0xc1667(%rip), %xmm1    # 0x11e178
divsd %xmm0, %xmm1
movsd %xmm1, -0x8(%rbp)
movsd 0x30ff76(%rip), %xmm0   # 0x36ca98
callq 0x9710
movsd -0x20(%rbp), %xmm1
divsd %xmm0, %xmm1
addsd -0x8(%rbp), %xmm1
movsd %xmm1, 0x30ff6b(%rip)   # 0x36caa8
movsd 0x30ff5b(%rip), %xmm0   # 0x36caa0
movsd 0xc1633(%rip), %xmm1    # 0x11e180
callq 0x94d0
movsd %xmm0, 0x30ff46(%rip)   # 0x36caa0
addq $0x30, %rsp
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: calc_jd_leap(int)
void calc_jd_leap(int why)
{
double days;

   // calculate the Julian date of the next leapsecond and how many days
   // until the event

   days = jd_leap - jd_utc;
   if(days < 0.0) have_jd_leap = have_leap_days = 0;
   else if(days >= ((double) LEAP_THRESH)) have_jd_leap = have_leap_days = 0;
   else have_jd_leap = have_leap_days = why;

   leap_days = (int) days;

//gregorian(0, jd_leap);
//sprintf(plot_title, "jd_leap %d:  have:%d  %04d/%02d/%02d %02d:%02d:%02d   days:%f", 
//why, have_jd_leap, g_year,g_month,g_day, g_hours,g_minutes,g_seconds, days);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x2b09f5(%rip), %rax    # 0x30d560
movsd (%rax), %xmm0
leaq 0x2b09ba(%rip), %rax    # 0x30d530
subsd (%rax), %xmm0
xorl %eax, %eax
ucomisd 0xc1604(%rip), %xmm0    # 0x11e188
cmovael %eax, %edi
xorpd %xmm1, %xmm1
ucomisd %xmm0, %xmm1
cmoval %eax, %edi
leaq 0x2b0657(%rip), %rax    # 0x30d1f0
movl %edi, (%rax)
leaq 0x2b09c6(%rip), %rax    # 0x30d568
movl %edi, (%rax)
cvttsd2si %xmm0, %eax
leaq 0x2b063d(%rip), %rcx    # 0x30d1ec
movl %eax, (%rcx)
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: calc_leap_days(double, unsigned short, int)
void calc_leap_days(double wn_lsf, unsigned short dn, int why)
{
double jd;

   jd = GPS_EPOCH + (wn_lsf * 7.0) + (dn) - jtime(0,0,0,1.0); // Julian day of leapsecond
if(wn_lsf < 1024) jd += rollover / (1024.0 * 7.0 * 24.0*60.0*60.0);
   jd_leap = jd;
   calc_jd_leap(1);
   return;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movapd %xmm0, -0x20(%rbp)
movsd 0xaed40(%rip), %xmm1    # 0x10b908
mulsd %xmm0, %xmm1
addsd 0xaecc4(%rip), %xmm1    # 0x10b898
xorps %xmm0, %xmm0
cvtsi2sd %edi, %xmm0
addsd %xmm1, %xmm0
movapd %xmm0, -0x10(%rbp)
movsd 0xac484(%rip), %xmm0    # 0x109070
xorl %edi, %edi
xorl %esi, %esi
xorl %edx, %edx
callq 0xd492e
leaq 0x1be862(%rip), %rax    # 0x21b460
movsd (%rax), %xmm1
divsd 0xaef16(%rip), %xmm1    # 0x10bb20
movapd -0x10(%rbp), %xmm2
subsd %xmm0, %xmm2
addsd %xmm2, %xmm1
movapd %xmm2, %xmm3
movapd -0x20(%rbp), %xmm2
cmpltsd 0xc1567(%rip), %xmm2    # 0x11e190
movapd %xmm2, %xmm0
andnpd %xmm3, %xmm0
andpd %xmm1, %xmm2
orpd %xmm0, %xmm2
leaq 0x2b0920(%rip), %rax    # 0x30d560
movlpd %xmm2, (%rax)
leaq 0x2b08e5(%rip), %rax    # 0x30d530
movsd (%rax), %xmm0
subsd %xmm0, %xmm2
movsd 0xc152d(%rip), %xmm0    # 0x11e188
cmpnlepd %xmm2, %xmm0
xorpd %xmm1, %xmm1
cvttsd2si %xmm2, %eax
cmpnltpd %xmm1, %xmm2
andpd %xmm0, %xmm2
movd %xmm2, %ecx
andl $0x1, %ecx
leaq 0x2b0571(%rip), %rdx    # 0x30d1f0
movl %ecx, (%rdx)
leaq 0x2b08e0(%rip), %rdx    # 0x30d568
movl %ecx, (%rdx)
leaq 0x2b055b(%rip), %rcx    # 0x30d1ec
movl %eax, (%rcx)
addq $0x20, %rsp
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/jkingan[P]ladyheather/heathgps.cpp
// Function: guess_leap_days()
void guess_leap_days()
{
double today;
double days;

   // If receiver has no day of leapsecond info, we attempt to guess it
   // assuming the leapsecond occurs on 30 Jun or 31 Dec.

   if((minor_alarms & MINOR_LEAP_PEND) == 0) return;  // no leap pending flag
   if(have_leap_days) return;  // receiver provided the leap day

   today = jdate(year,month,day);
   if(month >= 7) {
      days = jdate(year,12,31);
   }
   else {
      days = jdate(year,6,30);
   }
   jd_leap = days + jtime(23,59,59, 0.0);
   have_jd_leap = 2;
//   calc_jd_leap(2);

   days = days-today;
   if(days < 180.0) leap_days = (int) days;
   else leap_days = (-1);
   guessed_leap_days = '?';
}

// Assembly:
leaq 0x2b0538(%rip), %rax    # 0x30d1d8
testb $-0x80, (%rax)
je 0x5cd83
leaq 0x2b0540(%rip), %rax    # 0x30d1f0
cmpl $0x0, (%rax)
jne 0x5cd83
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
leaq 0x2b0811(%rip), %rbx    # 0x30d4dc
movl (%rbx), %edi
leaq 0x2b0804(%rip), %r14    # 0x30d4d8
movl (%r14), %esi
leaq 0x2b07f6(%rip), %rax    # 0x30d4d4
movl (%rax), %edx
callq 0xd485e
movsd %xmm0, -0x20(%rbp)
cmpl $0x7, (%r14)
movl (%rbx), %edi
jl 0x5ccfe
movl $0xc, %esi
movl $0x1f, %edx
jmp 0x5cd08
movl $0x6, %esi
movl $0x1e, %edx
callq 0xd485e
movsd %xmm0, -0x18(%rbp)
xorpd %xmm0, %xmm0
movl $0x17, %edi
movl $0x3b, %esi
movl $0x3b, %edx
callq 0xd492e
movsd -0x18(%rbp), %xmm1
addsd %xmm1, %xmm0
leaq 0x2b0826(%rip), %rax    # 0x30d560
movsd %xmm0, (%rax)
leaq 0x2b0823(%rip), %rax    # 0x30d568
movl $0x2, (%rax)
subsd -0x20(%rbp), %xmm1
movsd 0xaead8(%rip), %xmm0    # 0x10b830
ucomisd %xmm1, %xmm0
cvttsd2si %xmm1, %eax
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
cmoval %eax, %ecx
leaq 0x2b047d(%rip), %rax    # 0x30d1ec
movl %ecx, (%rax)
leaq 0x2b047c(%rip), %rax    # 0x30d1f4
movb $0x3f, (%rax)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq