Part Number: AM2434
Hi,
I have been working to migrate to MCELF format as part of migrating to SDK V12. We have four discrete programs, each running on their own core - this has been stable from SDK V8 through V11.
However, I am now having problems with the target crashing (CPU Exception) when loading from flash. I do not see this at all when running from the debugger (nor from booting the same binary in RPRC format with the V11 SBL).
I started by debugging the target using the same method as debugging SBL (wait loop) then stepping through. This all works fine.
When stepping through the code, I saw memory alignment exceptions - this is why the system doesn't boot. However, this turned out to be a complete red-herring but cost me a lot of time:
I eventually noticed that the dissasembly (in a few areas) was quite a different between booting from flash or booting from the debug probe. The dissasembled instructions in the area around the crash were random - it was clear that the program memory was corrupt and would obviously cause the crash.
To prove the memory corruption, I downloaded the raw program memory from of core 0 (0x70080000, length 0x70000 - as per the linker.cmd) for when I ran with the debug probe vs booting from flash. This confirmed differences in the areas that would crash.
I have double-double-double checked all of the linker.cmd files - all program and data memory are properly partitioned. Besides, I never had this problem with pre-mcelf, V8 - V11 SDKs.
So, I am at a bit of a loss of what to do next - except to revert to SDK V11 for now.
Any suggestions?
Thanks, Steve