cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
may_powitzer
Visitor
Visitor
430 Views
Registered: ‎08-31-2020

How do I debug FreeRTOS multithreaded application with Vitis?

Hi everyone,

I've seen this question before but couldn't find any solution to the problem.

https://forums.xilinx.com/t5/Embedded-Development-Tools/thread-aware-debugging-of-FreeRTOS-in-Vitis/td-p/1138571

I'm using Xilinx ZYNQ Ultrascale+ (R5 processor) zcu104 board. I opened a UDP server example from LwIP with FreeRTOS.

When I started debugging, a strange problem occurred, both suspend and resume debug buttons are active and I couldn't step in, step out or step over (view the attached pictured).

Sometimes I am able to click on the suspend button and I found out that the code is stuck in an infinity loop inside "Xil_PrefetchAbortHandler()".

When I don't debug my code or not using any breakpoints, the system is working fine and my code runs.

I found out that most of the time when the problem occurred is when I step over but if I step in then I won't happen.

 

Do you have an idea why is it happening? I've seen articles saying debugging FreeRTOS using Vitis is impossible. Hope it's not true.

 

Thank You!

May

 

 

debug_issue_pic.PNG
0 Kudos
1 Reply
shaunpur
Xilinx Employee
Xilinx Employee
194 Views
Registered: ‎10-16-2015

I have stepped through FreeRTOS code w/o issue in Vitis 2020.2.  However, as of now the IDE is not task/thread aware w.r.t. FreeRTOS.

Additionally, see my comments here regarding FreeRTOS trace with STM: https://forums.xilinx.com/t5/Embedded-Development-Tools/thread-aware-debugging-of-FreeRTOS-in-Vitis/m-p/1207332/highlight/true#M57579

0 Kudos