// File: /workspace/github_cpp_makefile_star2_O1/j-faria[P]kima/DNest4/code/Options.cpp
// Function: DNest4::Options::load(char const*)
void Options::load(const char* filename)
{
	std::fstream fin(filename, std::ios::in);
	if(!fin)
	{
		std::cerr<<"ERROR: Cannot open file "<<filename<<"."<<std::endl;
		exit(0);
	}

	// Read past comment lines at the top of the file
	while(fin.peek() == '#')
		fin.ignore(1000000, '\n');

	fin>>num_particles;	fin.ignore(1000000, '\n');
	fin>>new_level_interval;	fin.ignore(1000000, '\n');
	fin>>save_interval;	fin.ignore(1000000, '\n');
	fin>>thread_steps;	fin.ignore(1000000, '\n');
	fin>>max_num_levels;	fin.ignore(1000000, '\n');
	fin>>lambda;		fin.ignore(1000000, '\n');
	fin>>beta;		fin.ignore(1000000, '\n');
	fin>>max_num_saves;		fin.ignore(1000000, '\n');
	fin>>sample_file;		fin.ignore(1000000, '\n');
	fin>>sample_info_file;	fin.ignore(1000000, '\n');
	fin>>levels_file;

	if (sample_file.compare("#") == 0) sample_file = "sample.txt";
	if (sample_info_file.compare("#") == 0) sample_info_file = "sample_info.txt";
	if (levels_file.compare("#") == 0) levels_file = "levels.txt";

	fin.close();

	assert(num_particles > 0 && new_level_interval > 0 &&
			thread_steps > 0 && max_num_levels > 0 && lambda > 0. &&
			beta >= 0.);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x218, %rsp            # imm = 0x218
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x8(%rsp), %r15
movq %r15, %rdi
movl $0x8, %edx
callq 0x6550
movq (%r15), %rax
movq -0x18(%rax), %rax
testb $0x5, 0x28(%rsp,%rax)
jne 0x3bbd4
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x6150
cmpl $0x23, %eax
jne 0x3b97c
movl $0xf4240, %esi          # imm = 0xF4240
movq %r14, %rdi
movl $0xa, %edx
callq 0x6290
jmp 0x3b95b
leaq 0x8(%rsp), %rdi
movq %rbx, %rsi
callq 0x6700
leaq 0x8(%rsp), %rdi
movl $0xf4240, %esi          # imm = 0xF4240
movl $0xa, %edx
callq 0x6290
leaq 0x4(%rbx), %rsi
leaq 0x8(%rsp), %rdi
callq 0x6700
leaq 0x8(%rsp), %rdi
movl $0xf4240, %esi          # imm = 0xF4240
movl $0xa, %edx
callq 0x6290
leaq 0x8(%rbx), %rsi
leaq 0x8(%rsp), %rdi
callq 0x6700
leaq 0x8(%rsp), %rdi
movl $0xf4240, %esi          # imm = 0xF4240
movl $0xa, %edx
callq 0x6290
leaq 0xc(%rbx), %rsi
leaq 0x8(%rsp), %rdi
callq 0x6700
leaq 0x8(%rsp), %rdi
movl $0xf4240, %esi          # imm = 0xF4240
movl $0xa, %edx
callq 0x6290
leaq 0x10(%rbx), %rsi
leaq 0x8(%rsp), %rdi
callq 0x6700
leaq 0x8(%rsp), %rdi
movl $0xf4240, %esi          # imm = 0xF4240
movl $0xa, %edx
callq 0x6290
leaq 0x18(%rbx), %rsi
leaq 0x8(%rsp), %rdi
callq 0x62c0
leaq 0x8(%rsp), %rdi
movl $0xf4240, %esi          # imm = 0xF4240
movl $0xa, %edx
callq 0x6290
leaq 0x20(%rbx), %rsi
leaq 0x8(%rsp), %rdi
callq 0x62c0
leaq 0x8(%rsp), %rdi
movl $0xf4240, %esi          # imm = 0xF4240
movl $0xa, %edx
callq 0x6290
leaq 0x28(%rbx), %rsi
leaq 0x8(%rsp), %rdi
callq 0x6700
leaq 0x8(%rsp), %rdi
movl $0xf4240, %esi          # imm = 0xF4240
movl $0xa, %edx
callq 0x6290
leaq 0x30(%rbx), %r12
leaq 0x8(%rsp), %rdi
movq %r12, %rsi
callq 0x6510
leaq 0x8(%rsp), %rdi
movl $0xf4240, %esi          # imm = 0xF4240
movl $0xa, %edx
callq 0x6290
leaq 0x50(%rbx), %r15
leaq 0x8(%rsp), %rdi
movq %r15, %rsi
callq 0x6510
leaq 0x8(%rsp), %rdi
movl $0xf4240, %esi          # imm = 0xF4240
movl $0xa, %edx
callq 0x6290
leaq 0x70(%rbx), %r14
leaq 0x8(%rsp), %rdi
movq %r14, %rsi
callq 0x6510
leaq 0xc1b7(%rip), %rsi      # 0x47ca4
movq %r12, %rdi
callq 0x6100
testl %eax, %eax
jne 0x3bb14
movq 0x38(%rbx), %rdx
leaq 0xc079(%rip), %rcx      # 0x47b7d
movl $0xa, %r8d
movq %r12, %rdi
xorl %esi, %esi
callq 0x6600
leaq 0xc189(%rip), %rsi      # 0x47ca4
movq %r15, %rdi
callq 0x6100
testl %eax, %eax
jne 0x3bb42
movq 0x58(%rbx), %rdx
leaq 0xc056(%rip), %rcx      # 0x47b88
movl $0xf, %r8d
movq %r15, %rdi
xorl %esi, %esi
callq 0x6600
leaq 0xc15b(%rip), %rsi      # 0x47ca4
movq %r14, %rdi
callq 0x6100
testl %eax, %eax
jne 0x3bb70
movq 0x78(%rbx), %rdx
leaq 0xc038(%rip), %rcx      # 0x47b98
movl $0xa, %r8d
movq %r14, %rdi
xorl %esi, %esi
callq 0x6600
leaq 0x8(%rsp), %rdi
callq 0x6060
cmpl $0x0, (%rbx)
je 0x3bc21
cmpl $0x0, 0x4(%rbx)
je 0x3bc21
cmpl $0x0, 0xc(%rbx)
je 0x3bc21
cmpl $0x0, 0x10(%rbx)
je 0x3bc21
movsd 0x18(%rbx), %xmm1
xorpd %xmm0, %xmm0
ucomisd %xmm0, %xmm1
jbe 0x3bc21
movsd 0x20(%rbx), %xmm1
ucomisd %xmm0, %xmm1
jb 0x3bc21
leaq 0x8(%rsp), %rdi
callq 0x60c0
addq $0x218, %rsp            # imm = 0x218
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq 0x1740d(%rip), %rdi     # 0x52fe8
leaq 0xc0a9(%rip), %rsi      # 0x47c8b
movl $0x18, %edx
callq 0x64a0
movq 0x173f5(%rip), %rdi     # 0x52fe8
movq %r14, %rsi
callq 0x6440
movq %rax, %rbx
leaq 0xc26a(%rip), %rsi      # 0x47e6f
movl $0x1, %edx
movq %rax, %rdi
callq 0x64a0
movq %rbx, %rdi
callq 0x61c0
xorl %edi, %edi
callq 0x64e0
leaq 0xc07e(%rip), %rdi      # 0x47ca6
leaq 0xbfd3(%rip), %rsi      # 0x47c02
leaq 0xc0e3(%rip), %rcx      # 0x47d19
movl $0x4c, %edx
callq 0x62b0
jmp 0x3bc42
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x60c0
movq %rbx, %rdi
callq 0x6710
nop