// File: /workspace/github_cpp_makefile_star2_O3/istellartech[P]OpenTsiolkovsky/src/main.cpp
// Function: main
int main(int argc, const char * argv[]) {
    std::chrono::system_clock::time_point  start, end; // calcuration time measurement
    start = std::chrono::system_clock::now(); // mesurement start time
    
    std::cout << "Hello, OpenTsiolkovsky! version:" + current_version + "\n";

    string input_file_name;
    string input_file_default = "param_sample.json";
    if (argc == 1) {
        input_file_name = input_file_default;
    } else if (argc == 2) {
        input_file_name = argv[1];
    } else {
        cout << "argument error";
        return 1;
    }

    Rocket rocket(input_file_name);
    rocket.flight_simulation();
    
    end = std::chrono::system_clock::now();  // mesurement end time
    double elapsed = std::chrono::duration_cast<std::chrono::milliseconds>(end-start).count();
    std::cout << "Processing time: " << elapsed << "[ms]\n" << std::endl;
    
    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rsi, %r14
movl %edi, %ebp
callq 0x5080
movq %rax, %rbx
leaq 0x1ea0f(%rip), %rsi     # 0x25830
leaq 0x2b598(%rip), %rdx     # 0x323c0
leaq 0x8(%rsp), %r15
movq %r15, %rdi
callq 0x7154
leaq 0x1fbcd(%rip), %rsi     # 0x26a09
movq %r15, %rdi
callq 0x56a0
leaq 0x38(%rsp), %r15
movq %r15, -0x10(%r15)
movq (%rax), %rsi
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rsi
je 0x6e6b
movq %rsi, 0x28(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x38(%rsp)
jmp 0x6e77
movupd (%rcx), %xmm0
movupd %xmm0, (%r15)
movq %r15, %rsi
movq 0x8(%rax), %rdx
movq %rdx, 0x30(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq 0x2b11a(%rip), %rdi     # 0x31fb0
callq 0x5430
movq 0x28(%rsp), %rdi
cmpq %r15, %rdi
je 0x6eb2
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x53b0
leaq 0x18(%rsp), %r13
movq -0x10(%r13), %rdi
cmpq %r13, %rdi
je 0x6ecd
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x53b0
movq %r13, 0x8(%rsp)
movq $0x0, 0x10(%rsp)
movb $0x0, 0x18(%rsp)
leaq 0x88(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x1e95e(%rip), %rsi     # 0x25851
leaq 0x1e968(%rip), %rdx     # 0x25862
leaq 0x78(%rsp), %rdi
callq 0x76ba
cmpl $0x2, %ebp
je 0x6f23
cmpl $0x1, %ebp
jne 0x7049
leaq 0x8(%rsp), %rdi
leaq 0x78(%rsp), %rsi
callq 0x5220
jmp 0x6f51
movq 0x8(%r14), %r14
movq %r15, %rbp
leaq 0x8(%rsp), %r15
movq 0x8(%r15), %r12
movq %r14, %rdi
callq 0x51a0
movq %r15, %rdi
movq %rbp, %r15
xorl %esi, %esi
movq %r12, %rdx
movq %r14, %rcx
movq %rax, %r8
callq 0x5540
leaq 0x68(%rsp), %r14
movq %r14, -0x10(%r14)
movq 0x8(%rsp), %rsi
movq 0x10(%rsp), %rdx
addq %rsi, %rdx
leaq 0x58(%rsp), %rdi
callq 0x7624
leaq 0x28(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0x7d60
movq 0x58(%rsp), %rdi
cmpq %r14, %rdi
je 0x6f97
movq 0x68(%rsp), %rsi
incq %rsi
callq 0x53b0
leaq 0x28(%rsp), %rdi
callq 0xe7f6
callq 0x5080
movq %rax, %r14
movq 0x2b000(%rip), %rdi     # 0x31fb0
leaq 0x1e8bb(%rip), %rsi     # 0x25872
movl $0x11, %edx
callq 0x5430
subq %rbx, %r14
movabsq $0x431bde82d7b634db, %rcx # imm = 0x431BDE82D7B634DB
movq %r14, %rax
imulq %rcx
movq %rdx, %rax
shrq $0x3f, %rax
sarq $0x12, %rdx
addq %rax, %rdx
cvtsi2sd %rdx, %xmm0
movq 0x2afc2(%rip), %rdi     # 0x31fb0
callq 0x5570
movq %rax, %rbx
leaq 0x1e887(%rip), %rsi     # 0x25884
movl $0x5, %edx
movq %rax, %rdi
callq 0x5430
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x5370
movsbl %al, %esi
movq %rbx, %rdi
callq 0x5050
movq %rax, %rdi
callq 0x5270
leaq 0x40(%rsp), %rdi
callq 0x7238
leaq 0x28(%rsp), %rdi
callq 0x7238
xorl %ebx, %ebx
jmp 0x7066
movl $0x1, %ebx
movq 0x2af5b(%rip), %rdi     # 0x31fb0
leaq 0x1e807(%rip), %rsi     # 0x25863
movl $0xe, %edx
callq 0x5430
movq 0x78(%rsp), %rdi
cmpq %r15, %rdi
je 0x7080
movq 0x88(%rsp), %rsi
incq %rsi
callq 0x53b0
movq 0x8(%rsp), %rdi
cmpq %r13, %rdi
je 0x7097
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x53b0
movl %ebx, %eax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x7104
movq %rax, %rbx
movq 0x58(%rsp), %rdi
cmpq %r14, %rdi
je 0x711b
movq 0x68(%rsp), %rsi
incq %rsi
callq 0x53b0
jmp 0x711b
jmp 0x70cb
movq %rax, %rbx
jmp 0x711b
movq %rax, %rbx
jmp 0x7135
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %r15, %rdi
je 0x70f4
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x53b0
jmp 0x70f4
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
jne 0x713f
jmp 0x714c
movq %rax, %rbx
leaq 0x40(%rsp), %rdi
callq 0x7238
leaq 0x28(%rsp), %rdi
callq 0x7238
movq 0x78(%rsp), %rdi
cmpq %r15, %rdi
je 0x7135
movq 0x88(%rsp), %rsi
incq %rsi
callq 0x53b0
movq 0x8(%rsp), %rdi
cmpq %r13, %rdi
je 0x714c
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x53b0
movq %rbx, %rdi
callq 0x5650