// File: luooofan[P]hblzbd_compiler/src/generate_ir.cpp
// Function: ast::ArrayDefineWithInit::GenerateIR(ir::ContextInfo&, std::vector<ir::IR*, std::allocator<ir::IR*>>&)
void ArrayDefineWithInit::GenerateIR(ir::ContextInfo &ctx, std::vector<ir::IR *> &gIRList) {
  auto &name = this->name_.name_.name_;
  auto &scope = ir::gScopes[ctx.scope_id_];
  auto &symbol_table = scope.symbol_table_;
  // NOTE: 只需在当前作用域查找即可 找到则重定义
  const auto &array_iter = symbol_table.find(name);
  if (array_iter == symbol_table.end()) {
    // NOTE: 常量数组不一定能删 因为可能会有变量下标
    // if (this->is_const_) {
    // symbol_table.insert({name, ir::SymbolTableItem(true, true, -1)});
    // } else {
    symbol_table.insert({name, ir::SymbolTableItem(true, this->is_const_)});
    // }
    auto &symbol_item = symbol_table.find(name)->second;
    // 填shape
    for (const auto &shape : this->name_.shape_list_) {
      shape->Evaluate(ctx, gIRList);
      // 如果Evaluate没有执行成功会直接退出程序
      // 如果执行成功说明返回的一定是立即数
      symbol_item.shape_.push_back(ctx.opn_.imm_num_);
    }

    // 填width和dim total num
    std::stack<int> temp_width;
    int width = ir::kIntWidth;
    temp_width.push(width);
    for (auto reiter = symbol_item.shape_.rbegin(); reiter != symbol_item.shape_.rend(); ++reiter) {
      width *= *reiter;
      temp_width.push(width);
    }
    while (!temp_width.empty()) {
      symbol_item.width_.push_back(temp_width.top());
      temp_width.pop();
    }

    // 完成赋值操作 或者 填写initval(global or const)
    // prepare for arrayinitval
    ctx.dim_total_num_.clear();
    for (const auto width : symbol_item.width_) {
      ctx.dim_total_num_.push_back(width / ir::kIntWidth);
    }
    // ctx.dim_total_num_.push_back(1);
    ctx.array_name_ = name;
    ctx.array_offset_ = 0;
    ctx.brace_num_ = 1;

    if (ctx.scope_id_ == 0) {
      this->value_.Evaluate(ctx, gIRList);
    } else {
      // GenIR ALLOCA
      gIRList.push_back(new ir::IR{IROpKind::ALLOCA,
                                   ir::Opn{OpnType::Array, name, ctx.scope_id_, new ir::Opn(OpnType::Imm, 0)},
                                   ir::Opn{OpnType::Imm, symbol_item.width_[0]}});
      gIRList.push_back(new ir::IR(IROpKind::PARAM, {OpnType::Imm, symbol_item.width_[0]}));
      gIRList.push_back(new ir::IR(IROpKind::PARAM, IMM_0_OPN));
      gIRList.push_back(
          new ir::IR(IROpKind::PARAM, {OpnType::Array, name, ctx.scope_id_, new ir::Opn(OpnType::Imm, 0)}));
      ir::Opn temp = ir::Opn(OpnType::Null);
      // ctx.opn_ = temp;
      // ctx.shape_.clear();
      // TODO: 这里用name会导致段错误
      auto opn1 = ir::Opn(OpnType::Func, std::string("memset"));
      auto opn2 = ir::Opn(OpnType::Imm, 3);
      gIRList.push_back(new ir::IR(IROpKind::CALL, opn1, opn2, temp));
      if (this->is_const_) {
        ctx.array_offset_ = 0;
        ctx.brace_num_ = 1;
        this->value_.Evaluate(ctx, gIRList);
      }
      ctx.array_offset_ = 0;
      ctx.brace_num_ = 1;
      this->value_.GenerateIR(ctx, gIRList);
    }
  } else {
    ir::SemanticError(this->line_no_, this->name_.name_.name_ + ": variable redefined");
  }
}

// Assembly:
subq $0x678, %rsp            # imm = 0x678
movq %rdi, 0x670(%rsp)
movq %rsi, 0x668(%rsp)
movq %rdx, 0x660(%rsp)
movq 0x670(%rsp), %rax
movq %rax, 0xf0(%rsp)
movq 0x10(%rax), %rax
movq 0x10(%rax), %rax
movq 0x10(%rax), %rax
movq %rax, 0x658(%rsp)
movq 0x668(%rsp), %rax
movslq (%rax), %rsi
leaq 0x125b73(%rip), %rdi    # 0x14c628
callq 0x183c0
movq %rax, 0x650(%rsp)
movq 0x650(%rsp), %rax
movq %rax, 0x648(%rsp)
movq 0x648(%rsp), %rdi
movq 0x658(%rsp), %rsi
callq 0x1f270
movq %rax, 0x638(%rsp)
leaq 0x638(%rsp), %rax
movq %rax, 0x640(%rsp)
movq 0x640(%rsp), %rax
movq %rax, 0xf8(%rsp)
movq 0x648(%rsp), %rdi
callq 0x109d0
movq 0xf8(%rsp), %rdi
movq %rax, 0x630(%rsp)
leaq 0x630(%rsp), %rsi
callq 0x36e80
testb $0x1, %al
jne 0x26b42
jmp 0x27947
movq 0xf0(%rsp), %rax
movq 0x648(%rsp), %rcx
movq %rcx, 0xd8(%rsp)
movq 0x658(%rsp), %rcx
movq %rcx, 0xe0(%rsp)
movzbl 0xc(%rax), %edx
andl $0x1, %edx
leaq 0x570(%rsp), %rdi
movq %rdi, 0xe8(%rsp)
movl $0x1, %esi
callq 0x366c0
movq 0xe0(%rsp), %rsi
movq 0xe8(%rsp), %rdx
leaq 0x5c0(%rsp), %rdi
callq 0x36f40
jmp 0x26baa
movq 0xd8(%rsp), %rdi
leaq 0x5c0(%rsp), %rsi
callq 0x36670
movb %dl, 0xcf(%rsp)
movq %rax, 0xd0(%rsp)
jmp 0x26bd0
movb 0xcf(%rsp), %al
movq 0xd0(%rsp), %rcx
movq %rcx, 0x550(%rsp)
movb %al, 0x558(%rsp)
leaq 0x5c0(%rsp), %rdi
callq 0x36810
leaq 0x570(%rsp), %rdi
callq 0x36840
movq 0x648(%rsp), %rdi
movq 0x658(%rsp), %rsi
callq 0x1f270
movq %rax, 0x540(%rsp)
leaq 0x540(%rsp), %rdi
callq 0x36f80
movq %rax, %rcx
movq 0xf0(%rsp), %rax
addq $0x20, %rcx
movq %rcx, 0x548(%rsp)
movq 0x10(%rax), %rax
addq $0x18, %rax
movq %rax, 0x538(%rsp)
movq 0x538(%rsp), %rdi
callq 0x14bc0
movq %rax, 0x530(%rsp)
movq 0x538(%rsp), %rdi
callq 0x14bf0
movq %rax, 0x528(%rsp)
leaq 0x530(%rsp), %rdi
leaq 0x528(%rsp), %rsi
callq 0x14c20
testb $0x1, %al
jne 0x26ca1
jmp 0x26d58
leaq 0x530(%rsp), %rdi
callq 0x14c60
movq %rax, 0x520(%rsp)
movq 0x520(%rsp), %rdi
callq 0x14c70
movq %rax, %rdi
movq 0x668(%rsp), %rsi
movq 0x660(%rsp), %rdx
movq (%rdi), %rax
callq *0x18(%rax)
movq 0x548(%rsp), %rdi
addq $0x8, %rdi
movq 0x668(%rsp), %rsi
addq $0x8, %rsi
addq $0x4, %rsi
callq 0x1f2a0
leaq 0x530(%rsp), %rdi
callq 0x14c80
jmp 0x26c83
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x26d46
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
leaq 0x5c0(%rsp), %rdi
callq 0x36810
leaq 0x570(%rsp), %rdi
callq 0x36840
jmp 0x279c5
leaq 0x4d0(%rsp), %rdi
movq %rdi, 0xc0(%rsp)
callq 0x37040
movq 0xc0(%rsp), %rdi
leaq 0xd440c(%rip), %rax     # 0xfb188
movl (%rax), %eax
movl %eax, 0x4cc(%rsp)
leaq 0x4cc(%rsp), %rsi
callq 0x37070
jmp 0x26d94
movq 0x548(%rsp), %rsi
addq $0x8, %rsi
leaq 0x4c0(%rsp), %rdi
callq 0x370a0
movq 0x548(%rsp), %rsi
addq $0x8, %rsi
leaq 0x4b8(%rsp), %rdi
movq %rdi, 0xb0(%rsp)
callq 0x37120
movq 0xb0(%rsp), %rsi
leaq 0x4c0(%rsp), %rdi
callq 0x370f0
movb %al, 0xbf(%rsp)
jmp 0x26dec
movb 0xbf(%rsp), %al
testb $0x1, %al
jne 0x26df9
jmp 0x26e71
leaq 0x4c0(%rsp), %rdi
callq 0x37170
movq %rax, 0xa8(%rsp)
jmp 0x26e10
movq 0xa8(%rsp), %rax
movl (%rax), %ecx
movl 0x4cc(%rsp), %eax
imull %ecx, %eax
movl %eax, 0x4cc(%rsp)
leaq 0x4d0(%rsp), %rdi
leaq 0x4cc(%rsp), %rsi
callq 0x37070
jmp 0x26e42
jmp 0x26e44
leaq 0x4c0(%rsp), %rdi
callq 0x371a0
jmp 0x26e53
jmp 0x26dad
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x27938
jmp 0x26e73
leaq 0x4d0(%rsp), %rdi
callq 0x371d0
movb %al, 0xa7(%rsp)
jmp 0x26e89
movb 0xa7(%rsp), %al
xorb $-0x1, %al
testb $0x1, %al
jne 0x26e98
jmp 0x26eeb
movq 0x548(%rsp), %rax
addq $0x20, %rax
movq %rax, 0x90(%rsp)
leaq 0x4d0(%rsp), %rdi
callq 0x371f0
movq %rax, 0x98(%rsp)
jmp 0x26ec3
movq 0x98(%rsp), %rsi
movq 0x90(%rsp), %rdi
callq 0x1f2a0
jmp 0x26eda
leaq 0x4d0(%rsp), %rdi
callq 0x37200
jmp 0x26ee9
jmp 0x26e73
movq 0x668(%rsp), %rdi
addq $0x90, %rdi
callq 0x361a0
movq 0x548(%rsp), %rax
addq $0x20, %rax
movq %rax, 0x4b0(%rsp)
movq 0x4b0(%rsp), %rdi
callq 0x1fc30
movq %rax, 0x4a8(%rsp)
movq 0x4b0(%rsp), %rdi
callq 0x1f470
movq %rax, 0x4a0(%rsp)
leaq 0x4a8(%rsp), %rdi
leaq 0x4a0(%rsp), %rsi
callq 0x37210
testb $0x1, %al
jne 0x26f58
jmp 0x26fb7
leaq 0x4a8(%rsp), %rdi
callq 0x37250
movl (%rax), %eax
movl %eax, 0x49c(%rsp)
movq 0x668(%rsp), %rdi
addq $0x90, %rdi
movl 0x49c(%rsp), %eax
leaq 0xd41fd(%rip), %rcx     # 0xfb188
movl (%rcx), %ecx
cltd
idivl %ecx
movl %eax, 0x498(%rsp)
leaq 0x498(%rsp), %rsi
callq 0x36ea0
jmp 0x26fa6
jmp 0x26fa8
leaq 0x4a8(%rsp), %rdi
callq 0x37260
jmp 0x26f3d
movq 0x658(%rsp), %rsi
movq 0x668(%rsp), %rdi
addq $0x68, %rdi
callq 0x8050
jmp 0x26fd2
movq 0x668(%rsp), %rax
movl $0x0, 0x88(%rax)
movq 0x668(%rsp), %rax
movl $0x1, 0x8c(%rax)
movq 0x668(%rsp), %rax
cmpl $0x0, (%rax)
jne 0x2702f
movq 0xf0(%rsp), %rax
movq 0x18(%rax), %rdi
movq 0x668(%rsp), %rsi
movq 0x660(%rsp), %rdx
movq (%rdi), %rax
movq 0x18(%rax), %rax
callq *%rax
jmp 0x2702a
jmp 0x27926
movq 0x660(%rsp), %rax
movq %rax, 0x80(%rsp)
movl $0xe0, %edi
callq 0x8340
movq %rax, 0x88(%rsp)
jmp 0x27053
movb $0x1, 0x3ef(%rsp)
movq 0x658(%rsp), %rsi
leaq 0x430(%rsp), %rdi
callq 0x81a0
jmp 0x27072
movq 0x668(%rsp), %rax
movl (%rax), %eax
movl %eax, 0x74(%rsp)
movl $0x40, %edi
callq 0x8340
movq %rax, 0x78(%rsp)
jmp 0x27091
movq 0x78(%rsp), %rdi
movl $0x1, %esi
xorl %edx, %edx
callq 0x1f160
jmp 0x270a4
movq 0x78(%rsp), %r8
movl 0x74(%rsp), %ecx
leaq 0x450(%rsp), %rdi
movl $0x5, %esi
leaq 0x430(%rsp), %rdx
callq 0x36610
jmp 0x270c9
movq 0x548(%rsp), %rdi
addq $0x20, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x10a60
movl (%rax), %edx
leaq 0x3f0(%rsp), %rdi
movl $0x1, %esi
callq 0x1f160
jmp 0x270f4
movq 0x88(%rsp), %rdi
movl $0x16, %esi
leaq 0x450(%rsp), %rdx
leaq 0x3f0(%rsp), %rcx
callq 0x36880
jmp 0x27118
movq 0x80(%rsp), %rdi
movq 0x88(%rsp), %rax
movb $0x0, 0x3ef(%rsp)
movq %rax, 0x490(%rsp)
leaq 0x490(%rsp), %rsi
callq 0x185b0
jmp 0x27147
leaq 0x3f0(%rsp), %rdi
callq 0x1f210
leaq 0x450(%rsp), %rdi
callq 0x1f210
leaq 0x430(%rsp), %rdi
callq 0x8728
movq 0x660(%rsp), %rax
movq %rax, 0x60(%rsp)
movl $0xe0, %edi
callq 0x8340
movq %rax, 0x68(%rsp)
jmp 0x2718c
movb $0x1, 0x39f(%rsp)
movq 0x548(%rsp), %rdi
addq $0x20, %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x10a60
movl (%rax), %edx
leaq 0x3a0(%rsp), %rdi
movl $0x1, %esi
callq 0x1f160
jmp 0x271bf
movq 0x68(%rsp), %rdi
movl $0x8, %esi
leaq 0x3a0(%rsp), %rdx
callq 0x36c00
jmp 0x271d8
movq 0x60(%rsp), %rdi
movq 0x68(%rsp), %rax
movb $0x0, 0x39f(%rsp)
movq %rax, 0x3e0(%rsp)
leaq 0x3e0(%rsp), %rsi
callq 0x185b0
jmp 0x27201
leaq 0x3a0(%rsp), %rdi
callq 0x1f210
movq 0x660(%rsp), %rax
movq %rax, 0x50(%rsp)
movl $0xe0, %edi
callq 0x8340
movq %rax, 0x58(%rsp)
jmp 0x2722c
movb $0x1, 0x34f(%rsp)
leaq 0x350(%rsp), %rdi
movl $0x1, %esi
xorl %edx, %edx
callq 0x1f160
jmp 0x2724a
movq 0x58(%rsp), %rdi
movl $0x8, %esi
leaq 0x350(%rsp), %rdx
callq 0x36c00
jmp 0x27263
movq 0x50(%rsp), %rdi
movq 0x58(%rsp), %rax
movb $0x0, 0x34f(%rsp)
movq %rax, 0x390(%rsp)
leaq 0x390(%rsp), %rsi
callq 0x185b0
jmp 0x2728c
leaq 0x350(%rsp), %rdi
callq 0x1f210
movq 0x660(%rsp), %rax
movq %rax, 0x40(%rsp)
movl $0xe0, %edi
callq 0x8340
movq %rax, 0x48(%rsp)
jmp 0x272b7
movb $0x1, 0x2df(%rsp)
movq 0x658(%rsp), %rsi
leaq 0x2e0(%rsp), %rdi
callq 0x81a0
jmp 0x272d6
movq 0x668(%rsp), %rax
movl (%rax), %eax
movl %eax, 0x34(%rsp)
movl $0x40, %edi
callq 0x8340
movq %rax, 0x38(%rsp)
jmp 0x272f5
movq 0x38(%rsp), %rdi
movl $0x1, %esi
xorl %edx, %edx
callq 0x1f160
jmp 0x27308
movq 0x38(%rsp), %r8
movl 0x34(%rsp), %ecx
leaq 0x300(%rsp), %rdi
movl $0x5, %esi
leaq 0x2e0(%rsp), %rdx
callq 0x36610
jmp 0x2732d
movq 0x48(%rsp), %rdi
movl $0x8, %esi
leaq 0x300(%rsp), %rdx
callq 0x36c00
jmp 0x27346
movq 0x40(%rsp), %rdi
movq 0x48(%rsp), %rax
movb $0x0, 0x2df(%rsp)
movq %rax, 0x340(%rsp)
leaq 0x340(%rsp), %rsi
callq 0x185b0
jmp 0x2736f
leaq 0x300(%rsp), %rdi
callq 0x1f210
leaq 0x2e0(%rsp), %rdi
callq 0x8728
leaq 0x298(%rsp), %rdi
movl $0x4, %esi
callq 0x36dd0
jmp 0x2739d
leaq 0x237(%rsp), %rdi
movq %rdi, 0x28(%rsp)
callq 0x8680
movq 0x28(%rsp), %rdx
leaq 0xd3570(%rip), %rsi     # 0xfa92b
leaq 0x238(%rsp), %rdi
callq 0xc570
jmp 0x273ca
leaq 0x258(%rsp), %rdi
movl $0x3, %esi
leaq 0x238(%rsp), %rdx
callq 0x36d70
jmp 0x273e6
leaq 0x238(%rsp), %rdi
callq 0x8728
leaq 0x237(%rsp), %rdi
callq 0x83c0
leaq 0x1f0(%rsp), %rdi
movl $0x1, %esi
movl $0x3, %edx
callq 0x1f160
jmp 0x27419
movq 0x660(%rsp), %rax
movq %rax, 0x18(%rsp)
movl $0xe0, %edi
callq 0x8340
movq %rax, 0x20(%rsp)
jmp 0x27437
movb $0x1, 0x127(%rsp)
leaq 0x1a8(%rsp), %rdi
leaq 0x258(%rsp), %rsi
callq 0x43130
jmp 0x27456
leaq 0x168(%rsp), %rdi
leaq 0x1f0(%rsp), %rsi
callq 0x43130
jmp 0x2746d
leaq 0x128(%rsp), %rdi
leaq 0x298(%rsp), %rsi
callq 0x43130
jmp 0x27484
movq 0x20(%rsp), %rdi
movl $0x9, %esi
leaq 0x1a8(%rsp), %rdx
leaq 0x168(%rsp), %rcx
leaq 0x128(%rsp), %r8
callq 0x36a60
jmp 0x274ad
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rax
movb $0x0, 0x127(%rsp)
movq %rax, 0x1e8(%rsp)
leaq 0x1e8(%rsp), %rsi
callq 0x185b0
jmp 0x274d6
leaq 0x128(%rsp), %rdi
callq 0x1f210
leaq 0x168(%rsp), %rdi
callq 0x1f210
leaq 0x1a8(%rsp), %rdi
callq 0x1f210
movq 0xf0(%rsp), %rax
testb $0x1, 0xc(%rax)
je 0x27889
movq 0xf0(%rsp), %rax
movq 0x668(%rsp), %rcx
movl $0x0, 0x88(%rcx)
movq 0x668(%rsp), %rcx
movl $0x1, 0x8c(%rcx)
movq 0x18(%rax), %rdi
movq 0x668(%rsp), %rsi
movq 0x660(%rsp), %rdx
movq (%rdi), %rax
movq 0x18(%rax), %rax
callq *%rax
jmp 0x2755a
jmp 0x27889
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x27604
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x275f7
movq 0x78(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
movl $0x40, %esi
callq 0x8350
jmp 0x275f7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x275ea
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
leaq 0x3f0(%rsp), %rdi
callq 0x1f210
leaq 0x450(%rsp), %rdi
callq 0x1f210
leaq 0x430(%rsp), %rdi
callq 0x8728
testb $0x1, 0x3ef(%rsp)
jne 0x27610
jmp 0x27622
movq 0x88(%rsp), %rdi
movl $0xe0, %esi
callq 0x8350
jmp 0x27938
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x2765e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
leaq 0x3a0(%rsp), %rdi
callq 0x1f210
testb $0x1, 0x39f(%rsp)
jne 0x2766a
jmp 0x27679
movq 0x68(%rsp), %rdi
movl $0xe0, %esi
callq 0x8350
jmp 0x27938
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x276b5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
leaq 0x350(%rsp), %rdi
callq 0x1f210
testb $0x1, 0x34f(%rsp)
jne 0x276c1
jmp 0x276d0
movq 0x58(%rsp), %rdi
movl $0xe0, %esi
callq 0x8350
jmp 0x27938
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x27754
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x27747
movq 0x38(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
movl $0x40, %esi
callq 0x8350
jmp 0x27747
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
leaq 0x300(%rsp), %rdi
callq 0x1f210
leaq 0x2e0(%rsp), %rdi
callq 0x8728
testb $0x1, 0x2df(%rsp)
jne 0x27760
jmp 0x2776f
movq 0x48(%rsp), %rdi
movl $0xe0, %esi
callq 0x8350
jmp 0x27938
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x277ab
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
leaq 0x238(%rsp), %rdi
callq 0x8728
leaq 0x237(%rsp), %rdi
callq 0x83c0
jmp 0x27917
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x2790a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x278fd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x2786c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x2785f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
jmp 0x27852
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
leaq 0x128(%rsp), %rdi
callq 0x1f210
leaq 0x168(%rsp), %rdi
callq 0x1f210
leaq 0x1a8(%rsp), %rdi
callq 0x1f210
testb $0x1, 0x127(%rsp)
jne 0x27878
jmp 0x27887
movq 0x20(%rsp), %rdi
movl $0xe0, %esi
callq 0x8350
jmp 0x278fd
movq 0xf0(%rsp), %rax
movq 0x668(%rsp), %rcx
movl $0x0, 0x88(%rcx)
movq 0x668(%rsp), %rcx
movl $0x1, 0x8c(%rcx)
movq 0x18(%rax), %rdi
movq 0x668(%rsp), %rsi
movq 0x660(%rsp), %rdx
movq (%rdi), %rax
movq 0x10(%rax), %rax
callq *%rax
jmp 0x278d4
leaq 0x1f0(%rsp), %rdi
callq 0x1f210
leaq 0x258(%rsp), %rdi
callq 0x1f210
leaq 0x298(%rsp), %rdi
callq 0x1f210
jmp 0x27926
leaq 0x1f0(%rsp), %rdi
callq 0x1f210
leaq 0x258(%rsp), %rdi
callq 0x1f210
leaq 0x298(%rsp), %rdi
callq 0x1f210
jmp 0x27938
leaq 0x4d0(%rsp), %rdi
callq 0x37280
jmp 0x279bd
leaq 0x4d0(%rsp), %rdi
callq 0x37280
jmp 0x279c5
movq 0xf0(%rsp), %rax
movl 0x8(%rax), %ecx
movl %ecx, 0xc(%rsp)
movq 0x10(%rax), %rax
movq 0x10(%rax), %rax
movq 0x10(%rax), %rsi
leaq 0xd3221(%rip), %rdx     # 0xfab8a
leaq 0x100(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0xc720
movl 0xc(%rsp), %edi
movq 0x10(%rsp), %rsi
callq 0x47ce0
jmp 0x2798b
leaq 0x100(%rsp), %rdi
callq 0x8728
jmp 0x279bd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x568(%rsp)
movl %eax, 0x564(%rsp)
leaq 0x100(%rsp), %rdi
callq 0x8728
jmp 0x279c5
addq $0x678, %rsp            # imm = 0x678
retq
movq 0x568(%rsp), %rdi
callq 0x8670
nopw %cs:(%rax,%rax)