// File: /workspace/github_cpp_makefile_star2_O3/epfml[P]sent2vec/src/dictionary.cc
// Function: fasttext::Dictionary::readFromFile(std::istream&)
void Dictionary::readFromFile(std::istream& in) {
  std::string word;
  int64_t minThreshold = 1;
  while (readWord(in, word)) {
    add(word);
    if (ntokens_ % 1000000 == 0 && args_->verbose > 1) {
      std::cerr << "\rRead " << ntokens_  / 1000000 << "M words" << std::flush;
    }
    if (size_ > 0.75 * MAX_VOCAB_SIZE) {
      minThreshold++;
      threshold(minThreshold, minThreshold);
    }
  }
  if (args_->model == model_name::sent2vec || args_->model == model_name::cbowCWNgrams) {
    int32_t h = find("<PLACEHOLDER>");
    entry e;
    e.word = "<PLACEHOLDER>";
    e.count = 1e+18;
    e.type = entry_type::word;
    words_.push_back(e);
    word2int_[h] = size_++;
  }
  threshold(args_->minCount, args_->minCountLabel);
  if (args_->maxVocabSize > 0) {
    truncate(args_->maxVocabSize);
  }
  initTableDiscard();
  initNgrams();
  if (args_->model == model_name::sent2vec || args_->model == model_name::cbowCWNgrams) {
    assert(words_[0].word == "<PLACEHOLDER>");
    words_[0].count = 0;
  }
  if (args_->verbose > 0) {
    std::cerr << "\rRead " << ntokens_  / 1000000 << "M words" << std::endl;
    std::cerr << "Number of words:  " << nwords_ << std::endl;
    std::cerr << "Number of labels: " << nlabels_ << std::endl;
  }
  if (size_ == 0) {
    std::cerr << "Empty vocabulary. Try a smaller -minCount value."
              << std::endl;
    exit(EXIT_FAILURE);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x78, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x20(%rsp), %rax
movq %rax, -0x10(%rax)
movq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movl $0x1, %eax
movq %rax, 0x8(%rsp)
leaq 0x10(%rsp), %r12
movabsq $0x218def416bd80, %r15  # imm = 0x218DEF416BD80
movabsq $0x10c6f7a0b5ec, %r13   # imm = 0x10C6F7A0B5EC
movq %r14, %rsi
movq %r12, %rdx
callq 0x7216
testb %al, %al
je 0x7442
movq %rbx, %rdi
movq %r12, %rsi
callq 0x6576
movq 0x68(%rbx), %rax
movabsq $0x790fb65668c26139, %rcx # imm = 0x790FB65668C26139
imulq %rcx, %rax
addq %r15, %rax
rorq $0x6, %rax
cmpq %r13, %rax
ja 0x7418
movq (%rbx), %rax
cmpl $0x2, 0x100(%rax)
jl 0x7418
movl $0x6, %edx
movq 0x22c2b(%rip), %rdi     # 0x29ff0
leaq 0x1777e(%rip), %rsi     # 0x1eb4a
callq 0x4350
movabsq $0x431bde82d7b634db, %rax # imm = 0x431BDE82D7B634DB
imulq 0x68(%rbx)
movq %rdx, %rsi
shrq $0x3f, %rsi
sarq $0x12, %rdx
addq %rdx, %rsi
movq 0x22bfc(%rip), %rdi     # 0x29ff0
callq 0x42c0
movq %rax, %rbp
movl $0x7, %edx
movq %rax, %rdi
leaq 0x17746(%rip), %rsi     # 0x1eb51
callq 0x4350
movq %rbp, %rdi
callq 0x4200
cmpl $0x15752a1, 0x58(%rbx)  # imm = 0x15752A1
jl 0x7371
movq 0x8(%rsp), %rdx
incq %rdx
movq %rbx, %rdi
movq %rdx, %rsi
movq %rdx, 0x8(%rsp)
callq 0x7792
jmp 0x7371
movq (%rbx), %rax
movl 0xc0(%rax), %ecx
andl $-0x2, %ecx
cmpl $0x4, %ecx
jne 0x7535
leaq 0x40(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x176f2(%rip), %rsi     # 0x1eb59
leaq 0x176f8(%rip), %rdx     # 0x1eb66
leaq 0x30(%rsp), %rdi
callq 0x6310
leaq 0x30(%rsp), %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x648a
movl %eax, %ebp
movq (%r14), %rdi
cmpq %r15, %rdi
je 0x749f
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x4300
leaq 0x30(%rsp), %rdi
movq %r15, (%rdi)
xorl %eax, %eax
movq %rax, 0x8(%rdi)
movb $0x0, 0x10(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x30(%rdi)
movq %rax, 0x40(%rdi)
leaq 0x17696(%rip), %rcx     # 0x1eb59
movl $0xd, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x44b0
movabsq $0xde0b6b3a7640000, %rax # imm = 0xDE0B6B3A7640000
leaq 0x30(%rsp), %rsi
movq %rax, 0x20(%rsi)
movb $0x0, 0x28(%rsi)
leaq 0x28(%rbx), %rdi
callq 0xa706
movl 0x58(%rbx), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x58(%rbx)
movq 0x10(%rbx), %rcx
movl %ebp, %edx
movl %eax, (%rcx,%rdx,4)
movq 0x60(%rsp), %rdi
testq %rdi, %rdi
je 0x751b
movq 0x70(%rsp), %rsi
subq %rdi, %rsi
callq 0x4300
movq 0x30(%rsp), %rdi
cmpq %r15, %rdi
je 0x7532
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x4300
movq (%rbx), %rax
movslq 0xa8(%rax), %rsi
movslq 0xac(%rax), %rdx
movq %rbx, %rdi
callq 0x7792
movq (%rbx), %rax
movslq 0xa4(%rax), %rsi
testq %rsi, %rsi
jle 0x7562
movq %rbx, %rdi
callq 0x7b0a
movq %rbx, %rdi
callq 0x7c48
movq %rbx, %rdi
callq 0x709a
movq (%rbx), %rax
movl 0xc0(%rax), %ecx
andl $-0x2, %ecx
cmpl $0x4, %ecx
jne 0x75aa
movq 0x28(%rbx), %rdi
leaq 0x175cb(%rip), %rsi     # 0x1eb59
callq 0x40e0
testl %eax, %eax
jne 0x7736
movq 0x28(%rbx), %rax
movq $0x0, 0x20(%rax)
movq (%rbx), %rax
cmpl $0x0, 0x100(%rax)
jle 0x76d7
movq 0x22a32(%rip), %rdi     # 0x29ff0
leaq 0x17585(%rip), %rsi     # 0x1eb4a
movl $0x6, %edx
callq 0x4350
movabsq $0x431bde82d7b634db, %rax # imm = 0x431BDE82D7B634DB
imulq 0x68(%rbx)
movq %rdx, %rsi
shrq $0x3f, %rsi
sarq $0x12, %rdx
addq %rdx, %rsi
movq 0x229fe(%rip), %rdi     # 0x29ff0
callq 0x42c0
movq %rax, %r14
leaq 0x17550(%rip), %rsi     # 0x1eb51
movl $0x7, %edx
movq %rax, %rdi
callq 0x4350
movq (%r14), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x42d0
movsbl %al, %esi
movq %r14, %rdi
callq 0x4040
movq %rax, %rdi
callq 0x4200
movq 0x229b4(%rip), %rdi     # 0x29ff0
leaq 0x1757e(%rip), %rsi     # 0x1ebc1
movl $0x12, %edx
callq 0x4350
movl 0x5c(%rbx), %esi
movq 0x22999(%rip), %rdi     # 0x29ff0
callq 0x4580
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x42d0
movsbl %al, %esi
movq %r14, %rdi
callq 0x4040
movq %rax, %rdi
callq 0x4200
movq 0x22963(%rip), %rdi     # 0x29ff0
leaq 0x17540(%rip), %rsi     # 0x1ebd4
movl $0x12, %edx
callq 0x4350
movl 0x60(%rbx), %esi
movq 0x22948(%rip), %rdi     # 0x29ff0
callq 0x4580
movq %rax, %r14
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r14, %rdi
movl $0xa, %esi
callq 0x42d0
movsbl %al, %esi
movq %r14, %rdi
callq 0x4040
movq %rax, %rdi
callq 0x4200
cmpl $0x0, 0x58(%rbx)
je 0x7708
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x76f9
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x4300
addq $0x78, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x228e1(%rip), %rdi     # 0x29ff0
leaq 0x174d1(%rip), %rsi     # 0x1ebe7
movl $0x30, %edx
callq 0x4350
movq 0x228c9(%rip), %rdi     # 0x29ff0
callq 0x4170
movl $0x1, %edi
callq 0x4380
leaq 0x1742a(%rip), %rdi     # 0x1eb67
leaq 0x1726b(%rip), %rsi     # 0x1e9af
leaq 0x1743e(%rip), %rcx     # 0x1eb89
movl $0x105, %edx            # imm = 0x105
callq 0x41d0
jmp 0x776a
jmp 0x776a
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0xa730
jmp 0x776d
jmp 0x776a
movq %rax, %rbx
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x7789
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x4300
movq %rbx, %rdi
callq 0x45b0
nop