tags:

views:

79

answers:

3

We have one task who State is Ready+I . Can we find which task is it waiting for to release all semaphores? This is pre-6.0 vxworks

A: 

If I understand your question, you have a task that is inheriting the priority of some other task and you are having trouble identifying this other task. I don't recall if the i WindSh command prints the inherited priority but if it does that might give you a clue about which of the pended tasks you should look at. Once you've narrowed it down to a couple tasks you should be able to use the tw command to print information on what object a task is pended upon.

On a side note, why are you concerned about priority inheritance? After all priority inheritance isn't a problem, rather it is the solution to priority inversion.

Tim Kryger
Yes, the `i` command does print the inherited priority.
bstpierre
+1  A: 

If you can get a backtrace from the task, you should see it blocked on some kind of system entity, e.g., a semaphore. You can look at the arg list printed in the backtrace, and then use semShow from the C shell to get information about that semaphore. Other system synchronization entities offer similar *Show routines.

Presuming that the entity supports the concept of an "owner", semShow should display the TID of the owner.

Chris Cleeland
A: 

Under the older, Tornado-based systems, the WindView tool will allow you to see the relationship between tasks over time. WindView can show all your task state transitions, interrupts, semaphore operations, etc.

For newer, Workbench-based systems, the same tool is now called System Viewer.

WindView/System Viewer is the deluxe way to investigate any problem you are having with task states and how they got that way.

Jamie Cox