// File: /workspace/github_cpp_makefile_star2_O1/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 0x71e0
testb %al, %al
je 0x740c
movq %rbx, %rdi
movq %r12, %rsi
callq 0x6572
movq 0x68(%rbx), %rax
movabsq $0x790fb65668c26139, %rcx # imm = 0x790FB65668C26139
imulq %rcx, %rax
addq %r15, %rax
rorq $0x6, %rax
cmpq %r13, %rax
ja 0x73e2
movq (%rbx), %rax
cmpl $0x2, 0x100(%rax)
jl 0x73e2
movl $0x6, %edx
movq 0x22c61(%rip), %rdi     # 0x29ff0
leaq 0x177b4(%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 0x22c32(%rip), %rdi     # 0x29ff0
callq 0x42c0
movq %rax, %rbp
movl $0x7, %edx
movq %rax, %rdi
leaq 0x1777c(%rip), %rsi     # 0x1eb51
callq 0x4350
movq %rbp, %rdi
callq 0x4200
cmpl $0x15752a1, 0x58(%rbx)  # imm = 0x15752A1
jl 0x733b
movq 0x8(%rsp), %rdx
incq %rdx
movq %rbx, %rdi
movq %rdx, %rsi
movq %rdx, 0x8(%rsp)
callq 0x775c
jmp 0x733b
movq (%rbx), %rax
movl 0xc0(%rax), %eax
andl $-0x2, %eax
cmpl $0x4, %eax
jne 0x74fc
leaq 0x40(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x17728(%rip), %rsi     # 0x1eb59
leaq 0x1772e(%rip), %rdx     # 0x1eb66
leaq 0x30(%rsp), %rdi
callq 0x630e
leaq 0x30(%rsp), %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x6486
movl %eax, %ebp
movq (%r14), %rdi
cmpq %r15, %rdi
je 0x7469
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 0x176cc(%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 0xa6e2
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 0x74e5
movq 0x70(%rsp), %rsi
subq %rdi, %rsi
callq 0x4300
movq 0x30(%rsp), %rdi
cmpq %r15, %rdi
je 0x74fc
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x4300
movq (%rbx), %rax
movslq 0xa8(%rax), %rsi
movslq 0xac(%rax), %rdx
movq %rbx, %rdi
callq 0x775c
movq (%rbx), %rax
movslq 0xa4(%rax), %rsi
testq %rsi, %rsi
jle 0x752c
movq %rbx, %rdi
callq 0x7ac8
movq %rbx, %rdi
callq 0x7c06
movq %rbx, %rdi
callq 0x7066
movq (%rbx), %rax
movl 0xc0(%rax), %eax
andl $-0x2, %eax
cmpl $0x4, %eax
jne 0x7571
movq 0x28(%rbx), %rdi
leaq 0x17601(%rip), %rsi     # 0x1eb59
callq 0x40e0
testl %eax, %eax
jne 0x7700
movq 0x28(%rbx), %rax
movq $0x0, 0x20(%rax)
movq (%rbx), %rax
cmpl $0x0, 0x100(%rax)
jle 0x76a1
movq 0x22a68(%rip), %rdi     # 0x29ff0
leaq 0x175bb(%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 0x22a34(%rip), %rdi     # 0x29ff0
callq 0x42c0
movq %rax, %r14
leaq 0x17586(%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 0x229ea(%rip), %rdi     # 0x29ff0
leaq 0x175b4(%rip), %rsi     # 0x1ebc1
movl $0x12, %edx
callq 0x4350
movl 0x5c(%rbx), %esi
movq 0x229cf(%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 0x22999(%rip), %rdi     # 0x29ff0
leaq 0x17576(%rip), %rsi     # 0x1ebd4
movl $0x12, %edx
callq 0x4350
movl 0x60(%rbx), %esi
movq 0x2297e(%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 0x76d2
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x76c3
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 0x22917(%rip), %rdi     # 0x29ff0
leaq 0x17507(%rip), %rsi     # 0x1ebe7
movl $0x30, %edx
callq 0x4350
movq 0x228ff(%rip), %rdi     # 0x29ff0
callq 0x4170
movl $0x1, %edi
callq 0x4380
leaq 0x17460(%rip), %rdi     # 0x1eb67
leaq 0x172a1(%rip), %rsi     # 0x1e9af
leaq 0x17474(%rip), %rcx     # 0x1eb89
movl $0x105, %edx            # imm = 0x105
callq 0x41d0
jmp 0x7734
jmp 0x7734
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0xa70c
jmp 0x7737
jmp 0x7734
movq %rax, %rbx
movq 0x10(%rsp), %rdi
leaq 0x20(%rsp), %rax
cmpq %rax, %rdi
je 0x7753
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x4300
movq %rbx, %rdi
callq 0x45b0
nop