This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Is there more I can get from Task view

I have a task that is running off (I suspect corrupted data and endless loop). I have my own watchdog system that is resetting, this is called from a PRD (SWI) context. Using the ROV task view I can see my TSK that was running at the time. It is the task I suspected - great. I can see there is no SEM deadlock etc, so as I suspect this task is in endless loop. The ROV TSK view only tells me memory usage and basic state of the task (running/blocked/ready etc).

The CCS debug window also shows the current thread, which in my case is the PRD_F_swi() calling my watchdog. I can click this and highlight the line of source code. Is there anyway I can get this level of debug for the other threads, for example can I see the same for my tasks (running or blocked).

I really hope there is a nice way integrated into CCS, or do I have to manually decipher the task context objects to find their program/instruction pointer?

Details: BIOS 5.41.09.34, C55xx, CCS 4.2.0.10017

 

  • Unfortunately, ROV can't currently tell you the current instruction pointer for each TSK in your system. This would be nice, though! 

    Here are some suggestions, though:

    - The TSK view does contain a 'blockedOn' field which will hopefully tell you what object your TSK is blocked on. That may be enough to tell you where each TSK is currently sitting.

    - Using RTA or the LOG view in ROV, you can view the BIOS events showing you when TSK switches occurred, when HWIs and SWIs started and stopped, etc. This data may help you piece together the current state of the system. You could also drop your own LOG_printf statements into your code to the same affect.

    Thanks,

    Chris

  • Chris,

    So ROV wont help me. What about the general debug view window. It shows the current thread, its call stack, and you can click on the call history and the code view updates to the source line, the local watch view loads local variables etc. This is great, but as above only on the current thread. Is there any way to load other threads into this?

    Regards,

          Ben

  • I don't think so. I think the debug manager can display the call stack because it knows the current value of the program counter and stack pointer registers. Displaying this information for other threads would require OS-specific knowledge, though, so it's a feature that BIOS would have to provide through ROV or some other tool.

    Chris

  • > Unfortunately, ROV can't currently tell you the current instruction pointer for each TSK in your system. This would be nice, though! 

    Is this _still_ true (CCS 5.3.0)?  I'm trying to figure out what's going on with some code (not written by me) and a task is staying constantly READY, never suspending, and I need to know where it is 'executing'.  Not being able to obtain the program counter for that task is going to cause me a lot more work (especially since the code works for ~1 minute before getting into this state).  It's also very frustrating, because it seems obvious that ROV must be able to figure out what the program counter is (after all, it knows what the stack pointer is).