// File: /workspace/github_c_makefile_star2_O2/jeff-1amstudios[P]carmageddon-1-cheat-code-disassembly/src/test/framework/unity.c
// Function: UnityAssertEqualMemory
void UnityAssertEqualMemory(UNITY_INTERNAL_PTR expected,
                            UNITY_INTERNAL_PTR actual,
                            const UNITY_UINT32 length,
                            const UNITY_UINT32 num_elements,
                            const char* msg,
                            const UNITY_LINE_TYPE lineNumber,
                            const UNITY_FLAGS_T flags)
{
    UNITY_PTR_ATTRIBUTE const unsigned char* ptr_exp = (UNITY_PTR_ATTRIBUTE const unsigned char*)expected;
    UNITY_PTR_ATTRIBUTE const unsigned char* ptr_act = (UNITY_PTR_ATTRIBUTE const unsigned char*)actual;
    UNITY_UINT32 elements = num_elements;
    UNITY_UINT32 bytes;

    RETURN_IF_FAIL_OR_IGNORE;

    if ((elements == 0) || (length == 0))
    {
        UnityPrintPointlessAndBail();
    }

    if (expected == actual)
    {
        return; /* Both are NULL or same pointer */
    }

    if (UnityIsOneArrayNull(expected, actual, lineNumber, msg))
    {
        UNITY_FAIL_AND_BAIL;
    }

    while (elements--)
    {
        bytes = length;
        while (bytes--)
        {
            if (*ptr_exp != *ptr_act)
            {
                UnityTestResultsFailBegin(lineNumber);
                UnityPrint(UnityStrMemory);
                if (num_elements > 1)
                {
                    UnityPrint(UnityStrElement);
                    UnityPrintNumberUnsigned(num_elements - elements - 1);
                }
                UnityPrint(UnityStrByte);
                UnityPrintNumberUnsigned(length - bytes - 1);
                UnityPrint(UnityStrExpected);
                UnityPrintNumberByStyle(*ptr_exp, UNITY_DISPLAY_STYLE_HEX8);
                UnityPrint(UnityStrWas);
                UnityPrintNumberByStyle(*ptr_act, UNITY_DISPLAY_STYLE_HEX8);
                UnityAddMsgIfSpecified(msg);
                UNITY_FAIL_AND_BAIL;
            }
            ptr_exp++;
            ptr_act++;
        }
        if (flags == UNITY_ARRAY_TO_VAL)
        {
            ptr_exp = (UNITY_PTR_ATTRIBUTE const unsigned char*)expected;
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq 0x72b8(%rip), %rax      # 0xbe88
orq 0x72a9(%rip), %rax      # 0xbe80
jne 0x4c65
movl %edx, %ebp
testl %edx, %edx
je 0x4d18
testl %ecx, %ecx
je 0x4d18
movq %rsi, %r14
movq %rdi, %rbx
cmpq %rsi, %rdi
je 0x4c65
movq %rcx, 0x8(%rsp)
movq %rbx, %rdi
movq %r14, %rsi
movq %r9, %r15
movq %r9, %rdx
movq %r8, 0x10(%rsp)
movq %r8, %rcx
callq 0x439f
testl %eax, %eax
jne 0x4cfe
movl 0x50(%rsp), %eax
movl %ebp, %ecx
movq %rbx, %r13
movq 0x8(%rsp), %rdx
movl %edx, %r12d
subl $0x1, %edx
jb 0x4c65
leaq (%rcx,%r13), %r9
leaq (%r14,%rcx), %rsi
xorl %ebp, %ebp
cmpl %ebp, %ecx
je 0x4c54
movb (%r13,%rbp), %r8b
cmpb (%r14,%rbp), %r8b
jne 0x4c74
incq %rbp
jmp 0x4c40
testl %eax, %eax
cmoveq %rbx, %r9
movq %r9, %r13
movq %rsi, %r14
movl %edx, %r12d
jmp 0x4c31
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r15, %rdi
callq 0x3fad
leaq 0x27cd(%rip), %rdi      # 0x7450
callq 0x3942
movq 0x8(%rsp), %rbx
cmpl $0x2, %ebx
jb 0x4ca9
leaq 0x272e(%rip), %rdi      # 0x73c7
callq 0x3942
subl %r12d, %ebx
movq %rbx, %rdi
callq 0x3b17
leaq 0x27b2(%rip), %rdi      # 0x7462
callq 0x3942
movq %rbp, %rdi
callq 0x3b17
leaq 0x266f(%rip), %rdi      # 0x7333
callq 0x3942
movzbl (%r13,%rbp), %edi
pushq $0x41
popq %r15
movl %r15d, %esi
callq 0x3aa1
leaq 0x265c(%rip), %rdi      # 0x733e
callq 0x3942
movzbl (%r14,%rbp), %edi
movl %r15d, %esi
callq 0x3aa1
movq 0x10(%rsp), %rdi
callq 0x3fd2
movq $0x1, 0x7177(%rip) # 0xbe80
leaq 0x7180(%rip), %rdi      # 0xbe90
pushq $0x1
popq %rsi
callq 0x21d0
movq %r9, %rdi
movq %r8, %rbx
callq 0x3fad
leaq 0x2666(%rip), %rdi      # 0x7390
callq 0x3942
movq %rbx, %rdi
jmp 0x4cf9