CLA Code Debugging
1. Insert a breakpoint in CLA code
Insert MDEBUGSTOP instruction to halt CLA and then rebuild/reload
2. Enable CLA breakpoints
Enable CLA breakpoints in the debugger
3. Start the task
Done by peripheral interrupt, software (IACK) or MIFRC register
CLA executes instructions until MDEBUGSTOP
MPC will the have address of MDEBUGSTOP instruction
4. Single step the CLA code
Once halted, single step the CLA code
Can also run to the next MDEBUGSTOP or to the end of task
If another task is pending it will start at end of previous task
5. Disable CLA breakpoints, if desired
• The CLA can halt, single-step and run independently from the CPU
• Both the CLA and CPU are debugged from the same JTAG port
•
CLA single step – CLA pipeline is clocked only one cycle and then frozen
• CPU single step – CPU pipeline is flushed for each single step
Note: When debugging C code, the _mdebugstop() intrinsic places the
MDEBUGSTOP instruction at that position in the generated assembly code