Difference between debug and trace functionality

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Difference between debug and trace functionality

1,342 Views
prachipanse
Contributor III

Hi,

Where can I find the difference between the debug and trace functionalities? What features are present in each?

Regards,

Prachi

Tags (2)
0 Kudos
Reply
2 Replies

1,152 Views
thefallguy
Contributor IV

Debug and trace are two different, but complementary things. Very briefly:

  • Debug allows you to interact with the processor to examine its state while it is executing your application. You can stop, examine registers, peripherals and memory, step through code to examine its effects etc.
  • Trace records certain aspects of what your processor *has done*. That is, the application is running at full speed and trace can be switch on/off to record (for example) what instruction have been executed, and/or what data has been read/written to memory Cortex-M3/M4 have some trace capabilities built into the processor and allow you to trace accesses to a few memory locations and (if the *optional* ETM/ETB is implemented in the processor) the instructions executed. Cortex-M0+ allows some limited instruction tracing via the MTB.

*EDIT*: Note that not all NXP Cortex-M3/M4 parts have the instruction trace capability as the ETM/ETB has not been implemented in the processor. So, LPC17, LPC15 and LPC13 do not have instruction trace, but the LPC18, LPC43 do.

You can find more information here

http://www.nxp.com/assets/documents/data/en/user-guides/LPCXpresso_IDE_Instruction_Trace.pdf 

0 Kudos
Reply

1,152 Views
prachipanse
Contributor III

Hi,

This clarifies. Thank you.

Regards,

Prachi

0 Kudos
Reply