// File: /workspace/github_c_makefile_star2_O3/wjmelements[P]evm/src/dio.c
// Function: loadConfig
void loadConfig(const char *_configFile, int updateConfigFile) {
    if (_configFile != NULL) {
        int fd = open(_configFile, O_RDONLY);
        if (fd == -1) {
            perror(_configFile);
            _exit(1);
        }

        struct stat fstatus;
        int fstatSuccess = fstat(fd, &fstatus);
        if (fstatSuccess == -1) {
            perror(_configFile);
            _exit(1);
        }
        char *configContents = mmap(NULL, fstatus.st_size, PROT_READ, MAP_PRIVATE | MAP_FILE, fd, 0);
        {
            uint64_t prevLineNumber = lineNumber;
            struct testResults results = testResults;

            applyConfig(configContents);
            if (updateConfigFile) {
                updateConfig(configContents, _configFile);
            }

            lineNumber = prevLineNumber;
            testResults = results;
        }
        munmap(configContents, fstatus.st_size);
        close(fd);
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
testq %rdi, %rdi
je 0x7391
movl %esi, %ebx
movq %rdi, %r15
xorl %esi, %esi
xorl %eax, %eax
callq 0x3250
cmpl $-0x1, %eax
je 0x73a3
movl %eax, %ebp
leaq 0x48(%rsp), %rsi
movl %eax, %edi
callq 0x32a0
cmpl $-0x1, %eax
je 0x73ab
movq 0x78(%rsp), %r14
xorl %edi, %edi
movq %r14, %rsi
movl $0x1, %edx
movl $0x2, %ecx
movl %ebp, %r8d
xorl %r9d, %r9d
callq 0x30d0
movq %rax, %r12
movq 0x198e6(%rip), %r13     # 0x20a48
movups 0x198cf(%rip), %xmm0    # 0x20a38
movaps %xmm0, 0x30(%rsp)
movq %rax, %rdi
callq 0x4ca0
testl %ebx, %ebx
je 0x736c
movq %r13, 0x18(%rsp)
movq %r12, (%rsp)
movq %r15, 0x20(%rsp)
movl $0x7a120, %r14d         # imm = 0x7A120
movl $0x7a120, %edi          # imm = 0x7A120
movl $0x1, %esi
callq 0x31b0
movq %rax, %r12
movq 0x1988d(%rip), %r13     # 0x20a38
testq %r13, %r13
movl %ebp, 0xc(%rsp)
je 0x72f0
movq (%rsp), %rax
xorl %ebx, %ebx
movq 0x10(%r13), %rbp
movq %rbp, 0x10(%rsp)
subq %rax, %rbp
leaq (%rbx,%rbp), %r15
cmpq %r15, %r14
jae 0x7209
movl $0x1, %esi
movq %r15, %rdi
movq %rax, 0x28(%rsp)
callq 0x31b0
movq %r12, %r14
movq %rax, %r12
movq %rax, %rdi
movq %r14, %rsi
movq %rbx, %rdx
callq 0x31f0
movq %r14, %rdi
callq 0x3040
movq 0x28(%rsp), %rax
movq %r15, %r14
addq %r12, %rbx
movq %rbx, %rdi
movq %rax, %rsi
movq %rbp, %rdx
callq 0x31f0
movq 0x18(%r13), %rbp
cmpq 0x10(%rsp), %rbp
jne 0x7273
cmpq %r15, %r14
jae 0x7256
movl $0x1, %esi
movq %r15, %rdi
callq 0x31b0
movq %rax, %rbx
movq %rax, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0x31f0
movq %r12, %rdi
callq 0x3040
movq %r15, %r14
movq %rbx, %r12
movaps 0xb2b3(%rip), %xmm0     # 0x12510
movups %xmm0, 0x10(%r12,%r15)
movaps 0xb296(%rip), %xmm0     # 0x12500
movups %xmm0, (%r12,%r15)
addq $0x20, %r15
movq %r14, %rax
leaq 0x12(%r15), %r14
cmpq %r14, %rax
jae 0x72aa
movl $0x1, %esi
movq %r14, %rdi
callq 0x31b0
movq %rax, %rbx
movq %rax, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0x31f0
movq %r12, %rdi
callq 0x3040
movq %rbx, %r12
jmp 0x72ad
movq %rax, %r14
leaq (%r12,%r15), %rdi
movq %r14, %rsi
subq %r15, %rsi
movq 0x8(%r13), %rcx
leaq 0xb234(%rip), %rdx      # 0x124f6
xorl %eax, %eax
callq 0x3110
movslq %eax, %rbx
addq %r15, %rbx
movq %rbp, %rax
cmpq 0x10(%rsp), %rbp
jne 0x72e1
movb $0x22, (%r12,%rbx)
incq %rbx
movq (%r13), %r13
testq %r13, %r13
jne 0x71be
jmp 0x72f6
xorl %ebx, %ebx
movq (%rsp), %rax
movq %rax, %rdi
movq %rax, %r15
callq 0x30c0
movq %rax, %r14
leaq (%r12,%rbx), %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x31f0
movq 0x20(%rsp), %r15
movq %r15, %rdi
movl $0x1, %esi
xorl %eax, %eax
callq 0x3250
cmpl $-0x1, %eax
je 0x73b3
movl %eax, %ebp
addq %rbx, %r14
movl %eax, %edi
movq %r12, %rsi
movq %r14, %rdx
callq 0x30b0
cmpq $-0x1, %rax
movq %r12, %rbx
movq (%rsp), %r12
movq 0x18(%rsp), %r13
je 0x73bb
movl %ebp, %edi
callq 0x3160
movq %rbx, %rdi
callq 0x3040
movq 0x78(%rsp), %r14
movl 0xc(%rsp), %ebp
movq %r13, 0x196d5(%rip)     # 0x20a48
movaps 0x30(%rsp), %xmm0
movups %xmm0, 0x196b9(%rip)    # 0x20a38
movq %r12, %rdi
movq %r14, %rsi
callq 0x3230
movl %ebp, %edi
callq 0x3160
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r15, %rdi
callq 0x3609
movq %r15, %rdi
callq 0x35fb
movq %r15, %rdi
callq 0x35ed
movq %r15, %rdi
callq 0x35df