// File: chfeder[P]turbulence_generator/./TurbGen.h
// Function: TurbGen::check_for_update(double, double const*)
bool check_for_update(const double time, const double v_turb[]) {
        // ******************************************************
        // Update driving pattern based on input 'time'.
        // If it is 'time' to update the pattern, call OU noise update
        // and update the decomposition coefficients; otherwise, simply return.
        // ******************************************************
        if (verbose > 1) TurbGen_printf(FuncSig(__func__)+"entering.\n");
        // check if we need to update the OU pattern
        int step_requested = floor(time / dt); // requested OU step number based on input 'time'
        if (verbose > 1) TurbGen_printf("step_requested = %i\n", step_requested);
        if (step_requested <= step) {
            if (verbose > 1) TurbGen_printf("no update of pattern...returning.\n");
            if (verbose > 1) TurbGen_printf(FuncSig(__func__)+"exiting.\n");
            return false; // no update (yet) -> return false, i.e., no change of driving pattern
        }
        // check to see if we do automatic adjustment of the driving amplitude to reach user-defined target turbulent velocity dispersion
        if ((ampl_auto_adjust == 1) && (v_turb[X] > 0)) {
            double v_turb_for_ampl_adjust[3];
            // copy v_turb into v_turb_for_ampl_adjust (default, if we do not use time_averaging)
            for (int d = 0; d < ncmp; d++) v_turb_for_ampl_adjust[d] = v_turb[d]; // current v_turb
            // if the time is right, adjust the amplitude
            if (time > 0.1*t_decay) { // auto-adjustment start time (start at t > 0.1 turnover times; could start later)
                double ampl_factor_adjusted[3];
                double ampl_adjust_timescale[3];
                for (int d = 0; d < ncmp; d++) {
                    // ampl_factor_new would be the perfect match at this moment (based on target velocity and current v_turb)
                    double ampl_factor_new = ampl_factor[d] * pow(velocity / v_turb_for_ampl_adjust[d] / sqrt(ncmp), 1.5);
                    // approach ampl_factor_new based on timecale 'ampl_adjust_timescale' to avoid strong over- and under-shooting
                    ampl_adjust_timescale[d] = pow(ampl_factor_new/ampl_factor[d], 0.5) * t_decay; // experimental
                    double damping_factor = exp(-dt/ampl_adjust_timescale[d]);
                    ampl_factor_adjusted[d] = ampl_factor[d] * damping_factor + (1.0-damping_factor) * ampl_factor_new;
                }
                TurbGen_printf(" ===> auto-adjusting driving amplitude: ampl_factor (auto-adjusted) =");
                for (int d = 0; d < ncmp; d++) TurbGen_printf_raw(" %f", pow(ampl_factor_adjusted[d], 1.0/1.5));
                TurbGen_printf_raw("\n");
                TurbGen_printf(" ===> amplitude adjustment timescale (in units of t_turb) =");
                for (int d = 0; d < ncmp; d++) TurbGen_printf_raw(" %f", ampl_adjust_timescale[d]/t_decay);
                TurbGen_printf_raw("\n");
                for (int d = 0; d < ncmp; d++) ampl_factor[d] = ampl_factor_adjusted[d]; // set new (adjusted) ampl_factor
            }
        } // if (auto_adjust_amplitude)
        // if we are here: update OU vector
        for (int is = step; is < step_requested; is++) {
            OU_noise_update(); // this seeks to the requested OU state (updates OUphases)
            step++; // update internal OU step number
            if (verbose > 1) TurbGen_printf("step = %i, time = %f\n", step, step*dt);
        }
        get_decomposition_coeffs(); // calculate solenoidal and compressive coefficients (aka, akb) from OUphases
        double time_gen = step * dt;
        if (verbose) TurbGen_printf("Generated new turbulence driving pattern: #%6i, time = %e, time/t_turb = %-7.2f\n", step, time_gen, time_gen/t_decay);
        if (PE == 0) write_to_evol_file(time, ampl_factor, v_turb); // write evolution file
        if (verbose > 1) TurbGen_printf(FuncSig(__func__)+"exiting.\n");
        return true; // we just updated the driving pattern
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x400, %rsp            # imm = 0x400
movq %rdi, -0x10(%rbp)
movsd %xmm0, -0x18(%rbp)
movq %rsi, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x388(%rbp)
cmpl $0x1, (%rax)
jle 0x115cb
leaq -0x81(%rbp), %rdi
movq %rdi, -0x390(%rbp)
callq 0x3560
movq -0x390(%rbp), %rdx
leaq 0x4b4c(%rip), %rsi      # 0x16029
leaq -0x80(%rbp), %rdi
callq 0x4620
jmp 0x114e8
movq -0x388(%rbp), %rsi
leaq -0x60(%rbp), %rdi
leaq -0x80(%rbp), %rdx
callq 0x9b50
jmp 0x114fe
leaq 0x3f56(%rip), %rdx      # 0x1545b
leaq -0x40(%rbp), %rdi
leaq -0x60(%rbp), %rsi
callq 0x9b00
jmp 0x11514
movq -0x388(%rbp), %rdi
xorl %eax, %eax
leaq -0x40(%rbp), %rsi
callq 0x99f0
jmp 0x11528
leaq -0x40(%rbp), %rdi
callq 0x31e0
leaq -0x60(%rbp), %rdi
callq 0x31e0
leaq -0x80(%rbp), %rdi
callq 0x31e0
leaq -0x81(%rbp), %rdi
callq 0x3350
jmp 0x115cb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x115ba
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x115b1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x115a8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x40(%rbp), %rdi
callq 0x31e0
leaq -0x60(%rbp), %rdi
callq 0x31e0
leaq -0x80(%rbp), %rdi
callq 0x31e0
leaq -0x81(%rbp), %rdi
callq 0x3350
jmp 0x1234c
movq -0x388(%rbp), %rax
movsd -0x18(%rbp), %xmm0
divsd 0x1a0(%rax), %xmm0
callq 0x3510
movq -0x388(%rbp), %rax
cvttsd2si %xmm0, %ecx
movl %ecx, -0x98(%rbp)
cmpl $0x1, (%rax)
jle 0x116a7
leaq -0xb9(%rbp), %rdi
movq %rdi, -0x398(%rbp)
callq 0x3560
movq -0x398(%rbp), %rdx
leaq 0x4a1b(%rip), %rsi      # 0x1603a
leaq -0xb8(%rbp), %rdi
callq 0x4620
jmp 0x1162d
movq -0x388(%rbp), %rdi
movl -0x98(%rbp), %edx
xorl %eax, %eax
leaq -0xb8(%rbp), %rsi
callq 0x99f0
jmp 0x1164a
leaq -0xb8(%rbp), %rdi
callq 0x31e0
leaq -0xb9(%rbp), %rdi
callq 0x3350
jmp 0x116a7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x11696
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0xb8(%rbp), %rdi
callq 0x31e0
leaq -0xb9(%rbp), %rdi
callq 0x3350
jmp 0x1234c
movq -0x388(%rbp), %rcx
movl -0x98(%rbp), %eax
cmpl 0x174(%rcx), %eax
jg 0x118c2
movq -0x388(%rbp), %rax
cmpl $0x1, (%rax)
jle 0x11773
leaq -0xe1(%rbp), %rdi
movq %rdi, -0x3a0(%rbp)
callq 0x3560
movq -0x3a0(%rbp), %rdx
leaq 0x495e(%rip), %rsi      # 0x1604f
leaq -0xe0(%rbp), %rdi
callq 0x4620
jmp 0x116ff
movq -0x388(%rbp), %rdi
xorl %eax, %eax
leaq -0xe0(%rbp), %rsi
callq 0x99f0
jmp 0x11716
leaq -0xe0(%rbp), %rdi
callq 0x31e0
leaq -0xe1(%rbp), %rdi
callq 0x3350
jmp 0x11773
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x11762
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0xe0(%rbp), %rdi
callq 0x31e0
leaq -0xe1(%rbp), %rdi
callq 0x3350
jmp 0x1234c
movq -0x388(%rbp), %rax
cmpl $0x1, (%rax)
jle 0x118b9
leaq -0x149(%rbp), %rdi
movq %rdi, -0x3a8(%rbp)
callq 0x3560
movq -0x3a8(%rbp), %rdx
leaq 0x4885(%rip), %rsi      # 0x16029
leaq -0x148(%rbp), %rdi
callq 0x4620
jmp 0x117b2
movq -0x388(%rbp), %rsi
leaq -0x128(%rbp), %rdi
leaq -0x148(%rbp), %rdx
callq 0x9b50
jmp 0x117ce
leaq 0x3e54(%rip), %rdx      # 0x15629
leaq -0x108(%rbp), %rdi
leaq -0x128(%rbp), %rsi
callq 0x9b00
jmp 0x117ea
movq -0x388(%rbp), %rdi
xorl %eax, %eax
leaq -0x108(%rbp), %rsi
callq 0x99f0
jmp 0x11801
leaq -0x108(%rbp), %rdi
callq 0x31e0
leaq -0x128(%rbp), %rdi
callq 0x31e0
leaq -0x148(%rbp), %rdi
callq 0x31e0
leaq -0x149(%rbp), %rdi
callq 0x3350
jmp 0x118b9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x118a8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x1189c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x11890
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x108(%rbp), %rdi
callq 0x31e0
leaq -0x128(%rbp), %rdi
callq 0x31e0
leaq -0x148(%rbp), %rdi
callq 0x31e0
leaq -0x149(%rbp), %rdi
callq 0x3350
jmp 0x1234c
movb $0x0, -0x1(%rbp)
jmp 0x1233e
movq -0x388(%rbp), %rax
cmpl $0x1, 0x210(%rax)
jne 0x11fb5
movq -0x20(%rbp), %rax
movsd (%rax), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jbe 0x11fb5
movl $0x0, -0x174(%rbp)
movq -0x388(%rbp), %rcx
movl -0x174(%rbp), %eax
cmpl 0x160(%rcx), %eax
jge 0x1193b
movq -0x20(%rbp), %rax
movslq -0x174(%rbp), %rcx
movsd (%rax,%rcx,8), %xmm0
movslq -0x174(%rbp), %rax
movsd %xmm0, -0x170(%rbp,%rax,8)
movl -0x174(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x174(%rbp)
jmp 0x118f5
movq -0x388(%rbp), %rax
movsd -0x18(%rbp), %xmm0
movsd 0x3769(%rip), %xmm1     # 0x150b8
mulsd 0x198(%rax), %xmm1
ucomisd %xmm1, %xmm0
jbe 0x11fb3
movl $0x0, -0x1b4(%rbp)
movq -0x388(%rbp), %rcx
movl -0x1b4(%rbp), %eax
cmpl 0x160(%rcx), %eax
jge 0x11aed
movq -0x388(%rbp), %rax
movslq -0x1b4(%rbp), %rcx
movsd 0x1f8(%rax,%rcx,8), %xmm0
movsd %xmm0, -0x3b0(%rbp)
movsd 0x190(%rax), %xmm0
movslq -0x1b4(%rbp), %rcx
divsd -0x170(%rbp,%rcx,8), %xmm0
movsd %xmm0, -0x3b8(%rbp)
cvtsi2sdl 0x160(%rax), %xmm0
callq 0x3250
movaps %xmm0, %xmm1
movsd -0x3b8(%rbp), %xmm0
divsd %xmm1, %xmm0
movsd 0x3681(%rip), %xmm1     # 0x15068
callq 0x3540
movq -0x388(%rbp), %rax
movaps %xmm0, %xmm1
movsd -0x3b0(%rbp), %xmm0
mulsd %xmm1, %xmm0
movsd %xmm0, -0x1c0(%rbp)
movsd -0x1c0(%rbp), %xmm0
movslq -0x1b4(%rbp), %rcx
divsd 0x1f8(%rax,%rcx,8), %xmm0
movsd 0x35e6(%rip), %xmm1     # 0x15010
callq 0x3540
movq -0x388(%rbp), %rax
mulsd 0x198(%rax), %xmm0
movslq -0x1b4(%rbp), %rcx
movsd %xmm0, -0x1b0(%rbp,%rcx,8)
movsd 0x1a0(%rax), %xmm0
movq %xmm0, %rax
movabsq $-0x8000000000000000, %rcx # imm = 0x8000000000000000
xorq %rcx, %rax
movq %rax, %xmm0
movslq -0x1b4(%rbp), %rax
divsd -0x1b0(%rbp,%rax,8), %xmm0
callq 0x3570
movq -0x388(%rbp), %rax
movsd %xmm0, -0x1c8(%rbp)
movslq -0x1b4(%rbp), %rcx
movsd 0x1f8(%rax,%rcx,8), %xmm0
movsd -0x1c8(%rbp), %xmm2
movsd 0x3567(%rip), %xmm1     # 0x15018
subsd -0x1c8(%rbp), %xmm1
mulsd -0x1c0(%rbp), %xmm1
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movslq -0x1b4(%rbp), %rax
movsd %xmm0, -0x190(%rbp,%rax,8)
movl -0x1b4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1b4(%rbp)
jmp 0x1196b
leaq -0x1e9(%rbp), %rdi
movq %rdi, -0x3c0(%rbp)
callq 0x3560
movq -0x3c0(%rbp), %rdx
leaq 0x4564(%rip), %rsi      # 0x16072
leaq -0x1e8(%rbp), %rdi
callq 0x4620
jmp 0x11b1c
movq -0x388(%rbp), %rdi
xorl %eax, %eax
leaq -0x1e8(%rbp), %rsi
callq 0x99f0
jmp 0x11b33
leaq -0x1e8(%rbp), %rdi
callq 0x31e0
leaq -0x1e9(%rbp), %rdi
callq 0x3350
movl $0x0, -0x1f0(%rbp)
movq -0x388(%rbp), %rcx
movl -0x1f0(%rbp), %eax
cmpl 0x160(%rcx), %eax
jge 0x11c83
leaq -0x211(%rbp), %rdi
movq %rdi, -0x3c8(%rbp)
callq 0x3560
movq -0x3c8(%rbp), %rdx
leaq 0x4529(%rip), %rsi      # 0x160b8
leaq -0x210(%rbp), %rdi
callq 0x4620
jmp 0x11b9d
movslq -0x1f0(%rbp), %rax
movsd -0x190(%rbp,%rax,8), %xmm0
movsd 0x350b(%rip), %xmm1     # 0x150c0
callq 0x3540
movq -0x388(%rbp), %rdi
leaq -0x210(%rbp), %rsi
movb $0x1, %al
callq 0x12360
jmp 0x11bd1
leaq -0x210(%rbp), %rdi
callq 0x31e0
leaq -0x211(%rbp), %rdi
callq 0x3350
movl -0x1f0(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1f0(%rbp)
jmp 0x11b55
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x11c2f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x1e8(%rbp), %rdi
callq 0x31e0
leaq -0x1e9(%rbp), %rdi
callq 0x3350
jmp 0x1234c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x11c72
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x210(%rbp), %rdi
callq 0x31e0
leaq -0x211(%rbp), %rdi
callq 0x3350
jmp 0x1234c
leaq -0x239(%rbp), %rdi
movq %rdi, -0x3d0(%rbp)
callq 0x3560
movq -0x3d0(%rbp), %rdx
leaq 0x3bf5(%rip), %rsi      # 0x15899
leaq -0x238(%rbp), %rdi
callq 0x4620
jmp 0x11cb2
movq -0x388(%rbp), %rdi
xorl %eax, %eax
leaq -0x238(%rbp), %rsi
callq 0x12360
jmp 0x11cc9
leaq -0x238(%rbp), %rdi
callq 0x31e0
leaq -0x239(%rbp), %rdi
callq 0x3350
leaq -0x261(%rbp), %rdi
movq %rdi, -0x3d8(%rbp)
callq 0x3560
movq -0x3d8(%rbp), %rdx
leaq 0x43ba(%rip), %rsi      # 0x160bc
leaq -0x260(%rbp), %rdi
callq 0x4620
jmp 0x11d10
movq -0x388(%rbp), %rdi
xorl %eax, %eax
leaq -0x260(%rbp), %rsi
callq 0x99f0
jmp 0x11d27
leaq -0x260(%rbp), %rdi
callq 0x31e0
leaq -0x261(%rbp), %rdi
callq 0x3350
movl $0x0, -0x268(%rbp)
movq -0x388(%rbp), %rcx
movl -0x268(%rbp), %eax
cmpl 0x160(%rcx), %eax
jge 0x11eb9
leaq -0x289(%rbp), %rdi
movq %rdi, -0x3e0(%rbp)
callq 0x3560
movq -0x3e0(%rbp), %rdx
leaq 0x4335(%rip), %rsi      # 0x160b8
leaq -0x288(%rbp), %rdi
callq 0x4620
jmp 0x11d91
movq -0x388(%rbp), %rdi
movslq -0x268(%rbp), %rax
movsd -0x1b0(%rbp,%rax,8), %xmm0
movsd 0x198(%rdi), %xmm1
divsd %xmm1, %xmm0
leaq -0x288(%rbp), %rsi
movb $0x1, %al
callq 0x12360
jmp 0x11dc4
leaq -0x288(%rbp), %rdi
callq 0x31e0
leaq -0x289(%rbp), %rdi
callq 0x3350
movl -0x268(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x268(%rbp)
jmp 0x11d49
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x11e22
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x238(%rbp), %rdi
callq 0x31e0
leaq -0x239(%rbp), %rdi
callq 0x3350
jmp 0x1234c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x11e65
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x260(%rbp), %rdi
callq 0x31e0
leaq -0x261(%rbp), %rdi
callq 0x3350
jmp 0x1234c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x11ea8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x288(%rbp), %rdi
callq 0x31e0
leaq -0x289(%rbp), %rdi
callq 0x3350
jmp 0x1234c
leaq -0x2b1(%rbp), %rdi
movq %rdi, -0x3e8(%rbp)
callq 0x3560
movq -0x3e8(%rbp), %rdx
leaq 0x39bf(%rip), %rsi      # 0x15899
leaq -0x2b0(%rbp), %rdi
callq 0x4620
jmp 0x11ee8
movq -0x388(%rbp), %rdi
xorl %eax, %eax
leaq -0x2b0(%rbp), %rsi
callq 0x12360
jmp 0x11eff
leaq -0x2b0(%rbp), %rdi
callq 0x31e0
leaq -0x2b1(%rbp), %rdi
callq 0x3350
movl $0x0, -0x2b8(%rbp)
movq -0x388(%rbp), %rcx
movl -0x2b8(%rbp), %eax
cmpl 0x160(%rcx), %eax
jge 0x11fb1
movq -0x388(%rbp), %rax
movslq -0x2b8(%rbp), %rcx
movsd -0x190(%rbp,%rcx,8), %xmm0
movslq -0x2b8(%rbp), %rcx
movsd %xmm0, 0x1f8(%rax,%rcx,8)
movl -0x2b8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2b8(%rbp)
jmp 0x11f21
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x11fa0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x2b0(%rbp), %rdi
callq 0x31e0
leaq -0x2b1(%rbp), %rdi
callq 0x3350
jmp 0x1234c
jmp 0x11fb3
jmp 0x11fb5
movq -0x388(%rbp), %rax
movl 0x174(%rax), %eax
movl %eax, -0x2bc(%rbp)
movl -0x2bc(%rbp), %eax
cmpl -0x98(%rbp), %eax
jge 0x120d4
movq -0x388(%rbp), %rdi
callq 0x12450
movq -0x388(%rbp), %rax
movl 0x174(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x174(%rax)
cmpl $0x1, (%rax)
jle 0x120be
leaq -0x2e1(%rbp), %rdi
movq %rdi, -0x3f0(%rbp)
callq 0x3560
movq -0x3f0(%rbp), %rdx
leaq 0x40d2(%rip), %rsi      # 0x160f8
leaq -0x2e0(%rbp), %rdi
callq 0x4620
jmp 0x12034
movq -0x388(%rbp), %rdi
movl 0x174(%rdi), %edx
cvtsi2sd %edx, %xmm0
movsd 0x1a0(%rdi), %xmm1
mulsd %xmm1, %xmm0
leaq -0x2e0(%rbp), %rsi
movb $0x1, %al
callq 0x99f0
jmp 0x12061
leaq -0x2e0(%rbp), %rdi
callq 0x31e0
leaq -0x2e1(%rbp), %rdi
callq 0x3350
jmp 0x120be
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x120ad
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x2e0(%rbp), %rdi
callq 0x31e0
leaq -0x2e1(%rbp), %rdi
callq 0x3350
jmp 0x1234c
jmp 0x120c0
movl -0x2bc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2bc(%rbp)
jmp 0x11fc8
movq -0x388(%rbp), %rdi
callq 0xd360
movq -0x388(%rbp), %rax
cvtsi2sdl 0x174(%rax), %xmm0
mulsd 0x1a0(%rax), %xmm0
movsd %xmm0, -0x2f0(%rbp)
cmpl $0x0, (%rax)
je 0x121c8
leaq -0x311(%rbp), %rdi
movq %rdi, -0x3f8(%rbp)
callq 0x3560
movq -0x3f8(%rbp), %rdx
leaq 0x3fe5(%rip), %rsi      # 0x1610e
leaq -0x310(%rbp), %rdi
callq 0x4620
jmp 0x12137
movq -0x388(%rbp), %rdi
movl 0x174(%rdi), %edx
movsd -0x2f0(%rbp), %xmm0
movsd 0x198(%rdi), %xmm2
movaps %xmm0, %xmm1
divsd %xmm2, %xmm1
leaq -0x310(%rbp), %rsi
movb $0x2, %al
callq 0x99f0
jmp 0x1216b
leaq -0x310(%rbp), %rdi
callq 0x31e0
leaq -0x311(%rbp), %rdi
callq 0x3350
jmp 0x121c8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x121b7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x310(%rbp), %rdi
callq 0x31e0
leaq -0x311(%rbp), %rdi
callq 0x3350
jmp 0x1234c
movq -0x388(%rbp), %rax
cmpl $0x0, 0x150(%rax)
jne 0x121f7
movq -0x388(%rbp), %rdi
movsd -0x18(%rbp), %xmm0
movq %rdi, %rsi
addq $0x1f8, %rsi            # imm = 0x1F8
movq -0x20(%rbp), %rdx
callq 0x12600
movq -0x388(%rbp), %rax
cmpl $0x1, (%rax)
jle 0x1233a
leaq -0x379(%rbp), %rdi
movq %rdi, -0x400(%rbp)
callq 0x3560
movq -0x400(%rbp), %rdx
leaq 0x3e01(%rip), %rsi      # 0x16029
leaq -0x378(%rbp), %rdi
callq 0x4620
jmp 0x12236
movq -0x388(%rbp), %rsi
leaq -0x358(%rbp), %rdi
leaq -0x378(%rbp), %rdx
callq 0x9b50
jmp 0x12252
leaq 0x33d0(%rip), %rdx      # 0x15629
leaq -0x338(%rbp), %rdi
leaq -0x358(%rbp), %rsi
callq 0x9b00
jmp 0x1226e
movq -0x388(%rbp), %rdi
xorl %eax, %eax
leaq -0x338(%rbp), %rsi
callq 0x99f0
jmp 0x12285
leaq -0x338(%rbp), %rdi
callq 0x31e0
leaq -0x358(%rbp), %rdi
callq 0x31e0
leaq -0x378(%rbp), %rdi
callq 0x31e0
leaq -0x379(%rbp), %rdi
callq 0x3350
jmp 0x1233a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x1232c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x12320
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
jmp 0x12314
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x90(%rbp)
movl %eax, -0x94(%rbp)
leaq -0x338(%rbp), %rdi
callq 0x31e0
leaq -0x358(%rbp), %rdi
callq 0x31e0
leaq -0x378(%rbp), %rdi
callq 0x31e0
leaq -0x379(%rbp), %rdi
callq 0x3350
jmp 0x1234c
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x400, %rsp            # imm = 0x400
popq %rbp
retq
movq -0x90(%rbp), %rdi
callq 0x3550
nopl (%rax,%rax)