// File: vsklad[P]cgen/./bal/cnf/cnf/cnf.hpp
// Function: bal::Cnf::record_clauses(char const* const*, unsigned long, unsigned int*, unsigned long, unsigned long)
void record_clauses(const char* const * const map, const std::size_t map_size,
                            literalid_t args[], const std::size_t input_size, const std::size_t output_size) {
            assert(map_size > 0 && input_size > 0 && output_size > 0);
            
            // create output literals
            for (auto i = 0; i < output_size; i++) {
                if (literal_t__is_unassigned(args[input_size + i])) {
                    args[input_size + i] = new_variable_literal();
                };
            };
            
            // buffer for clause literals
            literalid_t literalid_args[input_size + output_size];
            
            // record clauses one by one from the map
            for(auto i = 0; i < map_size; i++) {
                _assert_level_1(std::char_traits<char>::length(map[i]) == input_size + output_size);
                
                clause_size_t clause_size = 0;
                
                // record clause literals
                for (auto j = 0; j < input_size + output_size; j++) {
                    if (map[i][j] == '0' || map[i][j] == '1') {
                        literalid_args[clause_size++] = literal_t__negated_onlyif(args[j], map[i][j] == '0');
                    };
                };
                
                append_clause(literalid_args, clause_size);
            };
        }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x60(%rbp)
xorl %eax, %eax
cmpq $0x0, -0x18(%rbp)
movb %al, -0x55(%rbp)
jbe 0x13b6b
xorl %eax, %eax
cmpq $0x0, -0x28(%rbp)
movb %al, -0x55(%rbp)
jbe 0x13b6b
cmpq $0x0, -0x30(%rbp)
seta %al
movb %al, -0x55(%rbp)
movb -0x55(%rbp), %al
testb $0x1, %al
jne 0x13b74
jmp 0x13b76
jmp 0x13b95
leaq 0x49603(%rip), %rdi     # 0x5d180
leaq 0x4962e(%rip), %rsi     # 0x5d1b2
movl $0x59, %edx
leaq 0x49638(%rip), %rcx     # 0x5d1c8
callq 0xd1c0
movl $0x0, -0x34(%rbp)
movslq -0x34(%rbp), %rax
cmpq -0x30(%rbp), %rax
jae 0x13be6
movq -0x20(%rbp), %rax
movq -0x28(%rbp), %rcx
movslq -0x34(%rbp), %rdx
addq %rdx, %rcx
cmpl $-0x1, (%rax,%rcx,4)
jne 0x13bd9
movq -0x60(%rbp), %rdi
movq (%rdi), %rax
callq *0x8(%rax)
movl %eax, %edx
movq -0x20(%rbp), %rax
movq -0x28(%rbp), %rcx
movslq -0x34(%rbp), %rsi
addq %rsi, %rcx
movl %edx, (%rax,%rcx,4)
jmp 0x13bdb
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x13b9c
movq -0x28(%rbp), %rax
movq -0x30(%rbp), %rcx
addq %rcx, %rax
movq %rsp, %rcx
movq %rcx, -0x40(%rbp)
leaq 0xf(,%rax,4), %rdx
andq $-0x10, %rdx
movq %rsp, %rcx
subq %rdx, %rcx
movq %rcx, -0x68(%rbp)
movq %rcx, %rsp
movq %rax, -0x48(%rbp)
movl $0x0, -0x4c(%rbp)
movslq -0x4c(%rbp), %rax
cmpq -0x18(%rbp), %rax
jae 0x13d37
movq -0x10(%rbp), %rax
movslq -0x4c(%rbp), %rcx
movq (%rax,%rcx,8), %rdi
callq 0x13d50
movq -0x28(%rbp), %rcx
addq -0x30(%rbp), %rcx
cmpq %rcx, %rax
jne 0x13c4a
jmp 0x13c69
leaq 0x495f7(%rip), %rdi     # 0x5d248
leaq 0x4955a(%rip), %rsi     # 0x5d1b2
movl $0x67, %edx
leaq 0x49564(%rip), %rcx     # 0x5d1c8
callq 0xd1c0
movw $0x0, -0x4e(%rbp)
movl $0x0, -0x54(%rbp)
movslq -0x54(%rbp), %rax
movq -0x28(%rbp), %rcx
addq -0x30(%rbp), %rcx
cmpq %rcx, %rax
jae 0x13d14
movq -0x10(%rbp), %rax
movslq -0x4c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movslq -0x54(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x30, %eax
je 0x13cbd
movq -0x10(%rbp), %rax
movslq -0x4c(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movslq -0x54(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x31, %eax
jne 0x13d04
movq -0x68(%rbp), %rax
movq -0x20(%rbp), %rcx
movslq -0x54(%rbp), %rdx
movl (%rcx,%rdx,4), %edx
movq -0x10(%rbp), %rcx
movslq -0x4c(%rbp), %rsi
movq (%rcx,%rsi,8), %rcx
movslq -0x54(%rbp), %rsi
movsbl (%rcx,%rsi), %edi
xorl %ecx, %ecx
movl $0x1, %esi
cmpl $0x30, %edi
cmovel %esi, %ecx
xorl %ecx, %edx
movw -0x4e(%rbp), %cx
movw %cx, %si
addw $0x1, %si
movw %si, -0x4e(%rbp)
movzwl %cx, %ecx
movl %edx, (%rax,%rcx,4)
jmp 0x13d06
movl -0x54(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x54(%rbp)
jmp 0x13c76
movq -0x68(%rbp), %rsi
movq -0x60(%rbp), %rdi
addq $0x78, %rdi
movzwl -0x4e(%rbp), %edx
callq 0x13950
movl -0x4c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x4c(%rbp)
jmp 0x13c1c
movq -0x40(%rbp), %rax
movq %rax, %rsp
movq %rbp, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)