// File: sidvishnoi[P]filesystem-assignment/handleInput.cpp
// Function: handleInput(FileSystem&)
int handleInput(FileSystem &disk) {
    /*
    objective: to create a terminal like CLI to handle disk operations
    input: reference to disk
    return:
        0: continue
        1: exit
    */
    string command;
    cout << KGRN << "(myFileSystem)> " << KRST;
    getline(cin, command);
    if (command.empty()) return 1;

    // split command into function and argument part
    vector<string> tokens;
    tokens = split(command, ' ');
    string fun = tokens[0];
    string arg = "";
    if (tokens.size() > 1) {
        arg = tokens[1];
    }

    string arg2 = "";
    if (tokens.size() > 2) {
        arg2 = tokens[2];
    }

    enum Choice {
        HELP, INFO, TREE, READ, CHECK, WRITE, FORMAT, EXIT, NEW_FILE, CAT, DEL, UNDEL, MKDIR, CD, PWD, LS, END
    };
    string CHOICES[] = {
        "help", "info", "tree", "read", "check", "write", "format", "exit", "new", "cat", "del", "undel", "mkdir", "chdir", "pwd", "list", ""
    };
    string choices[] = {
        "h", "info", "tree", "r", "c", "w", "f", "q", "n", "cat", "del", "undel", "mkdir", "cd", "pwd", "ls", ""
    };

    Choice selected = END;
    for (int i = 0; i < END; ++i) {
        if (CHOICES[i] == fun || choices[i] == fun) {
            selected = static_cast<Choice>(i);
            break;
        }
    }

    int sector;
    // handle command
    switch (selected) {
        case READ: {
            if (arg.empty()) {
                cout << "usage: read SECTOR" << endl;
                return 0;
            }
            // convert string to int
            istringstream(arg) >> sector;
            char readBuffer[kSectorSize_g];
            disk.readSector(sector, readBuffer);
            for (int i = 0; i < kSectorSize_g; ++i) {
                cout << readBuffer[i];
            }
            cout << endl;
            break;
        }
        case WRITE: {
            if (arg.empty()) {
                cout << "usage: write SECTOR" << endl;
                return 0;
            }
            istringstream(arg) >> sector;
            if (disk.getStatus(sector) == FileSystem::BUSY) {
                cout << "Overwrite sector data (y/n)? _\b";
                char t;
                cin >> t;
                if (t == 'y' || t == 'Y') {
                    char buf[kSectorSize_g];
                    createBuffer('.', buf);
                    disk.writeSector(sector, buf);
                } else {
                    cin.ignore(32767, '\n');
                    return 0;
                }
            } else {
                char buf[kSectorSize_g];
                createBuffer('.', buf);
                disk.writeSector(sector, buf);
                disk.setStatus(sector, 1);
            }
            break;
        }
        case CHECK: {
            if (arg.empty()) {
                cout << "usage: check SECTOR" << endl;
                return 0;
            }
            istringstream(arg) >> sector;
            int status = disk.getStatus(sector);
            cout << "sector #" << sector << " is ";
            if (status < disk.END && status > -1) {
                cout << disk.statusMsg[status] << endl;
            } else {
                cout << "pointing to sector #" << status << endl;
            }
            break;
        }
        case FORMAT:
            disk.format();
            break;
        case HELP: {
            ifstream helpFile;
            helpFile.open("help.txt", ios::in | ios::ate);
            int helpFileSize = helpFile.tellg();
            char helpMsg[helpFileSize];
            helpFile.seekg(0);
            helpFile.read(helpMsg, helpFileSize);
            helpFile.close();
            cout << helpMsg << endl;
            break;
        }
        case INFO:
            disk.info();
            break;
        case TREE:
            disk.tree();
            break;
        case NEW_FILE: {
            if (arg.empty()) {
                cout << "usage: new FILE_NAME [SRC_FILE]" << endl;
                return 0;
            }
            disk.createFile(arg.c_str(), arg2.c_str());
            break;
        }
        case CAT: {
            if (arg.empty()) {
                cout << "usage: cat FILE_NAME" << endl;
                return 0;
            }
            disk.readFile(arg.c_str());
            break;
        }
        case DEL: {
            if (arg.empty()) {
                cout << "usage: del FILE_NAME" << endl;
                return 0;
            }
            disk.deleteFile(arg.c_str());
            break;
        }
        case UNDEL: {
            if (arg.empty()) {
                cout << "usage: undel FILE_NAME" << endl;
                return 0;
            }
            disk.undeleteFile(arg.c_str());
            break;
        }
        case MKDIR: {
            if (arg.empty()) {
                cout << "usage: mkdir DIR_NAME" << endl;
                return 0;
            }
            disk.createDir(arg.c_str());
            break;
        }
        case CD: {
            if (arg.empty()) {
                cout << "usage: cd DIR_NAME" << endl;
                return 0;
            }
            vector<string> dir = split(arg, '/');
            for (int i = 0; i < dir.size(); ++i) {
                disk.changeDir(dir[i].c_str());
            }
            break;
        }
        case PWD:
            disk.printWorkingDir();
            break;
        case LS:
            disk.listDirectoryContents();
            break;
        case EXIT:
            return 1;
        default:
            cout << "(myFileSystem): command not found: " << fun << endl;
            return 0;
    }
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x1640, %rsp           # imm = 0x1640
movq %rdi, -0x10(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x3370
movq 0xcbf1(%rip), %rdi      # 0x10fd0
leaq 0x7cab(%rip), %rsi      # 0xc091
callq 0x3230
movq %rax, -0x1270(%rbp)
jmp 0x43f4
movq -0x1270(%rbp), %rdi
leaq 0x7c95(%rip), %rsi      # 0xc097
callq 0x3230
movq %rax, -0x1278(%rbp)
jmp 0x4410
movq -0x1278(%rbp), %rdi
leaq 0x7c8a(%rip), %rsi      # 0xc0a8
callq 0x3230
jmp 0x4425
movq 0xcbb4(%rip), %rdi      # 0x10fe0
leaq -0x30(%rbp), %rsi
callq 0x3050
jmp 0x4437
leaq -0x30(%rbp), %rdi
callq 0x3400
testb $0x1, %al
jne 0x4446
jmp 0x446a
movl $0x1, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x627b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x628c
leaq -0x58(%rbp), %rdi
callq 0x62c0
leaq -0x70(%rbp), %rdi
leaq -0x30(%rbp), %rsi
movl $0x20, %edx
callq 0x41d0
jmp 0x4487
leaq -0x58(%rbp), %rdi
movq %rdi, -0x1280(%rbp)
leaq -0x70(%rbp), %rsi
movq %rsi, -0x1288(%rbp)
callq 0x6350
movq -0x1288(%rbp), %rdi
callq 0x3d50
movq -0x1280(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x6380
movq %rax, %rsi
leaq -0x90(%rbp), %rdi
callq 0x30c0
jmp 0x44cf
leaq -0xb1(%rbp), %rdi
movq %rdi, -0x1290(%rbp)
callq 0x3460
movq -0x1290(%rbp), %rdx
leaq 0x7c62(%rip), %rsi      # 0xc152
leaq -0xb0(%rbp), %rdi
callq 0x63a0
jmp 0x44fe
leaq -0xb1(%rbp), %rdi
callq 0x3280
leaq -0x58(%rbp), %rdi
callq 0x6450
cmpq $0x1, %rax
jbe 0x4579
leaq -0x58(%rbp), %rdi
movl $0x1, %esi
callq 0x6380
movq %rax, %rsi
leaq -0xb0(%rbp), %rdi
callq 0x3030
jmp 0x4538
jmp 0x4579
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x6270
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0xb1(%rbp), %rdi
callq 0x3280
jmp 0x6264
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x6258
leaq -0xd9(%rbp), %rdi
movq %rdi, -0x1298(%rbp)
callq 0x3460
movq -0x1298(%rbp), %rdx
leaq 0x7bb8(%rip), %rsi      # 0xc152
leaq -0xd8(%rbp), %rdi
callq 0x63a0
jmp 0x45a8
leaq -0xd9(%rbp), %rdi
callq 0x3280
leaq -0x58(%rbp), %rdi
callq 0x6450
cmpq $0x2, %rax
jbe 0x4612
leaq -0x58(%rbp), %rdi
movl $0x2, %esi
callq 0x6380
movq %rax, %rsi
leaq -0xd8(%rbp), %rdi
callq 0x3030
jmp 0x45e2
jmp 0x4612
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0xd9(%rbp), %rdi
callq 0x3280
jmp 0x6258
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x624c
movb $0x1, -0x31a(%rbp)
leaq -0x300(%rbp), %rax
movq %rax, -0x12a8(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x309(%rbp), %rdi
movq %rdi, -0x12a0(%rbp)
callq 0x3460
movq -0x12a8(%rbp), %rdi
movq -0x12a0(%rbp), %rdx
leaq 0x7a57(%rip), %rsi      # 0xc0ad
callq 0x63a0
jmp 0x465d
leaq -0x2e0(%rbp), %rax
movq %rax, -0x12b8(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x30a(%rbp), %rdi
movq %rdi, -0x12b0(%rbp)
callq 0x3460
movq -0x12b8(%rbp), %rdi
movq -0x12b0(%rbp), %rdx
leaq 0x7a18(%rip), %rsi      # 0xc0b2
callq 0x63a0
jmp 0x46a1
leaq -0x2c0(%rbp), %rax
movq %rax, -0x12c8(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x30b(%rbp), %rdi
movq %rdi, -0x12c0(%rbp)
callq 0x3460
movq -0x12c8(%rbp), %rdi
movq -0x12c0(%rbp), %rdx
leaq 0x79d9(%rip), %rsi      # 0xc0b7
callq 0x63a0
jmp 0x46e5
leaq -0x2a0(%rbp), %rax
movq %rax, -0x12d8(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x30c(%rbp), %rdi
movq %rdi, -0x12d0(%rbp)
callq 0x3460
movq -0x12d8(%rbp), %rdi
movq -0x12d0(%rbp), %rdx
leaq 0x799a(%rip), %rsi      # 0xc0bc
callq 0x63a0
jmp 0x4729
leaq -0x280(%rbp), %rax
movq %rax, -0x12e8(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x30d(%rbp), %rdi
movq %rdi, -0x12e0(%rbp)
callq 0x3460
movq -0x12e8(%rbp), %rdi
movq -0x12e0(%rbp), %rdx
leaq 0x795b(%rip), %rsi      # 0xc0c1
callq 0x63a0
jmp 0x476d
leaq -0x260(%rbp), %rax
movq %rax, -0x12f8(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x30e(%rbp), %rdi
movq %rdi, -0x12f0(%rbp)
callq 0x3460
movq -0x12f8(%rbp), %rdi
movq -0x12f0(%rbp), %rdx
leaq 0x791d(%rip), %rsi      # 0xc0c7
callq 0x63a0
jmp 0x47b1
leaq -0x240(%rbp), %rax
movq %rax, -0x1308(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x30f(%rbp), %rdi
movq %rdi, -0x1300(%rbp)
callq 0x3460
movq -0x1308(%rbp), %rdi
movq -0x1300(%rbp), %rdx
leaq 0x78df(%rip), %rsi      # 0xc0cd
callq 0x63a0
jmp 0x47f5
leaq -0x220(%rbp), %rax
movq %rax, -0x1318(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x310(%rbp), %rdi
movq %rdi, -0x1310(%rbp)
callq 0x3460
movq -0x1318(%rbp), %rdi
movq -0x1310(%rbp), %rdx
leaq 0x78a2(%rip), %rsi      # 0xc0d4
callq 0x63a0
jmp 0x4839
leaq -0x200(%rbp), %rax
movq %rax, -0x1328(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x311(%rbp), %rdi
movq %rdi, -0x1320(%rbp)
callq 0x3460
movq -0x1328(%rbp), %rdi
movq -0x1320(%rbp), %rdx
leaq 0x7863(%rip), %rsi      # 0xc0d9
callq 0x63a0
jmp 0x487d
leaq -0x1e0(%rbp), %rax
movq %rax, -0x1338(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x312(%rbp), %rdi
movq %rdi, -0x1330(%rbp)
callq 0x3460
movq -0x1338(%rbp), %rdi
movq -0x1330(%rbp), %rdx
leaq 0x7823(%rip), %rsi      # 0xc0dd
callq 0x63a0
jmp 0x48c1
leaq -0x1c0(%rbp), %rax
movq %rax, -0x1348(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x313(%rbp), %rdi
movq %rdi, -0x1340(%rbp)
callq 0x3460
movq -0x1348(%rbp), %rdi
movq -0x1340(%rbp), %rdx
leaq 0x77e5(%rip), %rsi      # 0xc0e3
callq 0x63a0
jmp 0x4905
leaq -0x1a0(%rbp), %rax
movq %rax, -0x1358(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x314(%rbp), %rdi
movq %rdi, -0x1350(%rbp)
callq 0x3460
movq -0x1358(%rbp), %rdi
movq -0x1350(%rbp), %rdx
leaq 0x779f(%rip), %rsi      # 0xc0e1
callq 0x63a0
jmp 0x4949
leaq -0x180(%rbp), %rax
movq %rax, -0x1368(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x315(%rbp), %rdi
movq %rdi, -0x1360(%rbp)
callq 0x3460
movq -0x1368(%rbp), %rdi
movq -0x1360(%rbp), %rdx
leaq 0x7761(%rip), %rsi      # 0xc0e7
callq 0x63a0
jmp 0x498d
leaq -0x160(%rbp), %rax
movq %rax, -0x1378(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x316(%rbp), %rdi
movq %rdi, -0x1370(%rbp)
callq 0x3460
movq -0x1378(%rbp), %rdi
movq -0x1370(%rbp), %rdx
leaq 0x7723(%rip), %rsi      # 0xc0ed
callq 0x63a0
jmp 0x49d1
leaq -0x140(%rbp), %rax
movq %rax, -0x1388(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x317(%rbp), %rdi
movq %rdi, -0x1380(%rbp)
callq 0x3460
movq -0x1388(%rbp), %rdi
movq -0x1380(%rbp), %rdx
leaq 0x76e5(%rip), %rsi      # 0xc0f3
callq 0x63a0
jmp 0x4a15
leaq -0x120(%rbp), %rax
movq %rax, -0x1398(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x318(%rbp), %rdi
movq %rdi, -0x1390(%rbp)
callq 0x3460
movq -0x1398(%rbp), %rdi
movq -0x1390(%rbp), %rdx
leaq 0x76a5(%rip), %rsi      # 0xc0f7
callq 0x63a0
jmp 0x4a59
leaq -0x100(%rbp), %rax
movq %rax, -0x13a8(%rbp)
movq %rax, -0x308(%rbp)
leaq -0x319(%rbp), %rdi
movq %rdi, -0x13a0(%rbp)
callq 0x3460
movq -0x13a8(%rbp), %rdi
movq -0x13a0(%rbp), %rdx
leaq 0x76bc(%rip), %rsi      # 0xc152
callq 0x63a0
jmp 0x4a9d
movb $0x0, -0x31a(%rbp)
leaq -0x319(%rbp), %rdi
callq 0x3280
leaq -0x318(%rbp), %rdi
callq 0x3280
leaq -0x317(%rbp), %rdi
callq 0x3280
leaq -0x316(%rbp), %rdi
callq 0x3280
leaq -0x315(%rbp), %rdi
callq 0x3280
leaq -0x314(%rbp), %rdi
callq 0x3280
leaq -0x313(%rbp), %rdi
callq 0x3280
leaq -0x312(%rbp), %rdi
callq 0x3280
leaq -0x311(%rbp), %rdi
callq 0x3280
leaq -0x310(%rbp), %rdi
callq 0x3280
leaq -0x30f(%rbp), %rdi
callq 0x3280
leaq -0x30e(%rbp), %rdi
callq 0x3280
leaq -0x30d(%rbp), %rdi
callq 0x3280
leaq -0x30c(%rbp), %rdi
callq 0x3280
leaq -0x30b(%rbp), %rdi
callq 0x3280
leaq -0x30a(%rbp), %rdi
callq 0x3280
leaq -0x309(%rbp), %rdi
callq 0x3280
movb $0x1, -0x55a(%rbp)
leaq -0x540(%rbp), %rax
movq %rax, -0x13b8(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x549(%rbp), %rdi
movq %rdi, -0x13b0(%rbp)
callq 0x3460
movq -0x13b8(%rbp), %rdi
movq -0x13b0(%rbp), %rdx
leaq 0x7548(%rip), %rsi      # 0xc0fc
callq 0x63a0
jmp 0x4bbb
leaq -0x520(%rbp), %rax
movq %rax, -0x13c8(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x54a(%rbp), %rdi
movq %rdi, -0x13c0(%rbp)
callq 0x3460
movq -0x13c8(%rbp), %rdi
movq -0x13c0(%rbp), %rdx
leaq 0x74ba(%rip), %rsi      # 0xc0b2
callq 0x63a0
jmp 0x4bff
leaq -0x500(%rbp), %rax
movq %rax, -0x13d8(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x54b(%rbp), %rdi
movq %rdi, -0x13d0(%rbp)
callq 0x3460
movq -0x13d8(%rbp), %rdi
movq -0x13d0(%rbp), %rdx
leaq 0x747b(%rip), %rsi      # 0xc0b7
callq 0x63a0
jmp 0x4c43
leaq -0x4e0(%rbp), %rax
movq %rax, -0x13e8(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x54c(%rbp), %rdi
movq %rdi, -0x13e0(%rbp)
callq 0x3460
movq -0x13e8(%rbp), %rdi
movq -0x13e0(%rbp), %rdx
leaq 0x7471(%rip), %rsi      # 0xc0f1
callq 0x63a0
jmp 0x4c87
leaq -0x4c0(%rbp), %rax
movq %rax, -0x13f8(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x54d(%rbp), %rdi
movq %rdi, -0x13f0(%rbp)
callq 0x3460
movq -0x13f8(%rbp), %rdi
movq -0x13f0(%rbp), %rdx
leaq 0x743a(%rip), %rsi      # 0xc0fe
callq 0x63a0
jmp 0x4ccb
leaq -0x4a0(%rbp), %rax
movq %rax, -0x1408(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x54e(%rbp), %rdi
movq %rdi, -0x1400(%rbp)
callq 0x3460
movq -0x1408(%rbp), %rdi
movq -0x1400(%rbp), %rdx
leaq 0x73d3(%rip), %rsi      # 0xc0db
callq 0x63a0
jmp 0x4d0f
leaq -0x480(%rbp), %rax
movq %rax, -0x1418(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x54f(%rbp), %rdi
movq %rdi, -0x1410(%rbp)
callq 0x3460
movq -0x1418(%rbp), %rdi
movq -0x1410(%rbp), %rdx
leaq 0x73b4(%rip), %rsi      # 0xc100
callq 0x63a0
jmp 0x4d53
leaq -0x460(%rbp), %rax
movq %rax, -0x1428(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x550(%rbp), %rdi
movq %rdi, -0x1420(%rbp)
callq 0x3460
movq -0x1428(%rbp), %rdi
movq -0x1420(%rbp), %rdx
leaq 0x7372(%rip), %rsi      # 0xc102
callq 0x63a0
jmp 0x4d97
leaq -0x440(%rbp), %rax
movq %rax, -0x1438(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x551(%rbp), %rdi
movq %rdi, -0x1430(%rbp)
callq 0x3460
movq -0x1438(%rbp), %rdi
movq -0x1430(%rbp), %rdx
leaq 0x7330(%rip), %rsi      # 0xc104
callq 0x63a0
jmp 0x4ddb
leaq -0x420(%rbp), %rax
movq %rax, -0x1448(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x552(%rbp), %rdi
movq %rdi, -0x1440(%rbp)
callq 0x3460
movq -0x1448(%rbp), %rdi
movq -0x1440(%rbp), %rdx
leaq 0x72c5(%rip), %rsi      # 0xc0dd
callq 0x63a0
jmp 0x4e1f
leaq -0x400(%rbp), %rax
movq %rax, -0x1458(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x553(%rbp), %rdi
movq %rdi, -0x1450(%rbp)
callq 0x3460
movq -0x1458(%rbp), %rdi
movq -0x1450(%rbp), %rdx
leaq 0x7287(%rip), %rsi      # 0xc0e3
callq 0x63a0
jmp 0x4e63
leaq -0x3e0(%rbp), %rax
movq %rax, -0x1468(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x554(%rbp), %rdi
movq %rdi, -0x1460(%rbp)
callq 0x3460
movq -0x1468(%rbp), %rdi
movq -0x1460(%rbp), %rdx
leaq 0x7241(%rip), %rsi      # 0xc0e1
callq 0x63a0
jmp 0x4ea7
leaq -0x3c0(%rbp), %rax
movq %rax, -0x1478(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x555(%rbp), %rdi
movq %rdi, -0x1470(%rbp)
callq 0x3460
movq -0x1478(%rbp), %rdi
movq -0x1470(%rbp), %rdx
leaq 0x7203(%rip), %rsi      # 0xc0e7
callq 0x63a0
jmp 0x4eeb
leaq -0x3a0(%rbp), %rax
movq %rax, -0x1488(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x556(%rbp), %rdi
movq %rdi, -0x1480(%rbp)
callq 0x3460
movq -0x1488(%rbp), %rdi
movq -0x1480(%rbp), %rdx
leaq 0x71de(%rip), %rsi      # 0xc106
callq 0x63a0
jmp 0x4f2f
leaq -0x380(%rbp), %rax
movq %rax, -0x1498(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x557(%rbp), %rdi
movq %rdi, -0x1490(%rbp)
callq 0x3460
movq -0x1498(%rbp), %rdi
movq -0x1490(%rbp), %rdx
leaq 0x7187(%rip), %rsi      # 0xc0f3
callq 0x63a0
jmp 0x4f73
leaq -0x360(%rbp), %rax
movq %rax, -0x14a8(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x558(%rbp), %rdi
movq %rdi, -0x14a0(%rbp)
callq 0x3460
movq -0x14a8(%rbp), %rdi
movq -0x14a0(%rbp), %rdx
leaq 0x7159(%rip), %rsi      # 0xc109
callq 0x63a0
jmp 0x4fb7
leaq -0x340(%rbp), %rax
movq %rax, -0x14b8(%rbp)
movq %rax, -0x548(%rbp)
leaq -0x559(%rbp), %rdi
movq %rdi, -0x14b0(%rbp)
callq 0x3460
movq -0x14b8(%rbp), %rdi
movq -0x14b0(%rbp), %rdx
leaq 0x715e(%rip), %rsi      # 0xc152
callq 0x63a0
jmp 0x4ffb
movb $0x0, -0x55a(%rbp)
leaq -0x559(%rbp), %rdi
callq 0x3280
leaq -0x558(%rbp), %rdi
callq 0x3280
leaq -0x557(%rbp), %rdi
callq 0x3280
leaq -0x556(%rbp), %rdi
callq 0x3280
leaq -0x555(%rbp), %rdi
callq 0x3280
leaq -0x554(%rbp), %rdi
callq 0x3280
leaq -0x553(%rbp), %rdi
callq 0x3280
leaq -0x552(%rbp), %rdi
callq 0x3280
leaq -0x551(%rbp), %rdi
callq 0x3280
leaq -0x550(%rbp), %rdi
callq 0x3280
leaq -0x54f(%rbp), %rdi
callq 0x3280
leaq -0x54e(%rbp), %rdi
callq 0x3280
leaq -0x54d(%rbp), %rdi
callq 0x3280
leaq -0x54c(%rbp), %rdi
callq 0x3280
leaq -0x54b(%rbp), %rdi
callq 0x3280
leaq -0x54a(%rbp), %rdi
callq 0x3280
leaq -0x549(%rbp), %rdi
callq 0x3280
movl $0x10, -0x560(%rbp)
movl $0x0, -0x564(%rbp)
cmpl $0x10, -0x564(%rbp)
jge 0x55d7
movslq -0x564(%rbp), %rax
leaq -0x300(%rbp), %rdi
shlq $0x5, %rax
addq %rax, %rdi
leaq -0x90(%rbp), %rsi
callq 0x6470
testb $0x1, %al
jne 0x513e
movslq -0x564(%rbp), %rax
leaq -0x540(%rbp), %rdi
shlq $0x5, %rax
addq %rax, %rdi
leaq -0x90(%rbp), %rsi
callq 0x6470
testb $0x1, %al
jne 0x513e
jmp 0x55c1
movl -0x564(%rbp), %eax
movl %eax, -0x560(%rbp)
jmp 0x55d7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x531f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x5313
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x5307
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x52fb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x52ef
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x52e3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x52d7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x52cb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x52bf
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x52b3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x52a7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x529b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x528f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x5283
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x5277
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x526b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x319(%rbp), %rdi
callq 0x3280
leaq -0x318(%rbp), %rdi
callq 0x3280
leaq -0x317(%rbp), %rdi
callq 0x3280
leaq -0x316(%rbp), %rdi
callq 0x3280
leaq -0x315(%rbp), %rdi
callq 0x3280
leaq -0x314(%rbp), %rdi
callq 0x3280
leaq -0x313(%rbp), %rdi
callq 0x3280
leaq -0x312(%rbp), %rdi
callq 0x3280
leaq -0x311(%rbp), %rdi
callq 0x3280
leaq -0x310(%rbp), %rdi
callq 0x3280
leaq -0x30f(%rbp), %rdi
callq 0x3280
leaq -0x30e(%rbp), %rdi
callq 0x3280
leaq -0x30d(%rbp), %rdi
callq 0x3280
leaq -0x30c(%rbp), %rdi
callq 0x3280
leaq -0x30b(%rbp), %rdi
callq 0x3280
leaq -0x30a(%rbp), %rdi
callq 0x3280
leaq -0x309(%rbp), %rdi
callq 0x3280
testb $0x1, -0x31a(%rbp)
jne 0x5336
jmp 0x5383
movq -0x308(%rbp), %rax
leaq -0x300(%rbp), %rcx
cmpq %rax, %rcx
movq %rax, -0x14c0(%rbp)
je 0x5381
movq -0x14c0(%rbp), %rdi
addq $-0x20, %rdi
movq %rdi, -0x14c8(%rbp)
callq 0x3150
movq -0x14c8(%rbp), %rax
leaq -0x300(%rbp), %rcx
cmpq %rcx, %rax
movq %rax, -0x14c0(%rbp)
jne 0x5350
jmp 0x5383
jmp 0x624c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x5558
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x554c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x5540
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x5534
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x5528
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x551c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x5510
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x5504
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x54f8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x54ec
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x54e0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x54d4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x54c8
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x54bc
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x54b0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x54a4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x559(%rbp), %rdi
callq 0x3280
leaq -0x558(%rbp), %rdi
callq 0x3280
leaq -0x557(%rbp), %rdi
callq 0x3280
leaq -0x556(%rbp), %rdi
callq 0x3280
leaq -0x555(%rbp), %rdi
callq 0x3280
leaq -0x554(%rbp), %rdi
callq 0x3280
leaq -0x553(%rbp), %rdi
callq 0x3280
leaq -0x552(%rbp), %rdi
callq 0x3280
leaq -0x551(%rbp), %rdi
callq 0x3280
leaq -0x550(%rbp), %rdi
callq 0x3280
leaq -0x54f(%rbp), %rdi
callq 0x3280
leaq -0x54e(%rbp), %rdi
callq 0x3280
leaq -0x54d(%rbp), %rdi
callq 0x3280
leaq -0x54c(%rbp), %rdi
callq 0x3280
leaq -0x54b(%rbp), %rdi
callq 0x3280
leaq -0x54a(%rbp), %rdi
callq 0x3280
leaq -0x549(%rbp), %rdi
callq 0x3280
testb $0x1, -0x55a(%rbp)
jne 0x556f
jmp 0x55bc
movq -0x548(%rbp), %rax
leaq -0x540(%rbp), %rcx
cmpq %rax, %rcx
movq %rax, -0x14d0(%rbp)
je 0x55ba
movq -0x14d0(%rbp), %rdi
addq $-0x20, %rdi
movq %rdi, -0x14d8(%rbp)
callq 0x3150
movq -0x14d8(%rbp), %rax
leaq -0x540(%rbp), %rcx
cmpq %rcx, %rax
movq %rax, -0x14d0(%rbp)
jne 0x5589
jmp 0x55bc
jmp 0x61fe
jmp 0x55c3
movl -0x564(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x564(%rbp)
jmp 0x50e2
movl -0x560(%rbp), %eax
movq %rax, -0x14e0(%rbp)
subq $0xf, %rax
ja 0x607c
movq -0x14e0(%rbp), %rax
leaq 0x6a44(%rip), %rcx      # 0xc040
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
leaq -0xb0(%rbp), %rdi
callq 0x3400
testb $0x1, %al
jne 0x5617
jmp 0x566c
movq 0xb9b2(%rip), %rdi      # 0x10fd0
leaq 0x6ae7(%rip), %rsi      # 0xc10c
callq 0x3230
movq %rax, -0x14e8(%rbp)
jmp 0x5633
movq -0x14e8(%rbp), %rdi
movq 0xb97f(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5648
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x6150
leaq -0x6e8(%rbp), %rdi
leaq -0xb0(%rbp), %rsi
movl $0x8, %edx
callq 0x3410
jmp 0x5686
leaq -0x6e8(%rbp), %rdi
leaq -0x568(%rbp), %rsi
callq 0x6500
jmp 0x569b
leaq -0x6e8(%rbp), %rdi
callq 0x30f0
movq -0x10(%rbp), %rdi
movl -0x568(%rbp), %esi
leaq -0x8f0(%rbp), %rdx
callq 0x8290
jmp 0x56bf
movl $0x0, -0x8f4(%rbp)
cmpl $0x200, -0x8f4(%rbp)    # imm = 0x200
jge 0x5722
movslq -0x8f4(%rbp), %rax
movsbl -0x8f0(%rbp,%rax), %esi
movq 0xb8e5(%rip), %rdi      # 0x10fd0
callq 0x32c0
jmp 0x56f2
jmp 0x56f4
movl -0x8f4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8f4(%rbp)
jmp 0x56c9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x6e8(%rbp), %rdi
callq 0x30f0
jmp 0x6150
movq 0xb8a7(%rip), %rdi      # 0x10fd0
movq 0xb890(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5737
jmp 0x60d9
leaq -0xb0(%rbp), %rdi
callq 0x3400
testb $0x1, %al
jne 0x574e
jmp 0x5792
movq 0xb87b(%rip), %rdi      # 0x10fd0
leaq 0x69c3(%rip), %rsi      # 0xc11f
callq 0x3230
movq %rax, -0x14f0(%rbp)
jmp 0x576a
movq -0x14f0(%rbp), %rdi
movq 0xb848(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x577f
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
leaq -0xa78(%rbp), %rdi
leaq -0xb0(%rbp), %rsi
movl $0x8, %edx
callq 0x3410
jmp 0x57ac
leaq -0xa78(%rbp), %rdi
leaq -0x568(%rbp), %rsi
callq 0x6500
jmp 0x57c1
leaq -0xa78(%rbp), %rdi
callq 0x30f0
movq -0x10(%rbp), %rdi
movl -0x568(%rbp), %esi
callq 0x83a0
movl %eax, -0x14f4(%rbp)
jmp 0x57e4
movl -0x14f4(%rbp), %eax
cmpl $0x1, %eax
jne 0x58ac
movq 0xb7d6(%rip), %rdi      # 0x10fd0
leaq 0x6932(%rip), %rsi      # 0xc133
callq 0x3230
jmp 0x5808
movq 0xb7d1(%rip), %rdi      # 0x10fe0
leaq -0xa79(%rbp), %rsi
callq 0x3350
jmp 0x581d
movsbl -0xa79(%rbp), %eax
cmpl $0x79, %eax
je 0x5835
movsbl -0xa79(%rbp), %eax
cmpl $0x59, %eax
jne 0x587f
movl $0x2e, %edi
leaq -0xc80(%rbp), %rsi
callq 0x4330
jmp 0x5848
movq -0x10(%rbp), %rdi
movl -0x568(%rbp), %esi
leaq -0xc80(%rbp), %rdx
callq 0x8160
jmp 0x5860
jmp 0x58aa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0xa78(%rbp), %rdi
callq 0x30f0
jmp 0x6150
movq 0xb75a(%rip), %rdi      # 0x10fe0
movl $0x7fff, %esi           # imm = 0x7FFF
movl $0xa, %edx
callq 0x3170
jmp 0x5897
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
jmp 0x58ef
movl $0x2e, %edi
leaq -0xe80(%rbp), %rsi
callq 0x4330
jmp 0x58bf
movq -0x10(%rbp), %rdi
movl -0x568(%rbp), %esi
leaq -0xe80(%rbp), %rdx
callq 0x8160
jmp 0x58d7
movq -0x10(%rbp), %rdi
movl -0x568(%rbp), %esi
movl $0x1, %edx
callq 0x84b0
jmp 0x58ed
jmp 0x58ef
jmp 0x60d9
leaq -0xb0(%rbp), %rdi
callq 0x3400
testb $0x1, %al
jne 0x5906
jmp 0x594a
movq 0xb6c3(%rip), %rdi      # 0x10fd0
leaq 0x683f(%rip), %rsi      # 0xc153
callq 0x3230
movq %rax, -0x1500(%rbp)
jmp 0x5922
movq -0x1500(%rbp), %rdi
movq 0xb690(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5937
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
leaq -0x1000(%rbp), %rdi
leaq -0xb0(%rbp), %rsi
movl $0x8, %edx
callq 0x3410
jmp 0x5964
leaq -0x1000(%rbp), %rdi
leaq -0x568(%rbp), %rsi
callq 0x6500
jmp 0x5979
leaq -0x1000(%rbp), %rdi
callq 0x30f0
movq -0x10(%rbp), %rdi
movl -0x568(%rbp), %esi
callq 0x83a0
movl %eax, -0x1504(%rbp)
jmp 0x599c
movl -0x1504(%rbp), %eax
movl %eax, -0x1004(%rbp)
movq 0xb621(%rip), %rdi      # 0x10fd0
leaq 0x67c2(%rip), %rsi      # 0xc178
callq 0x3230
movq %rax, -0x1510(%rbp)
jmp 0x59c4
movq -0x1510(%rbp), %rdi
movl -0x568(%rbp), %esi
callq 0x3430
movq %rax, -0x1518(%rbp)
jmp 0x59df
movq -0x1518(%rbp), %rdi
leaq 0x677a(%rip), %rsi      # 0xc167
callq 0x3230
jmp 0x59f4
cmpl $0x6, -0x1004(%rbp)
jge 0x5a66
cmpl $-0x1, -0x1004(%rbp)
jle 0x5a66
movq -0x10(%rbp), %rdi
addq $0x68, %rdi
movslq -0x1004(%rbp), %rsi
callq 0x6530
movq %rax, %rsi
movq 0xb5ac(%rip), %rdi      # 0x10fd0
callq 0x3210
movq %rax, -0x1520(%rbp)
jmp 0x5a32
movq -0x1520(%rbp), %rdi
movq 0xb580(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5a47
jmp 0x5ab4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x1000(%rbp), %rdi
callq 0x30f0
jmp 0x6150
movq 0xb563(%rip), %rdi      # 0x10fd0
leaq 0x66f8(%rip), %rsi      # 0xc16c
callq 0x3230
movq %rax, -0x1528(%rbp)
jmp 0x5a82
movq -0x1528(%rbp), %rdi
movl -0x1004(%rbp), %esi
callq 0x3430
movq %rax, -0x1530(%rbp)
jmp 0x5a9d
movq -0x1530(%rbp), %rdi
movq 0xb515(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5ab2
jmp 0x5ab4
jmp 0x60d9
movq -0x10(%rbp), %rdi
callq 0x85e0
jmp 0x5ac4
jmp 0x60d9
leaq -0x1210(%rbp), %rdi
callq 0x32b0
jmp 0x5ad7
movl $0x8, %edi
movl $0x2, %esi
callq 0x62a0
movl %eax, -0x1534(%rbp)
jmp 0x5aee
movl -0x1534(%rbp), %edx
leaq 0x6686(%rip), %rsi      # 0xc181
leaq -0x1210(%rbp), %rdi
callq 0x3160
jmp 0x5b09
leaq -0x1210(%rbp), %rdi
callq 0x3440
movq %rdx, -0x1548(%rbp)
movq %rax, -0x1540(%rbp)
jmp 0x5b25
movq -0x1548(%rbp), %rax
movq -0x1540(%rbp), %rcx
movq %rcx, -0x1228(%rbp)
movq %rax, -0x1220(%rbp)
leaq -0x1228(%rbp), %rdi
callq 0x6550
movq %rax, -0x1550(%rbp)
jmp 0x5b56
movq -0x1550(%rbp), %rax
movl %eax, -0x1214(%rbp)
movl -0x1214(%rbp), %eax
movq %rsp, %rcx
movq %rcx, -0x1230(%rbp)
movq %rax, %rdx
addq $0xf, %rdx
andq $-0x10, %rdx
movq %rsp, %rcx
subq %rdx, %rcx
movq %rcx, -0x1558(%rbp)
movq %rcx, %rsp
movq %rax, -0x1238(%rbp)
xorl %eax, %eax
movl %eax, %esi
leaq -0x1248(%rbp), %rdi
callq 0x6570
jmp 0x5ba7
movq -0x1248(%rbp), %rsi
movq -0x1240(%rbp), %rdx
leaq -0x1210(%rbp), %rdi
callq 0x3310
jmp 0x5bc3
movq -0x1558(%rbp), %rsi
movslq -0x1214(%rbp), %rdx
leaq -0x1210(%rbp), %rdi
callq 0x3300
jmp 0x5bdf
leaq -0x1210(%rbp), %rdi
callq 0x3060
jmp 0x5bed
movq -0x1558(%rbp), %rsi
movq 0xb3d5(%rip), %rdi      # 0x10fd0
callq 0x3230
movq %rax, -0x1560(%rbp)
jmp 0x5c09
movq -0x1560(%rbp), %rdi
movq 0xb3a9(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5c1e
movl $0x5, -0x40(%rbp)
movq -0x1230(%rbp), %rax
movq %rax, %rsp
leaq -0x1210(%rbp), %rdi
callq 0x3070
jmp 0x60d9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x1210(%rbp), %rdi
callq 0x3070
jmp 0x6150
movq -0x10(%rbp), %rdi
callq 0xb7f0
jmp 0x5c68
jmp 0x60d9
movq -0x10(%rbp), %rdi
movl $0x1, %esi
movl $0x2, %edx
callq 0xb800
jmp 0x5c82
jmp 0x60d9
leaq -0xb0(%rbp), %rdi
callq 0x3400
testb $0x1, %al
jne 0x5c99
jmp 0x5cdd
movq 0xb330(%rip), %rdi      # 0x10fd0
leaq 0x64e3(%rip), %rsi      # 0xc18a
callq 0x3230
movq %rax, -0x1568(%rbp)
jmp 0x5cb5
movq -0x1568(%rbp), %rdi
movq 0xb2fd(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5cca
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
movq -0x10(%rbp), %rax
movq %rax, -0x1578(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0x30b0
movq %rax, -0x1570(%rbp)
leaq -0xd8(%rbp), %rdi
callq 0x30b0
movq -0x1578(%rbp), %rdi
movq -0x1570(%rbp), %rsi
movq %rax, %rdx
callq 0x9c40
jmp 0x5d1f
jmp 0x60d9
leaq -0xb0(%rbp), %rdi
callq 0x3400
testb $0x1, %al
jne 0x5d36
jmp 0x5d7a
movq 0xb293(%rip), %rdi      # 0x10fd0
leaq 0x6466(%rip), %rsi      # 0xc1aa
callq 0x3230
movq %rax, -0x1580(%rbp)
jmp 0x5d52
movq -0x1580(%rbp), %rdi
movq 0xb260(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5d67
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
movq -0x10(%rbp), %rax
movq %rax, -0x1588(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0x30b0
movq -0x1588(%rbp), %rdi
movq %rax, %rsi
callq 0xa480
jmp 0x5da2
jmp 0x60d9
leaq -0xb0(%rbp), %rdi
callq 0x3400
testb $0x1, %al
jne 0x5db9
jmp 0x5dfd
movq 0xb210(%rip), %rdi      # 0x10fd0
leaq 0x63f8(%rip), %rsi      # 0xc1bf
callq 0x3230
movq %rax, -0x1590(%rbp)
jmp 0x5dd5
movq -0x1590(%rbp), %rdi
movq 0xb1dd(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5dea
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
movq -0x10(%rbp), %rax
movq %rax, -0x1598(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0x30b0
movq -0x1598(%rbp), %rdi
movq %rax, %rsi
callq 0xa5e0
jmp 0x5e25
jmp 0x60d9
leaq -0xb0(%rbp), %rdi
callq 0x3400
testb $0x1, %al
jne 0x5e3c
jmp 0x5e80
movq 0xb18d(%rip), %rdi      # 0x10fd0
leaq 0x638a(%rip), %rsi      # 0xc1d4
callq 0x3230
movq %rax, -0x15a0(%rbp)
jmp 0x5e58
movq -0x15a0(%rbp), %rdi
movq 0xb15a(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5e6d
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
movq -0x10(%rbp), %rax
movq %rax, -0x15a8(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0x30b0
movq -0x15a8(%rbp), %rdi
movq %rax, %rsi
callq 0xaa20
jmp 0x5ea8
jmp 0x60d9
leaq -0xb0(%rbp), %rdi
callq 0x3400
testb $0x1, %al
jne 0x5ebf
jmp 0x5f03
movq 0xb10a(%rip), %rdi      # 0x10fd0
leaq 0x631e(%rip), %rsi      # 0xc1eb
callq 0x3230
movq %rax, -0x15b0(%rbp)
jmp 0x5edb
movq -0x15b0(%rbp), %rdi
movq 0xb0d7(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5ef0
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
movq -0x10(%rbp), %rax
movq %rax, -0x15b8(%rbp)
leaq -0xb0(%rbp), %rdi
callq 0x30b0
movq -0x15b8(%rbp), %rdi
movq %rax, %rsi
callq 0xaba0
jmp 0x5f2b
jmp 0x60d9
leaq -0xb0(%rbp), %rdi
callq 0x3400
testb $0x1, %al
jne 0x5f42
jmp 0x5f86
movq 0xb087(%rip), %rdi      # 0x10fd0
leaq 0x62b1(%rip), %rsi      # 0xc201
callq 0x3230
movq %rax, -0x15c0(%rbp)
jmp 0x5f5e
movq -0x15c0(%rbp), %rdi
movq 0xb054(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x5f73
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
leaq -0x1260(%rbp), %rdi
leaq -0xb0(%rbp), %rsi
movl $0x2f, %edx
callq 0x41d0
jmp 0x5fa0
movl $0x0, -0x1264(%rbp)
movslq -0x1264(%rbp), %rax
movq %rax, -0x15c8(%rbp)
leaq -0x1260(%rbp), %rdi
callq 0x6450
movq %rax, %rcx
movq -0x15c8(%rbp), %rax
cmpq %rcx, %rax
jae 0x603a
movq -0x10(%rbp), %rax
movq %rax, -0x15d0(%rbp)
movslq -0x1264(%rbp), %rsi
leaq -0x1260(%rbp), %rdi
callq 0x6380
movq %rax, %rdi
callq 0x30b0
movq -0x15d0(%rbp), %rdi
movq %rax, %rsi
callq 0xae70
jmp 0x600a
jmp 0x600c
movl -0x1264(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1264(%rbp)
jmp 0x5faa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x1260(%rbp), %rdi
callq 0x3d50
jmp 0x6150
movl $0x5, -0x40(%rbp)
leaq -0x1260(%rbp), %rdi
callq 0x3d50
jmp 0x60d9
movq -0x10(%rbp), %rdi
callq 0xb7d0
jmp 0x605d
jmp 0x60d9
movq -0x10(%rbp), %rdi
callq 0xb7e0
jmp 0x606a
jmp 0x60d9
movl $0x1, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
movq 0xaf4d(%rip), %rdi      # 0x10fd0
leaq 0x618a(%rip), %rsi      # 0xc214
callq 0x3230
movq %rax, -0x15d8(%rbp)
jmp 0x6098
movq -0x15d8(%rbp), %rdi
leaq -0x90(%rbp), %rsi
callq 0x3210
movq %rax, -0x15e0(%rbp)
jmp 0x60b4
movq -0x15e0(%rbp), %rdi
movq 0xaefe(%rip), %rsi      # 0x10fc0
callq 0x3260
jmp 0x60c9
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
jmp 0x60e7
movl $0x0, -0x4(%rbp)
movl $0x1, -0x40(%rbp)
leaq -0x540(%rbp), %rax
movq %rax, -0x15f0(%rbp)
addq $0x220, %rax            # imm = 0x220
movq %rax, -0x15e8(%rbp)
movq -0x15e8(%rbp), %rdi
addq $-0x20, %rdi
movq %rdi, -0x15f8(%rbp)
callq 0x3150
movq -0x15f0(%rbp), %rcx
movq -0x15f8(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x15e8(%rbp)
jne 0x6102
leaq -0x300(%rbp), %rax
movq %rax, -0x1608(%rbp)
addq $0x220, %rax            # imm = 0x220
movq %rax, -0x1600(%rbp)
jmp 0x619e
leaq -0x540(%rbp), %rax
movq %rax, -0x1618(%rbp)
addq $0x220, %rax            # imm = 0x220
movq %rax, -0x1610(%rbp)
movq -0x1610(%rbp), %rdi
addq $-0x20, %rdi
movq %rdi, -0x1620(%rbp)
callq 0x3150
movq -0x1618(%rbp), %rcx
movq -0x1620(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x1610(%rbp)
jne 0x616b
jmp 0x61fe
movq -0x1600(%rbp), %rdi
addq $-0x20, %rdi
movq %rdi, -0x1628(%rbp)
callq 0x3150
movq -0x1608(%rbp), %rcx
movq -0x1628(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x1600(%rbp)
jne 0x619e
leaq -0xd8(%rbp), %rdi
callq 0x3150
leaq -0xb0(%rbp), %rdi
callq 0x3150
leaq -0x90(%rbp), %rdi
callq 0x3150
leaq -0x58(%rbp), %rdi
callq 0x3d50
jmp 0x627b
leaq -0x300(%rbp), %rax
movq %rax, -0x1638(%rbp)
addq $0x220, %rax            # imm = 0x220
movq %rax, -0x1630(%rbp)
movq -0x1630(%rbp), %rdi
addq $-0x20, %rdi
movq %rdi, -0x1640(%rbp)
callq 0x3150
movq -0x1638(%rbp), %rcx
movq -0x1640(%rbp), %rax
cmpq %rcx, %rax
movq %rax, -0x1630(%rbp)
jne 0x6219
jmp 0x624c
leaq -0xd8(%rbp), %rdi
callq 0x3150
leaq -0xb0(%rbp), %rdi
callq 0x3150
leaq -0x90(%rbp), %rdi
callq 0x3150
leaq -0x58(%rbp), %rdi
callq 0x3d50
jmp 0x628c
leaq -0x30(%rbp), %rdi
callq 0x3150
movl -0x4(%rbp), %eax
movq %rbp, %rsp
popq %rbp
retq
leaq -0x30(%rbp), %rdi
callq 0x3150
movq -0x38(%rbp), %rdi
callq 0x3450
nop