// File: /workspace/github_cpp_makefile_star2_O1/pgrouchy[P]NoiseWorld/master.cpp
// Function: main
int main(int argc, char* argv[]) {

    if (argc != 2) {
        cout << "Usage: EMM_SymComm [runID]" << endl;
        exit(-1);
    }

    signal(SIGTERM, term_trap);

    list<Genome*>::iterator curGenome, curGenome2;
    list<Population*>::iterator curPop;

    string myFilename;

    Population *initPop;

    int i, j, fd, intStat, bestIsl, numInSync, counter1 = 0, counter2 = 0, zipCounter = 0, bestFit = 0, era_counter = 0;
    int myInt[6], myBestInt[6];
    double myDouble[2], myBestDouble[2];
    double densityTotal = 0.0;

    int run_id = atoi(argv[1]);

    FILE *dataFile;
    struct stat stFileInfo;
    ofstream myFile;
    struct flock fl = {F_WRLCK, SEEK_SET,   0,      0,     0 };
    fl.l_pid = getpid();

    string tempString, tempString2;

    // Initialize randomizer so that different runs produce different results
    srand( (unsigned)(run_id*100000) );
    //srand ( time(NULL) );

    // make necessary directories
    for (i = 0; i < NUM_ISLANDS; i++) {
        stringstream isl_sync_dir;
        isl_sync_dir << "mkdir /dev/shm/sync_dir_" << i;
        system(isl_sync_dir.str().c_str());

        stringstream isl_sync_file;
        isl_sync_file << "touch /dev/shm/sync_dir_" << i << "/folderSync.txt";
        system(isl_sync_file.str().c_str());
    }
    stringstream data_dir_ss;
    data_dir_ss << "mkdir dataDir_" << run_id;
    system(data_dir_ss.str().c_str());

    // Start islands
    for (i = 0; i < NUM_ISLANDS; i++) {
        // Generate initial population
        initPop = new Population(i);
        stringstream isl_pop_ss;
        isl_pop_ss << "/dev/shm/initPop_" << i << ".pop";
        initPop->savePop(isl_pop_ss.str().c_str());
        delete initPop;
    }
    for (i = 0; i < NUM_SLAVES; i++) {
        // Run slaves
        stringstream isl_ss;
        isl_ss << "nice ./EMM_island " << i << " " << run_id << " &";
        system(isl_ss.str().c_str());
    }

    // we run the simulation until it is killed by the system or user
    while (true) {
        numInSync = 0;
        for (i = 0; i < NUM_SLAVES; i++) {
            stringstream ss;
            ss << "/dev/shm/fitFlag_" << i << ".txt";
            intStat = stat(ss.str().c_str(),&stFileInfo);
            if (intStat == 0) {
                numInSync++;
            } else {
                break;
            }
        }

        if (numInSync == NUM_SLAVES) {

            era_counter++;

            ofstream myFile;
            stringstream ss_gen_file;
            ss_gen_file << "dataDir_" << run_id << "/genOutput.csv";
            myFile.open(ss_gen_file.str().c_str(), ios::out | ios::app);

            myBestInt[3] = -1;

            for (i = 0; i < NUM_ISLANDS; i++) {

                stringstream sync_ss1;
                sync_ss1 << "/dev/shm/sync_dir_" << i << "/folderSync.txt";
                // set file lock
                fl.l_type = F_WRLCK;
                fd = open(sync_ss1.str().c_str(), O_RDWR);
                fcntl(fd, F_SETLKW, &fl);

                stringstream ss2;
                ss2 << "/dev/shm/currentStatus_" << i << ".txt";
                dataFile = fopen(ss2.str().c_str(), "r");
                fscanf(dataFile, "%d,%d,%d,%d,%d,%lf,%lf,%d\n", &myInt[0], &myInt[1], &myInt[2], &myInt[3], &myInt[4], &myDouble[0], &myDouble[1], &myInt[5]);
                fclose(dataFile);

                myFile << "Isl " << i << " t-step " << myInt[1] << " numBirths: " << myInt[3] << " NumMigIn: " << myInt[4] << " avgAge: " << myDouble[0] << " beta: " << myDouble[1] << " hitWall: " << myBestInt[5] << endl;

                cout << "Isl " << i << " t-step " << myInt[1] << " numBirths: " << myInt[3] << " NumMigIn: " << myInt[4] << " avgAge: " << myDouble[0] << " beta: " << myDouble[1] << " hitWall: " << myBestInt[5] << endl;

                if (myInt[3] > myBestInt[3]) {
                    bestIsl = i;
                    for (j = 0; j < 6; j++) {
                        if (j < 2) {
                            myBestDouble[j] = myDouble[j];
                        }
                        myBestInt[j] = myInt[j];
                    }
                }

                // release lock file
                fl.l_type = F_UNLCK;
                fcntl(fd, F_SETLK, &fl);
                close(fd);
                
                counter1 += myInt[3];
                counter2++;
                densityTotal += myDouble[1];
            }
            myFile.close();

            stringstream copy_best_pop;
            copy_best_pop << "cp /dev/shm/popSnapshot-" << (era_counter * ERA) << "_" << bestIsl << ".pop dataDir_" << run_id << "/curBestPop.pop";
            system(copy_best_pop.str().c_str());

            if (myBestInt[3] > bestFit) {
                bestFit = myBestInt[3];
                stringstream copy_best_pop_2;
                copy_best_pop_2 << "cp /dev/shm/popSnapshot-" << (era_counter * ERA) << "_" << bestIsl << ".pop dataDir_" << run_id << "/overallBestPop.pop";
                system(copy_best_pop_2.str().c_str());
            }

            stringstream ss_avg_file;
            ss_avg_file << "dataDir_" << run_id << "/avgPopSize.csv";
            myFile.open(ss_avg_file.str().c_str(), ios::out | ios::app);
            myFile << ((double)counter1 / (double)counter2) << "  " << (densityTotal / (double)counter2) << endl;
            myFile.close();
            counter1 = 0;
            counter2 = 0;
            densityTotal = 0.0;

            stringstream do_zip;
            do_zip << "/dev/shm/zip_time_flag.txt";
            intStat = stat(do_zip.str().c_str(),&stFileInfo);
            if (intStat == 0) {
                stringstream zip_ss;
                if (zipCounter == 0) {
                    zip_ss << "zip -q -j dataDir_" << run_id << "/popSnapshots_" << zipCounter << ".zip /dev/shm/initPop_* /dev/shm/popSnapshot* /dev/shm/mig*.pop";
                } else {
                    zip_ss << "zip -q -j dataDir_" << run_id << "/popSnapshots_" << zipCounter << ".zip /dev/shm/popSnapshot* /dev/shm/mig*.pop";
                }
                system(zip_ss.str().c_str());

                stringstream zip_rm;
                zip_rm << "rm /dev/shm/popSnapshot*";
                system(zip_rm.str().c_str());

                if (zipCounter == 0) {
                    stringstream del_ss;
                    del_ss << "rm /dev/shm/initPop_*";
                    system(del_ss.str().c_str());
                }

                zipCounter++;
                stringstream rm_zip;
                rm_zip << "rm /dev/shm/zip_time_flag.txt";
                system(rm_zip.str().c_str());
            }


            for (i = 0; i < NUM_SLAVES; i++) {
                stringstream ss;
                ss << "rm /dev/shm/fitFlag_" << i << ".txt";
                system(ss.str().c_str());
            }
        }
        numInSync = 0;
        for (i = 0; i < NUM_SLAVES; i++) {
            stringstream ss;
            ss << "/dev/shm/syncFlag_" << i << ".txt";
            intStat = stat(ss.str().c_str(),&stFileInfo);
            if (intStat == 0) {
                numInSync++;
            } else {
                break;
            }
        }
        if (numInSync == NUM_SLAVES) {
            for (i = 0; i < NUM_SLAVES; i++) {
                stringstream ss;
                ss << "rm /dev/shm/syncFlag_" << i << ".txt";
                system(ss.str().c_str());
            }
        }
        usleep(100000);
    }

    return(0);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1238, %rsp           # imm = 0x1238
cmpl $0x2, %edi
jne 0x3bc5
movq %rsi, %rbx
leaq -0x1cf(%rip), %rsi      # 0x24ec
movl $0xf, %edi
callq 0x2250
leaq 0x2e0(%rsp), %rax
movq %rax, -0x10(%rax)
movq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movq 0x8(%rbx), %rdi
callq 0x22e0
movl %eax, %ebx
leaq 0x1038(%rsp), %rdi
callq 0x2320
movups 0x7cad(%rip), %xmm0     # 0xa3a8
movaps %xmm0, 0xd0(%rsp)
movupd 0x7c8d(%rip), %xmm0     # 0xa398
movapd %xmm0, 0xc0(%rsp)
callq 0x22b0
movl %eax, 0xd8(%rsp)
leaq 0x2c0(%rsp), %rax
movq %rax, -0x10(%rax)
xorl %r15d, %r15d
movq %r15, -0x8(%rax)
movb %r15b, (%rax)
leaq 0x2a0(%rsp), %rax
movq %rax, -0x10(%rax)
movq %r15, -0x8(%rax)
movb %r15b, (%rax)
movl %ebx, (%rsp)
imull $0x186a0, %ebx, %edi    # imm = 0x186A0
callq 0x21c0
movl $0x80, %ebp
leaq 0xe20(%rsp), %r13
movq %r13, %rax
addq %rbp, %rax
movq %rax, 0x8(%rsp)
leaq 0x2f0(%rsp), %r14
addq %r14, %rbp
movq 0xb837(%rip), %r12      # 0xdfb8
movq %r14, %rdi
callq 0x2100
movl $0x18, %edx
leaq 0x300(%rsp), %rbx
movq %rbx, %rdi
leaq 0x7963(%rip), %rsi      # 0xa103
callq 0x2230
movq %rbx, %rdi
movl %r15d, %esi
callq 0x2330
movq %r13, %rdi
leaq 0x308(%rsp), %rsi
callq 0x22f0
movq 0xe20(%rsp), %rdi
callq 0x2190
movq 0xe20(%rsp), %rdi
leaq 0xe30(%rsp), %rax
cmpq %rax, %rdi
je 0x27f2
movq 0xe30(%rsp), %rsi
incq %rsi
callq 0x2210
movq %r13, %rdi
callq 0x2100
movl $0x18, %edx
leaq 0xe30(%rsp), %rdi
leaq 0x790e(%rip), %rsi      # 0xa11c
callq 0x2230
leaq 0xe30(%rsp), %rdi
movl %r15d, %esi
callq 0x2330
movl $0xf, %edx
movq %rax, %rdi
leaq 0x7903(%rip), %rsi      # 0xa135
callq 0x2230
leaq 0x108(%rsp), %rdi
leaq 0xe38(%rsp), %rsi
callq 0x22f0
movq 0x108(%rsp), %rdi
callq 0x2190
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x287e
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x2210
movq %r13, %rdi
movq %r12, %rsi
callq 0x2130
movq 0x8(%rsp), %rdi
callq 0x2090
movq %r14, %rdi
movq %r12, %rsi
callq 0x2130
movq %rbp, %rdi
callq 0x2090
incl %r15d
cmpl $0x64, %r15d
jne 0x2781
leaq 0xe20(%rsp), %rdi
callq 0x2100
leaq 0xe30(%rsp), %rbx
leaq 0x7876(%rip), %rsi      # 0xa145
movl $0xe, %edx
movq %rbx, %rdi
callq 0x2230
movl (%rsp), %esi
movq %rbx, %rdi
callq 0x2330
leaq 0xe38(%rsp), %rsi
leaq 0x2f0(%rsp), %rdi
callq 0x22f0
movq 0x2f0(%rsp), %rdi
callq 0x2190
movq 0x2f0(%rsp), %rdi
leaq 0x300(%rsp), %rax
cmpq %rax, %rdi
je 0x292e
movq 0x300(%rsp), %rsi
incq %rsi
callq 0x2210
leaq 0x300(%rsp), %rbx
xorl %ebp, %ebp
leaq 0x2f0(%rsp), %r13
leaq 0xe8(%rsp), %r14
movq 0xb669(%rip), %r15      # 0xdfb8
movl $0x50, %edi
callq 0x2200
movq %rax, %r12
movq %rax, %rdi
movl %ebp, %esi
callq 0x424e
movq %r13, %rdi
callq 0x2100
movl $0x11, %edx
movq %rbx, %rdi
leaq 0x77d7(%rip), %rsi      # 0xa154
callq 0x2230
movq %rbx, %rdi
movl %ebp, %esi
callq 0x2330
movl $0x4, %edx
movq %rax, %rdi
leaq 0x7924(%rip), %rsi      # 0xa2bf
callq 0x2230
leaq 0x108(%rsp), %rdi
leaq 0x308(%rsp), %rsi
callq 0x22f0
movq 0x108(%rsp), %rsi
movq %r14, %rdi
leaq 0xc98(%rsp), %rdx
callq 0x43ea
movq %r12, %rdi
movq %r14, %rsi
callq 0x5908
movq 0xe8(%rsp), %rdi
leaq 0xf8(%rsp), %rax
cmpq %rax, %rdi
je 0x29fd
movq 0xf8(%rsp), %rsi
incq %rsi
callq 0x2210
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x2a22
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x2210
movq %r12, %rdi
callq 0x4428
movl $0x50, %esi
movq %r12, %rdi
callq 0x2210
movq %r13, %rdi
movq %r15, %rsi
callq 0x2130
leaq 0x370(%rsp), %rdi
callq 0x2090
incl %ebp
cmpl $0x64, %ebp
jne 0x294f
leaq 0x300(%rsp), %rbx
xorl %ebp, %ebp
leaq 0x2f0(%rsp), %r12
leaq 0x77ed(%rip), %r15      # 0xa260
leaq 0x76ff(%rip), %r14      # 0xa179
movq 0xb537(%rip), %r13      # 0xdfb8
movq %r12, %rdi
callq 0x2100
movl $0x12, %edx
movq %rbx, %rdi
leaq 0x76ce(%rip), %rsi      # 0xa166
callq 0x2230
movq %rbx, %rdi
movl %ebp, %esi
callq 0x2330
movq %rax, %r12
movl $0x1, %edx
movq %rax, %rdi
movq %r15, %rsi
callq 0x2230
movq %r12, %rdi
movl (%rsp), %esi
callq 0x2330
movl $0x2, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x2230
leaq 0x108(%rsp), %rdi
leaq 0x308(%rsp), %rsi
callq 0x22f0
movq 0x108(%rsp), %rdi
callq 0x2190
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x2b1c
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x2210
leaq 0x2f0(%rsp), %r12
movq %r12, %rdi
movq %r13, %rsi
callq 0x2130
leaq 0x370(%rsp), %rdi
callq 0x2090
incl %ebp
cmpl $0x14, %ebp
jne 0x2a81
movl $0x80, %ecx
leaq (%r12,%rcx), %rax
movq %rax, 0x8(%rsp)
leaq 0x4f0(%rsp), %rax
addq %rcx, %rax
movq %rax, 0x40(%rsp)
leaq 0xc98(%rsp), %r13
leaq (%r13,%rcx), %rax
movq %rax, 0x90(%rsp)
leaq 0xb10(%rsp), %rax
leaq (%rax,%rcx), %rax
movq %rax, 0x80(%rsp)
leaq 0x800(%rsp), %rax
addq %rcx, %rax
movq %rax, 0x98(%rsp)
leaq 0x988(%rsp), %rax
addq %rcx, %rax
movq %rax, 0x88(%rsp)
leaq 0x678(%rsp), %rax
addq %rcx, %rax
movq %rax, 0xb0(%rsp)
leaq 0x108(%rsp), %rax
addq %rax, %rcx
movq %rcx, 0xb8(%rsp)
movq 0xb3ef(%rip), %rax      # 0xdfd0
movq (%rax), %rcx
movq %rcx, 0xa8(%rsp)
movq 0x18(%rax), %rax
movq %rax, 0xa0(%rsp)
movl $0x0, 0x4(%rsp)
movl $0x0, 0x10(%rsp)
movl $0x0, 0x14(%rsp)
xorl %ebx, %ebx
xorl %r14d, %r14d
leaq 0x2f0(%rsp), %rdi
callq 0x2100
movl $0x11, %edx
leaq 0x300(%rsp), %rdi
leaq 0x770b(%rip), %rsi      # 0xa341
callq 0x2230
leaq 0x300(%rsp), %rdi
movl %ebx, %esi
callq 0x2330
movl $0x4, %edx
movq %rax, %rdi
leaq 0x74e7(%rip), %rsi      # 0xa140
callq 0x2230
leaq 0x108(%rsp), %rdi
leaq 0x308(%rsp), %rsi
callq 0x22f0
movq 0x108(%rsp), %rdi
leaq 0xfa8(%rsp), %rsi
callq 0x21b0
movl %eax, %ebp
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x2caf
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x2210
xorl %eax, %eax
testl %ebp, %ebp
sete %al
addl %eax, %r14d
leaq 0x2f0(%rsp), %rdi
movq 0xb2f0(%rip), %rsi      # 0xdfb8
callq 0x2130
movq 0x8(%rsp), %rdi
callq 0x2090
testl %ebp, %ebp
jne 0x2ce9
leal 0x1(%rbx), %eax
cmpl $0x13, %ebx
movl %eax, %ebx
jb 0x2c15
cmpl $0x14, %r14d
jne 0x3a12
leaq 0x2f0(%rsp), %rdi
callq 0x2320
movl (%rsp), %ebx
leaq 0x108(%rsp), %rdi
callq 0x2100
movl $0x8, %edx
leaq 0x118(%rsp), %rdi
leaq 0x7548(%rip), %rsi      # 0xa26c
callq 0x2230
leaq 0x118(%rsp), %rdi
movl %ebx, %esi
callq 0x2330
movl $0xe, %edx
movq %rax, %rdi
leaq 0x7435(%rip), %rsi      # 0xa17c
callq 0x2230
movq %r13, %rdi
leaq 0x120(%rsp), %rsi
callq 0x22f0
leaq 0x2f0(%rsp), %rdi
movq 0xc98(%rsp), %rsi
movl $0x11, %edx
callq 0x2050
movq 0xc98(%rsp), %rdi
leaq 0xca8(%rsp), %rax
cmpq %rax, %rdi
je 0x2d9b
movq 0xca8(%rsp), %rsi
incq %rsi
callq 0x2210
incl 0x14(%rsp)
xorpd %xmm0, %xmm0
movsd %xmm0, 0x48(%rsp)
xorl %r13d, %r13d
movl $0xffffffff, %r15d      # imm = 0xFFFFFFFF
xorl %r12d, %r12d
leaq 0xc98(%rsp), %rbx
movq %rbx, %rdi
callq 0x2100
movl $0x12, %edx
leaq 0xca8(%rsp), %rdi
leaq 0x7349(%rip), %rsi      # 0xa122
callq 0x2230
leaq 0x73db(%rip), %r14      # 0xa1c0
leaq 0xca8(%rsp), %rdi
movl %r13d, %esi
callq 0x2330
movl $0xf, %edx
movq %rax, %rdi
leaq 0x7331(%rip), %rsi      # 0xa135
callq 0x2230
movw $0x1, 0xc0(%rsp)
leaq 0x4f0(%rsp), %rdi
leaq 0xcb0(%rsp), %rsi
callq 0x22f0
movq 0x4f0(%rsp), %rdi
movl $0x2, %esi
xorl %eax, %eax
callq 0x2120
movl %eax, %ebp
movq 0x4f0(%rsp), %rdi
leaq 0x500(%rsp), %rax
cmpq %rax, %rdi
je 0x2e63
movq 0x500(%rsp), %rsi
incq %rsi
callq 0x2210
movl %ebp, %edi
movl $0x7, %esi
leaq 0xc0(%rsp), %rdx
xorl %eax, %eax
callq 0x20e0
leaq 0x4f0(%rsp), %rdi
callq 0x2100
movl $0x17, %edx
leaq 0x500(%rsp), %rdi
leaq 0x72f1(%rip), %rsi      # 0xa18b
callq 0x2230
leaq 0x500(%rsp), %rdi
movl %r13d, %esi
callq 0x2330
movl $0x4, %edx
movq %rax, %rdi
leaq 0x7282(%rip), %rsi      # 0xa140
callq 0x2230
leaq 0x678(%rsp), %rdi
leaq 0x508(%rsp), %rsi
callq 0x22f0
movq 0x678(%rsp), %rdi
leaq 0x72bc(%rip), %rsi      # 0xa1a3
callq 0x2240
movq %rax, %rbx
movq 0x678(%rsp), %rdi
leaq 0x688(%rsp), %rax
cmpq %rax, %rdi
je 0x2f14
movq 0x688(%rsp), %rsi
incq %rsi
callq 0x2210
movq %rbx, %rdi
leaq 0x7287(%rip), %rsi      # 0xa1a5
leaq 0x20(%rsp), %rdx
leaq 0x24(%rsp), %rcx
leaq 0x28(%rsp), %r8
leaq 0x2c(%rsp), %r9
xorl %eax, %eax
leaq 0x34(%rsp), %r10
pushq %r10
leaq 0x80(%rsp), %r10
pushq %r10
leaq 0x80(%rsp), %r10
pushq %r10
leaq 0x48(%rsp), %r10
pushq %r10
callq 0x2360
addq $0x20, %rsp
movq %rbx, %rdi
callq 0x21f0
movl $0x4, %edx
leaq 0x2f0(%rsp), %rdi
movq %r14, %rsi
callq 0x2230
leaq 0x2f0(%rsp), %rdi
movl %r13d, %esi
callq 0x2330
movq %rax, %rbx
movl $0x8, %edx
movq %rax, %rdi
leaq 0x7227(%rip), %rsi      # 0xa1c5
callq 0x2230
movl 0x24(%rsp), %esi
movq %rbx, %rdi
callq 0x2330
movq %rax, %rbx
movl $0xc, %edx
movq %rax, %rdi
leaq 0x720d(%rip), %rsi      # 0xa1ce
callq 0x2230
movl 0x2c(%rsp), %esi
movq %rbx, %rdi
callq 0x2330
movq %rax, %rbx
movl $0xb, %edx
movq %rax, %rdi
leaq 0x71f7(%rip), %rsi      # 0xa1db
callq 0x2230
movl 0x30(%rsp), %esi
movq %rbx, %rdi
callq 0x2330
movq %rax, %rbx
movl $0x9, %edx
movq %rax, %rdi
leaq 0x71e0(%rip), %rsi      # 0xa1e7
callq 0x2230
movsd 0x70(%rsp), %xmm0
movq %rbx, %rdi
callq 0x2300
movq %rax, %rbx
movl $0x7, %edx
movq %rax, %rdi
leaq 0x71c5(%rip), %rsi      # 0xa1f1
callq 0x2230
movsd 0x78(%rsp), %xmm0
movq %rbx, %rdi
callq 0x2300
movq %rax, %rbx
movl $0xa, %edx
movq %rax, %rdi
leaq 0x71a8(%rip), %rsi      # 0xa1f9
callq 0x2230
movq %rbx, %rdi
movl 0x1c(%rsp), %esi
callq 0x2330
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x20f0
movl $0x4, %edx
movq 0xaf40(%rip), %rdi      # 0xdfd8
movq %r14, %rsi
callq 0x2230
movq 0xaf31(%rip), %rdi      # 0xdfd8
movl %r13d, %esi
callq 0x2330
movq %rax, %rbx
movl $0x8, %edx
movq %rax, %rdi
leaq 0x7104(%rip), %rsi      # 0xa1c5
callq 0x2230
movl 0x24(%rsp), %esi
movq %rbx, %rdi
callq 0x2330
movq %rax, %rbx
movl $0xc, %edx
movq %rax, %rdi
leaq 0x70ea(%rip), %rsi      # 0xa1ce
callq 0x2230
movl 0x2c(%rsp), %esi
movq %rbx, %rdi
callq 0x2330
movq %rax, %rbx
movl $0xb, %edx
movq %rax, %rdi
leaq 0x70d4(%rip), %rsi      # 0xa1db
callq 0x2230
movl 0x30(%rsp), %esi
movq %rbx, %rdi
callq 0x2330
movq %rax, %rbx
movl $0x9, %edx
movq %rax, %rdi
leaq 0x70bd(%rip), %rsi      # 0xa1e7
callq 0x2230
movsd 0x70(%rsp), %xmm0
movq %rbx, %rdi
callq 0x2300
movq %rax, %rbx
movl $0x7, %edx
movq %rax, %rdi
leaq 0x70a2(%rip), %rsi      # 0xa1f1
callq 0x2230
movsd 0x78(%rsp), %xmm0
movq %rbx, %rdi
callq 0x2300
movq %rax, %rbx
movl $0xa, %edx
movq %rax, %rdi
leaq 0x7085(%rip), %rsi      # 0xa1f9
callq 0x2230
movq %rbx, %rdi
movl 0x1c(%rsp), %esi
callq 0x2330
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x20f0
movl 0x2c(%rsp), %eax
cmpl %r15d, %eax
jle 0x31c8
movl 0x34(%rsp), %ecx
movl %ecx, 0x1c(%rsp)
movl %eax, %r15d
movl %r13d, 0x18(%rsp)
movw $0x2, 0xc0(%rsp)
movl %ebp, %edi
movl $0x6, %esi
leaq 0xc0(%rsp), %rdx
xorl %eax, %eax
callq 0x20e0
movl %ebp, %edi
callq 0x2390
addl 0x2c(%rsp), %r12d
incl %r13d
movsd 0x48(%rsp), %xmm0
addsd 0x78(%rsp), %xmm0
movsd %xmm0, 0x48(%rsp)
leaq 0x4f0(%rsp), %rdi
movq 0xada0(%rip), %r14      # 0xdfb8
movq %r14, %rsi
callq 0x2130
movq 0x40(%rsp), %rdi
callq 0x2090
leaq 0xc98(%rsp), %rbx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x2130
movq 0x90(%rsp), %rdi
callq 0x2090
cmpl $0x64, %r13d
jne 0x2dbd
leaq 0x2f0(%rsp), %rdi
callq 0x22a0
movq %rbx, %r13
movq %rbx, %rdi
callq 0x2100
movl $0x18, %edx
leaq 0xca8(%rsp), %rdi
leaq 0x6f84(%rip), %rsi      # 0xa204
callq 0x2230
imull $0x186a0, 0x14(%rsp), %ebx # imm = 0x186A0
leaq 0xca8(%rsp), %rdi
movl %ebx, %esi
callq 0x2330
movq %rax, %r14
movl $0x1, %edx
movq %rax, %rdi
leaq 0x70b9(%rip), %rsi      # 0xa367
callq 0x2230
movq %r14, %rdi
movl 0x18(%rsp), %esi
callq 0x2330
movq %rax, %r14
movl $0xd, %edx
movq %rax, %rdi
leaq 0x6f4c(%rip), %rsi      # 0xa21d
callq 0x2230
movq %r14, %rdi
movl (%rsp), %esi
callq 0x2330
movl $0xf, %edx
movq %rax, %rdi
leaq 0x6f3b(%rip), %rsi      # 0xa22b
callq 0x2230
leaq 0x4f0(%rsp), %rdi
leaq 0xcb0(%rsp), %rsi
callq 0x22f0
movq 0x4f0(%rsp), %rdi
callq 0x2190
movl (%rsp), %ebp
movq 0x4f0(%rsp), %rdi
leaq 0x500(%rsp), %rax
cmpq %rax, %rdi
je 0x333f
movq 0x500(%rsp), %rsi
incq %rsi
callq 0x2210
cmpl 0x10(%rsp), %r15d
jle 0x3441
leaq 0x4f0(%rsp), %rdi
callq 0x2100
movl $0x18, %edx
leaq 0x500(%rsp), %rdi
leaq 0x6e99(%rip), %rsi      # 0xa204
callq 0x2230
leaq 0x500(%rsp), %rdi
movl %ebx, %esi
callq 0x2330
movq %rax, %rbx
movl $0x1, %edx
movq %rax, %rdi
leaq 0x6fd6(%rip), %rsi      # 0xa367
callq 0x2230
movq %rbx, %rdi
movl 0x18(%rsp), %esi
callq 0x2330
movq %rax, %rbx
movl $0xd, %edx
movq %rax, %rdi
leaq 0x6e69(%rip), %rsi      # 0xa21d
callq 0x2230
movq %rbx, %rdi
movl %ebp, %esi
callq 0x2330
movl $0x13, %edx
movq %rax, %rdi
leaq 0x6e69(%rip), %rsi      # 0xa23b
callq 0x2230
leaq 0x678(%rsp), %rdi
leaq 0x508(%rsp), %rsi
callq 0x22f0
movq 0x678(%rsp), %rdi
callq 0x2190
movq 0x678(%rsp), %rdi
leaq 0x688(%rsp), %rax
cmpq %rax, %rdi
je 0x341e
movq 0x688(%rsp), %rsi
incq %rsi
callq 0x2210
leaq 0x4f0(%rsp), %rdi
movq 0xab8b(%rip), %rsi      # 0xdfb8
callq 0x2130
movq 0x40(%rsp), %rdi
callq 0x2090
movl %r15d, 0x10(%rsp)
leaq 0x4f0(%rsp), %rdi
callq 0x2100
movl $0x8, %edx
leaq 0x500(%rsp), %rdi
leaq 0x6e0a(%rip), %rsi      # 0xa26c
callq 0x2230
leaq 0x500(%rsp), %rdi
movl %ebp, %esi
callq 0x2330
movl $0xf, %edx
movq %rax, %rdi
leaq 0x6dca(%rip), %rsi      # 0xa24f
callq 0x2230
leaq 0x678(%rsp), %rdi
leaq 0x508(%rsp), %rsi
callq 0x22f0
movq 0x678(%rsp), %rsi
leaq 0x2f0(%rsp), %rbx
movq %rbx, %rdi
movl $0x11, %edx
callq 0x2050
movq 0x678(%rsp), %rdi
leaq 0x688(%rsp), %rax
cmpq %rax, %rdi
je 0x34e1
movq 0x688(%rsp), %rsi
incq %rsi
callq 0x2210
cvtsi2sd %r12d, %xmm0
divsd 0x6b1a(%rip), %xmm0     # 0xa008
movq %rbx, %rdi
callq 0x2300
movq %rax, %rbx
movl $0x2, %edx
movq %rax, %rdi
leaq 0x6d57(%rip), %rsi      # 0xa25f
callq 0x2230
movsd 0x48(%rsp), %xmm0
divsd 0x6aed(%rip), %xmm0     # 0xa008
movq %rbx, %rdi
callq 0x2300
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x21d0
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2040
movq %rax, %rdi
callq 0x20f0
leaq 0x2f0(%rsp), %rdi
callq 0x22a0
leaq 0x678(%rsp), %rdi
callq 0x2100
movl $0x1a, %edx
leaq 0x688(%rsp), %rdi
leaq 0x6da8(%rip), %rsi      # 0xa323
callq 0x2230
leaq 0x988(%rsp), %rdi
leaq 0x690(%rsp), %rsi
callq 0x22f0
movq 0x988(%rsp), %rdi
leaq 0xfa8(%rsp), %rsi
callq 0x21b0
movl %eax, %ebx
movq 0x988(%rsp), %rdi
leaq 0x998(%rsp), %rax
cmpq %rax, %rdi
je 0x35d1
movq 0x998(%rsp), %rsi
incq %rsi
callq 0x2210
testl %ebx, %ebx
jne 0x389d
leaq 0x988(%rsp), %rdi
callq 0x2100
cmpl $0x0, 0x4(%rsp)
je 0x3646
movl $0x12, %edx
leaq 0x998(%rsp), %rdi
leaq 0x6c61(%rip), %rsi      # 0xa262
callq 0x2230
leaq 0x998(%rsp), %rdi
movl %ebp, %esi
callq 0x2330
movq %rax, %rbx
movl $0xe, %edx
movq %rax, %rdi
leaq 0x6c4e(%rip), %rsi      # 0xa275
callq 0x2230
movq %rbx, %rdi
movl 0x4(%rsp), %esi
callq 0x2330
movl $0x2c, %edx
leaq 0x6c80(%rip), %rsi      # 0xa2c4
jmp 0x369b
movl $0x12, %edx
leaq 0x998(%rsp), %rdi
leaq 0x6c08(%rip), %rsi      # 0xa262
callq 0x2230
leaq 0x998(%rsp), %rdi
movl %ebp, %esi
callq 0x2330
movq %rax, %rbx
movl $0xe, %edx
movq %rax, %rdi
leaq 0x6bf5(%rip), %rsi      # 0xa275
callq 0x2230
movq %rbx, %rdi
xorl %esi, %esi
callq 0x2330
movl $0x3f, %edx
leaq 0x6be9(%rip), %rsi      # 0xa284
movq %rax, %rdi
callq 0x2230
leaq 0x800(%rsp), %rdi
leaq 0x9a0(%rsp), %rsi
callq 0x22f0
movq 0x800(%rsp), %rdi
callq 0x2190
movq 0x800(%rsp), %rdi
leaq 0x810(%rsp), %rax
cmpq %rax, %rdi
je 0x36ea
movq 0x810(%rsp), %rsi
incq %rsi
callq 0x2210
leaq 0x800(%rsp), %rdi
callq 0x2100
movl $0x18, %edx
leaq 0x810(%rsp), %rdi
leaq 0x6be6(%rip), %rsi      # 0xa2f1
callq 0x2230
leaq 0xb10(%rsp), %rdi
leaq 0x818(%rsp), %rsi
callq 0x22f0
movq 0xb10(%rsp), %rdi
callq 0x2190
movq 0xb10(%rsp), %rdi
leaq 0xb20(%rsp), %rax
cmpq %rax, %rdi
je 0x3757
movq 0xb20(%rsp), %rsi
incq %rsi
callq 0x2210
cmpl $0x0, 0x4(%rsp)
jne 0x37dd
leaq 0xb10(%rsp), %rdi
callq 0x2100
movl $0x15, %edx
leaq 0xb20(%rsp), %rdi
leaq 0x6b8b(%rip), %rsi      # 0xa30a
callq 0x2230
leaq 0x50(%rsp), %rdi
leaq 0xb28(%rsp), %rsi
callq 0x22f0
movq 0x50(%rsp), %rdi
callq 0x2190
movq 0x50(%rsp), %rdi
leaq 0x60(%rsp), %rax
cmpq %rax, %rdi
je 0x37bc
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x2210
leaq 0xb10(%rsp), %rdi
movq 0xa7ed(%rip), %rsi      # 0xdfb8
callq 0x2130
movq 0x80(%rsp), %rdi
callq 0x2090
leaq 0xb10(%rsp), %rdi
callq 0x2100
movl $0x1d, %edx
leaq 0xb20(%rsp), %rdi
leaq 0x6b22(%rip), %rsi      # 0xa320
callq 0x2230
leaq 0x50(%rsp), %rdi
leaq 0xb28(%rsp), %rsi
callq 0x22f0
movq 0x50(%rsp), %rdi
callq 0x2190
movq 0x50(%rsp), %rdi
leaq 0x60(%rsp), %rax
cmpq %rax, %rdi
je 0x383b
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x2210
incl 0x4(%rsp)
leaq 0xb10(%rsp), %rdi
movq 0xa76a(%rip), %rbx      # 0xdfb8
movq %rbx, %rsi
callq 0x2130
movq 0x80(%rsp), %rdi
callq 0x2090
leaq 0x800(%rsp), %rdi
movq %rbx, %rsi
callq 0x2130
movq 0x98(%rsp), %rdi
callq 0x2090
leaq 0x988(%rsp), %rdi
movq %rbx, %rsi
callq 0x2130
movq 0x88(%rsp), %rdi
callq 0x2090
xorl %ebx, %ebx
leaq 0x988(%rsp), %r14
movq %r14, %rdi
callq 0x2100
movl $0x14, %edx
leaq 0x998(%rsp), %rdi
leaq 0x6a7b(%rip), %rsi      # 0xa33e
callq 0x2230
leaq 0x998(%rsp), %rdi
movl %ebx, %esi
callq 0x2330
movl $0x4, %edx
movq %rax, %rdi
leaq 0x685a(%rip), %rsi      # 0xa140
callq 0x2230
leaq 0x800(%rsp), %rdi
leaq 0x9a0(%rsp), %rsi
callq 0x22f0
movq 0x800(%rsp), %rdi
callq 0x2190
movq 0x800(%rsp), %rdi
leaq 0x810(%rsp), %rax
cmpq %rax, %rdi
je 0x3932
movq 0x810(%rsp), %rsi
incq %rsi
callq 0x2210
leaq 0x988(%rsp), %r14
movq %r14, %rdi
movq 0xa674(%rip), %rsi      # 0xdfb8
callq 0x2130
movq 0x88(%rsp), %rdi
callq 0x2090
incl %ebx
cmpl $0x14, %ebx
jne 0x38a7
leaq 0x678(%rsp), %rdi
movq 0xa648(%rip), %rbx      # 0xdfb8
movq %rbx, %rsi
callq 0x2130
movq 0xb0(%rsp), %rdi
callq 0x2090
leaq 0x4f0(%rsp), %rdi
movq %rbx, %rsi
callq 0x2130
movq 0x40(%rsp), %rdi
callq 0x2090
movq %r13, %rdi
movq %rbx, %rsi
callq 0x2130
movq 0x90(%rsp), %rdi
callq 0x2090
leaq 0x108(%rsp), %rdi
movq %rbx, %rsi
callq 0x2130
movq 0xb8(%rsp), %rdi
callq 0x2090
movq 0xa8(%rsp), %rax
movq %rax, 0x2f0(%rsp)
movq -0x18(%rax), %rax
movq 0xa0(%rsp), %rcx
movq %rcx, 0x2f0(%rsp,%rax)
leaq 0x2f8(%rsp), %rdi
callq 0x2180
leaq 0x3e8(%rsp), %rdi
callq 0x2090
xorl %ebx, %ebx
xorl %r14d, %r14d
leaq 0x2f0(%rsp), %rdi
callq 0x2100
movl $0x12, %edx
leaq 0x300(%rsp), %rdi
leaq 0x691e(%rip), %rsi      # 0xa356
callq 0x2230
leaq 0x300(%rsp), %rdi
movl %ebx, %esi
callq 0x2330
movl $0x4, %edx
movq %rax, %rdi
leaq 0x66e5(%rip), %rsi      # 0xa140
callq 0x2230
leaq 0x108(%rsp), %rdi
leaq 0x308(%rsp), %rsi
callq 0x22f0
movq 0x108(%rsp), %rdi
leaq 0xfa8(%rsp), %rsi
callq 0x21b0
movl %eax, %ebp
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x3ab1
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x2210
xorl %eax, %eax
testl %ebp, %ebp
sete %al
addl %eax, %r14d
leaq 0x2f0(%rsp), %rdi
movq 0xa4ee(%rip), %rsi      # 0xdfb8
callq 0x2130
movq 0x8(%rsp), %rdi
callq 0x2090
testl %ebp, %ebp
jne 0x3aeb
leal 0x1(%rbx), %eax
cmpl $0x13, %ebx
movl %eax, %ebx
jb 0x3a17
cmpl $0x14, %r14d
leaq 0x2f0(%rsp), %r14
jne 0x3bb6
xorl %ebx, %ebx
movq %r14, %rdi
callq 0x2100
movl $0x15, %edx
leaq 0x300(%rsp), %rdi
leaq 0x6838(%rip), %rsi      # 0xa353
callq 0x2230
leaq 0x300(%rsp), %rdi
movl %ebx, %esi
callq 0x2330
movl $0x4, %edx
movq %rax, %rdi
leaq 0x6602(%rip), %rsi      # 0xa140
callq 0x2230
leaq 0x108(%rsp), %rdi
leaq 0x308(%rsp), %rsi
callq 0x22f0
movq 0x108(%rsp), %rdi
callq 0x2190
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x3b8a
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x2210
leaq 0x2f0(%rsp), %r14
movq %r14, %rdi
movq 0xa41c(%rip), %rsi      # 0xdfb8
callq 0x2130
movq 0x8(%rsp), %rdi
callq 0x2090
incl %ebx
cmpl $0x14, %ebx
jne 0x3aff
movl $0x186a0, %edi          # imm = 0x186A0
callq 0x2290
jmp 0x2c10
movq 0xa40c(%rip), %rdi      # 0xdfd8
leaq 0x6515(%rip), %rsi      # 0xa0e8
callq 0x21e0
movq %rax, %rdi
callq 0x20b0
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
callq 0x2260
movq %rax, %rbx
movq 0x50(%rsp), %rdi
leaq 0x60(%rsp), %rax
cmpq %rax, %rdi
je 0x3c09
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x3c3a
jmp 0x3c0d
movq %rax, %rbx
jmp 0x3c3a
jmp 0x3c8b
movq %rax, %rbx
movq 0x50(%rsp), %rdi
leaq 0x60(%rsp), %rax
cmpq %rax, %rdi
je 0x3c3a
movq 0x60(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x3c3a
jmp 0x3c37
movq %rax, %rbx
movq 0xa377(%rip), %rsi      # 0xdfb8
leaq 0xb10(%rsp), %rdi
callq 0x2130
leaq 0xb90(%rsp), %rdi
callq 0x2090
jmp 0x3c8e
jmp 0x3c8b
movq %rax, %rbx
movq 0xb10(%rsp), %rdi
leaq 0xb20(%rsp), %rax
cmpq %rax, %rdi
je 0x3c8e
movq 0xb20(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x3c8e
jmp 0x3c8b
movq %rax, %rbx
movq 0xa323(%rip), %rsi      # 0xdfb8
leaq 0x800(%rsp), %rdi
callq 0x2130
leaq 0x880(%rsp), %rdi
callq 0x2090
jmp 0x3df3
jmp 0x3df0
movq %rax, %rbx
movq 0x800(%rsp), %rdi
leaq 0x810(%rsp), %rax
cmpq %rax, %rdi
je 0x3df3
movq 0x810(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x3df3
jmp 0x3df0
jmp 0x3e4c
movq %rax, %rbx
movq 0x678(%rsp), %rdi
leaq 0x688(%rsp), %rax
cmpq %rax, %rdi
je 0x3d1c
movq 0x688(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x3f2c
jmp 0x3dfd
jmp 0x3e0a
jmp 0x3e4c
jmp 0x3e4c
jmp 0x3e12
movq %rax, %rbx
movq 0x678(%rsp), %rdi
leaq 0x688(%rsp), %rax
cmpq %rax, %rdi
je 0x3f2c
movq 0x688(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x3f2c
jmp 0x3e12
jmp 0x3e0a
movq %rax, %rbx
movq 0x4f0(%rsp), %rdi
leaq 0x500(%rsp), %rax
cmpq %rax, %rdi
je 0x3f4d
movq 0x500(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x3f4d
jmp 0x3e0a
jmp 0x3e94
movq %rax, %rbx
movq 0xc98(%rsp), %rdi
leaq 0xca8(%rsp), %rax
cmpq %rax, %rdi
je 0x3fa8
movq 0xca8(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x3fa8
jmp 0x3e94
movq %rax, %rbx
jmp 0x3fc9
jmp 0x40ca
movq %rax, %rbx
jmp 0x3eea
jmp 0x40ca
movq %rax, %rbx
jmp 0x3f2c
jmp 0x3e94
movq %rax, %rbx
jmp 0x3f4d
movq %rax, %rbx
jmp 0x3f2c
movq %rax, %rbx
movq 0x800(%rsp), %rdi
leaq 0x810(%rsp), %rax
cmpq %rax, %rdi
je 0x3e42
movq 0x810(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x3eea
jmp 0x3ee7
movq %rax, %rbx
jmp 0x3f0b
jmp 0x3f63
jmp 0x3f54
movq %rax, %rbx
movq 0x4f0(%rsp), %rdi
leaq 0x500(%rsp), %rax
cmpq %rax, %rdi
je 0x3f87
movq 0x500(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x3f87
jmp 0x3f54
movq %rax, %rbx
jmp 0x3fa8
movq %rax, %rbx
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x3ec4
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x407b
jmp 0x400c
jmp 0x40ca
jmp 0x400c
jmp 0x40ca
jmp 0x400c
jmp 0x40ca
movq %rax, %rbx
movq 0xa0c7(%rip), %rsi      # 0xdfb8
leaq 0x988(%rsp), %rdi
callq 0x2130
leaq 0xa08(%rsp), %rdi
callq 0x2090
movq 0xa0a6(%rip), %rsi      # 0xdfb8
leaq 0x678(%rsp), %rdi
callq 0x2130
leaq 0x6f8(%rsp), %rdi
callq 0x2090
movq 0xa085(%rip), %rsi      # 0xdfb8
leaq 0x4f0(%rsp), %rdi
callq 0x2130
leaq 0x570(%rsp), %rdi
callq 0x2090
jmp 0x3f87
jmp 0x400c
movq %rax, %rbx
jmp 0x3f87
jmp 0x400c
jmp 0x400c
movq %rax, %rbx
movq 0xa04b(%rip), %rsi      # 0xdfb8
leaq 0x4f0(%rsp), %rdi
callq 0x2130
leaq 0x570(%rsp), %rdi
callq 0x2090
movq 0xa02a(%rip), %rsi      # 0xdfb8
leaq 0xc98(%rsp), %rdi
callq 0x2130
leaq 0xd18(%rsp), %rdi
callq 0x2090
movq 0xa009(%rip), %rsi      # 0xdfb8
leaq 0x108(%rsp), %rdi
callq 0x2130
leaq 0x188(%rsp), %rdi
callq 0x2090
leaq 0x2f0(%rsp), %rdi
callq 0x22c0
jmp 0x40cd
movq %rax, %rbx
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x4003
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x407b
jmp 0x400c
jmp 0x40ca
movq %rax, %rbx
jmp 0x407b
movq %rax, %rbx
movq 0xe8(%rsp), %rdi
leaq 0xf8(%rsp), %rax
cmpq %rax, %rdi
je 0x403e
movq 0xf8(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x403e
movq %rax, %rbx
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x407b
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x407b
jmp 0x4078
jmp 0x40ca
movq %rax, %rbx
movl $0x50, %esi
movq %r12, %rdi
jmp 0x40c1
jmp 0x40ca
movq %rax, %rbx
movq 0x9f36(%rip), %rsi      # 0xdfb8
leaq 0x2f0(%rsp), %rdi
callq 0x2130
leaq 0x370(%rsp), %rdi
callq 0x2090
jmp 0x40cd
movq %rax, %rbx
movq 0x2f0(%rsp), %rdi
leaq 0x300(%rsp), %rax
cmpq %rax, %rdi
je 0x40cd
movq 0x300(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x40cd
jmp 0x40ca
movq %rax, %rbx
movq 0x9ee4(%rip), %rsi      # 0xdfb8
leaq 0xe20(%rsp), %rdi
callq 0x2130
leaq 0xea0(%rsp), %rdi
jmp 0x4194
jmp 0x414a
movq %rax, %rbx
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x4157
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x4157
jmp 0x4154
jmp 0x414f
movq %rax, %rbx
movq 0xe20(%rsp), %rdi
leaq 0xe30(%rsp), %rax
cmpq %rax, %rdi
je 0x4178
movq 0xe30(%rsp), %rsi
incq %rsi
callq 0x2210
jmp 0x4178
jmp 0x414f
movq %rax, %rbx
jmp 0x4199
movq %rax, %rbx
jmp 0x4178
movq %rax, %rbx
movq 0x9e5a(%rip), %rsi      # 0xdfb8
leaq 0xe20(%rsp), %rdi
callq 0x2130
leaq 0xea0(%rsp), %rdi
callq 0x2090
movq 0x9e39(%rip), %rsi      # 0xdfb8
leaq 0x2f0(%rsp), %rdi
callq 0x2130
leaq 0x370(%rsp), %rdi
callq 0x2090
movq 0x290(%rsp), %rdi
leaq 0x2a0(%rsp), %rax
cmpq %rax, %rdi
je 0x41be
movq 0x2a0(%rsp), %rsi
incq %rsi
callq 0x2210
movq 0x2b0(%rsp), %rdi
leaq 0x2c0(%rsp), %rax
cmpq %rax, %rdi
je 0x41e3
movq 0x2c0(%rsp), %rsi
incq %rsi
callq 0x2210
movq 0x9de6(%rip), %rax      # 0xdfd0
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq 0x1040(%rsp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0x1038(%rsp,%rcx)
callq 0x2180
leaq 0x1130(%rsp), %rdi
callq 0x2090
jmp 0x4220
movq %rax, %rbx
movq 0x2d0(%rsp), %rdi
leaq 0x2e0(%rsp), %rax
cmpq %rax, %rdi
je 0x4245
movq 0x2e0(%rsp), %rsi
incq %rsi
callq 0x2210
movq %rbx, %rdi
callq 0x2340
nop