In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-29 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/01 Report--
This article will explain in detail what the status of Task in vxworks is. Xiaobian thinks it is quite practical, so share it with you for reference. I hope you can gain something after reading this article.
As mentioned earlier, in a multitasking system, tasks may have different states, such as Waiting or Ready. In fact, tasks in VxWorks may have many more states, mainly Ready, Pend, Delay, and Suspend. There is also a special state called Stop, as well as various combinations of states.
state
described
Pend
Task is waiting for a system resource (e.g. semaphore, IO)
Delay
The task is waiting for a period of time. It can also be regarded as a resource.
Ready
Task does not need to wait for any resource except possibly for CPU
Suspend
Mission suspended, unable to continue. There are two reasons for suspension:
1 manually suspend, for example by calling taskSuspend();
2 The task is suspended by the system after an exception occurs, such as calling the divide-by-zero operation.
Stop
Tasks are stopped by Debugger or ED&R mechanisms or SIGSTOP signals
Delay+S
Mission delayed and suspended
Pend+S
Task blocked and suspended
Pend+T
Task blocking and delay
Stop+P
Mission blocked and stopped
Stop+T
Mission delayed and stopped
Stop+S
Mission stopped and suspended
PEND+S+T
Task blocked and delayed and suspended
STOP+P+S
Task blocked and suspended and stopped by Debugger
STOP+P+T
Task blocked and delayed and stopped by Debugger
STOP+T+S
Task suspended and delayed and stopped by Debugger
ST+P+S+T
Task blocked and delayed and suspended and stopped by Debugger
Any of the above states +I
The priority of the task is inherited.
The status of the task can be seen in VxWorks Shell via command i:
An application or development tool can change the state of a task by calling system functions, such as taskSpawn(), which immediately enters the Ready queue, while taskCreate() or taskOpen(VX_TASK_NOACTIVATE), which only instantiates in the Suspend queue and then requires taskActivate() to enter the Ready queue.
Common state transition relationships are as follows:
The VxWorks kernel maintains the current state of each task, placing them in separate queues. The task at the front of the Ready queue is the task being executed by the CPU, so the state of this task can be called Executing.
As you can see from the figure above, what is queued in different queues is actually the TCB of each task.
Which task should be at the top of the Ready queue? This involves the scheduling strategy of the system, and we will come to it slowly later.
About "vxworks Task status what" this article is shared here, I hope the above content can be of some help to everyone, so that you can learn more knowledge, if you think the article is good, please share it to let more people see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.