// File: /workspace/github_cpp_makefile_star2_O1/aalto-speech[P]ftk/src/2g-prune.cc
// Function: main
int main(int argc, char* argv[]) {

    conf::Config config;
    config("usage: 2g-prune [OPTION...] WORDLIST TRANSITIONS_INIT MSFG_IN TRANSITIONS_OUT\n")
      ('h', "help", "", "", "display help")
      ('c', "candidates=INT", "arg", "5000", "Number of candidate subwords to try to remove per iteration")
      ('r', "removals=INT", "arg", "500", "Number of removals per iteration")
      ('m', "min-length=INT", "arg", "2", "Minimum length of subwords to remove, DEFAULT: 2")
      ('v', "vocab-size=INT", "arg must", "", "Target vocabulary size (stopping criterion)")
      ('t', "temp-models=INT", "arg", "0", "Write out intermediate models for #V mod INT == 0")
      ('b', "normalize-by-bigrams", "", "", "Normalize subword scores by the number of bigrams")
      ('f', "forward-backward", "", "", "Use Forward-backward segmentation instead of Viterbi")
      ('8', "utf-8", "", "", "Utf-8 character encoding in use");
    config.default_parse(argc, argv);
    if (config.arguments.size() != 4) config.print_help(stderr, 1);

    unsigned int n_candidates_per_iter = config["candidates"].get_int();
    unsigned int removals_per_iter = config["removals"].get_int();
    unsigned int min_removal_length = config["min-length"].get_int();
    unsigned int target_vocab_size = config["vocab-size"].get_int();
    string wordlist_fname = config.arguments[0];
    string initial_transitions_fname = config.arguments[1];
    string msfg_fname = config.arguments[2];
    string transition_fname = config.arguments[3];
    unsigned int temp_vocab_interval = config["temp-models"].get_int();
    bool normalize_by_bigrams = config["normalize-by-bigrams"].specified;
    bool enable_fb = config["forward-backward"].specified;
    bool utf8_encoding = config["utf-8"].specified;

    std::cerr << std::boolalpha;
    cerr << "parameters, wordlist: " << wordlist_fname << endl;
    cerr << "parameters, initial transitions: " << initial_transitions_fname << endl;
    cerr << "parameters, msfg: " << msfg_fname << endl;
    cerr << "parameters, transitions out: " << transition_fname << endl;
    cerr << "parameters, candidates per iteration: " << n_candidates_per_iter << endl;
    cerr << "parameters, removals per iteration: " << removals_per_iter << endl;
    cerr << "parameters, minimum length for subwords to remove: " << min_removal_length << endl;
    cerr << "parameters, target vocab size: " << target_vocab_size << endl;
    cerr << "parameters, floor lp: " << FLOOR_LP << endl;
    if (temp_vocab_interval > 0)
        cerr << "parameters, write temp models whenever #V modulo " << temp_vocab_interval << " == 0" << endl;
    else
        cerr << "parameters, write temp models: NO" << endl;
    cerr << "parameters, normalize subword scores by the number of bigrams: " << normalize_by_bigrams << endl;
    cerr << "parameters, use forward-backward: " << enable_fb << endl;
    cerr << "parameters, utf-8 encoding: " << utf8_encoding << endl;

    int word_maxlen;
    map<string, flt_type> all_chars;
    map<string, flt_type> freqs;
    map<string, flt_type> words;
    MultiStringFactorGraph msfg(start_end_symbol);
    transitions_t transitions;
    transitions_t trans_stats;
    map<string, flt_type> unigram_stats;
    set<string> short_subwords;

    cerr << "Reading initial transitions " << initial_transitions_fname << endl;
    int retval = Bigrams::read_transitions(transitions, initial_transitions_fname);
    if (retval < 0) {
        cerr << "something went wrong reading transitions" << endl;
        exit(EXIT_FAILURE);
    }
    cerr << "\tnumber of transitions: " << Bigrams::transition_count(transitions) << endl;
    cerr << "\tvocabulary size: " << transitions.size() << endl;

    map<string, flt_type> vocab;
    Bigrams::trans_to_vocab(transitions, vocab);
    find_short_factors(vocab, short_subwords, min_removal_length, utf8_encoding);

    cerr << "Reading word list " << wordlist_fname << endl;
    retval = Unigrams::read_vocab(wordlist_fname, words, word_maxlen, utf8_encoding);
    if (retval < 0) {
        cerr << "something went wrong reading word list" << endl;
        exit(EXIT_FAILURE);
    }
    cerr << "\t" << "wordlist size: " << words.size() << endl;
    cerr << "\t" << "maximum word length: " << word_maxlen << endl;

    cerr << "Reading msfg " << msfg_fname << endl;
    msfg.read(msfg_fname);
    msfg.prune_unused(transitions);

    std::cerr << std::setprecision(15);
    int iteration = 1;
    unsigned int next_out_vocab_size=0;
    while (true) {

        cerr << "Iteration " << iteration << endl;

        assign_scores(transitions, msfg);
        flt_type lp = Bigrams::collect_trans_stats(words, msfg, trans_stats, unigram_stats, enable_fb);
        transitions.swap(trans_stats);
        Bigrams::freqs_to_logprobs(transitions);
        trans_stats.clear();

        cerr << "\tbigram likelihood: " << lp << endl;
        cerr << "\tnumber of transitions: " << Bigrams::transition_count(transitions) << endl;
        cerr << "\tvocabulary size: " << transitions.size() << endl;

        if (iteration==1 && temp_vocab_interval > 0)
            next_out_vocab_size = transitions.size()/temp_vocab_interval * temp_vocab_interval;

        // Get candidate subwords
        cerr << "\tinitializing removals .." << endl;
        map<string, flt_type> candidates;
        Bigrams::init_candidates_freq(n_candidates_per_iter, unigram_stats, candidates, short_subwords);
        //Bigrams::init_candidates_num_contexts(n_candidates_per_iter, transitions, unigram_stats, candidates);

        // Score all candidates
        cerr << "\tranking removals .." << endl;
        assign_scores(transitions, msfg);
        Bigrams::rank_candidate_subwords(words, msfg, unigram_stats, transitions,
                                         candidates, enable_fb, normalize_by_bigrams);

        // Remove subwords
        vector<pair<string, flt_type> > sorted_scores;
        Unigrams::sort_vocab(candidates, sorted_scores, true);
        vector<string> to_remove;
        for (auto it = sorted_scores.begin(); it != sorted_scores.end(); ++it) {
            to_remove.push_back(it->first);
            if (((transitions.size()-to_remove.size()) % removals_per_iter == 0)
                  && to_remove.size() >= (removals_per_iter/2))
                    break;
        }
        Bigrams::remove_transitions(to_remove, transitions);
        for (auto it = to_remove.begin(); it != to_remove.end(); ++it)
            msfg.remove_arcs(*it);

        Bigrams::iterate(words, msfg, transitions, enable_fb, 1);
        msfg.prune_unused(transitions);

        // Write intermediate model
        if (temp_vocab_interval > 0
            && transitions.size() <= next_out_vocab_size
            && transitions.size() > target_vocab_size)
        {
            ostringstream transitions_temp;
            transitions_temp << "transitions." << transitions.size() << ".gz";
            cerr << "\twriting to: " << transitions_temp.str() << endl;
            Bigrams::write_transitions(transitions, transitions_temp.str());
            next_out_vocab_size -= temp_vocab_interval;
        }

        if  (transitions.size() <= target_vocab_size) break;
        iteration++;
    }

    // Write the final model
    Bigrams::write_transitions(transitions, transition_fname);

    exit(EXIT_SUCCESS);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xbc8, %rsp            # imm = 0xBC8
movq %rsi, %rbx
movl %edi, %r14d
leaq -0x880(%rbp), %rdi
callq 0x93ee
leaq -0x788(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0x22ecb(%rip), %rsi     # 0x28020
leaq 0x22f12(%rip), %rdx     # 0x2806e
leaq -0x798(%rbp), %rdi
callq 0x86ac
leaq -0x880(%rbp), %rdi
leaq -0x798(%rbp), %rsi
callq 0x9454
movq %rax, %r15
leaq -0x768(%rbp), %r13
movq %r13, -0x10(%r13)
leaq 0x22ee7(%rip), %rsi     # 0x28077
leaq 0x22ee4(%rip), %rdx     # 0x2807b
leaq -0x778(%rbp), %rdi
callq 0x86ac
leaq -0x628(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x237e2(%rip), %rdx     # 0x28997
leaq -0x638(%rbp), %rdi
movq %rdx, %rsi
callq 0x86ac
leaq -0x608(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x237c1(%rip), %rdx     # 0x28997
leaq -0x618(%rbp), %rdi
movq %rdx, %rsi
callq 0x86ac
leaq -0x5e8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22e78(%rip), %rsi     # 0x2806f
leaq 0x22e7d(%rip), %rdx     # 0x2807b
leaq -0x5f8(%rbp), %rdi
callq 0x86ac
leaq -0x778(%rbp), %rdx
leaq -0x638(%rbp), %rcx
leaq -0x618(%rbp), %r8
leaq -0x5f8(%rbp), %r9
movq %r15, %rdi
movl $0x68, %esi
callq 0x946c
movq %rax, %r15
leaq -0x5c8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22e34(%rip), %rsi     # 0x2807c
leaq 0x22e3b(%rip), %rdx     # 0x2808a
leaq -0x5d8(%rbp), %rdi
callq 0x86ac
leaq -0x5a8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22e1e(%rip), %rsi     # 0x2808b
leaq 0x22e1a(%rip), %rdx     # 0x2808e
leaq -0x5b8(%rbp), %rdi
callq 0x86ac
leaq -0x588(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22dfd(%rip), %rsi     # 0x2808f
leaq 0x22dfa(%rip), %rdx     # 0x28093
leaq -0x598(%rbp), %rdi
callq 0x86ac
leaq -0x568(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22ddd(%rip), %rsi     # 0x28094
leaq 0x22e11(%rip), %rdx     # 0x280cf
leaq -0x578(%rbp), %rdi
callq 0x86ac
leaq -0x5d8(%rbp), %rdx
leaq -0x5b8(%rbp), %rcx
leaq -0x598(%rbp), %r8
leaq -0x578(%rbp), %r9
movq %r15, %rdi
movl $0x63, %esi
callq 0x946c
movq %rax, %r15
leaq -0x548(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22dc8(%rip), %rsi     # 0x280d0
leaq 0x22dcd(%rip), %rdx     # 0x280dc
leaq -0x558(%rbp), %rdi
callq 0x86ac
leaq -0x528(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22d5e(%rip), %rsi     # 0x2808b
leaq 0x22d5a(%rip), %rdx     # 0x2808e
leaq -0x538(%rbp), %rdi
callq 0x86ac
leaq -0x508(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22d8b(%rip), %rsi     # 0x280dd
leaq 0x22d87(%rip), %rdx     # 0x280e0
leaq -0x518(%rbp), %rdi
callq 0x86ac
leaq -0x4e8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22d6a(%rip), %rsi     # 0x280e1
leaq 0x22d83(%rip), %rdx     # 0x28101
leaq -0x4f8(%rbp), %rdi
callq 0x86ac
leaq -0x558(%rbp), %rdx
leaq -0x538(%rbp), %rcx
leaq -0x518(%rbp), %r8
leaq -0x4f8(%rbp), %r9
movq %r15, %rdi
movl $0x72, %esi
callq 0x946c
movq %rax, %r15
leaq -0x4c8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22d3a(%rip), %rsi     # 0x28102
leaq 0x22d41(%rip), %rdx     # 0x28110
leaq -0x4d8(%rbp), %rdi
callq 0x86ac
leaq -0x4a8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22c9e(%rip), %rsi     # 0x2808b
leaq 0x22c9a(%rip), %rdx     # 0x2808e
leaq -0x4b8(%rbp), %rdi
callq 0x86ac
leaq -0x488(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22d2e(%rip), %rsi     # 0x28140
leaq 0x22d28(%rip), %rdx     # 0x28141
leaq -0x498(%rbp), %rdi
callq 0x86ac
leaq -0x468(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22cda(%rip), %rsi     # 0x28111
leaq 0x22d03(%rip), %rdx     # 0x28141
leaq -0x478(%rbp), %rdi
callq 0x86ac
leaq -0x4d8(%rbp), %rdx
leaq -0x4b8(%rbp), %rcx
leaq -0x498(%rbp), %r8
leaq -0x478(%rbp), %r9
movq %r15, %rdi
movl $0x6d, %esi
callq 0x946c
movq %rax, %r15
leaq -0x448(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22cba(%rip), %rsi     # 0x28142
leaq 0x22cc1(%rip), %rdx     # 0x28150
leaq -0x458(%rbp), %rdi
callq 0x86ac
leaq -0x428(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22ca4(%rip), %rsi     # 0x28151
leaq 0x22ca5(%rip), %rdx     # 0x28159
leaq -0x438(%rbp), %rdi
callq 0x86ac
leaq -0x408(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x234c5(%rip), %rdx     # 0x28997
leaq -0x418(%rbp), %rdi
movq %rdx, %rsi
callq 0x86ac
leaq -0x3e8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22c67(%rip), %rsi     # 0x2815a
leaq 0x22c8b(%rip), %rdx     # 0x28185
leaq -0x3f8(%rbp), %rdi
callq 0x86ac
leaq -0x458(%rbp), %rdx
leaq -0x438(%rbp), %rcx
leaq -0x418(%rbp), %r8
leaq -0x3f8(%rbp), %r9
movq %r15, %rdi
movl $0x76, %esi
callq 0x946c
movq %rax, %r15
leaq -0x3c8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22c42(%rip), %rsi     # 0x28186
leaq 0x22c4a(%rip), %rdx     # 0x28195
leaq -0x3d8(%rbp), %rdi
callq 0x86ac
leaq -0x3a8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22b22(%rip), %rsi     # 0x2808b
leaq 0x22b1e(%rip), %rdx     # 0x2808e
leaq -0x3b8(%rbp), %rdi
callq 0x86ac
leaq -0x388(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22c38(%rip), %rsi     # 0x281c6
leaq 0x22c32(%rip), %rdx     # 0x281c7
leaq -0x398(%rbp), %rdi
callq 0x86ac
leaq -0x368(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22be3(%rip), %rsi     # 0x28196
leaq 0x22c0d(%rip), %rdx     # 0x281c7
leaq -0x378(%rbp), %rdi
callq 0x86ac
leaq -0x3d8(%rbp), %rdx
leaq -0x3b8(%rbp), %rcx
leaq -0x398(%rbp), %r8
leaq -0x378(%rbp), %r9
movq %r15, %rdi
movl $0x74, %esi
callq 0x946c
movq %rax, %r15
leaq -0x348(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22bc4(%rip), %rsi     # 0x281c8
leaq 0x22bd1(%rip), %rdx     # 0x281dc
leaq -0x358(%rbp), %rdi
callq 0x86ac
leaq -0x328(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x2336e(%rip), %rdx     # 0x28997
leaq -0x338(%rbp), %rdi
movq %rdx, %rsi
callq 0x86ac
leaq -0x308(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x2334d(%rip), %rdx     # 0x28997
leaq -0x318(%rbp), %rdi
movq %rdx, %rsi
callq 0x86ac
leaq -0x2e8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22b72(%rip), %rsi     # 0x281dd
leaq 0x22b9c(%rip), %rdx     # 0x2820e
leaq -0x2f8(%rbp), %rdi
callq 0x86ac
leaq -0x358(%rbp), %rdx
leaq -0x338(%rbp), %rcx
leaq -0x318(%rbp), %r8
leaq -0x2f8(%rbp), %r9
movq %r15, %rdi
movl $0x62, %esi
callq 0x946c
movq %rax, %r15
leaq -0x2c8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22b53(%rip), %rsi     # 0x2820f
leaq 0x22b5c(%rip), %rdx     # 0x2821f
leaq -0x2d8(%rbp), %rdi
callq 0x86ac
leaq -0x2a8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x232b6(%rip), %rdx     # 0x28997
leaq -0x2b8(%rbp), %rdi
movq %rdx, %rsi
callq 0x86ac
leaq -0x288(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x23295(%rip), %rdx     # 0x28997
leaq -0x298(%rbp), %rdi
movq %rdx, %rsi
callq 0x86ac
leaq -0x268(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22afd(%rip), %rsi     # 0x28220
leaq 0x22b2a(%rip), %rdx     # 0x28254
leaq -0x278(%rbp), %rdi
callq 0x86ac
leaq -0x2d8(%rbp), %rdx
leaq -0x2b8(%rbp), %rcx
leaq -0x298(%rbp), %r8
leaq -0x278(%rbp), %r9
movq %r15, %rdi
movl $0x66, %esi
callq 0x946c
movq %rax, %r15
leaq -0x248(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22ae1(%rip), %rsi     # 0x28255
leaq 0x22adf(%rip), %rdx     # 0x2825a
leaq -0x258(%rbp), %rdi
callq 0x86ac
leaq -0x228(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x231fe(%rip), %rdx     # 0x28997
leaq -0x238(%rbp), %rdi
movq %rdx, %rsi
callq 0x86ac
leaq -0x208(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x231dd(%rip), %rdx     # 0x28997
leaq -0x218(%rbp), %rdi
movq %rdx, %rsi
callq 0x86ac
leaq -0x1e8(%rbp), %rax
movq %rax, -0x10(%rax)
leaq 0x22a80(%rip), %rsi     # 0x2825b
leaq 0x22a98(%rip), %rdx     # 0x2827a
leaq -0x1f8(%rbp), %rdi
callq 0x86ac
leaq -0x258(%rbp), %rdx
leaq -0x238(%rbp), %rcx
leaq -0x218(%rbp), %r8
leaq -0x1f8(%rbp), %r9
movq %r15, %rdi
movl $0x38, %esi
callq 0x946c
movq -0x1f8(%rbp), %rdi
leaq -0x1e8(%rbp), %rax
cmpq %rax, %rdi
je 0x582f
callq 0x4360
movq -0x218(%rbp), %rdi
leaq -0x208(%rbp), %rax
cmpq %rax, %rdi
je 0x5847
callq 0x4360
movq -0x238(%rbp), %rdi
leaq -0x228(%rbp), %rax
cmpq %rax, %rdi
je 0x585f
callq 0x4360
movq -0x258(%rbp), %rdi
leaq -0x248(%rbp), %rax
cmpq %rax, %rdi
je 0x5877
callq 0x4360
movq -0x278(%rbp), %rdi
leaq -0x268(%rbp), %rax
cmpq %rax, %rdi
je 0x588f
callq 0x4360
movq -0x298(%rbp), %rdi
leaq -0x288(%rbp), %rax
cmpq %rax, %rdi
je 0x58a7
callq 0x4360
movq -0x2b8(%rbp), %rdi
leaq -0x2a8(%rbp), %rax
cmpq %rax, %rdi
je 0x58bf
callq 0x4360
movq -0x2d8(%rbp), %rdi
leaq -0x2c8(%rbp), %rax
cmpq %rax, %rdi
je 0x58d7
callq 0x4360
movq -0x2f8(%rbp), %rdi
leaq -0x2e8(%rbp), %rax
cmpq %rax, %rdi
je 0x58ef
callq 0x4360
movq -0x318(%rbp), %rdi
leaq -0x308(%rbp), %rax
cmpq %rax, %rdi
je 0x5907
callq 0x4360
movq -0x338(%rbp), %rdi
leaq -0x328(%rbp), %rax
cmpq %rax, %rdi
je 0x591f
callq 0x4360
movq -0x358(%rbp), %rdi
leaq -0x348(%rbp), %rax
cmpq %rax, %rdi
je 0x5937
callq 0x4360
movq -0x378(%rbp), %rdi
leaq -0x368(%rbp), %rax
cmpq %rax, %rdi
je 0x594f
callq 0x4360
movq -0x398(%rbp), %rdi
leaq -0x388(%rbp), %rax
cmpq %rax, %rdi
je 0x5967
callq 0x4360
movq -0x3b8(%rbp), %rdi
leaq -0x3a8(%rbp), %rax
cmpq %rax, %rdi
je 0x597f
callq 0x4360
movq -0x3d8(%rbp), %rdi
leaq -0x3c8(%rbp), %rax
cmpq %rax, %rdi
je 0x5997
callq 0x4360
movq -0x3f8(%rbp), %rdi
leaq -0x3e8(%rbp), %rax
cmpq %rax, %rdi
je 0x59af
callq 0x4360
movq -0x418(%rbp), %rdi
leaq -0x408(%rbp), %rax
cmpq %rax, %rdi
je 0x59c7
callq 0x4360
movq -0x438(%rbp), %rdi
leaq -0x428(%rbp), %rax
cmpq %rax, %rdi
je 0x59df
callq 0x4360
movq -0x458(%rbp), %rdi
leaq -0x448(%rbp), %rax
cmpq %rax, %rdi
je 0x59f7
callq 0x4360
movq -0x478(%rbp), %rdi
leaq -0x468(%rbp), %rax
cmpq %rax, %rdi
je 0x5a0f
callq 0x4360
movq -0x498(%rbp), %rdi
leaq -0x488(%rbp), %rax
cmpq %rax, %rdi
je 0x5a27
callq 0x4360
movq -0x4b8(%rbp), %rdi
leaq -0x4a8(%rbp), %rax
cmpq %rax, %rdi
je 0x5a3f
callq 0x4360
movq -0x4d8(%rbp), %rdi
leaq -0x4c8(%rbp), %rax
cmpq %rax, %rdi
je 0x5a57
callq 0x4360
movq -0x4f8(%rbp), %rdi
leaq -0x4e8(%rbp), %rax
cmpq %rax, %rdi
je 0x5a6f
callq 0x4360
movq -0x518(%rbp), %rdi
leaq -0x508(%rbp), %rax
cmpq %rax, %rdi
je 0x5a87
callq 0x4360
movq -0x538(%rbp), %rdi
leaq -0x528(%rbp), %rax
cmpq %rax, %rdi
je 0x5a9f
callq 0x4360
movq -0x558(%rbp), %rdi
leaq -0x548(%rbp), %rax
cmpq %rax, %rdi
je 0x5ab7
callq 0x4360
movq -0x578(%rbp), %rdi
leaq -0x568(%rbp), %rax
cmpq %rax, %rdi
je 0x5acf
callq 0x4360
movq -0x598(%rbp), %rdi
leaq -0x588(%rbp), %rax
cmpq %rax, %rdi
je 0x5ae7
callq 0x4360
movq -0x5b8(%rbp), %rdi
leaq -0x5a8(%rbp), %rax
cmpq %rax, %rdi
je 0x5aff
callq 0x4360
movq -0x5d8(%rbp), %rdi
leaq -0x5c8(%rbp), %rax
cmpq %rax, %rdi
je 0x5b17
callq 0x4360
movq -0x5f8(%rbp), %rdi
leaq -0x5e8(%rbp), %rax
cmpq %rax, %rdi
je 0x5b2f
callq 0x4360
movq -0x618(%rbp), %rdi
leaq -0x608(%rbp), %rax
cmpq %rax, %rdi
je 0x5b47
callq 0x4360
movq -0x638(%rbp), %rdi
leaq -0x628(%rbp), %rax
cmpq %rax, %rdi
je 0x5b5f
callq 0x4360
movq -0x778(%rbp), %rdi
cmpq %r13, %rdi
je 0x5b70
callq 0x4360
movq -0x798(%rbp), %rdi
cmpq %r12, %rdi
je 0x5b81
callq 0x4360
leaq -0x880(%rbp), %rdi
movl %r14d, %esi
movq %rbx, %rdx
callq 0x9eba
movq -0x7e0(%rbp), %rax
subq -0x7e8(%rbp), %rax
cmpq $0x80, %rax
je 0x5bc4
movq 0x30418(%rip), %rax     # 0x35fc8
movq (%rax), %rsi
leaq -0x880(%rbp), %rdi
movl $0x1, %edx
callq 0xa45c
leaq -0x748(%rbp), %r14
movq %r14, -0x10(%r14)
leaq 0x226a5(%rip), %rsi     # 0x2827b
leaq 0x226a8(%rip), %rdx     # 0x28285
leaq -0x758(%rbp), %rdi
callq 0x86ac
leaq -0x880(%rbp), %rdi
leaq -0x758(%rbp), %rsi
callq 0x9f74
movq %rax, %rdi
callq 0x9310
movl %eax, -0x6c(%rbp)
movq -0x758(%rbp), %rdi
cmpq %r14, %rdi
je 0x5c18
callq 0x4360
leaq -0x728(%rbp), %r14
movq %r14, -0x10(%r14)
leaq 0x2265c(%rip), %rsi     # 0x28286
leaq 0x2265d(%rip), %rdx     # 0x2828e
leaq -0x738(%rbp), %rdi
callq 0x86ac
leaq -0x880(%rbp), %rdi
leaq -0x738(%rbp), %rsi
callq 0x9f74
movq %rax, %rdi
callq 0x9310
movq %rax, -0x80(%rbp)
movq -0x738(%rbp), %rdi
cmpq %r14, %rdi
je 0x5c6d
callq 0x4360
leaq -0x708(%rbp), %r14
movq %r14, -0x10(%r14)
leaq 0x22610(%rip), %rsi     # 0x2828f
leaq 0x22613(%rip), %rdx     # 0x28299
leaq -0x718(%rbp), %rdi
callq 0x86ac
leaq -0x880(%rbp), %rdi
leaq -0x718(%rbp), %rsi
callq 0x9f74
movq %rax, %rdi
callq 0x9310
movl %eax, -0x2c(%rbp)
movq -0x718(%rbp), %rdi
cmpq %r14, %rdi
je 0x5cc1
callq 0x4360
leaq -0x6e8(%rbp), %r14
movq %r14, -0x10(%r14)
leaq 0x225c7(%rip), %rsi     # 0x2829a
leaq 0x225ca(%rip), %rdx     # 0x282a4
leaq -0x6f8(%rbp), %rdi
callq 0x86ac
leaq -0x880(%rbp), %rdi
leaq -0x6f8(%rbp), %rsi
callq 0x9f74
movq %rax, %rdi
callq 0x9310
movl %eax, %ebx
movq -0x6f8(%rbp), %rdi
cmpq %r14, %rdi
je 0x5d14
callq 0x4360
movq -0x7e8(%rbp), %rax
leaq -0x130(%rbp), %rcx
movq %rcx, -0x10(%rcx)
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
leaq -0x140(%rbp), %rdi
callq 0x8612
movq -0x7e8(%rbp), %rax
leaq -0x170(%rbp), %rcx
movq %rcx, -0x10(%rcx)
movq 0x20(%rax), %rsi
movq 0x28(%rax), %rdx
addq %rsi, %rdx
leaq -0x180(%rbp), %rdi
callq 0x8612
movq -0x7e8(%rbp), %rax
leaq -0x150(%rbp), %rcx
movq %rcx, -0x10(%rcx)
movq 0x40(%rax), %rsi
movq 0x48(%rax), %rdx
addq %rsi, %rdx
leaq -0x160(%rbp), %rdi
callq 0x8612
movq -0x7e8(%rbp), %rax
leaq -0x1c8(%rbp), %rcx
movq %rcx, -0x10(%rcx)
movq 0x60(%rax), %rsi
movq 0x68(%rax), %rdx
addq %rsi, %rdx
leaq -0x1d8(%rbp), %rdi
callq 0x8612
leaq -0x6c8(%rbp), %r14
movq %r14, -0x10(%r14)
leaq 0x224dc(%rip), %rsi     # 0x282a5
leaq 0x224e0(%rip), %rdx     # 0x282b0
leaq -0x6d8(%rbp), %rdi
callq 0x86ac
leaq -0x880(%rbp), %rdi
leaq -0x6d8(%rbp), %rsi
callq 0x9f74
movq %rax, %rdi
callq 0x9310
movl %eax, -0x30(%rbp)
movq -0x6d8(%rbp), %rdi
cmpq %r14, %rdi
je 0x5e0b
callq 0x4360
leaq -0x6a8(%rbp), %r15
movq %r15, -0x10(%r15)
leaq 0x223ab(%rip), %rsi     # 0x281c8
leaq 0x223b8(%rip), %rdx     # 0x281dc
leaq -0x6b8(%rbp), %rdi
callq 0x86ac
leaq -0x880(%rbp), %rdi
leaq -0x6b8(%rbp), %rsi
callq 0x9f74
movb 0x4a(%rax), %r14b
movq -0x6b8(%rbp), %rdi
cmpq %r15, %rdi
je 0x5e58
callq 0x4360
leaq -0x688(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0x223a4(%rip), %rsi     # 0x2820f
leaq 0x223ad(%rip), %rdx     # 0x2821f
leaq -0x698(%rbp), %rdi
callq 0x86ac
leaq -0x880(%rbp), %rdi
leaq -0x698(%rbp), %rsi
callq 0x9f74
movb 0x4a(%rax), %r15b
movq -0x698(%rbp), %rdi
cmpq %r12, %rdi
je 0x5ea6
callq 0x4360
leaq -0x668(%rbp), %r12
movq %r12, -0x10(%r12)
leaq 0x2239c(%rip), %rsi     # 0x28255
leaq 0x2239a(%rip), %rdx     # 0x2825a
leaq -0x678(%rbp), %rdi
callq 0x86ac
leaq -0x880(%rbp), %rdi
leaq -0x678(%rbp), %rsi
callq 0x9f74
movb 0x4a(%rax), %r13b
movq -0x678(%rbp), %rdi
cmpq %r12, %rdi
je 0x5ef4
callq 0x4360
movq 0x300ed(%rip), %rdi     # 0x35fe8
movq (%rdi), %rax
movq -0x18(%rax), %rax
orl $0x1, 0x18(%rdi,%rax)
leaq 0x223a3(%rip), %rsi     # 0x282b1
movl $0x16, %edx
callq 0x4410
movq -0x140(%rbp), %rsi
movq -0x138(%rbp), %rdx
movq 0x300bb(%rip), %rdi     # 0x35fe8
callq 0x4410
movq %rax, %rdi
callq 0x4180
movq 0x300a7(%rip), %rdi     # 0x35fe8
leaq 0x22380(%rip), %rsi     # 0x282c8
movl $0x21, %edx
callq 0x4410
movq -0x180(%rbp), %rsi
movq -0x178(%rbp), %rdx
movq 0x30081(%rip), %rdi     # 0x35fe8
callq 0x4410
movq %rax, %rdi
callq 0x4180
movq 0x3006d(%rip), %rdi     # 0x35fe8
leaq 0x22368(%rip), %rsi     # 0x282ea
movl $0x12, %edx
callq 0x4410
movq -0x160(%rbp), %rsi
movq -0x158(%rbp), %rdx
movq 0x30047(%rip), %rdi     # 0x35fe8
callq 0x4410
movq %rax, %rdi
callq 0x4180
movq 0x30033(%rip), %rdi     # 0x35fe8
leaq 0x22341(%rip), %rsi     # 0x282fd
movl $0x1d, %edx
callq 0x4410
movq -0x1d8(%rbp), %rsi
movq -0x1d0(%rbp), %rdx
movq 0x3000d(%rip), %rdi     # 0x35fe8
callq 0x4410
movq %rax, %rdi
callq 0x4180
movq 0x2fff9(%rip), %rdi     # 0x35fe8
leaq 0x22325(%rip), %rsi     # 0x2831b
movl $0x26, %edx
callq 0x4410
movl -0x6c(%rbp), %esi
movq 0x2ffde(%rip), %rdi     # 0x35fe8
callq 0x4260
movq %rax, %rdi
callq 0x4180
movq 0x2ffca(%rip), %rdi     # 0x35fe8
leaq 0x2231d(%rip), %rsi     # 0x28342
movl $0x24, %edx
callq 0x4410
movl -0x80(%rbp), %r12d
movq 0x2ffae(%rip), %rdi     # 0x35fe8
movq %r12, %rsi
callq 0x4260
movq %rax, %rdi
callq 0x4180
movq 0x2ff97(%rip), %rdi     # 0x35fe8
leaq 0x2230f(%rip), %rsi     # 0x28367
movl $0x33, %edx
callq 0x4410
movl -0x2c(%rbp), %esi
movq 0x2ff7c(%rip), %rdi     # 0x35fe8
callq 0x4260
movq %rax, %rdi
callq 0x4180
movq 0x2ff68(%rip), %rdi     # 0x35fe8
leaq 0x22314(%rip), %rsi     # 0x2839b
movl $0x1f, %edx
callq 0x4410
movl %ebx, %esi
movq 0x2ff4e(%rip), %rdi     # 0x35fe8
movq %rsi, -0x100(%rbp)
callq 0x4260
movq %rax, %rdi
callq 0x4180
movq 0x2ff33(%rip), %rdi     # 0x35fe8
leaq 0x222ff(%rip), %rsi     # 0x283bb
movl $0x16, %edx
callq 0x4410
movq 0x2ff1b(%rip), %rbx     # 0x35fe8
movsd 0x21f33(%rip), %xmm0    # 0x28008
movq %rbx, %rdi
callq 0x45c0
movq %rax, %rdi
callq 0x4180
movl -0x30(%rbp), %eax
movl %eax, %ecx
movq %rcx, -0xf8(%rbp)
testl %eax, %eax
je 0x6139
movq 0x2feec(%rip), %rdi     # 0x35fe8
leaq 0x222cf(%rip), %rsi     # 0x283d2
movl $0x31, %edx
callq 0x4410
movq 0x2fed4(%rip), %rdi     # 0x35fe8
movq -0xf8(%rbp), %rsi
callq 0x4260
movq %rax, %rbx
leaq 0x22098(%rip), %rsi     # 0x281c2
movl $0x5, %edx
movq %rax, %rdi
callq 0x4410
jmp 0x614d
leaq 0x222c4(%rip), %rsi     # 0x28404
movl $0x21, %edx
movq %rbx, %rdi
callq 0x4410
movq %rbx, %rdi
callq 0x4180
movq 0x2fe8c(%rip), %rdi     # 0x35fe8
leaq 0x222c3(%rip), %rsi     # 0x28426
movl $0x3f, %edx
callq 0x4410
movzbl %r14b, %esi
movq 0x2fe70(%rip), %rdi     # 0x35fe8
movl %esi, -0xb4(%rbp)
callq 0x4600
movq %rax, %rdi
callq 0x4180
movq 0x2fe56(%rip), %rdi     # 0x35fe8
leaq 0x222cd(%rip), %rsi     # 0x28466
movl $0x22, %edx
callq 0x4410
movzbl %r15b, %esi
movq 0x2fe3a(%rip), %rdi     # 0x35fe8
movl %esi, -0x34(%rbp)
callq 0x4600
movq %rax, %rdi
callq 0x4180
movq 0x2fe23(%rip), %rdi     # 0x35fe8
leaq 0x222bd(%rip), %rsi     # 0x28489
movl $0x1c, %edx
callq 0x4410
movzbl %r13b, %ebx
movq 0x2fe07(%rip), %rdi     # 0x35fe8
movl %ebx, %esi
callq 0x4600
movq %rax, %rdi
callq 0x4180
leaq -0x968(%rbp), %rax
xorl %r14d, %r14d
movl %r14d, (%rax)
movq %r14, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %r14, 0x20(%rax)
leaq -0x938(%rbp), %rax
movl %r14d, (%rax)
movq %r14, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %r14, 0x20(%rax)
leaq -0x7c0(%rbp), %rax
movl %r14d, (%rax)
movq %r14, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %r14, 0x20(%rax)
leaq 0x30178(%rip), %rsi     # 0x363c0
leaq -0xbe0(%rbp), %rdi
callq 0x743a
leaq -0x60(%rbp), %rax
movl %r14d, (%rax)
movq %r14, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %r14, 0x20(%rax)
leaq -0xa8(%rbp), %rax
movl %r14d, (%rax)
movq %r14, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %r14, 0x20(%rax)
leaq -0x8a8(%rbp), %rax
movl %r14d, (%rax)
movq %r14, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %r14, 0x20(%rax)
leaq -0x908(%rbp), %rax
movl %r14d, (%rax)
movq %r14, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %r14, 0x20(%rax)
movq 0x2fd28(%rip), %rdi     # 0x35fe8
leaq 0x221df(%rip), %rsi     # 0x284a6
movl $0x1c, %edx
callq 0x4410
movq -0x180(%rbp), %rsi
movq -0x178(%rbp), %rdx
movq 0x2fd02(%rip), %rdi     # 0x35fe8
callq 0x4410
movq %rax, %rdi
callq 0x4180
leaq -0x68(%rbp), %rdi
leaq -0x180(%rbp), %rsi
callq 0x240d2
testl %eax, %eax
jns 0x6330
movq 0x2fcda(%rip), %rdi     # 0x35fe8
leaq 0x221ae(%rip), %rsi     # 0x284c3
movl $0x28, %edx
callq 0x4410
movq 0x2fcc2(%rip), %rdi     # 0x35fe8
callq 0x4180
jmp 0x6497
movq 0x2fcb1(%rip), %rdi     # 0x35fe8
leaq 0x221ae(%rip), %rsi     # 0x284ec
movl $0x18, %edx
callq 0x4410
leaq -0x68(%rbp), %rdi
callq 0x24876
movq 0x2fc90(%rip), %rdi     # 0x35fe8
movl %eax, %esi
callq 0x4650
movq %rax, %rdi
callq 0x4180
movq 0x2fc7a(%rip), %rdi     # 0x35fe8
leaq 0x22190(%rip), %rsi     # 0x28505
movl $0x12, %edx
callq 0x4410
movq -0x40(%rbp), %rsi
movq 0x2fc5e(%rip), %rdi     # 0x35fe8
callq 0x4260
movq %rax, %rdi
callq 0x4180
leaq -0x8d8(%rbp), %rax
movl $0x0, (%rax)
xorl %ecx, %ecx
movq %rcx, 0x8(%rax)
movq %rax, 0x10(%rax)
movq %rax, 0x18(%rax)
movq %rcx, 0x20(%rax)
leaq -0x68(%rbp), %rdi
leaq -0x8e0(%rbp), %rsi
callq 0x248ca
leaq -0x8e0(%rbp), %rdi
leaq -0x910(%rbp), %rsi
movl -0x2c(%rbp), %edx
movl %ebx, %ecx
callq 0x7231
movq 0x2fc03(%rip), %rdi     # 0x35fe8
leaq 0x2212c(%rip), %rsi     # 0x28518
movl $0x12, %edx
callq 0x4410
movq -0x140(%rbp), %rsi
movq -0x138(%rbp), %rdx
movq 0x2fbdd(%rip), %rdi     # 0x35fe8
callq 0x4410
movq %rax, %rdi
callq 0x4180
leaq -0x648(%rbp), %r14
movq %r14, -0x10(%r14)
movq -0x140(%rbp), %rsi
movq -0x138(%rbp), %rdx
addq %rsi, %rdx
leaq -0x658(%rbp), %rdi
callq 0x8612
leaq -0x658(%rbp), %rdi
leaq -0x7c8(%rbp), %rsi
leaq -0xb8(%rbp), %rdx
movl %ebx, %ecx
callq 0x1f016
movl %eax, %ebx
movq -0x658(%rbp), %rdi
cmpq %r14, %rdi
je 0x646f
callq 0x4360
testl %ebx, %ebx
jns 0x64a1
movq 0x2fb6e(%rip), %rdi     # 0x35fe8
leaq 0x220aa(%rip), %rsi     # 0x2852b
movl $0x26, %edx
callq 0x4410
movq 0x2fb56(%rip), %rdi     # 0x35fe8
callq 0x4180
movl $0x1, %edi
callq 0x4430
movq 0x2fb40(%rip), %rdi     # 0x35fe8
leaq 0x224e7(%rip), %rsi     # 0x28996
movl $0x1, %edx
callq 0x4410
movq 0x2fb28(%rip), %rdi     # 0x35fe8
leaq 0x2208b(%rip), %rsi     # 0x28552
movl $0xf, %edx
callq 0x4410
movq -0x7a0(%rbp), %rsi
movq 0x2fb09(%rip), %rdi     # 0x35fe8
callq 0x4260
movq %rax, %rdi
callq 0x4180
movq 0x2faf5(%rip), %rdi     # 0x35fe8
leaq 0x2249c(%rip), %rsi     # 0x28996
movl $0x1, %edx
callq 0x4410
movq 0x2fadd(%rip), %rdi     # 0x35fe8
leaq 0x22050(%rip), %rsi     # 0x28562
movl $0x15, %edx
callq 0x4410
movl -0xb8(%rbp), %esi
movq 0x2fabf(%rip), %rdi     # 0x35fe8
callq 0x4650
movq %rax, %rdi
callq 0x4180
movq 0x2faab(%rip), %rdi     # 0x35fe8
leaq 0x22034(%rip), %rsi     # 0x28578
movl $0xd, %edx
callq 0x4410
movq -0x160(%rbp), %rsi
movq -0x158(%rbp), %rdx
movq 0x2fa85(%rip), %rdi     # 0x35fe8
callq 0x4410
movq %rax, %rdi
callq 0x4180
leaq -0xbe0(%rbp), %rdi
leaq -0x160(%rbp), %rsi
callq 0x14df6
leaq -0xbe0(%rbp), %rdi
leaq -0x68(%rbp), %rsi
callq 0x1495a
movq 0x2fa4e(%rip), %rcx     # 0x35fe8
movq (%rcx), %rax
movq -0x18(%rax), %rax
movq $0xf, 0x8(%rcx,%rax)
movq -0x80(%rbp), %rax
shrl %eax
movq %rax, -0x80(%rbp)
movl $0x1, -0x2c(%rbp)
leaq -0xbe0(%rbp), %rbx
leaq -0xf0(%rbp), %r15
movq $0x0, -0x78(%rbp)
movq -0x100(%rbp), %r13
movl $0xa, %edx
movq 0x2fa04(%rip), %rdi     # 0x35fe8
leaq 0x21f9b(%rip), %rsi     # 0x28586
callq 0x4410
movq 0x2f9f1(%rip), %rdi     # 0x35fe8
movl -0x2c(%rbp), %esi
callq 0x4650
movq %rax, %rdi
callq 0x4180
leaq -0x68(%rbp), %rdi
movq %rbx, %rsi
callq 0x1ab0f
leaq -0x7c8(%rbp), %rdi
movq %rbx, %rsi
leaq -0xb0(%rbp), %rdx
leaq -0x8b0(%rbp), %rcx
movl -0x34(%rbp), %r8d
callq 0x22f96
movsd %xmm0, -0x188(%rbp)
movq -0x58(%rbp), %rcx
movq -0xa0(%rbp), %rax
testq %rcx, %rcx
je 0x66ab
testq %rax, %rax
je 0x6706
movq %rax, -0x58(%rbp)
movq %rcx, -0xa0(%rbp)
movups -0x50(%rbp), %xmm0
movups -0x98(%rbp), %xmm1
movups %xmm1, -0x50(%rbp)
movups %xmm0, -0x98(%rbp)
leaq -0x60(%rbp), %rcx
movq %rcx, 0x8(%rax)
movq -0xa0(%rbp), %rax
leaq -0xa8(%rbp), %rcx
movq %rcx, 0x8(%rax)
movq -0x40(%rbp), %rax
movq -0x88(%rbp), %rcx
movq %rcx, -0x40(%rbp)
movq %rax, -0x88(%rbp)
jmp 0x674d
testq %rax, %rax
je 0x674d
movl -0xa8(%rbp), %ecx
movl %ecx, -0x60(%rbp)
movq %rax, -0x58(%rbp)
movups -0x98(%rbp), %xmm0
movups %xmm0, -0x50(%rbp)
leaq -0x60(%rbp), %rcx
movq %rcx, 0x8(%rax)
movq -0x88(%rbp), %rax
movq %rax, -0x40(%rbp)
xorl %ecx, %ecx
movq %rcx, -0xa0(%rbp)
leaq -0xa8(%rbp), %rax
movq %rax, -0x98(%rbp)
movq %rax, -0x90(%rbp)
movq %rcx, -0x88(%rbp)
jmp 0x674d
movl -0x60(%rbp), %eax
movl %eax, -0xa8(%rbp)
movq %rcx, -0xa0(%rbp)
movups -0x50(%rbp), %xmm0
movups %xmm0, -0x98(%rbp)
leaq -0xa8(%rbp), %rax
movq %rax, 0x8(%rcx)
movq -0x40(%rbp), %rax
movq %rax, -0x88(%rbp)
xorl %ecx, %ecx
movq %rcx, -0x58(%rbp)
leaq -0x60(%rbp), %rax
movq %rax, -0x50(%rbp)
movq %rax, -0x48(%rbp)
movq %rcx, -0x40(%rbp)
leaq -0x68(%rbp), %rdi
movsd 0x218af(%rip), %xmm0    # 0x28008
callq 0x23160
leaq -0xb0(%rbp), %rdi
callq 0x8746
movl $0x14, %edx
movq 0x2f872(%rip), %rdi     # 0x35fe8
leaq 0x21e14(%rip), %rsi     # 0x28591
callq 0x4410
movq 0x2f85f(%rip), %rdi     # 0x35fe8
movsd -0x188(%rbp), %xmm0
callq 0x45c0
movq %rax, %rdi
callq 0x4180
movl $0x18, %edx
movq 0x2f83e(%rip), %rdi     # 0x35fe8
leaq 0x21d3b(%rip), %rsi     # 0x284ec
callq 0x4410
leaq -0x68(%rbp), %rdi
callq 0x24876
movq 0x2f822(%rip), %rdi     # 0x35fe8
movl %eax, %esi
callq 0x4650
movq %rax, %rdi
callq 0x4180
movl $0x12, %edx
movq 0x2f807(%rip), %rdi     # 0x35fe8
leaq 0x21d1d(%rip), %rsi     # 0x28505
callq 0x4410
movq -0x40(%rbp), %rsi
movq 0x2f7f0(%rip), %rdi     # 0x35fe8
callq 0x4260
movq %rax, %rdi
callq 0x4180
cmpl $0x0, -0x30(%rbp)
je 0x6827
cmpl $0x1, -0x2c(%rbp)
jne 0x6827
movq -0x40(%rbp), %rcx
movq %rcx, %rax
xorl %edx, %edx
divq -0xf8(%rbp)
subl %edx, %ecx
movq %rcx, -0x78(%rbp)
movl $0x19, %edx
movq 0x2f7b5(%rip), %rdi     # 0x35fe8
leaq 0x21d6c(%rip), %rsi     # 0x285a6
callq 0x4410
movq 0x2f7a2(%rip), %rdi     # 0x35fe8
callq 0x4180
movl $0x0, -0x1b0(%rbp)
xorl %ecx, %ecx
movq %rcx, -0x1a8(%rbp)
leaq -0x1b0(%rbp), %rax
movq %rax, -0x1a0(%rbp)
movq %rax, -0x198(%rbp)
movq %rcx, -0x190(%rbp)
movl -0x6c(%rbp), %edi
leaq -0x8b0(%rbp), %rsi
leaq -0x1b8(%rbp), %rdx
leaq -0x910(%rbp), %rcx
callq 0x25044
movl $0x14, %edx
movq 0x2f745(%rip), %rdi     # 0x35fe8
leaq 0x21d16(%rip), %rsi     # 0x285c0
callq 0x4410
movq 0x2f732(%rip), %rdi     # 0x35fe8
callq 0x4180
leaq -0x68(%rbp), %rdi
movq %rbx, %rsi
callq 0x1ab0f
movl -0xb4(%rbp), %eax
movl %eax, (%rsp)
leaq -0x7c8(%rbp), %rdi
movq %rbx, %rsi
leaq -0x8b0(%rbp), %rdx
leaq -0x68(%rbp), %rcx
leaq -0x1b8(%rbp), %r8
movl -0x34(%rbp), %r9d
callq 0x2535c
xorps %xmm0, %xmm0
movaps %xmm0, -0x120(%rbp)
movq $0x0, -0x110(%rbp)
leaq -0x1b8(%rbp), %rdi
leaq -0x120(%rbp), %rsi
movl $0x1, %edx
callq 0x1f72c
xorps %xmm0, %xmm0
movaps %xmm0, -0xf0(%rbp)
movq $0x0, -0xe0(%rbp)
movq -0x120(%rbp), %r14
cmpq -0x118(%rbp), %r14
je 0x6987
movq %r15, %rdi
movq %r14, %rsi
callq 0x75ea
movq -0xe8(%rbp), %rcx
subq -0xf0(%rbp), %rcx
movq -0x40(%rbp), %rax
sarq $0x5, %rcx
subq %rcx, %rax
xorl %edx, %edx
divq %r12
testq %rdx, %rdx
sete %al
cmpq -0x80(%rbp), %rcx
setae %cl
testb %cl, %al
jne 0x6987
addq $0x28, %r14
jmp 0x693e
movq %r15, %rdi
leaq -0x68(%rbp), %rsi
callq 0x24300
movq -0xf0(%rbp), %r14
cmpq -0xe8(%rbp), %r14
je 0x69b4
movq %rbx, %rdi
movq %r14, %rsi
callq 0x147f0
addq $0x20, %r14
jmp 0x699a
leaq -0x7c8(%rbp), %rdi
movq %rbx, %rsi
leaq -0x68(%rbp), %rdx
movl -0x34(%rbp), %ecx
movl $0x1, %r8d
callq 0x22e8c
movq %rbx, %rdi
leaq -0x68(%rbp), %rsi
callq 0x1495a
cmpl $0x0, -0x30(%rbp)
je 0x6b1e
movq -0x40(%rbp), %rax
movl -0x78(%rbp), %ecx
cmpq %rcx, %rax
seta %cl
cmpq -0x100(%rbp), %rax
setbe %al
orb %cl, %al
jne 0x6b1e
leaq -0xae8(%rbp), %rdi
callq 0x44c0
movl $0xc, %edx
leaq -0xae8(%rbp), %rdi
leaq 0x21bb1(%rip), %rsi     # 0x285d5
callq 0x4410
movq -0x40(%rbp), %rsi
leaq -0xae8(%rbp), %rdi
callq 0x4260
movl $0x3, %edx
movq %rax, %rdi
leaq 0x21b9a(%rip), %rsi     # 0x285e2
callq 0x4410
movl $0xd, %edx
movq 0x2f58f(%rip), %rdi     # 0x35fe8
leaq 0x21b86(%rip), %rsi     # 0x285e6
callq 0x4410
leaq -0xd8(%rbp), %rdi
leaq -0xae0(%rbp), %rsi
callq 0x45a0
movq -0xd8(%rbp), %rsi
movq -0xd0(%rbp), %rdx
movq 0x2f55b(%rip), %rdi     # 0x35fe8
callq 0x4410
movq %rax, %rdi
callq 0x4180
movq -0xd8(%rbp), %rdi
leaq -0xc8(%rbp), %rax
cmpq %rax, %rdi
je 0x6ab2
callq 0x4360
leaq -0xd8(%rbp), %rdi
leaq -0xae0(%rbp), %rsi
callq 0x45a0
leaq -0x68(%rbp), %rdi
leaq -0xd8(%rbp), %rsi
xorl %edx, %edx
movl $0x6, %ecx
callq 0x23d96
movq -0xd8(%rbp), %rdi
leaq -0xc8(%rbp), %rax
cmpq %rax, %rdi
je 0x6af4
callq 0x4360
movq -0x78(%rbp), %rax
subl -0x30(%rbp), %eax
movq %rax, -0x78(%rbp)
leaq -0xae8(%rbp), %rdi
movq 0x2f4ab(%rip), %rsi     # 0x35fb8
callq 0x41c0
leaq -0xa78(%rbp), %rdi
callq 0x4110
movq -0x40(%rbp), %r14
xorl %eax, %eax
cmpq %r13, %r14
seta %al
addl %eax, -0x2c(%rbp)
movq %r15, %rdi
callq 0x7636
leaq -0x120(%rbp), %rdi
callq 0x7684
leaq -0x1b8(%rbp), %rdi
callq 0x8348
cmpq %r13, %r14
ja 0x65d8
leaq -0x68(%rbp), %rdi
leaq -0x1d8(%rbp), %rsi
xorl %edx, %edx
movl $0x6, %ecx
callq 0x23d96
xorl %edi, %edi
callq 0x4430
jmp 0x6bfd
jmp 0x6b7d
jmp 0x6b9c
movq %rax, %rbx
movq -0xd8(%rbp), %rdi
leaq -0xc8(%rbp), %rax
cmpq %rax, %rdi
je 0x6b9f
callq 0x4360
jmp 0x6b9f
jmp 0x6b9c
movq %rax, %rbx
movq 0x2f412(%rip), %rsi     # 0x35fb8
leaq -0xae8(%rbp), %rdi
callq 0x41c0
leaq -0xa78(%rbp), %rdi
callq 0x4110
jmp 0x6bc9
jmp 0x6bc6
jmp 0x6bc6
jmp 0x6bc6
movq %rax, %rbx
leaq -0xf0(%rbp), %rdi
callq 0x7636
jmp 0x6bda
movq %rax, %rbx
leaq -0x120(%rbp), %rdi
callq 0x7684
jmp 0x6beb
movq %rax, %rbx
leaq -0x1b8(%rbp), %rdi
callq 0x8348
jmp 0x6c16
jmp 0x6bfd
jmp 0x6bfd
movq %rax, %rbx
jmp 0x6c16
movq %rax, %rbx
movq -0x658(%rbp), %rdi
cmpq %r14, %rdi
je 0x6c16
callq 0x4360
leaq -0x8e0(%rbp), %rdi
callq 0x8348
jmp 0x6c29
jmp 0x6c26
movq %rax, %rbx
leaq -0x910(%rbp), %rdi
callq 0x83b2
leaq -0x8b0(%rbp), %rdi
callq 0x8348
leaq -0xb0(%rbp), %rdi
callq 0x841c
leaq -0x68(%rbp), %rdi
callq 0x841c
leaq -0xbe0(%rbp), %rdi
callq 0x13c5c
jmp 0x6c67
movq %rax, %rbx
leaq -0x7c8(%rbp), %rdi
callq 0x8348
leaq -0x940(%rbp), %rdi
callq 0x8348
leaq -0x970(%rbp), %rdi
callq 0x8348
jmp 0x6cdc
jmp 0x6cd9
movq %rax, %rbx
movq -0x678(%rbp), %rdi
jmp 0x6ca7
jmp 0x6cd9
movq %rax, %rbx
movq -0x698(%rbp), %rdi
cmpq %r12, %rdi
jne 0x6cd2
jmp 0x6cdc
jmp 0x6cd9
movq %rax, %rbx
movq -0x6b8(%rbp), %rdi
cmpq %r15, %rdi
jne 0x6cd2
jmp 0x6cdc
jmp 0x6cd9
movq %rax, %rbx
movq -0x6d8(%rbp), %rdi
cmpq %r14, %rdi
je 0x6cdc
callq 0x4360
jmp 0x6cdc
movq %rax, %rbx
movq -0x1d8(%rbp), %rdi
leaq -0x1c8(%rbp), %rax
cmpq %rax, %rdi
je 0x6cf9
callq 0x4360
jmp 0x6cf9
movq %rax, %rbx
movq -0x160(%rbp), %rdi
leaq -0x150(%rbp), %rax
cmpq %rax, %rdi
je 0x6d16
callq 0x4360
jmp 0x6d16
movq %rax, %rbx
movq -0x180(%rbp), %rdi
leaq -0x170(%rbp), %rax
cmpq %rax, %rdi
je 0x6d33
callq 0x4360
jmp 0x6d33
movq %rax, %rbx
movq -0x140(%rbp), %rdi
leaq -0x130(%rbp), %rax
cmpq %rax, %rdi
jne 0x71d7
jmp 0x71e1
jmp 0x71de
movq %rax, %rbx
movq -0x6f8(%rbp), %rdi
jmp 0x6d91
jmp 0x71de
movq %rax, %rbx
movq -0x718(%rbp), %rdi
jmp 0x6d91
jmp 0x71de
movq %rax, %rbx
movq -0x738(%rbp), %rdi
jmp 0x6d91
jmp 0x71de
movq %rax, %rbx
movq -0x758(%rbp), %rdi
cmpq %r14, %rdi
jne 0x71d7
jmp 0x71e1
jmp 0x71de
jmp 0x71de
movq %rax, %rbx
movq -0x1f8(%rbp), %rdi
leaq -0x1e8(%rbp), %rax
cmpq %rax, %rdi
je 0x6dc9
callq 0x4360
jmp 0x6dc9
movq %rax, %rbx
movq -0x218(%rbp), %rdi
leaq -0x208(%rbp), %rax
cmpq %rax, %rdi
je 0x6de6
callq 0x4360
jmp 0x6de6
movq %rax, %rbx
movq -0x238(%rbp), %rdi
leaq -0x228(%rbp), %rax
cmpq %rax, %rdi
je 0x6e03
callq 0x4360
jmp 0x6e03
movq %rax, %rbx
movq -0x258(%rbp), %rdi
leaq -0x248(%rbp), %rax
cmpq %rax, %rdi
je 0x6e22
callq 0x4360
jmp 0x6e22
jmp 0x6e1f
movq %rax, %rbx
movq -0x278(%rbp), %rdi
leaq -0x268(%rbp), %rax
cmpq %rax, %rdi
je 0x6e3f
callq 0x4360
jmp 0x6e3f
movq %rax, %rbx
movq -0x298(%rbp), %rdi
leaq -0x288(%rbp), %rax
cmpq %rax, %rdi
je 0x6e5c
callq 0x4360
jmp 0x6e5c
movq %rax, %rbx
movq -0x2b8(%rbp), %rdi
leaq -0x2a8(%rbp), %rax
cmpq %rax, %rdi
je 0x6e79
callq 0x4360
jmp 0x6e79
movq %rax, %rbx
movq -0x2d8(%rbp), %rdi
leaq -0x2c8(%rbp), %rax
cmpq %rax, %rdi
je 0x6e98
callq 0x4360
jmp 0x6e98
jmp 0x6e95
movq %rax, %rbx
movq -0x2f8(%rbp), %rdi
leaq -0x2e8(%rbp), %rax
cmpq %rax, %rdi
je 0x6eb5
callq 0x4360
jmp 0x6eb5
movq %rax, %rbx
movq -0x318(%rbp), %rdi
leaq -0x308(%rbp), %rax
cmpq %rax, %rdi
je 0x6ed2
callq 0x4360
jmp 0x6ed2
movq %rax, %rbx
movq -0x338(%rbp), %rdi
leaq -0x328(%rbp), %rax
cmpq %rax, %rdi
je 0x6eef
callq 0x4360
jmp 0x6eef
movq %rax, %rbx
movq -0x358(%rbp), %rdi
leaq -0x348(%rbp), %rax
cmpq %rax, %rdi
je 0x6f0e
callq 0x4360
jmp 0x6f0e
jmp 0x6f0b
movq %rax, %rbx
movq -0x378(%rbp), %rdi
leaq -0x368(%rbp), %rax
cmpq %rax, %rdi
je 0x6f2b
callq 0x4360
jmp 0x6f2b
movq %rax, %rbx
movq -0x398(%rbp), %rdi
leaq -0x388(%rbp), %rax
cmpq %rax, %rdi
je 0x6f48
callq 0x4360
jmp 0x6f48
movq %rax, %rbx
movq -0x3b8(%rbp), %rdi
leaq -0x3a8(%rbp), %rax
cmpq %rax, %rdi
je 0x6f65
callq 0x4360
jmp 0x6f65
movq %rax, %rbx
movq -0x3d8(%rbp), %rdi
leaq -0x3c8(%rbp), %rax
cmpq %rax, %rdi
je 0x6f84
callq 0x4360
jmp 0x6f84
jmp 0x6f81
movq %rax, %rbx
movq -0x3f8(%rbp), %rdi
leaq -0x3e8(%rbp), %rax
cmpq %rax, %rdi
je 0x6fa1
callq 0x4360
jmp 0x6fa1
movq %rax, %rbx
movq -0x418(%rbp), %rdi
leaq -0x408(%rbp), %rax
cmpq %rax, %rdi
je 0x6fbe
callq 0x4360
jmp 0x6fbe
movq %rax, %rbx
movq -0x438(%rbp), %rdi
leaq -0x428(%rbp), %rax
cmpq %rax, %rdi
je 0x6fdb
callq 0x4360
jmp 0x6fdb
movq %rax, %rbx
movq -0x458(%rbp), %rdi
leaq -0x448(%rbp), %rax
cmpq %rax, %rdi
je 0x6ffa
callq 0x4360
jmp 0x6ffa
jmp 0x6ff7
movq %rax, %rbx
movq -0x478(%rbp), %rdi
leaq -0x468(%rbp), %rax
cmpq %rax, %rdi
je 0x7017
callq 0x4360
jmp 0x7017
movq %rax, %rbx
movq -0x498(%rbp), %rdi
leaq -0x488(%rbp), %rax
cmpq %rax, %rdi
je 0x7034
callq 0x4360
jmp 0x7034
movq %rax, %rbx
movq -0x4b8(%rbp), %rdi
leaq -0x4a8(%rbp), %rax
cmpq %rax, %rdi
je 0x7051
callq 0x4360
jmp 0x7051
movq %rax, %rbx
movq -0x4d8(%rbp), %rdi
leaq -0x4c8(%rbp), %rax
cmpq %rax, %rdi
je 0x7070
callq 0x4360
jmp 0x7070
jmp 0x706d
movq %rax, %rbx
movq -0x4f8(%rbp), %rdi
leaq -0x4e8(%rbp), %rax
cmpq %rax, %rdi
je 0x708d
callq 0x4360
jmp 0x708d
movq %rax, %rbx
movq -0x518(%rbp), %rdi
leaq -0x508(%rbp), %rax
cmpq %rax, %rdi
je 0x70aa
callq 0x4360
jmp 0x70aa
movq %rax, %rbx
movq -0x538(%rbp), %rdi
leaq -0x528(%rbp), %rax
cmpq %rax, %rdi
je 0x70c7
callq 0x4360
jmp 0x70c7
movq %rax, %rbx
movq -0x558(%rbp), %rdi
leaq -0x548(%rbp), %rax
cmpq %rax, %rdi
je 0x70e6
callq 0x4360
jmp 0x70e6
jmp 0x70e3
movq %rax, %rbx
movq -0x578(%rbp), %rdi
leaq -0x568(%rbp), %rax
cmpq %rax, %rdi
je 0x7103
callq 0x4360
jmp 0x7103
movq %rax, %rbx
movq -0x598(%rbp), %rdi
leaq -0x588(%rbp), %rax
cmpq %rax, %rdi
je 0x7120
callq 0x4360
jmp 0x7120
movq %rax, %rbx
movq -0x5b8(%rbp), %rdi
leaq -0x5a8(%rbp), %rax
cmpq %rax, %rdi
je 0x713d
callq 0x4360
jmp 0x713d
movq %rax, %rbx
movq -0x5d8(%rbp), %rdi
leaq -0x5c8(%rbp), %rax
cmpq %rax, %rdi
je 0x715c
callq 0x4360
jmp 0x715c
jmp 0x7159
movq %rax, %rbx
movq -0x5f8(%rbp), %rdi
leaq -0x5e8(%rbp), %rax
cmpq %rax, %rdi
je 0x7179
callq 0x4360
jmp 0x7179
movq %rax, %rbx
movq -0x618(%rbp), %rdi
leaq -0x608(%rbp), %rax
cmpq %rax, %rdi
je 0x7196
callq 0x4360
jmp 0x7196
movq %rax, %rbx
movq -0x638(%rbp), %rdi
leaq -0x628(%rbp), %rax
cmpq %rax, %rdi
je 0x71b3
callq 0x4360
jmp 0x71b3
movq %rax, %rbx
movq -0x778(%rbp), %rdi
cmpq %r13, %rdi
je 0x71cb
callq 0x4360
jmp 0x71cb
jmp 0x71c8
movq %rax, %rbx
movq -0x798(%rbp), %rdi
cmpq %r12, %rdi
je 0x71e1
callq 0x4360
jmp 0x71e1
movq %rax, %rbx
leaq -0x7e8(%rbp), %rdi
callq 0x7636
leaq -0x818(%rbp), %rdi
callq 0x84de
leaq -0x848(%rbp), %rdi
callq 0x8548
leaq -0x860(%rbp), %r14
movq %r14, %rdi
callq 0x84aa
movq -0x20(%r14), %rdi
leaq -0x870(%rbp), %rax
cmpq %rax, %rdi
je 0x7229
callq 0x4360
movq %rbx, %rdi
callq 0x4680