|
|||||||||||
Technical Support Support Resources
Product Information |
ARM: Warning: Event Recorder not Located in Uninitialized MemoryInformation in this knowledgebase article applies to:
SYMPTOMI am using the Event Recorder to debug my application. That works ok, but after updating to Keil MDK 5.25 pre-release 2 or newer, I receive the following message in the command window, when starting a debug session: Warning: Event Recorder not located in uninitialized memory! What is the problem with this? CAUSETo make sure the Event Recorder displays correct data, especially after the target was reset, certain control structures of the Event Recorder must not be initialized when the target boots up. When the debugger finds these control structures initialized in your application, the above warning displays. RESOLUTIONConfigure your project so that the Event Recorder control structures do not get initialized by your application. This can be done by editing the linker scatter file, or in µVision if you don't use a custom scatter file in your project. In the Options for Target ... -> Target dialog decrease one of the RAM ranges where default is checked, e. g. IRAM1, by 4kB for example. The actual size depends on how many records are to be buffered in the EventRecordConf.h file. Then fill in this freed range in another range, e. g. IRAM2, and make sure the NoInit option is checked. Close the dialog with OK. Then select in the Project Window the file Compiler -> EventRecorder.c to open the context menu for it and select Options for Component Class 'Compiler'. On the Memory tab configure Zero Initialized Data away from default to IRAM2, the range where previously the freed range was added. Close this dialog also with "OK". Then rebuild the project. The changes can be verified by examining the scatter file generated by µVision. The scatter file should look something like this: ; ************************************************************* ; *** Scatter-Loading Description File generated by µVision *** ; ************************************************************* LR_IROM1 0x1A000000 0x00080000 { ; load region size_region ER_IROM1 0x1A000000 0x00080000 { ; load address = execution address *.o (RESET, +First) *(InRoot$$Sections) .ANY (+RO) } RW_IRAM1 0x20000000 0x0000F000 { ; RW data .ANY (+RW +ZI) } RW_IRAM2 0x2000F000 UNINIT 0x00001000 { EventRecorder.o (+ZI) } } Notice the UNINIT attribute in the RW_IRAM2 region. If you use a custom scatter file, make a similar modification to that file to place the event recorder code module in an uninitialized region. STATUSThe detection mechanism is specific to the Arm Compiler toolchain. If you use a different compiler toolchain, the debugger can't warn you correctly, whether the Event Recorder control structures are initialized in the project or not. MORE INFORMATION
SEE ALSOLast Reviewed: Thursday, November 12, 2020 | ||||||||||
|
Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.