// File: ahupowerdns[P]mcounter/./ext/doctest.h
// Function: doctest::detail::ContextState::finalizeTestCaseData()
void finalizeTestCaseData() {
            seconds = timer.getElapsedSeconds();

            // update the non-atomic counters
            numAsserts += numAssertsCurrentTest_atomic;
            numAssertsFailed += numAssertsFailedCurrentTest_atomic;
            numAssertsCurrentTest       = numAssertsCurrentTest_atomic;
            numAssertsFailedCurrentTest = numAssertsFailedCurrentTest_atomic;

            if(numAssertsFailedCurrentTest)
                failure_flags |= TestCaseFailureReason::AssertFailure;

            if(Approx(currentTest->m_timeout).epsilon(DBL_EPSILON) != 0 &&
               Approx(seconds).epsilon(DBL_EPSILON) > currentTest->m_timeout)
                failure_flags |= TestCaseFailureReason::Timeout;

            if(currentTest->m_should_fail) {
                if(failure_flags) {
                    failure_flags |= TestCaseFailureReason::ShouldHaveFailedAndDid;
                } else {
                    failure_flags |= TestCaseFailureReason::ShouldHaveFailedButDidnt;
                }
            } else if(failure_flags && currentTest->m_may_fail) {
                failure_flags |= TestCaseFailureReason::CouldHaveFailedAndDid;
            } else if(currentTest->m_expected_failures > 0) {
                if(numAssertsFailedCurrentTest == currentTest->m_expected_failures) {
                    failure_flags |= TestCaseFailureReason::FailedExactlyNumTimes;
                } else {
                    failure_flags |= TestCaseFailureReason::DidntFailExactlyNumTimes;
                }
            }

            bool ok_to_fail = (TestCaseFailureReason::ShouldHaveFailedAndDid & failure_flags) ||
                              (TestCaseFailureReason::CouldHaveFailedAndDid & failure_flags) ||
                              (TestCaseFailureReason::FailedExactlyNumTimes & failure_flags);

            // if any subcase has failed - the whole test case has failed
            testCaseSuccess = !(failure_flags && !ok_to_fail);
            if(!testCaseSuccess)
                numTestCasesFailed++;
        }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x48(%rbp)
addq $0x10f0, %rdi           # imm = 0x10F0
callq 0x26790
movq -0x48(%rbp), %rdi
movsd %xmm0, 0xa8(%rdi)
addq $0xb8, %rdi
callq 0x20d40
movq -0x48(%rbp), %rdi
addl 0x98(%rdi), %eax
movl %eax, 0x98(%rdi)
addq $0x8b8, %rdi            # imm = 0x8B8
callq 0x20d40
movq -0x48(%rbp), %rdi
addl 0x9c(%rdi), %eax
movl %eax, 0x9c(%rdi)
addq $0xb8, %rdi
callq 0x20d40
movq -0x48(%rbp), %rdi
movl %eax, 0xa0(%rdi)
addq $0x8b8, %rdi            # imm = 0x8B8
callq 0x20d40
movl %eax, %ecx
movq -0x48(%rbp), %rax
movl %ecx, 0xa4(%rax)
cmpl $0x0, 0xa4(%rax)
je 0x2214e
movq -0x48(%rbp), %rax
movl 0xb0(%rax), %ecx
orl $0x1, %ecx
movl %ecx, 0xb0(%rax)
movq -0x48(%rbp), %rax
movq 0x20(%rax), %rax
movsd 0x48(%rax), %xmm0
leaq -0x20(%rbp), %rdi
callq 0x9650
leaq -0x20(%rbp), %rdi
movsd 0x16168(%rip), %xmm0    # 0x382d8
callq 0x9710
movq %rax, %rdi
xorps %xmm0, %xmm0
callq 0x9860
movb %al, %cl
xorl %eax, %eax
testb $0x1, %cl
movb %al, -0x49(%rbp)
jne 0x2218e
jmp 0x221cc
movq -0x48(%rbp), %rax
movsd 0xa8(%rax), %xmm0
leaq -0x38(%rbp), %rdi
callq 0x9650
leaq -0x38(%rbp), %rdi
movsd 0x16129(%rip), %xmm0    # 0x382d8
callq 0x9710
movq %rax, %rdi
movq -0x48(%rbp), %rax
movq 0x20(%rax), %rax
movsd 0x48(%rax), %xmm0
callq 0x9ac0
movb %al, -0x49(%rbp)
movb -0x49(%rbp), %al
testb $0x1, %al
jne 0x221d5
jmp 0x221e8
movq -0x48(%rbp), %rax
movl 0xb0(%rax), %ecx
orl $0x10, %ecx
movl %ecx, 0xb0(%rax)
movq -0x48(%rbp), %rax
movq 0x20(%rax), %rax
testb $0x1, 0x3c(%rax)
je 0x22230
movq -0x48(%rbp), %rax
cmpl $0x0, 0xb0(%rax)
je 0x22218
movq -0x48(%rbp), %rax
movl 0xb0(%rax), %ecx
orl $0x40, %ecx
movl %ecx, 0xb0(%rax)
jmp 0x2222b
movq -0x48(%rbp), %rax
movl 0xb0(%rax), %ecx
orl $0x20, %ecx
movl %ecx, 0xb0(%rax)
jmp 0x222b8
movq -0x48(%rbp), %rax
cmpl $0x0, 0xb0(%rax)
je 0x22263
movq -0x48(%rbp), %rax
movq 0x20(%rax), %rax
testb $0x1, 0x3b(%rax)
je 0x22263
movq -0x48(%rbp), %rax
movl 0xb0(%rax), %ecx
orl $0x200, %ecx            # imm = 0x200
movl %ecx, 0xb0(%rax)
jmp 0x222b6
movq -0x48(%rbp), %rax
movq 0x20(%rax), %rax
cmpl $0x0, 0x40(%rax)
jle 0x222b4
movq -0x48(%rbp), %rcx
movl 0xa4(%rcx), %eax
movq 0x20(%rcx), %rcx
cmpl 0x40(%rcx), %eax
jne 0x2229c
movq -0x48(%rbp), %rax
movl 0xb0(%rax), %ecx
orl $0x100, %ecx            # imm = 0x100
movl %ecx, 0xb0(%rax)
jmp 0x222b2
movq -0x48(%rbp), %rax
movl 0xb0(%rax), %ecx
orl $0x80, %ecx
movl %ecx, 0xb0(%rax)
jmp 0x222b4
jmp 0x222b6
jmp 0x222b8
movq -0x48(%rbp), %rax
movl 0xb0(%rax), %ecx
andl $0x40, %ecx
movb $0x1, %al
cmpl $0x0, %ecx
movb %al, -0x4a(%rbp)
jne 0x22301
movq -0x48(%rbp), %rax
movl 0xb0(%rax), %ecx
andl $0x200, %ecx            # imm = 0x200
movb $0x1, %al
cmpl $0x0, %ecx
movb %al, -0x4a(%rbp)
jne 0x22301
movq -0x48(%rbp), %rax
movl 0xb0(%rax), %eax
andl $0x100, %eax            # imm = 0x100
cmpl $0x0, %eax
setne %al
movb %al, -0x4a(%rbp)
movq -0x48(%rbp), %rcx
movb -0x4a(%rbp), %al
andb $0x1, %al
movb %al, -0x39(%rbp)
xorl %eax, %eax
cmpl $0x0, 0xb0(%rcx)
movb %al, -0x4b(%rbp)
je 0x22323
movb -0x39(%rbp), %al
xorb $-0x1, %al
movb %al, -0x4b(%rbp)
movq -0x48(%rbp), %rax
movb -0x4b(%rbp), %cl
xorb $-0x1, %cl
andb $0x1, %cl
movb %cl, 0xb4(%rax)
testb $0x1, 0xb4(%rax)
jne 0x22352
movq -0x48(%rbp), %rax
movl 0x94(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x94(%rax)
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)