// File: /workspace/github_c_makefile_star2_O3/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 0x6b7d(%rip), %rax      # 0xbe88
orq 0x6b6e(%rip), %rax      # 0xbe80
jne 0x53a5
movl %edx, %ebp
testl %edx, %edx
je 0x5453
movl %ecx, %r12d
testl %ecx, %ecx
je 0x5453
movq %rsi, %r14
movq %rdi, %rbx
cmpq %rsi, %rdi
je 0x53a5
movq %rbx, %rdi
movq %r14, %rsi
movq %r9, 0x10(%rsp)
movq %r9, %rdx
movq %r8, 0x8(%rsp)
movq %r8, %rcx
callq 0x4aab
testl %eax, %eax
jne 0x5437
movl 0x50(%rsp), %eax
leal -0x1(%rbp), %ecx
incq %rcx
movl %ebp, %edx
movl %r12d, %r15d
movq %rbx, %r13
movq 0x10(%rsp), %rdi
leal -0x1(%r15), %esi
leaq (%rcx,%r13), %r10
leaq (%r14,%rcx), %r8
xorl %ebp, %ebp
movb (%r13,%rbp), %r9b
cmpb (%r14,%rbp), %r9b
jne 0x53b4
incq %rbp
cmpl %ebp, %edx
jne 0x5380
testl %eax, %eax
cmoveq %rbx, %r10
movl %esi, %r15d
movq %r8, %r14
movq %r10, %r13
testl %esi, %esi
jne 0x5372
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x46b4
leaq 0x3090(%rip), %rdi      # 0x8450
callq 0x3f36
cmpl $0x1, %r12d
je 0x53e2
leaq 0x2ff5(%rip), %rdi      # 0x83c7
callq 0x3f36
subl %r15d, %r12d
movq %r12, %rdi
callq 0x4123
leaq 0x3079(%rip), %rdi      # 0x8462
callq 0x3f36
movq %rbp, %rdi
callq 0x4123
leaq 0x2f36(%rip), %rdi      # 0x8333
callq 0x3f36
movzbl (%r13,%rbp), %edi
movl $0x41, %esi
callq 0x40a7
leaq 0x2f25(%rip), %rdi      # 0x833e
callq 0x3f36
movzbl (%r14,%rbp), %edi
movl $0x41, %esi
callq 0x40a7
movq 0x8(%rsp), %rdi
callq 0x46db
movq $0x1, 0x6a3e(%rip) # 0xbe80
leaq 0x6a47(%rip), %rdi      # 0xbe90
movl $0x1, %esi
callq 0x21d0
movq %r9, %rdi
movq %r8, %rbx
callq 0x46b4
leaq 0x2f2b(%rip), %rdi      # 0x8390
callq 0x3f36
movq %rbx, %rdi
jmp 0x5432