// File: /workspace/github_c_makefile_star2_O0/fukunagatsu[P]RIblast/db_construction.cpp
// Function: DbConstruction::SaveIndexData(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::vector<int, std::allocator<int>>&, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>>&, std::vector<std::vector<int, std::allocator<int>>, std::allocator<std::vector<int, std::allocator<int>>>>&)
void  DbConstruction::SaveIndexData(string file_name, vector<int> &suffix_array, vector<vector <int> > &start_hash, vector<vector <int> > &end_hash){
  ofstream of((file_name+".ind").c_str(), ios::out | ios::binary);
  int count = suffix_array.size();
  vector<int>::iterator it;
  of.write(reinterpret_cast<const char*>(&count), sizeof(int));
  for(it = suffix_array.begin(); it != suffix_array.end(); it++){
    of.write(reinterpret_cast<const char*>(&*it), sizeof(int));
  }
  for(int i = 0; i< start_hash.size();i++){
    for(it = start_hash[i].begin(); it != start_hash[i].end(); it++){
      of.write(reinterpret_cast<const char*>(&*it), sizeof(int));
    }
  }
  for(int i = 0; i< end_hash.size();i++){
    for(it = end_hash[i].begin(); it != end_hash[i].end(); it++){
      of.write(reinterpret_cast<const char*>(&*it), sizeof(int));
    }
  }
  of.close();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x2e0, %rsp            # imm = 0x2E0
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
leaq 0x2e407(%rip), %rdx     # 0x3886d
leaq -0x248(%rbp), %rdi
movq %rdi, -0x2d0(%rbp)
callq 0xbc70
movq -0x2d0(%rbp), %rdi
callq 0x3110
movq %rax, -0x2c8(%rbp)
movl $0x10, %edi
movl $0x4, %esi
callq 0xbcf0
movl %eax, -0x2bc(%rbp)
jmp 0xa4a3
movl -0x2bc(%rbp), %edx
movq -0x2c8(%rbp), %rsi
leaq -0x228(%rbp), %rdi
callq 0x32e0
jmp 0xa4be
leaq -0x248(%rbp), %rdi
callq 0x3190
movq -0x18(%rbp), %rdi
callq 0x55a0
movl %eax, -0x258(%rbp)
leaq -0x260(%rbp), %rdi
callq 0xbe30
leaq -0x228(%rbp), %rdi
leaq -0x258(%rbp), %rsi
movl $0x4, %edx
callq 0x33a0
jmp 0xa4ff
movq -0x18(%rbp), %rdi
callq 0x5f20
movq %rax, -0x268(%rbp)
movq -0x268(%rbp), %rax
movq %rax, -0x260(%rbp)
movq -0x18(%rbp), %rdi
callq 0x5ba0
movq %rax, -0x270(%rbp)
leaq -0x260(%rbp), %rdi
leaq -0x270(%rbp), %rsi
callq 0xbe50
testb $0x1, %al
jne 0xa549
jmp 0xa5ca
leaq -0x260(%rbp), %rdi
callq 0xbe90
movq %rax, %rsi
leaq -0x228(%rbp), %rdi
movl $0x4, %edx
callq 0x33a0
jmp 0xa56b
jmp 0xa56d
leaq -0x260(%rbp), %rdi
xorl %esi, %esi
callq 0xbeb0
movq %rax, -0x278(%rbp)
jmp 0xa51d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x250(%rbp)
movl %eax, -0x254(%rbp)
leaq -0x248(%rbp), %rdi
callq 0x3190
jmp 0xa7c1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x250(%rbp)
movl %eax, -0x254(%rbp)
leaq -0x228(%rbp), %rdi
callq 0x3410
jmp 0xa7c1
movl $0x0, -0x27c(%rbp)
movslq -0x27c(%rbp), %rax
movq %rax, -0x2d8(%rbp)
movq -0x20(%rbp), %rdi
callq 0x4f80
movq %rax, %rcx
movq -0x2d8(%rbp), %rax
cmpq %rcx, %rax
jae 0xa6b4
movq -0x20(%rbp), %rdi
movslq -0x27c(%rbp), %rsi
callq 0xbbe0
movq %rax, %rdi
callq 0x5f20
movq %rax, -0x288(%rbp)
movq -0x288(%rbp), %rax
movq %rax, -0x260(%rbp)
movq -0x20(%rbp), %rdi
movslq -0x27c(%rbp), %rsi
callq 0xbbe0
movq %rax, %rdi
callq 0x5ba0
movq %rax, -0x290(%rbp)
leaq -0x260(%rbp), %rdi
leaq -0x290(%rbp), %rsi
callq 0xbe50
testb $0x1, %al
jne 0xa663
jmp 0xa69e
leaq -0x260(%rbp), %rdi
callq 0xbe90
movq %rax, %rsi
leaq -0x228(%rbp), %rdi
movl $0x4, %edx
callq 0x33a0
jmp 0xa685
jmp 0xa687
leaq -0x260(%rbp), %rdi
xorl %esi, %esi
callq 0xbeb0
movq %rax, -0x298(%rbp)
jmp 0xa62b
jmp 0xa6a0
movl -0x27c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x27c(%rbp)
jmp 0xa5d4
movl $0x0, -0x29c(%rbp)
movslq -0x29c(%rbp), %rax
movq %rax, -0x2e0(%rbp)
movq -0x28(%rbp), %rdi
callq 0x4f80
movq %rax, %rcx
movq -0x2e0(%rbp), %rax
cmpq %rcx, %rax
jae 0xa79e
movq -0x28(%rbp), %rdi
movslq -0x29c(%rbp), %rsi
callq 0xbbe0
movq %rax, %rdi
callq 0x5f20
movq %rax, -0x2a8(%rbp)
movq -0x2a8(%rbp), %rax
movq %rax, -0x260(%rbp)
movq -0x28(%rbp), %rdi
movslq -0x29c(%rbp), %rsi
callq 0xbbe0
movq %rax, %rdi
callq 0x5ba0
movq %rax, -0x2b0(%rbp)
leaq -0x260(%rbp), %rdi
leaq -0x2b0(%rbp), %rsi
callq 0xbe50
testb $0x1, %al
jne 0xa74d
jmp 0xa788
leaq -0x260(%rbp), %rdi
callq 0xbe90
movq %rax, %rsi
leaq -0x228(%rbp), %rdi
movl $0x4, %edx
callq 0x33a0
jmp 0xa76f
jmp 0xa771
leaq -0x260(%rbp), %rdi
xorl %esi, %esi
callq 0xbeb0
movq %rax, -0x2b8(%rbp)
jmp 0xa715
jmp 0xa78a
movl -0x29c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x29c(%rbp)
jmp 0xa6be
leaq -0x228(%rbp), %rdi
callq 0x33f0
jmp 0xa7ac
leaq -0x228(%rbp), %rdi
callq 0x3410
addq $0x2e0, %rsp            # imm = 0x2E0
popq %rbp
retq
movq -0x250(%rbp), %rdi
callq 0x34d0
nopl (%rax)