Gary-Hobson commented on issue #16739: URL: https://github.com/apache/nuttx/issues/16739#issuecomment-3788740898
> [@Gary-Hobson](https://github.com/Gary-Hobson): do you have an idea, why you removed the commit ([a84d685](https://github.com/apache/nuttx/commit/a84d685be4de3f84fc866660547c516e199e264f)) from the final version of your PR [#16675](https://github.com/apache/nuttx/pull/16675)? > > Without this commit, the above failure occurs for me. The missing commit fixes this. @sumpfralle You can temporarily replace the implementation of __gnu_mcount_nc for now. I will submit a formal patch later and supplement it with documentation and usage examples. ```asm __gnu_mcount_nc: #if defined(CONFIG_ARCH_CORTEXM0) || defined(CONFIG_ARCH_CORTEXM23) /* Cortex-M0/M0+/M23 - ARMv6-M and ARMv8-M Baseline */ /* These cores only support limited Thumb-1 instruction set */ push {r0, r1, r2, r3, lr} /* Save registers */ mov r1, lr movs r2, #1 bics r1, r2 /* R1 contains callee address, with thumb bit cleared */ ldr r0, [sp, #20] /* R0 contains caller address */ movs r2, #1 bics r0, r2 /* Clear thumb bit */ bl mcount_internal /* Jump to internal _mcount() implementation */ pop {r0, r1, r2, r3} /* Restore r0-r3 */ pop {r1} /* Pop saved lr into r1 */ bx r1 /* Return to caller */ #else /* ARMv7-M/A/R and higher - Full Thumb-2 support */ push {r0, r1, r2, r3, lr} /* Save registers */ mov r1, lr bic r1, r1, #1 /* R1 contains callee address, with thumb bit cleared */ ldr r0, [sp, #20] /* R0 contains caller address */ bic r0, r0, #1 /* Clear thumb bit */ bl mcount_internal /* Jump to internal _mcount() implementation */ pop {r0, r1, r2, r3, ip, lr} /* Restore saved registers */ bx ip /* Return to callee */ #endif ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
