// File: /workspace/github_cpp_makefile_star2_O2/ncbi[P]amr/seq.cpp
// Function: Seq_sp::KmerIndex::find(Seq_sp::Dna const&)
Vector<KmerIndex::NumId> KmerIndex::find (const Dna &dna) 
{
  ASSERT (canRead);
  
  unordered_map<string,size_t> id2num;  id2num. rehash (100000);  // PAR
  const size_t seqSize = dna. seq. size ();
  FOR (size_t, i, seqSize)
    if (i + kmer_size <= seqSize)
    {
      const Dna kmer ("x", dna. seq. substr (i, kmer_size), false);
      kmer. qc ();
      ASSERT (kmer. seq. size () == kmer_size);
      if (kmer. getXs ())
        continue;
      const StringVector ids (code2ids (dna2code (kmer)));
      for (const string& id : ids)
        id2num [id] ++;
    }
    
  Vector<NumId> num2id;  num2id. reserve (id2num. size ());
  for (const auto& it : id2num)
    num2id << std::move (NumId (it. second, it. first));
  num2id. sort ();
  
  return num2id; 
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1b8, %rsp            # imm = 0x1B8
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
callq 0xc070
movq %rax, 0x40(%rsp)
andl $0x0, (%rax)
movq %r15, 0x10(%rsp)
cmpb $0x0, 0x238(%r15)
je 0x5a6b5
movq %rbx, 0x38(%rsp)
leaq 0x120(%rsp), %rax
movq %rax, -0x30(%rax)
movq $0x1, -0x28(%rax)
xorps %xmm0, %xmm0
movups %xmm0, -0x20(%rax)
movl $0x3f800000, -0x10(%rax) # imm = 0x3F800000
movups %xmm0, -0x8(%rax)
leaq 0xf0(%rsp), %rdi
movl $0x186a0, %esi          # imm = 0x186A0
callq 0x5d43c
movq 0x30(%r14), %rbp
addq $0x28, %r14
movq %r14, 0x48(%rsp)
xorl %r13d, %r13d
leaq 0xf0(%rsp), %r14
cmpq %rbp, %r13
je 0x5a549
movq 0x10(%rsp), %rax
movq 0x240(%rax), %rax
addq %r13, %rax
cmpq %rbp, %rax
ja 0x5a541
leaq 0x18(%rsp), %rdi
leaq 0x5403(%rip), %rsi      # 0x5f857
leaq 0x70(%rsp), %rdx
callq 0xdbbe
movq 0x10(%rsp), %rax
movq 0x240(%rax), %rcx
leaq 0x50(%rsp), %r12
movq %r12, %rdi
movq 0x48(%rsp), %rsi
movq %r13, %rdx
callq 0xc5f0
leaq 0x128(%rsp), %r15
movq %r15, %rdi
leaq 0x18(%rsp), %rbx
movq %rbx, %rsi
movq %r12, %rdx
xorl %ecx, %ecx
callq 0x5b6bc
movq %r12, %rdi
callq 0xcbe8
movq %rbx, %rdi
callq 0xcbe8
movq %r15, %rdi
callq 0x5b3b2
movq 0x40(%rsp), %rax
andl $0x0, (%rax)
movq 0x158(%rsp), %rax
movq 0x10(%rsp), %rcx
cmpq 0x240(%rcx), %rax
jne 0x5a5db
leaq 0x128(%rsp), %rdi
callq 0x488ea
testq %rax, %rax
jne 0x5a534
leaq 0x128(%rsp), %rdi
callq 0x58b62
leaq 0x18(%rsp), %rdi
movq 0x10(%rsp), %rsi
movq %rax, %rdx
callq 0x5a932
movq 0x18(%rsp), %r12
movq 0x20(%rsp), %rbx
cmpq %rbx, %r12
je 0x5a52a
movq %r14, %rdi
movq %r12, %rsi
callq 0x2e312
incq (%rax)
addq $0x20, %r12
jmp 0x5a511
leaq 0x18(%rsp), %rdi
callq 0x29e28
leaq 0x128(%rsp), %rdi
callq 0x5bd06
incq %r13
jmp 0x5a427
xorps %xmm0, %xmm0
movq 0x38(%rsp), %r12
movups %xmm0, 0x9(%r12)
movups %xmm0, (%r12)
movq 0x108(%rsp), %rsi
movq %r12, %rdi
callq 0x5b6d2
movq 0x100(%rsp), %r15
leaq 0x130(%rsp), %r14
leaq 0x128(%rsp), %rbx
testq %r15, %r15
je 0x5a5b1
leaq 0x8(%r15), %rdx
movq 0x28(%r15), %rsi
movq %rbx, %rdi
callq 0x5a0b6
movq %r12, %rdi
movq %rbx, %rsi
callq 0x5b774
movq %r14, %rdi
callq 0xcbe8
movq (%r15), %r15
jmp 0x5a584
movq %r12, %rdi
callq 0x5b79c
leaq 0xf0(%rsp), %rdi
callq 0x2ca48
movq %r12, %rax
addq $0x1b8, %rsp            # imm = 0x1B8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0xc6d0
testl %eax, %eax
jne 0x5a795
leaq 0x8a23(%rip), %rsi      # 0x63012
leaq 0xb0(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0xdbbe
leaq 0x90(%rsp), %rdi
movl $0x1390, %esi           # imm = 0x1390
callq 0xe2d5
leaq 0xd0(%rsp), %rdi
leaq 0xb0(%rsp), %rsi
leaq 0x90(%rsp), %rdx
callq 0xe26e
leaq 0x3b9a(%rip), %rdx      # 0x5e1d1
leaq 0x70(%rsp), %rdi
leaq 0xd0(%rsp), %rsi
callq 0xe24f
leaq 0xa35f(%rip), %rsi      # 0x649af
leaq 0x178(%rsp), %rdi
leaq 0xe(%rsp), %rdx
callq 0xdbbe
leaq 0x4263(%rip), %rdx      # 0x5e8cc
leaq 0x198(%rsp), %rdi
leaq 0x178(%rsp), %rsi
callq 0xe24f
leaq 0x50(%rsp), %rdi
leaq 0x70(%rsp), %rsi
leaq 0x198(%rsp), %rdx
callq 0xe26e
leaq 0xa1b4(%rip), %rdx      # 0x64850
leaq 0x18(%rsp), %rdi
leaq 0x50(%rsp), %rsi
callq 0xe24f
leaq 0x18(%rsp), %rdi
callq 0x101d0
callq 0xc6d0
testl %eax, %eax
jne 0x5a795
leaq 0x8949(%rip), %rsi      # 0x63012
leaq 0x70(%rsp), %rdi
leaq 0x198(%rsp), %rdx
callq 0xdbbe
leaq 0xd0(%rsp), %rdi
movl $0x1387, %esi           # imm = 0x1387
callq 0xe2d5
leaq 0x50(%rsp), %rdi
leaq 0x70(%rsp), %rsi
leaq 0xd0(%rsp), %rdx
callq 0xe26e
leaq 0x3ac6(%rip), %rdx      # 0x5e1d1
leaq 0x18(%rsp), %rdi
leaq 0x50(%rsp), %rsi
callq 0xe24f
leaq 0xa28e(%rip), %rsi      # 0x649af
leaq 0x90(%rsp), %rdi
leaq 0x178(%rsp), %rdx
callq 0xdbbe
leaq 0x418f(%rip), %rdx      # 0x5e8cc
leaq 0xb0(%rsp), %rdi
leaq 0x90(%rsp), %rsi
callq 0xe24f
leaq 0xf0(%rsp), %rdi
leaq 0x18(%rsp), %rsi
leaq 0xb0(%rsp), %rdx
callq 0xe26e
leaq 0xa048(%rip), %rdx      # 0x647bb
leaq 0x128(%rsp), %rdi
leaq 0xf0(%rsp), %rsi
callq 0xe24f
leaq 0x128(%rsp), %rdi
callq 0x101d0
pushq $0x1
popq %rdi
callq 0xc6f0
movq %rax, %rbx
leaq 0x128(%rsp), %rdi
callq 0xcbe8
jmp 0x5a7b2
movq %rax, %rbx
leaq 0xf0(%rsp), %rdi
callq 0xcbe8
jmp 0x5a7c4
movq %rax, %rbx
leaq 0xb0(%rsp), %rdi
callq 0xcbe8
jmp 0x5a7d6
movq %rax, %rbx
leaq 0x90(%rsp), %rdi
callq 0xcbe8
jmp 0x5a7e8
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0xcbe8
jmp 0x5a815
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0xcbe8
jmp 0x5a806
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0xcbe8
jmp 0x5a824
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0xcbe8
jmp 0x5a836
movq %rax, %rbx
leaq 0x198(%rsp), %rdi
callq 0xcbe8
jmp 0x5a848
movq %rax, %rbx
leaq 0xd0(%rsp), %rdi
callq 0xcbe8
jmp 0x5a85a
movq %rax, %rbx
leaq 0x178(%rsp), %rdi
callq 0xcbe8
jmp 0x5a86c
movq %rax, %rbx
leaq 0x70(%rsp), %rdi
callq 0xcbe8
jmp 0x5a929
movq %rax, %rbx
leaq 0x70(%rsp), %rdi
callq 0xcbe8
jmp 0x5a883
movq %rax, %rbx
jmp 0x5a929
movq %rax, %rbx
leaq 0xd0(%rsp), %rdi
callq 0xcbe8
jmp 0x5a895
movq %rax, %rbx
leaq 0x90(%rsp), %rdi
callq 0xcbe8
jmp 0x5a8a9
jmp 0x5a8be
movq %rax, %rbx
leaq 0xb0(%rsp), %rdi
callq 0xcbe8
jmp 0x5a90f
jmp 0x5a8e1
jmp 0x5a8fd
jmp 0x5a8fd
movq %rax, %rbx
jmp 0x5a91c
movq %rax, %rbx
leaq 0x50(%rsp), %rdi
callq 0xcbe8
jmp 0x5a8d5
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0xcbe8
jmp 0x5a91c
movq %rax, %rbx
jmp 0x5a8f1
movq %rax, %rbx
movq %r14, %rdi
callq 0xcbe8
movq 0x38(%rsp), %rdi
callq 0x5b7b2
jmp 0x5a91c
movq %rax, %rbx
jmp 0x5a90f
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0x29e28
leaq 0x128(%rsp), %rdi
callq 0x5bd06
leaq 0xf0(%rsp), %rdi
callq 0x2ca48
movq %rbx, %rdi
callq 0xcaa0
nop