// File: /workspace/github_cpp_makefile_star2_O3/aalto-speech[P]ftk/src/Unigrams.cc
// Function: Unigrams::read_vocab(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, double, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const, double>>>&, int&, bool)
int
Unigrams::read_vocab(string fname,
                     map<string, flt_type> &vocab,
                     int &maxlen,
                     bool utf8)
{
    SimpleFileInput vocabfile(fname);

    string line;
    flt_type count;
    maxlen = -1;
    while (vocabfile.getline(line)) {
        stringstream ss(line);
        string word;
        ss >> count;
        ss >> word;
        vocab[word] = count;

        maxlen = max(maxlen, (int)get_factor_length(word, utf8));
    }

    return vocab.size();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x218, %rsp            # imm = 0x218
movl %ecx, -0x34(%rbp)
movq %rdx, %r15
movq %rsi, -0x40(%rbp)
leaq -0xa0(%rbp), %r14
movq %r14, -0x10(%r14)
movq (%rdi), %rsi
movq 0x8(%rdi), %rdx
addq %rsi, %rdx
leaq -0xb0(%rbp), %rbx
movq %rbx, %rdi
callq 0x5f0e
leaq -0x30(%rbp), %rdi
movq %rbx, %rsi
callq 0x604c
movq -0xb0(%rbp), %rdi
cmpq %r14, %rdi
je 0x1d57d
callq 0x4350
leaq -0x80(%rbp), %rax
movq %rax, -0x10(%rax)
movq $0x0, -0x8(%rax)
movb $0x0, (%rax)
movl $0xffffffff, (%r15)     # imm = 0xFFFFFFFF
leaq -0x58(%rbp), %r14
leaq -0x90(%rbp), %r13
leaq -0x238(%rbp), %r12
leaq -0x68(%rbp), %rbx
movq -0x30(%rbp), %rdi
movq (%rdi), %rax
movq %r13, %rsi
callq *(%rax)
testb %al, %al
je 0x1d699
movq %r12, %rdi
movq %r13, %rsi
movl $0x18, %edx
callq 0x4580
movq %r14, -0x68(%rbp)
movq $0x0, -0x60(%rbp)
movb $0x0, -0x58(%rbp)
movq %r12, %rdi
leaq -0x70(%rbp), %rsi
callq 0x4240
movq %r12, %rdi
movq %rbx, %rsi
callq 0x4450
movsd -0x70(%rbp), %xmm0
movsd %xmm0, -0x48(%rbp)
movq -0x40(%rbp), %rdi
movq %rbx, %rsi
callq 0x1af86
movsd -0x48(%rbp), %xmm0
movsd %xmm0, (%rax)
movq -0x68(%rbp), %rdi
movq -0x60(%rbp), %rax
cmpb $0x0, -0x34(%rbp)
je 0x1d65e
testq %rax, %rax
je 0x1d662
xorl %edx, %edx
xorl %ecx, %ecx
movb (%rdi,%rdx), %r8b
movl $0x1, %esi
testb %r8b, %r8b
jns 0x1d653
movl $0x4, %esi
cmpb $-0x11, %r8b
ja 0x1d653
cmpb $-0x20, %r8b
movl $0x2, %esi
sbbl $-0x1, %esi
addl %esi, %edx
incl %ecx
cmpq %rdx, %rax
ja 0x1d62e
jmp 0x1d664
movl %eax, %ecx
jmp 0x1d664
xorl %ecx, %ecx
movl (%r15), %eax
cmpl %ecx, %eax
cmovgl %eax, %ecx
movl %ecx, (%r15)
cmpq %r14, %rdi
je 0x1d679
callq 0x4350
movq %r12, %rdi
movq 0x1690d(%rip), %rsi     # 0x33f90
callq 0x42c0
leaq -0x1b8(%rbp), %rdi
callq 0x4110
jmp 0x1d5ad
movq -0x40(%rbp), %rax
movq 0x28(%rax), %rbx
movq -0x90(%rbp), %rdi
leaq -0x80(%rbp), %rax
cmpq %rax, %rdi
je 0x1d6b6
callq 0x4350
leaq -0x30(%rbp), %rdi
callq 0x619e
movl %ebx, %eax
addq $0x218, %rsp            # imm = 0x218
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0xb0(%rbp), %rdi
cmpq %r14, %rdi
je 0x1d73e
callq 0x4350
jmp 0x1d73e
jmp 0x1d6eb
movq %rax, %rbx
jmp 0x1d720
movq %rax, %rbx
movq -0x68(%rbp), %rdi
cmpq %r14, %rdi
je 0x1d701
callq 0x4350
movq 0x16888(%rip), %rsi     # 0x33f90
leaq -0x238(%rbp), %rdi
callq 0x42c0
leaq -0x1b8(%rbp), %rdi
callq 0x4110
movq -0x90(%rbp), %rdi
leaq -0x80(%rbp), %rax
cmpq %rax, %rdi
je 0x1d735
callq 0x4350
leaq -0x30(%rbp), %rdi
callq 0x619e
movq %rbx, %rdi
callq 0x4650