Please note: We are aware of an issue affecting replies on the Arm Community forums, which may not be loading as expected.
We apologize for any inconvenience and appreciate your patience while we investigate and work to resolve the issue.
Thank you for your understanding.
cpu: at91sam7x256
I have in my project some global objects, they are by default placed at address 0x200000. My program seems to work properly but occasionally beginning of RAM is filled with zeros by Keil library function at label: __decompress1 in deassembly window. It makes some my variables and pointers are useles and program stops responding. The worst is, that pointers are defined as const and they are not expected to change.
Any idea how to solve this error?
Why don't you 'push' and 'pop' R12 ?
Because r12 is a scratch register that may be modified by the callee. The caller is responsible for saving it. The SVC (formerly known as SWI) is a synchronous call (unlike an IRQ for instance), i.e. the compiler has to apply the same rules as for a normal function call.
Regards Marcus http://www.doulos.com/arm/