// File: /workspace/github_c_makefile_star2_O2/fukunagatsu[P]RIblast/db_construction.cpp
// Function: DbConstruction::Run(DbConstructionParameters)
void DbConstruction::Run(const DbConstructionParameters parameters){
  vector<string> sequences; sequences.reserve(10);
  vector<unsigned char> encoded_sequences;
  vector<int> suffix_array;
  vector<vector <int> > start_hash; start_hash.reserve(parameters.GetHashSize());
  vector<vector <int> > end_hash; start_hash.reserve(parameters.GetHashSize());

  ReadFastaFile(parameters, sequences);
  CalculateAccessibility(parameters,sequences);
  ConstructSuffixArray(parameters, sequences,encoded_sequences,suffix_array);
  ConstructHashForShortSubstring(parameters, encoded_sequences, suffix_array, start_hash, end_hash);

  SaveIndexData(parameters.GetDbFilename(), suffix_array, start_hash, end_hash);
  SaveSequenceData(parameters.GetDbFilename(), sequences, encoded_sequences);
  
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x218, %rsp            # imm = 0x218
movq %rsi, %rbx
movq %rdi, %r14
xorps %xmm0, %xmm0
leaq 0x40(%rsp), %rdi
movaps %xmm0, (%rdi)
andq $0x0, 0x10(%rdi)
pushq $0xa
popq %rsi
callq 0x5f58
andq $0x0, 0x30(%rsp)
andq $0x0, 0x10(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, 0x20(%rsp)
movaps %xmm0, (%rsp)
leaq 0x80(%rsp), %rdi
movaps %xmm0, (%rdi)
andq $0x0, 0x10(%rdi)
movslq 0x40(%rbx), %rsi
callq 0x4020
xorps %xmm0, %xmm0
movaps %xmm0, 0x60(%rsp)
andq $0x0, 0x70(%rsp)
movslq 0x40(%rbx), %rsi
leaq 0x80(%rsp), %rdi
callq 0x4020
leaq 0x1c8(%rsp), %rdi
movq %rbx, %rsi
callq 0x3c10
leaq 0x1c8(%rsp), %rsi
leaq 0x40(%rsp), %rdx
movq %r14, %rdi
callq 0x55ba
leaq 0x1c8(%rsp), %rdi
callq 0x3c50
leaq 0x178(%rsp), %rdi
movq %rbx, %rsi
callq 0x3c10
leaq 0x178(%rsp), %rsi
leaq 0x40(%rsp), %rdx
callq 0x5682
leaq 0x178(%rsp), %rdi
callq 0x3c50
leaq 0x128(%rsp), %rdi
movq %rbx, %rsi
callq 0x3c10
leaq 0x128(%rsp), %rsi
leaq 0x40(%rsp), %rdx
leaq 0x20(%rsp), %rcx
movq %rsp, %r8
callq 0x5732
leaq 0x128(%rsp), %rdi
callq 0x3c50
leaq 0xd8(%rsp), %rdi
movq %rbx, %rsi
callq 0x3c10
leaq 0xd8(%rsp), %rsi
leaq 0x20(%rsp), %rdx
movq %rsp, %rcx
leaq 0x80(%rsp), %r8
leaq 0x60(%rsp), %r9
movq %r14, %rdi
callq 0x579a
leaq 0xd8(%rsp), %rdi
callq 0x3c50
leaq 0xb8(%rsp), %rdi
movq %rbx, %rsi
callq 0x32d0
leaq 0xb8(%rsp), %rsi
movq %rsp, %rdx
leaq 0x80(%rsp), %rcx
leaq 0x60(%rsp), %r8
callq 0x59e0
leaq 0xb8(%rsp), %rdi
callq 0x3100
leaq 0x98(%rsp), %rdi
movq %rbx, %rsi
callq 0x32d0
leaq 0x98(%rsp), %rsi
leaq 0x40(%rsp), %rdx
leaq 0x20(%rsp), %rcx
callq 0x5b66
leaq 0x98(%rsp), %rdi
callq 0x3100
leaq 0x60(%rsp), %rdi
callq 0x4122
leaq 0x80(%rsp), %rdi
callq 0x4122
movq %rsp, %rdi
callq 0x4632
leaq 0x20(%rsp), %rdi
callq 0x4710
leaq 0x40(%rsp), %rdi
callq 0x4144
addq $0x218, %rsp            # imm = 0x218
popq %rbx
popq %r14
retq
movq %rax, %rbx
leaq 0x98(%rsp), %rdi
jmp 0x5532
movq %rax, %rbx
leaq 0xb8(%rsp), %rdi
callq 0x3100
jmp 0x557f
movq %rax, %rbx
leaq 0xd8(%rsp), %rdi
jmp 0x556b
movq %rax, %rbx
leaq 0x128(%rsp), %rdi
jmp 0x556b
movq %rax, %rbx
leaq 0x178(%rsp), %rdi
jmp 0x556b
movq %rax, %rbx
leaq 0x1c8(%rsp), %rdi
callq 0x3c50
jmp 0x557f
movq %rax, %rbx
jmp 0x5589
movq %rax, %rbx
jmp 0x55a8
movq %rax, %rbx
leaq 0x60(%rsp), %rdi
callq 0x4122
leaq 0x80(%rsp), %rdi
callq 0x4122
movq %rsp, %rdi
callq 0x4632
leaq 0x20(%rsp), %rdi
callq 0x4710
leaq 0x40(%rsp), %rdi
callq 0x4144
movq %rbx, %rdi
callq 0x33a0