// File: /workspace/github_cpp_makefile_star2_O3/momohatt[P]seccampDB/database.cpp
// Function: DataBase::deserialize(std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::pair<ChangeMode, int>, 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, std::pair<ChangeMode, int>>>>&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>)
void DataBase::deserialize(DBDiff& diff, vector<string> buf) {
    for (const auto& line : buf) {
        vector<string> fields = words(line);
        if (fields.size() != 4) {
            diff = {};
            return;
        }
        // checksum validation
        string str = fields[1] + fields[2] + fields[3];
        if (((unsigned int) stol(fields[0])) != crc32(str)) {
            diff = {};
            return;
        }
        diff[fields[1]] = make_pair(
                stoi(fields[2]) ? Delete : New,
                stoi(fields[3]));
    }
    return;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rsi, %r13
movq (%rdx), %rsi
movq 0x8(%rdx), %rax
movq %rax, 0x88(%rsp)
cmpq %rax, %rsi
je 0x6128
leaq 0x48(%rsp), %r12
leaq 0x18(%rsp), %r14
movq %rsp, %rdi
movq %rsi, 0x90(%rsp)
callq 0x399c
movq (%rsp), %rdx
movq 0x8(%rsp), %rax
subq %rdx, %rax
cmpq $0x80, %rax
jne 0x6114
leaq 0x20(%rdx), %rsi
addq $0x40, %rdx
movq %r14, %rdi
callq 0x7704
movq (%rsp), %rax
movq 0x60(%rax), %rsi
movq 0x68(%rax), %rdx
movq %r14, %rdi
callq 0x30d0
movq %r12, 0x38(%rsp)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x5ee7
movq %rdx, 0x38(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x48(%rsp)
jmp 0x5eef
movups (%rcx), %xmm0
movups %xmm0, (%r12)
movq 0x8(%rax), %rdx
movq %rdx, 0x40(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq 0x18(%rsp), %rdi
leaq 0x28(%rsp), %rax
cmpq %rax, %rdi
je 0x5f23
movq 0x28(%rsp), %rsi
incq %rsi
callq 0x32a0
movq (%rsp), %rax
movq (%rax), %rbx
callq 0x3050
movq %rax, %rbp
movl (%rax), %r14d
movl $0x0, (%rax)
movq %rbx, %rdi
leaq 0x18(%rsp), %rsi
movl $0xa, %edx
callq 0x3350
movq %rax, 0x58(%rsp)
cmpq %rbx, 0x18(%rsp)
je 0x613a
movl (%rbp), %eax
testl %eax, %eax
je 0x5f6e
cmpl $0x22, %eax
jne 0x5f72
jmp 0x615e
movl %r14d, (%rbp)
leaq 0x70(%rsp), %rax
movq %rax, 0x60(%rsp)
movq 0x38(%rsp), %rsi
movq 0x40(%rsp), %rdx
addq %rsi, %rdx
leaq 0x60(%rsp), %rdi
callq 0x839a
leaq 0x18(%rsp), %r14
leaq 0x60(%rsp), %rdi
callq 0x3f69
movl %eax, %r15d
movq 0x60(%rsp), %rdi
leaq 0x70(%rsp), %rax
cmpq %rax, %rdi
je 0x5fc1
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x32a0
cmpl 0x58(%rsp), %r15d
je 0x5fd9
movq %r13, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x8e16
jmp 0x60d2
movq %r13, %rbx
movq (%rsp), %rax
movq 0x40(%rax), %r12
movl (%rbp), %r13d
movl $0x0, (%rbp)
movq %r12, %rdi
movq %r14, %rsi
movl $0xa, %edx
callq 0x3350
cmpq %r12, 0x18(%rsp)
je 0x616a
leaq -0x80000000(%rax), %rdx
movabsq $-0x100000000, %rcx     # imm = 0xFFFFFFFF00000000
cmpq %rcx, %rdx
jb 0x6146
movl (%rbp), %r14d
cmpl $0x22, %r14d
je 0x6146
movq %rax, 0x80(%rsp)
testl %r14d, %r14d
jne 0x6046
movl %r13d, (%rbp)
movl %r13d, %r14d
movq (%rsp), %rax
movq 0x60(%rax), %r13
movl $0x0, (%rbp)
movq %r13, %rdi
leaq 0x18(%rsp), %rsi
movl $0xa, %edx
callq 0x3350
cmpq %r13, 0x18(%rsp)
je 0x6176
movq %rax, %r12
addq $-0x80000000, %rax      # imm = 0x80000000
movabsq $-0x100000000, %rcx     # imm = 0xFFFFFFFF00000000
cmpq %rcx, %rax
jb 0x6152
movl (%rbp), %eax
cmpl $0x22, %eax
je 0x6152
movq %rbx, %r13
testl %eax, %eax
jne 0x60a5
movl %r14d, (%rbp)
movq (%rsp), %rsi
addq $0x20, %rsi
movq %r13, %rdi
callq 0x73ca
xorl %ecx, %ecx
cmpl $0x0, 0x80(%rsp)
setne %cl
movl %ecx, (%rax)
movl %r12d, 0x4(%rax)
leaq 0x48(%rsp), %r12
leaq 0x18(%rsp), %r14
movq 0x38(%rsp), %rdi
cmpq %r12, %rdi
je 0x60e9
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x32a0
movq %rsp, %rdi
callq 0x3fa6
cmpl 0x58(%rsp), %r15d
movq 0x90(%rsp), %rsi
jne 0x6128
addq $0x20, %rsi
cmpq 0x88(%rsp), %rsi
jne 0x5e78
jmp 0x6128
movq %r13, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x8e16
movq %rsp, %rdi
callq 0x3fa6
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x6484(%rip), %rdi      # 0xc5c5
callq 0x3190
leaq 0x5f38(%rip), %rdi      # 0xc085
callq 0x3380
leaq 0x5f2c(%rip), %rdi      # 0xc085
callq 0x3380
leaq 0x6460(%rip), %rdi      # 0xc5c5
callq 0x3380
leaq 0x5f14(%rip), %rdi      # 0xc085
callq 0x3190
leaq 0x5f08(%rip), %rdi      # 0xc085
callq 0x3190
jmp 0x6197
jmp 0x61d6
jmp 0x61db
movq %rax, %rbx
cmpl $0x0, (%rbp)
jne 0x61e8
movl %r13d, (%rbp)
jmp 0x61e8
movq %rax, %rbx
jmp 0x6204
movq %rax, %rbx
movq 0x18(%rsp), %rdi
leaq 0x28(%rsp), %rax
cmpq %rax, %rdi
je 0x6204
movq 0x28(%rsp), %rsi
jmp 0x61fc
movq %rax, %rbx
movq 0x60(%rsp), %rdi
leaq 0x70(%rsp), %rax
cmpq %rax, %rdi
je 0x61e8
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x32a0
jmp 0x61e8
movq %rax, %rbx
jmp 0x61e8
movq %rax, %rbx
cmpl $0x0, (%rbp)
jne 0x61e8
movl %r14d, (%rbp)
movq 0x38(%rsp), %rdi
leaq 0x48(%rsp), %rax
cmpq %rax, %rdi
je 0x6204
movq 0x48(%rsp), %rsi
incq %rsi
callq 0x32a0
movq %rsp, %rdi
callq 0x3fa6
movq %rbx, %rdi
callq 0x3410