// File: /workspace/github_c_makefile_star2_O3/atomlang[P]atomlang/src/pk_debug.c
// Function: dumpFunctionCode
void dumpFunctionCode(PKVM* vm, Function* func, pkByteBuffer* buff) {

#define INDENTATION "  "
#define ADD_CHAR(vm, buff, c) pkByteBufferWrite(buff, vm, c)
#define INT_WIDTH 5
#define ADD_INTEGER(vm, buff, value, width)                          \
  do {                                                               \
    char sbuff[STR_INT_BUFF_SIZE];                                   \
    int length;                                                      \
    if ((width) > 0) length = sprintf(sbuff, "%*d", (width), value); \
    else length = sprintf(sbuff, "%d", value);                       \
    pkByteBufferAddString(buff, vm, sbuff, (uint32_t)length);        \
  } while(false)

  uint32_t i = 0;
  uint8_t* opcodes = func->fn->opcodes.data;
  uint32_t* lines = func->fn->oplines.data;
  uint32_t line = 1, last_line = 0;

  // This will print: Instruction Dump of function 'fn' "path.pk"\n
  pkByteBufferAddString(buff, vm,
                        STR_AND_LEN("Instruction Dump of function '"));
  pkByteBufferAddString(buff, vm, STR_AND_LEN(func->name));
  pkByteBufferAddString(buff, vm, STR_AND_LEN("' \""));
  pkByteBufferAddString(buff, vm, STR_AND_LEN(func->owner->path->data));
  pkByteBufferAddString(buff, vm, STR_AND_LEN("\"\n"));

#define READ_BYTE() (opcodes[i++])
#define READ_SHORT() (i += 2, opcodes[i - 2] << 8 | opcodes[i-1])

#define NO_ARGS() ADD_CHAR(vm, buff, '\n')
#define BYTE_ARG()                                 \
  do {                                             \
    ADD_INTEGER(vm, buff, READ_BYTE(), INT_WIDTH); \
    ADD_CHAR(vm, buff, '\n');                      \
  } while (false)

#define SHORT_ARG()                                 \
  do {                                              \
    ADD_INTEGER(vm, buff, READ_SHORT(), INT_WIDTH); \
    ADD_CHAR(vm, buff, '\n');                       \
  } while (false)

  while (i < func->fn->opcodes.count) {
    ASSERT_INDEX(i, func->fn->opcodes.count);

    // Prints the line number.
    line = lines[i];
    if (line != last_line) {
      last_line = line;
      pkByteBufferAddString(buff, vm, STR_AND_LEN(INDENTATION));
      ADD_INTEGER(vm, buff, line, INT_WIDTH - 1);
      ADD_CHAR(vm, buff, ':');

    } else {
      pkByteBufferAddString(buff, vm, STR_AND_LEN(INDENTATION "     "));
    }

    // Prints: INDENTATION "%4d  %-16s"

    pkByteBufferAddString(buff, vm, STR_AND_LEN(INDENTATION));
    ADD_INTEGER(vm, buff, i, INT_WIDTH - 1);
    pkByteBufferAddString(buff, vm, STR_AND_LEN("  "));

    const char* op_name = op_names[opcodes[i]];
    uint32_t op_length = (uint32_t)strlen(op_name);
    pkByteBufferAddString(buff, vm, op_name, op_length);
    for (uint32_t j = 0; j < 16 - op_length; j++) { // Padding.
      ADD_CHAR(vm, buff, ' ');
    }

    Opcode op = (Opcode)func->fn->opcodes.data[i++];
    switch (op) {
      case OP_PUSH_CONSTANT:
      {
        int index = READ_SHORT();
        ASSERT_INDEX((uint32_t)index, func->owner->literals.count);
        Var value = func->owner->literals.data[index];

        // Prints: %5d [val]\n
        ADD_INTEGER(vm, buff, index, INT_WIDTH);
        ADD_CHAR(vm, buff, ' ');
        dumpValue(vm, value, buff);
        ADD_CHAR(vm, buff, '\n');
        break;
      }

      case OP_PUSH_NULL:
      case OP_PUSH_0:
      case OP_PUSH_TRUE:
      case OP_PUSH_FALSE:
      case OP_SWAP:
        NO_ARGS();
        break;

      case OP_PUSH_LIST:     SHORT_ARG(); break;
      case OP_PUSH_INSTANCE:
      {
        int ty_index = READ_BYTE();
        ASSERT_INDEX((uint32_t)ty_index, func->owner->classes.count);
        uint32_t name_ind = func->owner->classes.data[ty_index]->name;
        ASSERT_INDEX(name_ind, func->owner->names.count);
        String* ty_name = func->owner->names.data[name_ind];

        // Prints: %5d [Ty:%s]\n
        ADD_INTEGER(vm, buff, ty_index, INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" [Ty:"));
        pkByteBufferAddString(buff, vm, ty_name->data, ty_name->length);
        pkByteBufferAddString(buff, vm, STR_AND_LEN("]\n"));
        break;
      }
      case OP_PUSH_MAP:      NO_ARGS();   break;
      case OP_LIST_APPEND:   NO_ARGS();   break;
      case OP_MAP_INSERT:    NO_ARGS();   break;
      case OP_INST_APPEND:   NO_ARGS();   break;

      case OP_PUSH_LOCAL_0:
      case OP_PUSH_LOCAL_1:
      case OP_PUSH_LOCAL_2:
      case OP_PUSH_LOCAL_3:
      case OP_PUSH_LOCAL_4:
      case OP_PUSH_LOCAL_5:
      case OP_PUSH_LOCAL_6:
      case OP_PUSH_LOCAL_7:
      case OP_PUSH_LOCAL_8:
      case OP_PUSH_LOCAL_N:
      {

        int arg;
        if (op == OP_PUSH_LOCAL_N) {
          arg = READ_BYTE();
          ADD_INTEGER(vm, buff, arg, INT_WIDTH);

        } else {
          arg = (int)(op - OP_PUSH_LOCAL_0);
          for (int j = 0; j < INT_WIDTH; j++) ADD_CHAR(vm, buff, ' ');
        }

        if (arg < func->arity) {
          // Prints: (arg:%d)\n
          pkByteBufferAddString(buff, vm, STR_AND_LEN(" (param:"));
          ADD_INTEGER(vm, buff, arg, 1);
          pkByteBufferAddString(buff, vm, STR_AND_LEN(")\n"));

        } else {
          ADD_CHAR(vm, buff, '\n');
        }

      } break;

      case OP_STORE_LOCAL_0:
      case OP_STORE_LOCAL_1:
      case OP_STORE_LOCAL_2:
      case OP_STORE_LOCAL_3:
      case OP_STORE_LOCAL_4:
      case OP_STORE_LOCAL_5:
      case OP_STORE_LOCAL_6:
      case OP_STORE_LOCAL_7:
      case OP_STORE_LOCAL_8:
      case OP_STORE_LOCAL_N:
      {
        int arg;
        if (op == OP_STORE_LOCAL_N) {
          arg = READ_BYTE();
          ADD_INTEGER(vm, buff, arg, INT_WIDTH);

        } else {
          arg = (int)(op - OP_STORE_LOCAL_0);
          for (int j = 0; j < INT_WIDTH; j++) ADD_CHAR(vm, buff, ' ');
        }

        if (arg < func->arity) {
          // Prints: (arg:%d)\n
          pkByteBufferAddString(buff, vm, STR_AND_LEN(" (param:"));
          ADD_INTEGER(vm, buff, arg, 1);
          pkByteBufferAddString(buff, vm, STR_AND_LEN(")\n"));

        } else {
          ADD_CHAR(vm, buff, '\n');
        }

      } break;

      case OP_PUSH_GLOBAL:
      case OP_STORE_GLOBAL:
      {
        int index = READ_BYTE();
        int name_index = func->owner->global_names.data[index];
        String* name = func->owner->names.data[name_index];

        // Prints: %5d '%s'\n
        ADD_INTEGER(vm, buff, index, INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" '"));
        pkByteBufferAddString(buff, vm, name->data, name->length);
        pkByteBufferAddString(buff, vm, STR_AND_LEN("'\n"));
        break;
      }

      case OP_PUSH_FN:
      {
        int fn_index = READ_BYTE();
        const char* name = func->owner->functions.data[fn_index]->name;

        // Prints: %5d [Fn:%s]\n
        ADD_INTEGER(vm, buff, fn_index, INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" [Fn:"));
        pkByteBufferAddString(buff, vm, STR_AND_LEN(name));
        pkByteBufferAddString(buff, vm, STR_AND_LEN("]\n"));
        break;
      }

      case OP_PUSH_TYPE:
      {
        int ty_index = READ_BYTE();
        ASSERT_INDEX((uint32_t)ty_index, func->owner->classes.count);
        uint32_t name_ind = func->owner->classes.data[ty_index]->name;
        ASSERT_INDEX(name_ind, func->owner->names.count);
        String* ty_name = func->owner->names.data[name_ind];

        // Prints: %5d [Ty:%s]\n
        ADD_INTEGER(vm, buff, ty_index, INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" [Ty:"));
        pkByteBufferAddString(buff, vm, ty_name->data, ty_name->length);
        pkByteBufferAddString(buff, vm, STR_AND_LEN("]\n"));

        break;
      }

      case OP_PUSH_BUILTIN_FN:
      {
        int index = READ_BYTE();
        const char* name = getBuiltinFunctionName(vm, index);

        // Prints: %5d [Fn:%s]\n
        ADD_INTEGER(vm, buff, index, INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" [Fn:"));
        pkByteBufferAddString(buff, vm, STR_AND_LEN(name));
        pkByteBufferAddString(buff, vm, STR_AND_LEN("]\n"));
        break;
      }

      case OP_POP:    NO_ARGS(); break;
      case OP_IMPORT:
      {
        int index = READ_SHORT();
        String* name = func->owner->names.data[index];

        // Prints: %5d '%s'\n
        ADD_INTEGER(vm, buff, index, INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" '"));
        pkByteBufferAddString(buff, vm, name->data, name->length);
        pkByteBufferAddString(buff, vm, STR_AND_LEN("'\n"));
        break;
      }

      case OP_CALL:
        // Prints: %5d (argc)\n
        ADD_INTEGER(vm, buff, READ_BYTE(), INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" (argc)\n"));
        break;

      case OP_TAIL_CALL:
        // Prints: %5d (argc)\n
        ADD_INTEGER(vm, buff, READ_BYTE(), INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" (argc)\n"));
        break;

      case OP_ITER_TEST: NO_ARGS(); break;

      case OP_ITER:
      case OP_JUMP:
      case OP_JUMP_IF:
      case OP_JUMP_IF_NOT:
      {
        int offset = READ_SHORT();

        // Prints: %5d (ip:%d)\n
        ADD_INTEGER(vm, buff, offset, INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" (ip:"));
        ADD_INTEGER(vm, buff, i + offset, 0);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(")\n"));
        break;
      }

      case OP_LOOP:
      {
        int offset = READ_SHORT();

        // Prints: %5d (ip:%d)\n
        ADD_INTEGER(vm, buff, -offset, INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" (ip:"));
        ADD_INTEGER(vm, buff, i - offset, 0);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(")\n"));
        break;
      }

      case OP_RETURN: NO_ARGS(); break;

      case OP_GET_ATTRIB:
      case OP_GET_ATTRIB_KEEP:
      case OP_SET_ATTRIB:
      {
        int index = READ_SHORT();
        String* name = func->owner->names.data[index];

        // Prints: %5d '%s'\n
        ADD_INTEGER(vm, buff, index, INT_WIDTH);
        pkByteBufferAddString(buff, vm, STR_AND_LEN(" '"));
        pkByteBufferAddString(buff, vm, name->data, name->length);
        pkByteBufferAddString(buff, vm, STR_AND_LEN("'\n"));
      } break;

      case OP_GET_SUBSCRIPT:
      case OP_GET_SUBSCRIPT_KEEP:
      case OP_SET_SUBSCRIPT:
        NO_ARGS();
        break;

      case OP_NEGATIVE:
      case OP_NOT:
      case OP_BIT_NOT:
      case OP_ADD:
      case OP_SUBTRACT:
      case OP_MULTIPLY:
      case OP_DIVIDE:
      case OP_MOD:
      case OP_BIT_AND:
      case OP_BIT_OR:
      case OP_BIT_XOR:
      case OP_BIT_LSHIFT:
      case OP_BIT_RSHIFT:
      case OP_EQEQ:
      case OP_NOTEQ:
      case OP_LT:
      case OP_LTEQ:
      case OP_GT:
      case OP_GTEQ:
      case OP_RANGE:
      case OP_IN:
      case OP_REPL_PRINT:
      case OP_END:
        NO_ARGS();
        break;

      default:
        UNREACHABLE();
        break;
    }
  }

  ADD_CHAR(vm, buff, '\0');

// Undefin everything defined for this function.
#undef INDENTATION
#undef ADD_CHAR
#undef STR_AND_LEN
#undef READ_BYTE
#undef READ_SHORT
#undef BYTE_ARG
#undef SHORT_ARG

}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movq 0x38(%rsi), %rax
movq (%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x40(%rsp)
leaq 0xe75c(%rip), %rdx      # 0x1cb08
movq %rbx, %rdi
movq %r14, %rsi
movl $0x1e, %ecx
callq 0x8a34
movq 0x10(%r15), %r12
movq %r12, %rdi
callq 0x2140
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe748(%rip), %rdx      # 0x1cb27
movq %rbx, %rdi
movq %r14, %rsi
movl $0x3, %ecx
callq 0x8a34
movq 0x18(%r15), %rax
movq 0x18(%rax), %r12
addq $0x1c, %r12
movq %r12, %rdi
callq 0x2140
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0x111f8(%rip), %rdx     # 0x1f612
movq %rbx, %rdi
movq %r14, %rsi
movl $0x2, %ecx
callq 0x8a34
movq %r15, 0x20(%rsp)
movq 0x38(%r15), %rax
cmpl $0x0, 0x8(%rax)
je 0xece9
leaq 0xe710(%rip), %r12      # 0x1cb54
xorl %r15d, %r15d
movl $0x0, 0x3c(%rsp)
movl %r15d, %ecx
movq 0x40(%rsp), %rax
movq %rcx, 0x30(%rsp)
movl (%rax,%rcx,4), %r13d
cmpl 0x3c(%rsp), %r13d
jne 0xe48c
movq %rbx, %rdi
movq %r14, %rsi
leaq 0xe6db(%rip), %rdx      # 0x1cb4f
movl $0x7, %ecx
callq 0x8a34
leaq 0xe6c6(%rip), %r15      # 0x1cb4b
leaq 0x14(%rsp), %rbp
jmp 0xe4e5
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl $0x2, %ecx
callq 0x8a34
leaq 0x14(%rsp), %rbp
movq %rbp, %rdi
leaq 0xe69d(%rip), %r15      # 0x1cb4b
movq %r15, %rsi
movl $0x4, %edx
movl %r13d, %ecx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %rbp, %rdx
movl %eax, %ecx
callq 0x8a34
movq %rbx, %rdi
movq %r14, %rsi
movl $0x3a, %edx
callq 0x8562
movl %r13d, 0x3c(%rsp)
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl $0x2, %ecx
callq 0x8a34
movq %rbp, %rdi
movq %r15, %rsi
movl $0x4, %edx
movq 0x30(%rsp), %r15
movl %r15d, %ecx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %rbp, %rdx
movl %eax, %ecx
callq 0x8a34
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl $0x2, %ecx
callq 0x8a34
xorl %edi, %edi
callq 0x2140
movq %rax, %r13
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
movl %r13d, %ecx
callq 0x8a34
cmpl $0x10, %r13d
je 0xe56e
addl $-0x10, %r13d
movq %rbx, %rdi
movq %r14, %rsi
movl $0x20, %edx
callq 0x8562
incl %r13d
jne 0xe559
movq 0x20(%rsp), %rax
movq 0x38(%rax), %rax
movq (%rax), %rax
movzbl (%rax,%r15), %r12d
cmpq $0x4c, %r12
ja 0xed1e
movq %r15, %rbp
incl %r15d
leaq 0xe43e(%rip), %rcx      # 0x1c9d4
movslq (%rcx,%r12,4), %rax
addq %rcx, %rax
jmpq *%rax
cmpl $0x15, %r12d
je 0xe5cb
movl $0x5, %ebp
movq %rbx, %rdi
movq %r14, %rsi
movl $0x20, %edx
callq 0x8562
decl %ebp
jne 0xe5aa
leal -0xc(%r12), %r13d
jmp 0xe631
cmpl $0x1f, %r12d
jne 0xe613
movq 0x30(%rsp), %rbp
addl $0x2, %ebp
movl %r15d, %eax
movq 0x8(%rsp), %rcx
movzbl (%rcx,%rax), %r13d
leaq 0xe564(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r12
movq %r12, %rdi
movl $0x5, %edx
movl %r13d, %ecx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
movl %ebp, %r15d
jmp 0xe631
movl $0x5, %ebp
movq %rbx, %rdi
movq %r14, %rsi
movl $0x20, %edx
callq 0x8562
decl %ebp
jne 0xe618
leal -0x16(%r12), %r13d
movq 0x20(%rsp), %rax
cmpl 0x20(%rax), %r13d
jge 0xe69a
leaq 0xe51a(%rip), %rdx      # 0x1cb5d
movq %rbx, %rdi
movq %r14, %rsi
movl $0x8, %ecx
callq 0x8a34
leaq 0xe4f1(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r12
movq %r12, %rdi
movl $0x1, %edx
movl %r13d, %ecx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe4ed(%rip), %rdx      # 0x1cb75
movq %rbx, %rdi
movq %r14, %rsi
movl $0x2, %ecx
callq 0x8a34
jmp 0xe6aa
movq %rbx, %rdi
movq %r14, %rsi
movl $0xa, %edx
callq 0x8562
leaq 0xe4a3(%rip), %r12      # 0x1cb54
movq 0x20(%rsp), %rax
movq 0x38(%rax), %rax
cmpl 0x8(%rax), %r15d
jb 0xe44f
jmp 0xece9
leal 0x3(%rbp), %eax
movl %eax, 0x2c(%rsp)
movl %r15d, %eax
movq 0x8(%rsp), %rdx
movzbl (%rdx,%rax), %eax
shll $0x8, %eax
leal 0x2(%rbp), %ecx
movzbl (%rdx,%rcx), %r13d
orl %eax, %r13d
leaq 0xe45a(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r12
movq %r12, %rdi
movl $0x5, %edx
movl %r13d, %ecx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe459(%rip), %rdx      # 0x1cb78
movq %rbx, %rdi
movq %r14, %rsi
movl $0x5, %ecx
callq 0x8a34
leal 0x3(%rbp,%r13), %edx
leaq 0x112e6(%rip), %rsi     # 0x1fa21
leaq 0x14(%rsp), %r12
movq %r12, %rdi
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe414(%rip), %rdx      # 0x1cb75
jmp 0xe7f5
leal 0x3(%rbp), %eax
movl %eax, 0x2c(%rsp)
movl %r15d, %eax
movq 0x8(%rsp), %rcx
movzbl (%rcx,%rax), %eax
shll $0x8, %eax
addl $0x2, %ebp
movzbl (%rcx,%rbp), %ecx
orl %eax, %ecx
movq 0x20(%rsp), %rax
movq 0x18(%rax), %rax
movq 0x60(%rax), %rax
movq (%rax,%rcx,8), %r13
leaq 0xe3ae(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r12
movq %r12, %rdi
movl $0x5, %edx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe35c(%rip), %rdx      # 0x1cb24
movq %rbx, %rdi
movq %r14, %rsi
movl $0x2, %ecx
callq 0x8a34
movl 0x14(%r13), %ecx
addq $0x1c, %r13
movq %rbx, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0x8a34
leaq 0xe371(%rip), %rdx      # 0x1cb66
movq %rbx, %rdi
movq %r14, %rsi
movl $0x2, %ecx
callq 0x8a34
movl 0x2c(%rsp), %r15d
jmp 0xe6aa
addl $0x2, %ebp
movl %r15d, %eax
movq 0x8(%rsp), %rcx
movzbl (%rcx,%rax), %ecx
leaq 0xe326(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r12
movq %r12, %rdi
movl $0x5, %edx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe31f(%rip), %rdx      # 0x1cb6f
movq %rbx, %rdi
movq %r14, %rsi
movl $0x8, %ecx
jmp 0xeb3c
addl $0x2, %ebp
movl %r15d, %eax
movq 0x8(%rsp), %rcx
movzbl (%rcx,%rax), %ecx
movq 0x20(%rsp), %rax
movq 0x18(%rax), %rax
movq 0x30(%rax), %rdx
movq 0x60(%rax), %rax
movslq (%rdx,%rcx,4), %rdx
movq (%rax,%rdx,8), %r13
leaq 0xe2bc(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r12
movq %r12, %rdi
movl $0x5, %edx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe26a(%rip), %rdx      # 0x1cb24
movq %rbx, %rdi
movq %r14, %rsi
movl $0x2, %ecx
callq 0x8a34
movl 0x14(%r13), %ecx
addq $0x1c, %r13
movq %rbx, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0x8a34
leaq 0xe27f(%rip), %rdx      # 0x1cb66
jmp 0xeb31
movl %r15d, %eax
movq 0x8(%rsp), %rcx
movzbl (%rcx,%rax), %ecx
movq 0x20(%rsp), %rax
movq 0x18(%rax), %rax
cmpl %ecx, 0x58(%rax)
jbe 0xed0f
movq 0x50(%rax), %rdx
movl %ecx, %esi
movq (%rdx,%rsi,8), %rdx
movl 0x18(%rdx), %edx
cmpl 0x68(%rax), %edx
leaq 0xe233(%rip), %r12      # 0x1cb54
movq 0x30(%rsp), %r15
jae 0xed14
addl $0x2, %r15d
movq 0x60(%rax), %rax
movq (%rax,%rdx,8), %r13
leaq 0xe20c(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %rbp
movq %rbp, %rdi
movl $0x5, %edx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %rbp, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe1ed(%rip), %rdx      # 0x1cb57
movq %rbx, %rdi
movq %r14, %rsi
movl $0x5, %ecx
callq 0x8a34
movl 0x14(%r13), %ecx
addq $0x1c, %r13
movq %rbx, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0x8a34
leaq 0xe217(%rip), %rdx      # 0x1cbae
movq %rbx, %rdi
movq %r14, %rsi
movl $0x2, %ecx
callq 0x8a34
jmp 0xe6b1
movl %r15d, %eax
movq 0x8(%rsp), %rcx
movzbl (%rcx,%rax), %ecx
movq 0x20(%rsp), %rax
movq 0x18(%rax), %rax
cmpl %ecx, 0x58(%rax)
jbe 0xed05
movq 0x50(%rax), %rdx
movl %ecx, %esi
movq (%rdx,%rsi,8), %rdx
movl 0x18(%rdx), %edx
cmpl 0x68(%rax), %edx
movq 0x30(%rsp), %r15
jae 0xed0a
addl $0x2, %r15d
movq 0x60(%rax), %rax
movq (%rax,%rdx,8), %r13
leaq 0xe153(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r12
movq %r12, %rdi
movl $0x5, %edx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe134(%rip), %rdx      # 0x1cb57
movq %rbx, %rdi
movq %r14, %rsi
movl $0x5, %ecx
callq 0x8a34
movl 0x14(%r13), %ecx
addq $0x1c, %r13
movq %rbx, %rdi
movq %r14, %rsi
movq %r13, %rdx
callq 0x8a34
leaq 0xe15e(%rip), %rdx      # 0x1cbae
movq %rbx, %rdi
movq %r14, %rsi
movl $0x2, %ecx
callq 0x8a34
jmp 0xe6aa
addl $0x2, %ebp
movl %r15d, %eax
movq 0x8(%rsp), %rcx
movzbl (%rcx,%rax), %ecx
movq 0x20(%rsp), %rax
movq 0x18(%rax), %rax
movq 0x40(%rax), %rax
movq (%rax,%rcx,8), %rax
movq 0x10(%rax), %r13
leaq 0xe0bb(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r12
movq %r12, %rdi
movl $0x5, %edx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
jmp 0xeaf4
addl $0x2, %ebp
movl %r15d, %eax
movq 0x8(%rsp), %rcx
movzbl (%rcx,%rax), %r12d
movq %r14, %rdi
movl %r12d, %esi
callq 0x1375a
movq %rax, %r13
leaq 0xe077(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r15
movq %r15, %rdi
movl $0x5, %edx
movl %r12d, %ecx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r15, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe067(%rip), %rdx      # 0x1cb69
movq %rbx, %rdi
movq %r14, %rsi
movl $0x5, %ecx
callq 0x8a34
movq %r13, %rdi
callq 0x2140
movq %rbx, %rdi
movq %r14, %rsi
movq %r13, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xe07d(%rip), %rdx      # 0x1cbae
movq %rbx, %rdi
movq %r14, %rsi
movl $0x2, %ecx
callq 0x8a34
movl %ebp, %r15d
jmp 0xe6aa
leal 0x3(%rbp), %r13d
movl %r15d, %eax
movq 0x8(%rsp), %rcx
movzbl (%rcx,%rax), %eax
shll $0x8, %eax
addl $0x2, %ebp
movzbl (%rcx,%rbp), %ebp
orl %eax, %ebp
movl %ebp, %ecx
negl %ecx
leaq 0xdfdb(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r12
movq %r12, %rdi
movl $0x5, %edx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xdfdd(%rip), %rdx      # 0x1cb78
movq %rbx, %rdi
movq %r14, %rsi
movl $0x5, %ecx
callq 0x8a34
movl %r13d, %edx
subl %ebp, %edx
leaq 0x10e6a(%rip), %rsi     # 0x1fa21
leaq 0x14(%rsp), %r12
movq %r12, %rdi
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
movl %eax, %ecx
callq 0x8a34
leaq 0xdf98(%rip), %rdx      # 0x1cb75
movq %rbx, %rdi
movq %r14, %rsi
movl $0x2, %ecx
callq 0x8a34
movl %r13d, %r15d
jmp 0xe6aa
leal 0x3(%rbp), %r12d
movl %r15d, %eax
movq 0x8(%rsp), %rcx
movzbl (%rcx,%rax), %eax
shll $0x8, %eax
addl $0x2, %ebp
movzbl (%rcx,%rbp), %ecx
orl %eax, %ecx
leaq 0xdf33(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r13
movq %r13, %rdi
movl $0x5, %edx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r13, %rdx
movl %eax, %ecx
callq 0x8a34
movq %rbx, %rdi
movq %r14, %rsi
movl $0xa, %edx
callq 0x8562
movl %r12d, %r15d
jmp 0xe6aa
movl %r15d, %eax
movq 0x8(%rsp), %rdx
movzbl (%rdx,%rax), %eax
shll $0x8, %eax
leal 0x2(%rbp), %ecx
movzbl (%rdx,%rcx), %ecx
orl %eax, %ecx
movq 0x20(%rsp), %rax
movq 0x18(%rax), %rax
cmpl 0x78(%rax), %ecx
jae 0xed19
addl $0x3, %ebp
movq 0x70(%rax), %rax
movl %ecx, %edx
movq (%rax,%rdx,8), %r15
leaq 0xdeb9(%rip), %rsi      # 0x1cb4b
leaq 0x14(%rsp), %r13
movq %r13, %rdi
movl $0x5, %edx
xorl %eax, %eax
callq 0x2360
movq %rbx, %rdi
movq %r14, %rsi
movq %r13, %rdx
movl %eax, %ecx
callq 0x8a34
movq %rbx, %rdi
movq %r14, %rsi
movl $0x20, %edx
callq 0x8562
movq %r14, %rdi
movq %r15, %rsi
movq %rbx, %rdx
callq 0xe338
movq %rbx, %rdi
movq %r14, %rsi
movl $0xa, %edx
callq 0x8562
jmp 0xeb41
movq %rbx, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x8562
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x4899
callq 0x48cf
callq 0x4905
callq 0x493b
callq 0x4971
callq 0x49a5