LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/JMMackenzie[P]binary_to_jass/compress_integer_variable_byte.cpp
// Function: JASS::compress_integer_variable_byte::encode(void*, unsigned long, unsigned int const*, unsigned long)
size_t compress_integer_variable_byte::encode(void *encoded_as_void, size_t encoded_buffer_length, const integer *source, size_t source_integers)
		{
		uint8_t *encoded = static_cast<uint8_t *>(encoded_as_void);
		size_t used = 0;						// the number of bytes of storage used so far

		const integer *end = source + source_integers;			// the end of the input sequence
		
		/*
			Iterate over each integer in the input sequence
		*/
		for (const integer *current = source; current < end; current++)
			{
			/*
				find out how much space it'll take
			*/
			size_t needed = bytes_needed_for(*current);
			
			/*
				make sure it'll fit in the output buffer
			*/
			if (used + needed > encoded_buffer_length)
				return 0;				// didn't fit so return failure state.
			
			/*
				it fits so encode and add to the size used
			*/
			compress_into(encoded, *current);
			used += needed;
			}

		return used;
		}

// Assembly:
testq %r8, %r8
jle 0x587f2
leaq (%rcx,%r8,4), %rdi
xorl %eax, %eax
movl (%rcx), %r9d
movl $0x1, %r8d
cmpl $0x80, %r9d
jb 0x58774
movl $0x2, %r8d
cmpl $0x4000, %r9d           # imm = 0x4000
jb 0x58774
movl $0x3, %r8d
cmpl $0x200000, %r9d         # imm = 0x200000
jb 0x58774
cmpl $0x10000000, %r9d       # imm = 0x10000000
movl $0x5, %r8d
sbbq $0x0, %r8
addq %rax, %r8
cmpq %rdx, %r8
ja 0x587df
cmpl $0x80, %r9d
jb 0x587d2
cmpl $0x4000, %r9d           # imm = 0x4000
jb 0x587c5
cmpl $0x200000, %r9d         # imm = 0x200000
jb 0x587b8
cmpl $0x10000000, %r9d       # imm = 0x10000000
jb 0x587ab
movl %r9d, %eax
shrl $0x1c, %eax
movb %al, (%rsi)
incq %rsi
movl %r9d, %eax
shrl $0x15, %eax
andb $0x7f, %al
movb %al, (%rsi)
incq %rsi
movl %r9d, %eax
shrl $0xe, %eax
andb $0x7f, %al
movb %al, (%rsi)
incq %rsi
movl %r9d, %eax
shrl $0x7, %eax
andb $0x7f, %al
movb %al, (%rsi)
incq %rsi
orb $-0x80, %r9b
movb %r9b, (%rsi)
incq %rsi
movq %r8, %rax
cmpq %rdx, %r8
ja 0x587f2
addq $0x4, %rcx
cmpq %rdi, %rcx
jb 0x58733
retq
xorl %eax, %eax
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/bcthomas[P]shrinksam/src/shrinksam.cpp
// Function: show_usage(int)
void show_usage(int status) {
	cerr << Shrinksam::progname << " - shrinks a SAM file while maintaining mate pair information" << endl;
	cerr << endl << "(Written by bct - 2013)" << endl;
	cerr << endl << "Usage:" << endl;
	cerr << Shrinksam::progname << " -i <sam infile name> -k <shrunk sam outfile name>" << endl << endl;
	cerr << Shrinksam::progname << " -k <shrunk sam outfile name> <stdin>" << endl << endl;
	cerr << Shrinksam::progname << " < <stdin> > out" << endl << endl;

	cerr << "  Options:" << endl;
	cerr << "    -i, --input,        Optional - if not given, will read from stdin" << endl;
	cerr << "    -k, --shrunk,       Name for shrunk SAM output file" << endl;
	cerr << "    -d, --delete-input, Delete the input sam file (requires -i argument)" << endl;
	cerr << "    -u, --unpaired,     SAM file was from an unpaired mapping" << endl;
	cerr << "    -h, --help,         Display this help and exit" << endl;
	cerr << "    -v, --verbose,      Print extra details during the run" << endl;
	cerr << "    --version,          Output version information and exit" << endl;

	exit(status);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %edi, %ebx
movq 0x5d9f(%rip), %rsi      # 0x9338
movq 0x5a50(%rip), %r14      # 0x8ff0
movq %r14, %rdi
callq 0x3210
leaq 0x2a7b(%rip), %rsi      # 0x602a
movq %rax, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
movq %r14, %rdi
callq 0x3100
leaq 0x2a9a(%rip), %rsi      # 0x6068
movq %rax, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
movq %r14, %rdi
callq 0x3100
leaq 0x2a93(%rip), %rsi      # 0x6080
movq %rax, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
movq 0x5d34(%rip), %rsi      # 0x9338
movq %r14, %rdi
callq 0x3210
leaq 0x2a74(%rip), %rsi      # 0x6087
movq %rax, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
movq %rax, %rdi
callq 0x3100
movq 0x5d06(%rip), %rsi      # 0x9338
movq %r14, %rdi
callq 0x3210
leaq 0x2a79(%rip), %rsi      # 0x60ba
movq %rax, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
movq %rax, %rdi
callq 0x3100
movq 0x5cd8(%rip), %rsi      # 0x9338
movq %r14, %rdi
callq 0x3210
leaq 0x2a71(%rip), %rsi      # 0x60e0
movq %rax, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
movq %rax, %rdi
callq 0x3100
leaq 0x2a63(%rip), %rsi      # 0x60f1
movq %r14, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
leaq 0x2a57(%rip), %rsi      # 0x60fc
movq %r14, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
leaq 0x2a86(%rip), %rsi      # 0x6142
movq %r14, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
leaq 0x2aa7(%rip), %rsi      # 0x617a
movq %r14, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
leaq 0x2ad9(%rip), %rsi      # 0x61c3
movq %r14, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
leaq 0x2b00(%rip), %rsi      # 0x6201
movq %r14, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
leaq 0x2b1c(%rip), %rsi      # 0x6234
movq %r14, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
leaq 0x2b40(%rip), %rsi      # 0x626f
movq %r14, %rdi
callq 0x3210
movq %rax, %rdi
callq 0x3100
movl %ebx, %edi
callq 0x3290
// File: /workspace/github_cpp_makefile_star2_O1/bcthomas[P]shrinksam/src/sam.h
// Function: Shrinksam::Sam::find_cigar(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
std::string Sam::find_cigar(const std::string s) {
		for(std::vector<std::string>::iterator it = other.begin(); it != other.end(); ++it) {
			if ((*it).find(s) == 0)
				return(*it);
		}
		return("");
	}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movq 0xd8(%rsi), %r14
cmpq 0xe0(%rsi), %r14
sete %bpl
je 0x3f51
movq %rdx, %r15
movq %rsi, %r12
movq (%r15), %rsi
movq 0x8(%r15), %rcx
movq %r14, %rdi
xorl %edx, %edx
callq 0x33b0
testq %rax, %rax
je 0x3f33
addq $0x20, %r14
cmpq 0xe0(%r12), %r14
sete %bpl
jne 0x3f09
jmp 0x3f51
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
movq (%r14), %rsi
movq 0x8(%r14), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x55ce
testb %bpl, %bpl
je 0x3f6a
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
leaq 0x2556(%rip), %rdx      # 0x64b5
movq %rbx, %rdi
movq %rdx, %rsi
callq 0x565e
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/bcthomas[P]shrinksam/src/process_stream.cpp
// Function: parse_read_name(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
std::string parse_read_name(const string &oldname) {
	if ( (oldname.rfind("/1") == string::npos) && (oldname.rfind("/2") == string::npos) )
		return(oldname);
	else {
		std::string::size_type len = oldname.length();
		return(oldname.substr(0,len-2));
	}
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x24b9(%rip), %rsi      # 0x6440
movl $0x2, %ecx
movq %r14, %rdi
movq $-0x1, %rdx
callq 0x32b0
cmpq $-0x1, %rax
jne 0x3fc2
leaq 0x249b(%rip), %rsi      # 0x6443
movl $0x2, %ecx
movq %r14, %rdi
movq $-0x1, %rdx
callq 0x32b0
cmpq $-0x1, %rax
je 0x3fe2
movq 0x8(%r14), %rcx
addq $-0x2, %rcx
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x3260
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
movq (%r14), %rsi
movq 0x8(%r14), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x55ce
jmp 0x3fd7
// File: /workspace/github_cpp_makefile_star2_O1/bcthomas[P]shrinksam/src/sam.h
// Function: Shrinksam::operator<<(std::ostream&, Shrinksam::Sam const&)
std::ostream& operator<< (std::ostream &o, const Sam &i) {
				o << i.qname   << "\t"
				  << i.flag    << "\t"
				  << i.rname   << "\t"
				  << i.pos     << "\t"
				  << i.mapq    << "\t"
				  << i.cigar   << "\t"
				  << i.rnext   << "\t"
				  << i.pnext   << "\t"
				  << i.tlen    << "\t"
				  << i.seq     << "\t"
				  << i.qual    << "\t";
				for( auto it = i.other.begin(); it != i.other.end(); ++it) {
					if (++it != i.other.end()) { // incr to see what next element is
						--it;                    // next element is not end(), so decr
						o << *it << "\t";
					} else {
						--it;                    // decr to go back to right pos
						o << *it;
					}
				}
				return o;
			}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq (%rsi), %rsi
movq 0x8(%r14), %rdx
callq 0x3280
movq %rax, %r12
leaq 0x14e4(%rip), %r15      # 0x64b4
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movl 0x20(%r14), %esi
movq %r12, %rdi
callq 0x33a0
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movq 0x28(%r14), %rsi
movq 0x30(%r14), %rdx
movq %r12, %rdi
callq 0x3280
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movl 0x48(%r14), %esi
movq %r12, %rdi
callq 0x33a0
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movl 0x4c(%r14), %esi
movq %r12, %rdi
callq 0x33a0
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movq 0x50(%r14), %rsi
movq 0x58(%r14), %rdx
movq %r12, %rdi
callq 0x3280
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movq 0x70(%r14), %rsi
movq 0x78(%r14), %rdx
movq %r12, %rdi
callq 0x3280
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movl 0x90(%r14), %esi
movq %r12, %rdi
callq 0x33a0
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movl 0x94(%r14), %esi
movq %r12, %rdi
callq 0x33a0
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movq 0x98(%r14), %rsi
movq 0xa0(%r14), %rdx
movq %r12, %rdi
callq 0x3280
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movq 0xb8(%r14), %rsi
movq 0xc0(%r14), %rdx
movq %r12, %rdi
callq 0x3280
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movq 0xd8(%r14), %r12
movq 0xe0(%r14), %r13
cmpq %r13, %r12
je 0x5189
leaq 0x1361(%rip), %r15      # 0x64b4
movq (%r12), %rsi
movq 0x8(%r12), %rdx
addq $0x20, %r12
movq %rbx, %rdi
callq 0x3280
cmpq %r13, %r12
je 0x517d
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x3280
movq 0xe0(%r14), %r13
cmpq %r13, %r12
jne 0x5153
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/distributions/Empirical.cpp
// Function: DNest4::Empirical::Empirical(char const*)
Empirical::Empirical(const char* filename)
{
    string value;
	ifstream file(filename);
    while(file >> value) {
        data.push_back(stod(value));
    }
	file.close();
    // std::cout << "done reading data from " << filename << std::endl;
    std::sort(data.begin(), data.end());
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x248, %rsp            # imm = 0x248
movq %rdi, %rbx
leaq 0x4b451(%rip), %rax     # 0x52348
movq %rax, (%rdi)
leaq 0x8(%rdi), %rax
movq %rax, 0x8(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rdi)
xorl %eax, %eax
movq %rax, 0x18(%rdi)
leaq 0x20(%rsp), %rcx
movq %rcx, -0x10(%rcx)
movq %rax, -0x8(%rcx)
movb $0x0, (%rcx)
leaq 0x40(%rsp), %rdi
movl $0x8, %edx
callq 0x6770
leaq 0x40(%rsp), %r15
leaq 0x10(%rsp), %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x6510
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x6fc6
movq 0x10(%rsp), %rbp
callq 0x6040
movq %rax, %r14
movl (%rax), %r13d
movl $0x0, (%rax)
movq %rbp, %rdi
leaq 0x38(%rsp), %rsi
callq 0x6390
cmpq %rbp, 0x38(%rsp)
je 0x7042
movl (%r14), %eax
testl %eax, %eax
je 0x6f91
cmpl $0x22, %eax
jne 0x6f94
jmp 0x704e
movl %r13d, (%r14)
movsd %xmm0, 0x30(%rsp)
movq 0x10(%rbx), %rsi
cmpq 0x18(%rbx), %rsi
je 0x6fb2
movsd %xmm0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x10(%rbx)
jmp 0x6f39
movq 0x8(%rsp), %rdi
leaq 0x30(%rsp), %rdx
callq 0x744a
jmp 0x6f39
leaq 0x40(%rsp), %rdi
callq 0x60a0
movq 0x8(%rbx), %r14
movq 0x10(%rbx), %r15
cmpq %r15, %r14
je 0x700a
movq %r15, %rax
subq %r14, %rax
sarq $0x3, %rax
bsrq %rax, %rdx
xorl $0x3f, %edx
addl %edx, %edx
xorq $0x7e, %rdx
movq %r14, %rdi
movq %r15, %rsi
callq 0x7589
movq %r14, %rdi
movq %r15, %rsi
callq 0x7682
leaq 0x40(%rsp), %rdi
callq 0x60e0
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x7030
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x6460
addq $0x248, %rsp            # imm = 0x248
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x38047(%rip), %rdi     # 0x3f090
callq 0x6250
leaq 0x3803b(%rip), %rdi     # 0x3f090
callq 0x65a0
movq %rax, %r15
jmp 0x707e
jmp 0x7063
jmp 0x7063
movq %rax, %r15
jmp 0x7074
movq %rax, %r15
cmpl $0x0, (%r14)
jne 0x7074
movl %r13d, (%r14)
leaq 0x40(%rsp), %rdi
callq 0x60e0
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x709a
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x6460
movq 0x8(%rsp), %rax
movq (%rax), %rdi
testq %rdi, %rdi
je 0x70b3
movq 0x18(%rbx), %rsi
subq %rdi, %rsi
callq 0x6460
movq %r15, %rdi
callq 0x6710
nop
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/distributions/Empirical.cpp
// Function: DNest4::Empirical::cdf_inverse(double) const
double Empirical::cdf_inverse(double p) const
{
    if(p < 0.0 || p > 1.0)
        throw std::domain_error("Input to cdf_inverse must be in [0, 1].");
    
    double poi = -0.5*(1 - p) + p*(data.size()-0.5);

    size_t left = max(int64_t(floor(poi)), int64_t(0));
    size_t right = min(int64_t(ceil(poi)), int64_t(data.size() - 1));

    double datLeft = data.at(left);
    double datRight = data.at(right);

    double t = poi - left;
    double quantile = (1 - t)*datLeft + t*datRight;

    return quantile;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
xorpd %xmm1, %xmm1
ucomisd %xmm0, %xmm1
ja 0x72c0
ucomisd 0x37e45(%rip), %xmm0    # 0x3f030
ja 0x72c0
movsd 0x37e37(%rip), %xmm3    # 0x3f030
subsd %xmm0, %xmm3
movq 0x8(%rdi), %r15
movq 0x10(%rdi), %rbx
subq %r15, %rbx
sarq $0x3, %rbx
movq %rbx, %xmm1
punpckldq 0x37df7(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1]
subpd 0x37dff(%rip), %xmm1    # 0x3f020
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
movsd 0x37e03(%rip), %xmm1    # 0x3f038
addsd %xmm1, %xmm2
mulsd %xmm0, %xmm2
mulsd %xmm1, %xmm3
addsd %xmm2, %xmm3
movapd %xmm3, %xmm0
movsd %xmm3, 0x8(%rsp)
callq 0x6680
cvttsd2si %xmm0, %rax
xorl %r14d, %r14d
testq %rax, %rax
cmovgq %rax, %r14
movsd 0x8(%rsp), %xmm0
callq 0x6090
cvttsd2si %xmm0, %rsi
leaq -0x1(%rbx), %rax
cmpq %rsi, %rax
cmovlq %rax, %rsi
cmpq %r14, %rbx
jbe 0x72f2
cmpq %rsi, %rbx
jbe 0x72fe
xorps %xmm0, %xmm0
cvtsi2sd %r14, %xmm0
movsd 0x8(%rsp), %xmm1
subsd %xmm0, %xmm1
movsd 0x37d8e(%rip), %xmm0    # 0x3f030
subsd %xmm1, %xmm0
mulsd (%r15,%rsi,8), %xmm1
mulsd (%r15,%r14,8), %xmm0
addsd %xmm1, %xmm0
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
movl $0x10, %edi
callq 0x61d0
movq %rax, %rbx
leaq 0x37d6c(%rip), %rsi     # 0x3f040
movq %rax, %rdi
callq 0x6280
movq 0x4bc5d(%rip), %rsi     # 0x52f40
movq 0x4bc76(%rip), %rdx     # 0x52f60
movq %rbx, %rdi
callq 0x66c0
leaq 0x37db6(%rip), %rdi     # 0x3f0af
movq %r14, %rsi
jmp 0x7305
leaq 0x37daa(%rip), %rdi     # 0x3f0af
movq %rbx, %rdx
xorl %eax, %eax
callq 0x65d0
movq %rax, %r14
movq %rbx, %rdi
callq 0x6340
movq %r14, %rdi
callq 0x6710
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/distributions/Gaussian_from_Tc.cpp
// Function: DNest4::Gaussian_from_Tc::Gaussian_from_Tc(double, double, double, double)
Gaussian_from_Tc::Gaussian_from_Tc(double Tc, double errTc, double P, double errP)
    {
        double t0 = Data::get_instance().M0_epoch;

        // propagate uncertainty on Tc and P to phi
        double A, B, AoB, sA, sB;
        A = t0 - Tc;
        B = (2 * M_PI * P);
        AoB = A / B;
        sA = errTc;
        sB = (2 * M_PI * errP);

        // build the Gaussian distribution for phi
        m = AoB;
        s = fabs(AoB) * sqrt(pow(sA/A, 2) + pow(sB/B, 2));
        d = Gaussian(m, s);
    }

// Assembly:
pushq %r14
pushq %rbx
subq $0x48, %rsp
movsd %xmm3, 0x10(%rsp)
movsd %xmm2, 0x20(%rsp)
movsd %xmm1, (%rsp)
movsd %xmm0, 0x18(%rsp)
movq %rdi, %rbx
leaq 0x4a984(%rip), %rax     # 0x52408
movq %rax, (%rdi)
addq $0x18, %rdi
movsd 0x3759d(%rip), %xmm1    # 0x3f030
xorps %xmm0, %xmm0
callq 0x3d83c
movsd 0x10(%rsp), %xmm0
leaq 0x4b958(%rip), %rax     # 0x53400
movsd 0x100(%rax), %xmm2
subsd 0x18(%rsp), %xmm2
movsd 0x37692(%rip), %xmm1    # 0x3f150
movsd 0x20(%rsp), %xmm4
mulsd %xmm1, %xmm4
movsd (%rsp), %xmm3
divsd %xmm2, %xmm3
divsd %xmm4, %xmm2
mulsd %xmm1, %xmm0
movsd %xmm2, 0x8(%rbx)
andpd 0x3767a(%rip), %xmm2    # 0x3f160
mulsd %xmm3, %xmm3
divsd %xmm4, %xmm0
mulsd %xmm0, %xmm0
addsd %xmm3, %xmm0
ucomisd 0x3765a(%rip), %xmm0    # 0x3f158
jb 0x7b09
xorps %xmm1, %xmm1
sqrtsd %xmm0, %xmm1
jmp 0x7b1c
movapd %xmm2, (%rsp)
callq 0x63b0
movapd (%rsp), %xmm2
movapd %xmm0, %xmm1
mulsd %xmm2, %xmm1
movsd %xmm1, 0x10(%rbx)
movsd 0x8(%rbx), %xmm0
leaq 0x28(%rsp), %r14
movq %r14, %rdi
callq 0x3d83c
movq 0x18(%r14), %rax
movq %rax, 0x30(%rbx)
movups 0x8(%r14), %xmm0
movups %xmm0, 0x20(%rbx)
addq $0x48, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/distributions/mixGaussianLogUniform.cpp
// Function: DNest4::mixGaussianLogUniform::cdf_inverse(double) const
double mixGaussianLogUniform::cdf_inverse(double p) const
{
    // not implemented
    // throw std::runtime_error("cdf_inverse not implemented for `mixGaussianLogUniform`");

    // estimate cdf_inverse with bisection
    double tol = 2e-12, a = lower, b = upper;
    double c = a;

    while ((b - a) >= tol)
    {
        c = (a + b) / 2;
        if (cdf(c) - p == 0.0)
            break;
        else if ((cdf(c) - p) * (cdf(a) - p) < 0)
            b = c;
        else
            a = c;
    }

    return c;
}

// Assembly:
pushq %rbx
subq $0x40, %rsp
movsd 0x18(%rdi), %xmm2
movsd 0x20(%rdi), %xmm4
movapd %xmm4, %xmm1
subsd %xmm2, %xmm1
ucomisd 0x37479(%rip), %xmm1    # 0x3f1a0
jae 0x7d32
movapd %xmm2, %xmm3
jmp 0x7e09
movq %rdi, %rbx
movsd %xmm0, 0x8(%rsp)
movapd %xmm2, 0x30(%rsp)
movapd %xmm2, %xmm0
movsd %xmm4, 0x20(%rsp)
addsd %xmm4, %xmm0
mulsd 0x37441(%rip), %xmm0    # 0x3f198
movq (%rbx), %rax
movq %rbx, %rdi
movapd %xmm0, 0x10(%rsp)
callq *0x10(%rax)
xorpd %xmm2, %xmm2
movsd 0x8(%rsp), %xmm1
subsd %xmm1, %xmm0
ucomisd %xmm2, %xmm0
jne 0x7d80
jnp 0x7e03
movq (%rbx), %rax
movq %rbx, %rdi
movapd 0x10(%rsp), %xmm0
callq *0x10(%rax)
subsd 0x8(%rsp), %xmm0
movsd %xmm0, 0x28(%rsp)
movq (%rbx), %rax
movq %rbx, %rdi
movapd 0x30(%rsp), %xmm0
callq *0x10(%rax)
xorpd %xmm2, %xmm2
subsd 0x8(%rsp), %xmm0
mulsd 0x28(%rsp), %xmm0
ucomisd %xmm0, %xmm2
movapd 0x10(%rsp), %xmm3
movapd %xmm3, %xmm1
ja 0x7dd0
movsd 0x20(%rsp), %xmm1
cmpltsd %xmm2, %xmm0
movapd 0x30(%rsp), %xmm2
andpd %xmm0, %xmm2
andnpd %xmm3, %xmm0
orpd %xmm0, %xmm2
movapd %xmm1, %xmm0
subsd %xmm2, %xmm0
ucomisd 0x373a9(%rip), %xmm0    # 0x3f1a0
movapd %xmm1, %xmm4
jae 0x7d3b
jmp 0x7e09
movapd 0x10(%rsp), %xmm3
movapd %xmm3, %xmm0
addq $0x40, %rsp
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/distributions/mixGaussianLogUniform.cpp
// Function: DNest4::mixGaussianLogUniform::perturb(double&, DNest4::RNG&) const
double mixGaussianLogUniform::perturb(double& x, RNG& rng) const
{
    x = cdf(x);
    x += rng.randh();
    wrap(x, 0.0, 1.0);
    if (rng.rand_int(2) == 0)
        x = G.cdf_inverse(x);
    else
        x = LU.cdf_inverse(x);
    return 0.0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
movsd (%rsi), %xmm0
movq (%rdi), %rax
callq *0x10(%rax)
movsd %xmm0, (%rbx)
movq %r15, %rdi
callq 0x3c0ec
addsd (%rbx), %xmm0
movsd %xmm0, (%rbx)
movsd 0x3718c(%rip), %xmm1    # 0x3f030
xorpd %xmm0, %xmm0
movq %rbx, %rdi
callq 0x3c5fb
movq %r15, %rdi
movl $0x2, %esi
callq 0x3c1d6
movsd (%rbx), %xmm0
testl %eax, %eax
je 0x7ed3
addq $0x48, %r14
movq %r14, %rdi
callq 0x3e138
jmp 0x7edf
addq $0x28, %r14
movq %r14, %rdi
callq 0x3d8ca
movsd %xmm0, (%rbx)
xorps %xmm0, %xmm0
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/RVConditionalPrior.cpp
// Function: RVConditionalPrior::from_prior(DNest4::RNG&)
void RVConditionalPrior::from_prior(RNG& rng)
{
    if(hyperpriors)
    {
        center = log_muP_prior->generate(rng);
        width = wP_prior->generate(rng);
        muK = exp(log_muK_prior->generate(rng));
    }
}

// Assembly:
leaq 0x3ce8b(%rip), %rax     # 0x45382
cmpb $0x1, (%rax)
jne 0x8548
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq 0x70(%rdi), %rdi
callq 0x3d1dc
movsd %xmm0, 0x8(%rbx)
movq 0x80(%rbx), %rdi
movq %r14, %rsi
callq 0x3d1dc
movsd %xmm0, 0x10(%rbx)
movq 0x90(%rbx), %rdi
movq %r14, %rsi
callq 0x3d1dc
callq 0x6730
movsd %xmm0, 0x18(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/RVConditionalPrior.cpp
// Function: RVConditionalPrior::perturb_hyperparameters(DNest4::RNG&)
double RVConditionalPrior::perturb_hyperparameters(RNG& rng)
{
    double logH = 0.;

    if(hyperpriors)
    {
        int which = rng.rand_int(3);

        if(which == 0)
            log_muP_prior->perturb(center, rng);
        else if(which == 1)
            wP_prior->perturb(width, rng);
        else
        {
            muK = log(muK);
            log_muK_prior->perturb(muK, rng);
            muK = exp(muK);
        }
    }

    return logH;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0x3ce2c(%rip), %rax     # 0x45382
cmpb $0x1, (%rax)
jne 0x85cd
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
movl $0x3, %esi
callq 0x3c1d6
cmpl $0x1, %eax
je 0x8581
testl %eax, %eax
jne 0x8599
movq 0x70(%rbx), %rdi
addq $0x8, %rbx
jmp 0x858c
movq 0x80(%rbx), %rdi
addq $0x10, %rbx
movq %rbx, %rsi
movq %r14, %rdx
callq 0x3d1f6
jmp 0x85cd
leaq 0x18(%rbx), %r15
movsd 0x18(%rbx), %xmm0
callq 0x63c0
movsd %xmm0, 0x18(%rbx)
movq 0x90(%rbx), %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x3d1f6
movsd 0x18(%rbx), %xmm0
callq 0x6730
movsd %xmm0, 0x18(%rbx)
xorps %xmm0, %xmm0
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/RVConditionalPrior.cpp
// Function: RVConditionalPrior::log_pdf(std::vector<double, std::allocator<double>> const&) const
double RVConditionalPrior::log_pdf(const std::vector<double>& vec) const
{
    if(hyperpriors)
    {
        if(vec[2] < 0. || vec[2] > 2.*M_PI ||
           vec[3] < 0. || vec[3] >= 1.0 ||
           vec[4] < 0. || vec[4] > 2.*M_PI)
             return -1E300;

        Pprior->setpars(center, width);
        Kprior->setpars(muK);
    }
    else
    {
        if(vec[0] < 1. || vec[0] > 1E4 ||
           vec[1] < 0. ||
           vec[2] < 0. || vec[2] > 2.*M_PI ||
           vec[3] < 0. || vec[3] >= 1.0 ||
           vec[4] < 0. || vec[4] > 2.*M_PI)
             return -1E300;
    }

    return Pprior->log_pdf(vec[0]) + 
           Kprior->log_pdf(vec[1]) + 
           phiprior->log_pdf(vec[2]) + 
           eprior->log_pdf(vec[3]) + 
           wprior->log_pdf(vec[4]);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x3cd9b(%rip), %rcx     # 0x45382
movq (%rsi), %rax
cmpb $0x1, (%rcx)
jne 0x8702
movsd 0x10(%rax), %xmm1
xorpd %xmm0, %xmm0
ucomisd %xmm1, %xmm0
movsd 0x36bd0(%rip), %xmm0    # 0x3f1d8
ja 0x8731
ucomisd 0x36b3a(%rip), %xmm1    # 0x3f150
ja 0x8731
movsd 0x18(%rax), %xmm1
xorpd %xmm2, %xmm2
ucomisd %xmm1, %xmm2
ja 0x8731
ucomisd 0x369f9(%rip), %xmm1    # 0x3f030
jae 0x8731
movsd 0x20(%rax), %xmm1
ucomisd %xmm1, %xmm2
ja 0x8731
ucomisd 0x36afc(%rip), %xmm1    # 0x3f150
ja 0x8731
movq 0x20(%r14), %rdi
movsd 0x8(%r14), %xmm0
movsd 0x10(%r14), %xmm1
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x30(%r14), %rdi
movsd 0x18(%r14), %xmm0
movq (%rdi), %rax
callq *(%rax)
movq 0x20(%r14), %rdi
movq (%rbx), %rax
movsd (%rax), %xmm0
movq (%rdi), %rax
callq *0x20(%rax)
movsd %xmm0, (%rsp)
movq 0x30(%r14), %rdi
movq (%rbx), %rax
movsd 0x8(%rax), %xmm0
movq (%rdi), %rax
callq *0x20(%rax)
addsd (%rsp), %xmm0
movsd %xmm0, (%rsp)
movq 0x50(%r14), %rdi
movq (%rbx), %rax
movsd 0x10(%rax), %xmm0
movq (%rdi), %rax
callq *0x20(%rax)
addsd (%rsp), %xmm0
movsd %xmm0, (%rsp)
movq 0x40(%r14), %rdi
movq (%rbx), %rax
movsd 0x18(%rax), %xmm0
movq (%rdi), %rax
callq *0x20(%rax)
addsd (%rsp), %xmm0
movsd %xmm0, (%rsp)
movq 0x60(%r14), %rdi
movq (%rbx), %rax
movsd 0x20(%rax), %xmm0
movq (%rdi), %rax
callq *0x20(%rax)
addsd (%rsp), %xmm0
jmp 0x8731
movsd (%rax), %xmm1
movsd 0x36922(%rip), %xmm0    # 0x3f030
ucomisd %xmm1, %xmm0
movsd 0x36abe(%rip), %xmm0    # 0x3f1d8
ja 0x8731
ucomisd 0x36abc(%rip), %xmm1    # 0x3f1e0
ja 0x8731
xorpd %xmm1, %xmm1
ucomisd 0x8(%rax), %xmm1
jbe 0x8739
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movsd 0x10(%rax), %xmm2
ucomisd %xmm2, %xmm1
ja 0x8731
ucomisd 0x36a04(%rip), %xmm2    # 0x3f150
ja 0x8731
movsd 0x18(%rax), %xmm1
xorpd %xmm2, %xmm2
ucomisd %xmm1, %xmm2
ja 0x8731
ucomisd 0x368cb(%rip), %xmm1    # 0x3f030
jae 0x8731
movsd 0x20(%rax), %xmm1
ucomisd %xmm1, %xmm2
ja 0x8731
ucomisd 0x369d6(%rip), %xmm1    # 0x3f150
jbe 0x867f
jmp 0x8731
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/RVConditionalPrior.cpp
// Function: RVConditionalPrior::from_uniform(std::vector<double, std::allocator<double>>&) const
void RVConditionalPrior::from_uniform(std::vector<double>& vec) const
{
    if(hyperpriors)
    {
        Pprior->setpars(center, width);
        Kprior->setpars(muK);
    }

    vec[0] = Pprior->cdf_inverse(vec[0]);
    vec[1] = Kprior->cdf_inverse(vec[1]);
    vec[2] = phiprior->cdf_inverse(vec[2]);
    vec[3] = eprior->cdf_inverse(vec[3]);
    vec[4] = wprior->cdf_inverse(vec[4]);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x3cbef(%rip), %rax     # 0x45382
cmpb $0x1, (%rax)
jne 0x87bd
movq 0x20(%r14), %rdi
movsd 0x8(%r14), %xmm0
movsd 0x10(%r14), %xmm1
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x30(%r14), %rdi
movsd 0x18(%r14), %xmm0
movq (%rdi), %rax
callq *(%rax)
movq 0x20(%r14), %rdi
movq (%rbx), %rax
movsd (%rax), %xmm0
movq (%rdi), %rax
callq *0x18(%rax)
movq (%rbx), %rax
movsd %xmm0, (%rax)
movq 0x30(%r14), %rdi
movsd 0x8(%rax), %xmm0
movq (%rdi), %rax
callq *0x18(%rax)
movq (%rbx), %rax
movsd %xmm0, 0x8(%rax)
movq 0x50(%r14), %rdi
movsd 0x10(%rax), %xmm0
movq (%rdi), %rax
callq *0x18(%rax)
movq (%rbx), %rax
movsd %xmm0, 0x10(%rax)
movq 0x40(%r14), %rdi
movsd 0x18(%rax), %xmm0
movq (%rdi), %rax
callq *0x18(%rax)
movq (%rbx), %rax
movsd %xmm0, 0x18(%rax)
movq 0x60(%r14), %rdi
movsd 0x20(%rax), %xmm0
movq (%rdi), %rax
callq *0x18(%rax)
movq (%rbx), %rax
movsd %xmm0, 0x20(%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/RVConditionalPrior.cpp
// Function: RVConditionalPrior::to_uniform(std::vector<double, std::allocator<double>>&) const
void RVConditionalPrior::to_uniform(std::vector<double>& vec) const
{
    if(hyperpriors)
    {
        Pprior->setpars(center, width);
        Kprior->setpars(muK);
    }

    vec[0] = Pprior->cdf(vec[0]);
    vec[1] = Kprior->cdf(vec[1]);
    vec[2] = phiprior->cdf(vec[2]);
    vec[3] = eprior->cdf(vec[3]);
    vec[4] = wprior->cdf(vec[4]);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x3cb37(%rip), %rax     # 0x45382
cmpb $0x1, (%rax)
jne 0x8875
movq 0x20(%r14), %rdi
movsd 0x8(%r14), %xmm0
movsd 0x10(%r14), %xmm1
movq (%rdi), %rax
callq *0x8(%rax)
movq 0x30(%r14), %rdi
movsd 0x18(%r14), %xmm0
movq (%rdi), %rax
callq *(%rax)
movq 0x20(%r14), %rdi
movq (%rbx), %rax
movsd (%rax), %xmm0
movq (%rdi), %rax
callq *0x10(%rax)
movq (%rbx), %rax
movsd %xmm0, (%rax)
movq 0x30(%r14), %rdi
movsd 0x8(%rax), %xmm0
movq (%rdi), %rax
callq *0x10(%rax)
movq (%rbx), %rax
movsd %xmm0, 0x8(%rax)
movq 0x50(%r14), %rdi
movsd 0x10(%rax), %xmm0
movq (%rdi), %rax
callq *0x10(%rax)
movq (%rbx), %rax
movsd %xmm0, 0x10(%rax)
movq 0x40(%r14), %rdi
movsd 0x18(%rax), %xmm0
movq (%rdi), %rax
callq *0x10(%rax)
movq (%rbx), %rax
movsd %xmm0, 0x18(%rax)
movq 0x60(%r14), %rdi
movsd 0x20(%rax), %xmm0
movq (%rdi), %rax
callq *0x10(%rax)
movq (%rbx), %rax
movsd %xmm0, 0x20(%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/Data.cpp
// Function: operator>>(std::istream&, std::vector<double, std::allocator<double>>&)
istream& operator >> ( istream& ins, record_t& record )
  // Let's overload the stream input operator to read a list of CSV fields (which a CSV record).
  //-----------------------------------------------------------------------------
  {
  // make sure that the returned record contains only the stuff we read now
  record.clear();

  // read the entire line into a string (a CSV record is terminated by a newline)
  string line;
  getline( ins, line );

  // now we'll use a stringstream to separate the fields out of the line
  stringstream ss( line );

  // convert each field to a double and 
  // add the newly-converted field to the end of the record
  double f;
  while (ss >> f)
    record.push_back(f);

  // Now we have read a single line, converted into a list of fields, converted the fields
  // from strings to doubles, and stored the results in the argument record, so
  // we just return the argument stream as required for this kind of input overload function.
  return ins;
  }

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1b0, %rsp            # imm = 0x1B0
movq %rsi, %r14
movq %rdi, %rbx
movq (%rsi), %rax
cmpq %rax, 0x8(%rsi)
je 0x917a
movq %rax, 0x8(%r14)
leaq 0x18(%rsp), %r13
movq %r13, -0x10(%r13)
movq $0x0, -0x8(%r13)
movb $0x0, (%r13)
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x6430
movsbl %al, %edx
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x6780
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
movl $0x18, %edx
callq 0x6620
leaq 0x28(%rsp), %r15
movq %rsp, %r12
movq %r15, %rdi
movq %r12, %rsi
callq 0x62c0
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x9213
movq 0x8(%r14), %rsi
cmpq 0x10(%r14), %rsi
je 0x9206
movsd (%rsp), %xmm0
movsd %xmm0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x8(%r14)
jmp 0x91d0
movq %r14, %rdi
movq %r12, %rdx
callq 0xbf7a
jmp 0x91d0
movq 0x49d0e(%rip), %rsi     # 0x52f28
leaq 0x28(%rsp), %rdi
callq 0x6360
leaq 0xa8(%rsp), %rdi
callq 0x6130
movq 0x8(%rsp), %rdi
cmpq %r13, %rdi
je 0x9248
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x6460
movq %rbx, %rax
addq $0x1b0, %rsp            # imm = 0x1B0
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jmp 0x925e
movq %rax, %rbx
jmp 0x9284
movq %rax, %rbx
movq 0x49cbb(%rip), %rsi     # 0x52f28
leaq 0x28(%rsp), %rdi
callq 0x6360
leaq 0xa8(%rsp), %rdi
callq 0x6130
movq 0x8(%rsp), %rdi
cmpq %r13, %rdi
je 0x929b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x6460
movq %rbx, %rdi
callq 0x6710
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/Data.cpp
// Function: operator>>(std::istream&, std::vector<std::vector<double, std::allocator<double>>, std::allocator<std::vector<double, std::allocator<double>>>>&)
istream& operator >> ( istream& ins, data_t& data )
// Overload the stream input operator to read a list of CSV records. We only 
// need to worry about reading records, and not fields.
{
  // make sure that the returned data only contains the CSV data we read here
  // data.clear();

  // for every record we can read from the file, append it to our resulting data
  // except if it's in the header
  record_t record;
  while (ins >> record)
    {
      data.push_back(record);
    }

  // return the argument stream
  return ins;  
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movq %rsp, %r15
movaps %xmm0, (%r15)
movq $0x0, 0x10(%r15)
movq %rbx, %rdi
movq %r15, %rsi
callq 0x9157
movq (%rbx), %rax
movq -0x18(%rax), %rax
testb $0x5, 0x20(%rbx,%rax)
jne 0x92ea
movq %r14, %rdi
movq %r15, %rsi
callq 0xb8ea
jmp 0x92c4
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x9300
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x6460
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x9326
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x6460
movq %rbx, %rdi
callq 0x6710
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/Data.cpp
// Function: Data::get_max_RV_span() const
double Data::get_max_RV_span() const
{
  // for multiple instruments, calculate individual RV spans and return largest
  if (datamulti) {
    double span = 0.0;
    for(size_t j=0; j<number_instruments; j++)
    {
      vector<double> obsy;
      for (size_t i=0; i<y.size(); ++i) 
      {
        if (obsi[i] == j + 1) 
        {
          obsy.push_back(y[i]);
        }
      }
      const auto min = std::min_element(obsy.begin(), obsy.end());
      const auto max = std::max_element(obsy.begin(), obsy.end());
      double this_obs_span = *max - *min;
      if (this_obs_span > span)
        span = this_obs_span;
    }
    return span;
  }

  // for one instrument only, this is easy
  else {
    return get_RV_span();
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
cmpb $0x1, 0xf4(%rdi)
jne 0xb295
cmpl $0x0, 0xf8(%rbx)
je 0xb2ab
xorpd %xmm1, %xmm1
xorl %r15d, %r15d
movq %rsp, %r14
movsd %xmm1, 0x20(%rsp)
xorpd %xmm0, %xmm0
movapd %xmm0, (%rsp)
movq $0x0, 0x10(%rsp)
movq 0x18(%rbx), %rdx
cmpq %rdx, 0x20(%rbx)
je 0xb1e2
leaq 0x1(%r15), %r12
xorl %r13d, %r13d
xorl %ebp, %ebp
movq 0x48(%rbx), %rax
movslq (%rax,%rbp,4), %rax
cmpq %rax, %r12
jne 0xb1c7
addq %r13, %rdx
movq 0x8(%rsp), %rsi
cmpq 0x10(%rsp), %rsi
je 0xb1bf
movsd (%rdx), %xmm0
movsd %xmm0, (%rsi)
addq $0x8, %rsi
movq %rsi, 0x8(%rsp)
jmp 0xb1c7
movq %r14, %rdi
callq 0xbf7a
incq %rbp
movq 0x18(%rbx), %rdx
movq 0x20(%rbx), %rax
subq %rdx, %rax
sarq $0x3, %rax
addq $0x8, %r13
cmpq %rax, %rbp
jb 0xb190
movq (%rsp), %rdi
movq 0x8(%rsp), %rax
cmpq %rax, %rdi
sete %dl
leaq 0x8(%rdi), %rcx
cmpq %rax, %rcx
sete %sil
orb %dl, %sil
movq %rdi, %rdx
jne 0xb228
movq %rcx, %r8
movq %rdi, %r9
movsd (%r9), %xmm0
ucomisd (%r8), %xmm0
movq %r8, %rdx
ja 0xb21c
movq %r9, %rdx
addq $0x8, %r8
movq %rdx, %r9
cmpq %rax, %r8
jne 0xb20a
movq %rdi, %r8
testb %sil, %sil
jne 0xb24f
movq %rdi, %rsi
movsd (%rcx), %xmm0
ucomisd (%rsi), %xmm0
movq %rcx, %r8
ja 0xb243
movq %rsi, %r8
addq $0x8, %rcx
movq %r8, %rsi
cmpq %rax, %rcx
jne 0xb233
movsd (%r8), %xmm0
subsd (%rdx), %xmm0
testq %rdi, %rdi
je 0xb276
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
movsd %xmm0, 0x18(%rsp)
callq 0x6460
movsd 0x18(%rsp), %xmm0
maxsd 0x20(%rsp), %xmm0
incq %r15
movslq 0xf8(%rbx), %rax
movapd %xmm0, %xmm1
cmpq %rax, %r15
jb 0xb165
jmp 0xb2af
movq %rbx, %rdi
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xb0b8
xorpd %xmm0, %xmm0
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq (%rsp), %rdi
testq %rdi, %rdi
je 0xb2d7
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x6460
movq %rbx, %rdi
callq 0x6710
nop
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/Data.cpp
// Function: Data::get_adjusted_RV_var() const
double Data::get_adjusted_RV_var() const
{
    int ni;
    double sum, mean;
    std::vector<double> rva(t.size());

    for(size_t j=0; j<number_instruments; j++)
    {
      ni = 0;
      sum = 0.;
      for (size_t i=0; i<t.size(); i++)
        if(obsi[i] == j+1) {sum += y[i]; ni++;}
      mean = sum / ni;
      // cout << "sum: " << sum << endl;
      // cout << "mean: " << mean << endl;
      for (size_t i=0; i<t.size(); i++)
        if(obsi[i] == j+1) rva[i] = y[i] - mean;
    }

    mean = std::accumulate(rva.begin(), rva.end(), 0.0) / rva.size();
    double accum = 0.0;
    std::for_each (rva.begin(), rva.end(), [&](const double d) {
        accum += (d - mean) * (d - mean);
    });
    return accum / (y.size()-1);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rdi, %rbx
movq 0x8(%rdi), %rsi
subq (%rdi), %rsi
sarq $0x3, %rsi
leaq 0x18(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0xbb9c
movslq 0xf8(%rbx), %rax
testq %rax, %rax
je 0xb3bd
movq (%rbx), %rcx
movq 0x8(%rbx), %rdx
movq %rdx, %rsi
subq %rcx, %rsi
sarq $0x3, %rsi
movq 0x48(%rbx), %rdi
cmpq $0x1, %rsi
adcq $0x0, %rsi
xorl %r8d, %r8d
movsd 0x34182(%rip), %xmm0    # 0x3f4c0
movapd %xmm0, %xmm1
cmpq %rcx, %rdx
je 0xb37f
leaq 0x1(%r8), %r9
movq 0x18(%rbx), %r10
xorpd %xmm1, %xmm1
xorl %r11d, %r11d
xorl %r14d, %r14d
movslq (%rdi,%r14,4), %r15
cmpq %r15, %r9
jne 0xb36b
addsd (%r10,%r14,8), %xmm1
incl %r11d
incq %r14
cmpq %r14, %rsi
jne 0xb359
xorps %xmm2, %xmm2
cvtsi2sd %r11d, %xmm2
divsd %xmm2, %xmm1
cmpq %rcx, %rdx
je 0xb3b5
leaq 0x1(%r8), %r9
movq 0x18(%rbx), %r10
movq 0x18(%rsp), %r11
xorl %r14d, %r14d
movslq (%rdi,%r14,4), %r15
cmpq %r15, %r9
jne 0xb3ad
movsd (%r10,%r14,8), %xmm2
subsd %xmm1, %xmm2
movsd %xmm2, (%r11,%r14,8)
incq %r14
cmpq %r14, %rsi
jne 0xb394
incq %r8
cmpq %rax, %r8
jne 0xb33e
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rax
xorpd %xmm0, %xmm0
xorpd %xmm3, %xmm3
cmpq %rax, %rdi
je 0xb3e4
movq %rdi, %rcx
addsd (%rcx), %xmm3
addq $0x8, %rcx
cmpq %rax, %rcx
jne 0xb3d7
movq %rax, %rcx
subq %rdi, %rcx
je 0xb435
sarq $0x3, %rcx
movq %rcx, %xmm1
punpckldq 0x33c13(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1]
subpd 0x33c1b(%rip), %xmm1    # 0x3f020
movapd %xmm1, %xmm2
unpckhpd %xmm1, %xmm2            # xmm2 = xmm2[1],xmm1[1]
addsd %xmm1, %xmm2
divsd %xmm2, %xmm3
xorpd %xmm0, %xmm0
movq %rdi, %rcx
movsd (%rcx), %xmm1
subsd %xmm3, %xmm1
mulsd %xmm1, %xmm1
addsd %xmm1, %xmm0
addq $0x8, %rcx
cmpq %rax, %rcx
jne 0xb41c
movq 0x18(%rbx), %r14
movq 0x20(%rbx), %rbx
testq %rdi, %rdi
je 0xb45b
movq 0x28(%rsp), %rsi
subq %rdi, %rsi
movsd %xmm0, 0x10(%rsp)
callq 0x6460
movsd 0x10(%rsp), %xmm0
subq %r14, %rbx
sarq $0x3, %rbx
decq %rbx
movq %rbx, %xmm2
punpckldq 0x33b9e(%rip), %xmm2 # xmm2 = xmm2[0],mem[0],xmm2[1],mem[1]
subpd 0x33ba6(%rip), %xmm2    # 0x3f020
movapd %xmm2, %xmm1
unpckhpd %xmm2, %xmm1            # xmm1 = xmm1[1],xmm2[1]
addsd %xmm2, %xmm1
divsd %xmm1, %xmm0
addq $0x30, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/RVmodel.cpp
// Function: RVmodel::add_known_object()
void RVmodel::add_known_object()
{
    auto data = Data::get_instance();
    auto t = data.get_t();
    double f, v, ti, Tp;
    for(int j=0; j<n_known_object; j++)
    {
        for(size_t i=0; i<t.size(); i++)
        {
            ti = t[i];
            Tp = data.M0_epoch-(KO_P[j]*KO_phi[j])/(2.*M_PI);
            f = kepler::true_anomaly(ti, KO_P[j], KO_e[j], Tp);
            v = KO_K[j] * (cos(f+KO_w[j]) + KO_e[j]*cos(KO_w[j]));
            mu[i] += v;
        }
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x140, %rsp            # imm = 0x140
movq %rdi, %rbx
leaq 0x43612(%rip), %rsi     # 0x53400
leaq 0x38(%rsp), %r14
movq %r14, %rdi
callq 0x1560c
movq %rsp, %rdi
movq %r14, %rsi
callq 0xc1e6
leaq 0x3557f(%rip), %rax     # 0x4538c
movslq (%rax), %r14
testq %r14, %r14
jle 0xff2b
xorl %r15d, %r15d
movsd 0x2f89c(%rip), %xmm2    # 0x3f6c0
movq (%rsp), %rax
cmpq %rax, 0x8(%rsp)
je 0xff1f
xorl %r12d, %r12d
xorl %r13d, %r13d
movsd (%rax,%r13,8), %xmm0
movq 0x308(%rbx), %rax
movq 0x338(%rbx), %rcx
movsd (%rax,%r15,8), %xmm1
movq 0x350(%rbx), %rax
movsd (%rax,%r15,8), %xmm3
mulsd %xmm1, %xmm3
divsd %xmm2, %xmm3
addsd 0x138(%rsp), %xmm3
movsd (%rcx,%r15,8), %xmm2
callq 0xff71
movq 0x320(%rbx), %rax
movq 0x368(%rbx), %rcx
movsd (%rax,%r15,8), %xmm1
movsd %xmm1, 0x28(%rsp)
addsd (%rcx,%r15,8), %xmm0
callq 0x6790
movsd %xmm0, 0x20(%rsp)
movq 0x338(%rbx), %rax
movq 0x368(%rbx), %rcx
movsd (%rax,%r15,8), %xmm0
movsd %xmm0, 0x18(%rsp)
movsd (%rcx,%r15,8), %xmm0
callq 0x6790
movsd 0x2f7ec(%rip), %xmm2    # 0x3f6c0
mulsd 0x18(%rsp), %xmm0
addsd 0x20(%rsp), %xmm0
mulsd 0x28(%rsp), %xmm0
movsd %xmm0, 0x30(%rsp)
movq 0x380(%rbx), %rax
fldt (%rax,%r12)
faddl 0x30(%rsp)
fstpt (%rax,%r12)
incq %r13
movq (%rsp), %rax
movq 0x8(%rsp), %rcx
subq %rax, %rcx
sarq $0x3, %rcx
addq $0x10, %r12
cmpq %rcx, %r13
jb 0xfe39
incq %r15
cmpq %r14, %r15
jne 0xfe24
movq (%rsp), %rdi
testq %rdi, %rdi
je 0xff41
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x6460
leaq 0x38(%rsp), %rdi
callq 0xb832
addq $0x140, %rsp            # imm = 0x140
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0xb832
movq %rbx, %rdi
callq 0x6710
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/RVmodel.cpp
// Function: kepler::true_anomaly(double, double, double, double)
double true_anomaly(double t, double period, double ecc, double t_peri)
    {
        double n = 2.*M_PI/period;  // mean motion
        double M = n*(t - t_peri);  // mean anomaly

        // Solve Kepler's equation
        double E = kepler(M, ecc);

        // Calculate true anomaly
        double cosE = cos(E);
        double f = acos( (cosE - ecc)/( 1 - ecc*cosE ) );
        // acos gives the principal values ie [0:PI]
        // when E goes above PI we need another condition
        if(E > M_PI)
            f = 2*M_PI - f;

        return f;

    }

// Assembly:
subq $0x18, %rsp
movaps %xmm2, %xmm4
movsd %xmm2, 0x8(%rsp)
movsd 0x2f1ca(%rip), %xmm2    # 0x3f150
divsd %xmm1, %xmm2
subsd %xmm3, %xmm0
mulsd %xmm2, %xmm0
movaps %xmm4, %xmm1
callq 0x1530b
movsd %xmm0, 0x10(%rsp)
callq 0x6790
movapd %xmm0, %xmm1
movsd 0x8(%rsp), %xmm2
subsd %xmm2, %xmm1
mulsd %xmm0, %xmm2
movsd 0x2f071(%rip), %xmm0    # 0x3f030
subsd %xmm2, %xmm0
divsd %xmm0, %xmm1
movapd %xmm1, %xmm0
callq 0x6420
movsd 0x2f178(%rip), %xmm3    # 0x3f150
subsd %xmm0, %xmm3
movsd 0x2f6d4(%rip), %xmm1    # 0x3f6b8
cmpltsd 0x10(%rsp), %xmm1
movapd %xmm1, %xmm2
andnpd %xmm0, %xmm2
andpd %xmm3, %xmm1
orpd %xmm2, %xmm1
movapd %xmm1, %xmm0
addq $0x18, %rsp
retq
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/RVmodel.cpp
// Function: RVmodel::remove_known_object()
void RVmodel::remove_known_object()
{
    auto data = Data::get_instance();
    auto t = data.get_t();
    double f, v, ti, Tp;
    // cout << "in remove_known_obj: " << KO_P[1] << endl;
    for(int j=0; j<n_known_object; j++)
    {
        for(size_t i=0; i<t.size(); i++)
        {
            ti = t[i];
            Tp = data.M0_epoch-(KO_P[j]*KO_phi[j])/(2.*M_PI);
            f = kepler::true_anomaly(ti, KO_P[j], KO_e[j], Tp);
            v = KO_K[j] * (cos(f+KO_w[j]) + KO_e[j]*cos(KO_w[j]));
            mu[i] -= v;
        }
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x140, %rsp            # imm = 0x140
movq %rdi, %rbx
leaq 0x433e2(%rip), %rsi     # 0x53400
leaq 0x38(%rsp), %r14
movq %r14, %rdi
callq 0x1560c
movq %rsp, %rdi
movq %r14, %rsi
callq 0xc1e6
leaq 0x3534f(%rip), %rax     # 0x4538c
movslq (%rax), %r14
testq %r14, %r14
jle 0x1015b
xorl %r15d, %r15d
movsd 0x2f66c(%rip), %xmm2    # 0x3f6c0
movq (%rsp), %rax
cmpq %rax, 0x8(%rsp)
je 0x1014f
xorl %r12d, %r12d
xorl %r13d, %r13d
movsd (%rax,%r13,8), %xmm0
movq 0x308(%rbx), %rax
movq 0x338(%rbx), %rcx
movsd (%rax,%r15,8), %xmm1
movq 0x350(%rbx), %rax
movsd (%rax,%r15,8), %xmm3
mulsd %xmm1, %xmm3
divsd %xmm2, %xmm3
addsd 0x138(%rsp), %xmm3
movsd (%rcx,%r15,8), %xmm2
callq 0xff71
movq 0x320(%rbx), %rax
movq 0x368(%rbx), %rcx
movsd (%rax,%r15,8), %xmm1
movsd %xmm1, 0x28(%rsp)
addsd (%rcx,%r15,8), %xmm0
callq 0x6790
movsd %xmm0, 0x20(%rsp)
movq 0x338(%rbx), %rax
movq 0x368(%rbx), %rcx
movsd (%rax,%r15,8), %xmm0
movsd %xmm0, 0x18(%rsp)
movsd (%rcx,%r15,8), %xmm0
callq 0x6790
movsd 0x2f5bc(%rip), %xmm2    # 0x3f6c0
mulsd 0x18(%rsp), %xmm0
addsd 0x20(%rsp), %xmm0
mulsd 0x28(%rsp), %xmm0
movsd %xmm0, 0x30(%rsp)
movq 0x380(%rbx), %rax
fldt (%rax,%r12)
fsubl 0x30(%rsp)
fstpt (%rax,%r12)
incq %r13
movq (%rsp), %rax
movq 0x8(%rsp), %rcx
subq %rax, %rcx
sarq $0x3, %rcx
addq $0x10, %r12
cmpq %rcx, %r13
jb 0x10069
incq %r15
cmpq %r14, %r15
jne 0x10054
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x10171
movq 0x10(%rsp), %rsi
subq %rdi, %rsi
callq 0x6460
leaq 0x38(%rsp), %rdi
callq 0xb832
addq $0x140, %rsp            # imm = 0x140
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0xb832
movq %rbx, %rdi
callq 0x6710
nop
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/RVmodel.cpp
// Function: murison::kepler(double, double)
double kepler(double M, double ecc)
    {
        double tol;
        if (ecc < 0.8) tol = 1e-14;
        else tol = 1e-13;

        double Mnorm = fmod(M, 2.*M_PI);
        double E0 = keplerstart3(ecc, Mnorm);
        double dE = tol + 1;
        double E = M;
        int count = 0;
        while (dE > tol)
        {
            E = E0 - eps3(ecc, Mnorm, E0);
            dE = abs(E-E0);
            E0 = E;
            count++;
            // failed to converge, this only happens for nearly parabolic orbits
            if (count == 100) break;
        }
        return E;

    }

// Assembly:
pushq %rbx
subq $0x40, %rsp
movsd %xmm0, 0x20(%rsp)
movsd 0x2a938(%rip), %xmm2    # 0x3f6f0
xorl %eax, %eax
movsd %xmm1, 0x18(%rsp)
ucomisd %xmm1, %xmm2
seta %al
leaq 0x2a982(%rip), %rcx     # 0x3f750
movsd (%rcx,%rax,8), %xmm1
movsd %xmm1, 0x28(%rsp)
movsd 0x2a36f(%rip), %xmm1    # 0x3f150
callq 0x6530
movsd %xmm0, 0x10(%rsp)
callq 0x6790
movsd %xmm0, 0x8(%rsp)
movsd 0x10(%rsp), %xmm0
callq 0x60b0
movsd 0x2a226(%rip), %xmm1    # 0x3f030
movsd 0x28(%rsp), %xmm2
addsd %xmm2, %xmm1
ucomisd %xmm2, %xmm1
movsd 0x20(%rsp), %xmm1
jbe 0x14f61
movsd 0x2a8cc(%rip), %xmm4    # 0x3f6f8
movsd 0x8(%rsp), %xmm5
mulsd %xmm5, %xmm4
movsd 0x18(%rsp), %xmm3
movapd %xmm3, %xmm1
mulsd %xmm3, %xmm1
movapd %xmm1, %xmm2
mulsd %xmm3, %xmm2
mulsd %xmm2, %xmm4
mulsd 0x2a1e0(%rip), %xmm2    # 0x3f038
addsd %xmm1, %xmm4
addsd %xmm3, %xmm2
mulsd %xmm5, %xmm4
addsd %xmm2, %xmm4
mulsd %xmm0, %xmm4
addsd 0x10(%rsp), %xmm4
movl $0x64, %ebx
movapd %xmm4, %xmm1
movsd %xmm4, 0x8(%rsp)
movsd %xmm1, 0x20(%rsp)
movapd %xmm4, %xmm0
callq 0x6790
movsd %xmm0, 0x38(%rsp)
movsd 0x18(%rsp), %xmm2
mulsd %xmm0, %xmm2
addsd 0x2a858(%rip), %xmm2    # 0x3f700
movsd %xmm2, 0x30(%rsp)
movsd 0x8(%rsp), %xmm0
callq 0x60b0
movsd 0x8(%rsp), %xmm4
movapd %xmm0, %xmm1
movsd 0x18(%rsp), %xmm7
mulsd %xmm7, %xmm1
movapd %xmm1, %xmm2
subsd %xmm4, %xmm2
addsd 0x10(%rsp), %xmm2
movapd %xmm2, %xmm3
movsd 0x2a2b1(%rip), %xmm5    # 0x3f198
mulsd %xmm5, %xmm3
mulsd %xmm1, %xmm3
movsd 0x30(%rsp), %xmm1
divsd %xmm1, %xmm3
addsd %xmm1, %xmm3
movapd %xmm1, %xmm6
movapd %xmm2, %xmm1
divsd %xmm3, %xmm1
movsd 0x38(%rsp), %xmm3
mulsd 0x2a7c9(%rip), %xmm3    # 0x3f6e0
mulsd %xmm1, %xmm3
mulsd %xmm5, %xmm0
addsd %xmm3, %xmm0
mulsd %xmm7, %xmm0
mulsd %xmm1, %xmm0
movsd 0x20(%rsp), %xmm1
addsd %xmm6, %xmm0
divsd %xmm0, %xmm2
subsd %xmm2, %xmm1
decl %ebx
je 0x14f61
movapd %xmm1, %xmm0
subsd %xmm4, %xmm0
andpd 0x2a20f(%rip), %xmm0    # 0x3f160
ucomisd 0x28(%rsp), %xmm0
movapd %xmm1, %xmm4
ja 0x14e7b
movapd %xmm1, %xmm0
addq $0x40, %rsp
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/src/RVmodel.cpp
// Function: murison::keplerstart3(double, double)
double keplerstart3(double e, double M)
    {
        double t34 = e*e;
        double t35 = e*t34;
        double t33 = cos(M);
        return M + (-0.5*t35 + e + (t34 + 1.5*t33*t35)*t33)*sin(M);
    }

// Assembly:
subq $0x28, %rsp
movsd %xmm1, 0x10(%rsp)
movapd %xmm0, %xmm2
movsd %xmm0, 0x20(%rsp)
mulsd %xmm0, %xmm0
movsd %xmm0, 0x8(%rsp)
mulsd %xmm2, %xmm0
movsd %xmm0, 0x18(%rsp)
movapd %xmm1, %xmm0
callq 0x6790
movsd 0x2a094(%rip), %xmm2    # 0x3f038
movsd 0x18(%rsp), %xmm3
mulsd %xmm3, %xmm2
addsd 0x20(%rsp), %xmm2
movsd 0x2a73c(%rip), %xmm1    # 0x3f6f8
mulsd %xmm0, %xmm1
mulsd %xmm3, %xmm1
addsd 0x8(%rsp), %xmm1
mulsd %xmm1, %xmm0
addsd %xmm2, %xmm0
movsd %xmm0, 0x8(%rsp)
movsd 0x10(%rsp), %xmm0
callq 0x60b0
mulsd 0x8(%rsp), %xmm0
addsd 0x10(%rsp), %xmm0
addq $0x28, %rsp
retq